How to fix Netbeans 7.4 (and Netbeans 8.0) Ugly Text and Popups in Ubuntu 13.10? I've tried various workarounds, but I haven't yet found a way to make the fonts in Netbeans look right. I've tried changing the config files of Netbeans, and trying the instructions here that don't seem to have any effect since they aren't installed in 13.10.

My specific question has three parts: 1) why is every font 18 or less drawing characters with lines that are only one pixel thick, and the . and : are making only one pixel on the screen - unless I force bold, or a huge font of 19 or more:

(If this is a Java problem, why is Eclipse fine?)

Bad font, thin and not easily readable

Almost okay font - but HUGE:

If you look at the terminal or native Ubuntu apps they don't show up as only one pixel - is there a solution for this?

2) Why does Netbeans show a box at the end of the line, when text is too long and overflows to the next displayed line?

3) Maybe not related, but why do popup-windows of Netbeans have this small dropdown below them? This happens both with the netbeans-starting info window, and the git changes popouts from the bar with the line-numbers.

Ugly git integration showing changes:

Update

No change in 8.0, unfortunately :(

1. Fonts

I searched a bit on this issue, but I didn't find a way on how to make the fonts "bolder". The issue does not seem to be Ubuntu 13.10-specific however. The link you refer to is about another bug, that actually makes some text a bit thicker. (see below)

I did find some things that can help you, I do not know if you will find them better, feel free to try them.

Make it use system fonts in menu and other places

This bug actually makes a lot of the text nicer in my opinion. Just sudo apt-get install fonts-unfonts-core and restart netbeans. (only works with JDK7) It will look like this:

However, this does not change the editor font.

Change theme

Changing the theme changes the fonts a bit, however, it does not make them thicker.

gedit ~/netbeans-7.4/etc/netbeans.conf

And add --laf Metal to the netbeans_default_options

The default theme is "GTK". I like "Metal" myself. you can find a complete list of themes on the netbeans website

Other options

i have not tried it out myself but this answer seems promising. Let me know if it looks better...

2. Overflow

I do not understand what you mean. Maybe a screenshot would help?

3. Weird windows that have wrong size, wrong shading

Seems to be a bug in java. If i use JDK6 it is actually way worse...

Go to Tools > Options. Select the appearance tab and choose the preferred look and feel to Metal. See if it fixes the theme and fonts.

If you like to have a darker theme, go to Tools > Plugins and install "Darcula LAF for NetBeans".


Play on Linux, Steam Games I have installed PoL and I have also installed Steam.  I want to use the Windows client rather than the Linux client because I doubt very much the games I have will be available on Linux client yet.

Anyway, I have heard that I should use different prefixes for EVERY game/application I install.  What's the best way to do this for Steam games?

Well, not alot of games will run through playonlinux and then with Steam, the only Windows/Mac game that I've seen that ran on linux for play on linux and then steam is "haunted"  And the graphics were great with 760 GTX, everything looked really pretty.  Unfortunately haunted is a game like Myst which really isn't my thing.  But if you like Myst, download haunted through play on linux, and then steam.  If you purchase crossover, you can use that and run some more games that won't run otherwise.  One game you can run with crossover is Rift if you run crossover with steam, and you can play that at max graphics also flawlessly.  If you like free games, you should try World of Warcraft at the molten wow website.  Oddly enough World of Warcraft runs flawlessly with the newest wines, it's really pretty cool.  And it runs like it does in Windows, yay.  Unfortunately the GMs there are a tad unfair, I was permabanned from it after I had 3 accounts that were worth 70 million gold; even though I wasn't running any cheats or exploits bans are not appealable.  But, so far that has been the best gaming experience I've had in Linux, and WoW is a great game.  Just watch the number of auctions you're keeping reposted, and don't have a private guild bank because apparently that looks suspicious and they can get confused and ban you for it.


How to map wacom correctly to monitor I am using Ubuntu 12.10 and I am running dual screens(23inch and 15 inch). I have a wacom intuos 2 9x12 that will will not map correctly to my second monitor which is also 9x12(1400x1050). The reason I need to solve this is because I have created a homemade cintiq and I draw on the screen (you can see what I'm talking about here: http://forum.bongofish.co.uk/index.php?topic=2096.0). The pen matches quite accurately on the x axis of my screen, so I believe the width of my wacom tablet area is okay. I think the problem is the y axis of my wacom. The cursor matches my pen towards the bottom of the screen, but as I move to the top of the screen, the distance from my pen tip to the cursor increases(the cursor is about 1 inch below pen when at top of screen).

I have looked on the Internet for hours trying to find a solution and I cannot find any.

Also, I want to say that this problem only happens in Ubuntu, I also have Windows 7 installed, and the wacom matches the screen perfectly. I'm also a complete noob to linux so I don't know much about navigating terminal.

First, determine how your system recognizes your tablet.
In a terminal enter: xsetwacom --list devices

  Wacom BambooPT 2FG 4x5 Pen stylus id: 10  type: STYLUS
  Wacom BambooPT 2FG 4x5 Finger touch    id: 11  type: TOUCH
  Wacom BambooPT 2FG 4x5 Pad pad     id: 12  type: PAD
  Wacom BambooPT 2FG 4x5 Pen eraser  id: 17  type: ERASER

Next determine which display or "output" to map your tablet to in your systems display settings or in the terminal with xrandr --listactivemonitors
on my system that shows:

  0: +*HDMI-2 1920/521x1080/293+1600+0  HDMI-2
  1: +HDMI-1 1600/443x900/249+0+0  HDMI-1

Finally, using the information you just gathered, use
xsetwacom --set "[YourWacomDevice]" MapToOutput [your display] (repeat for each device listed ).

[YourWacomDevice] = device name or id:#

so, for me that would be

  xsetwacom --set "10" MapToOutput HDMI-2
  xsetwacom --set "11" MapToOutput HDMI-2
  xsetwacom --set "12" MapToOutput HDMI-2
  xsetwacom --set "17" MapToOutput HDMI-2

Since these settings aren't kept after a reboot, you may want to save them in a script that runs on startup.

Using xsetwacom --help lists possible options and commands. With the --list parameters command, we can see a list of all the supported parameters. Near the end of that list is MapToOutput      - Map the device to the given output.

man xsetwacom will display it's manual entry or you can read it here

for more information about identifying and configuring displays with xrandr read this question

Thanks to @RyanWC and @user1355 for pointing me in the right direction.

This may be a little late, but I just made a simple python script that will rotate which monitor your device is bound to. Currently, Linux is the only OS supported, but you can make pull requests. You can find it here:
wacom-input-screen-switcher

  A python program to change what screen your tablet is mapped to.
  Usually invoked by a button on the tablet. Linux is currently the only
  OS supported. You will need to install screeninfo with pip for it to
  work. I currently do not have an automated install script for that.
  You will need to install it for python3 since that is what this code
  uses.

pip install screeninfo

  Example of key binding:

  In a startup script issue the command:

xsetwacom --set <id or name of device pad (of "type: PAD") here> button 2 key XF86WWW

  Then have your system run wiss.py when you press that button.


How to execute a script as super user first checking the user and getting pass from askpass if not super user thers a similar question out there How can I determine whether a shell-script runs as root or not?

I have the same doubt with different result

Is it possible to, within the BASH script prior to everything being run, check if the script is being run as superuser, and if not, print a message saying You must be superuser to use this script, then subsequently

get pass from the user using askpass or something like that then execute the same script as superuser?

I just call sudo if the program needs root permissions, but doesn't have:

#!/bin/bash
if [ $(id -u) != 0 ]; then
   echo "This script requires root permissions"
   sudo "$0" "$@"
   exit
fi

"$0" contains the name of the script, "$@" optional arguments. It may be omitted if your program does not accept arguments.

Note: this shellscript is expected to be run in a shell, if this script should run as GUI, use something like gksu or kdesudo instead of sudo.

this does not work although Lekensteyn is right on point.

you have to set the variable equal to the output of id -u

ID=$(id -u)
if [ $ID != 0 ]
then
sudo "$0" "$@"
exit
fi

if you use echo to output this script requires root permissions that will show up every time a user other than root(since its id=0) runs the script regardless of whether or not it needs root permissions, so just keep it simple.


Is there a way to block the use of swap memory for a specific program? I'm trying to maximize the performance of a game, and if it access to the swap memory the fps drops.
Is there a way to "block" the swap memory for a specific program? For the moment i reduce the swappiness value until the use of ram is not enough for start to use the swap, but it is highly unstable, also my pc is a low-end one it has 2gb ram, when i start the game only the ram hits the 95% also i put the game in -20 niceness so the freezing possiblity grows a lot.
Any help is good help :)

The operating system has no provisions to allow you to indicate selectively what processes can be swapped and what cannot. What you did is the best you can do: decreasing swapiness. To make sure your game does not use swap, you could temporarily disable swap (sudo swapoff). Based on your description, however, your system will then likely crash because it probably will run out of memory. With swap, it will not crash, but eventually start to be very slow, because chunks of physical memory are swapped back and forth to the much slower hard drive.
End conclusion: run a less memory consuming game or buy more physical RAM.


Connection refused when Host OS(Ubuntu) telnet the Guest OS(Windows XP) of the Virtualbox I can't telnet the Guest OS(Windows xp) in my ubuntu machine but I can successfully ping its IP address.

In the network settings of guest os, I enabled two adapters. Here are the  the settings of the two adapters.

For the first adapter:

Attached to: NAT
Adapter: Intel PRO/1000 MT Server(82545SEM)
Promiscuous Mode: Deny
Cable Connect: enabled

For the second adapter:

Attached to: Host-only Adapter
Name: vboxnet0
Adapter: Intel PRO/1000 MT Desktop(82545SEM)
Promiscuous Mode: Deny
Cable Connect: enabled

I added port 1234 in the Exceptions of Windows Firewall Settings in guest OS just for testing. I can ping the IP Address and ssh the Host OS.

This is the result when I executed the telnet command.

user@micmic:~$ telnet 192.168.56.101 1234
Trying 192.168.56.101...
telnet: Unable to connect to remote host: Connection refused

Make sure you installed the following packages:

sudo apt-get install ssh
sudo apt-get install telnetd-ssl
sudo apt-get install openssh-server


scripting chroot, how to? So I'm looking at:

https://help.ubuntu.com/community/LiveCDCustomizationFromScratch

and trying the following within a bash script:

sudo chroot chroot

mount none -t proc /proc
mount none -t sysfs /sys
mount none -t devpts /dev/pts

Running the script drops to a shell at sudo chroot chroot. When I exit that I get the expected warnings about mount needing root. Is there a way I can keep all this within one shell script?

Edit: I want this to be a repeatable process, which is why I want to script the whole thing rather than type it in time and time again.

Create a second script (e.g. chroot.sh) and place it in your chroot/ folder.

Now edit the command in your original script to this:

chroot chroot/ ./chroot.sh

Now the script chroot.sh will be executed inside your chroot.

I think it's not saying that you should put those commands into a script, but that you should type them; i.e., type the mount commands into the sudo shell.


How do I restore two finger middle click again? it used to be that tapping two fingers on the touchpad send a middle mouse click. Now it does a right click and three fingers now are the middle click. I really can't understand the change and think it is a bug or badly copied from Apple or something. The reasoning escapes me totally.
I use middle click to open links in a new tab in the browser all day and I rarely use right click (and I have a right mouse button below the touchpad, doh)
Tapping three fingers on my tiny EeePC touchpad is next to impossible so I want the old behavior.
I found:

synclient TapButtons2=2
synclient TapButtons3=3

but that did not work on 10.10

Does anyone know how to restore sane behavior?

The default settings that seem to be enabled with "tap to click" (on my laptop anyway) also provides the following functionality:

Middle Click (tap at top right of scroll area)
Right Click (tap at bottom right of scroll area)

synclient TapButton2=3 TapButton3=2

key named according to number of fingers, value indicates mouse button number.


How to open .mrc files I've just downloaded some .mrc files. But I couldn't find the right application to open it. I'm using Ubuntu 11.10 What application should I have to open them?

I would try opening a file in gedit or another plain text editor.

Assuming these are very small files (2 kilobytes or smaller), they are usually mIRC script files, for use with the Windows IRC client of the same name.


After upgrading from13.10 to 14.04 screen on a laptop doesn't work but First my laptop CPU/GPU is Intel Celeron N2815 (Bay Trail) and I am in dual boot with windows 8.

I have upgraded from ubuntu 13.10 to 14.04 today through update manager. And after upgrading and after booting the only thing that happens is that screen doesn't show ubuntu logo for booting and that at some point it turns off. Also then I hear ubuntu sound when it comes to login screen. The screen doesn't turn on after that. (Also I have to tell you that I tried to install ubuntu 14.04 from USB and that there was the same problem. It asked me what I want to do (Try or install ubuntu) and it doesn't matter what option I selected the result was the same.)

Then I decided to try some stuf. First I tried to bootup with Ubuntu with Linux 3.11.0-19-generic. And it went well. The screen was working and everything was fine. Then I decided to try to hook my desktops screen on laptop via HDMI and right away it worked. Both screens were on and I had two screens. So I went in System Settings -> Displays and there saw 3 screens. Built-in Display, my secondary desktop display and unknown display. In 13.10 I had to turn of Unknown Display because all the workspaces were size of built-in display + Unknown Display so I didn't saw my edges.

Now that I know that my graphics drivers work and everything is fine, I tried default booting in ubuntu. Still connected to my desktop display via HDMI it started booting and booted. But the problem was that only desktops display was working. Laptops display was off. So happily I again went into Display settings only to notice that I only get two displays. Desktops and some other with strange unfamiliar name: Chi Mei Optoelectronics corp. 15,6" (I will add screen shots :) ). This other screen was on and should somewhere work but not on laptop. As far as I can remember Laptops screen was always named Built-in Display (in 12.04 and 13.10). And I never had the same problem.

So now I have some questions.
What is the difference between: Ubuntu with Linux 3.11.0-19-generic and 3.13.0-24-generic (I don't know much about Linux as I am new to this stuff. But I know a thing or two about computers.)? Is this different kernels?
Also I want to know if there is important difference between and if it is important which one I use to run ubuntu. Of cours I want to use default one as I don't want to wait every time to ask me. And of course I would be very grateful if anyone will take time and try to help me.

Thank you for your time :)

Ubuntu with Linux 3.11.0-19-generic:

Default boot:

P.S. I can't upload images because I don't have reputation 10.

So I went in System Settings -> Displays and there saw 3 screens.
  Built-in Display, my secondary desktop display and unknown display.

Probably bug #1244827 "Ubuntu detects a non-existing screen"

  What is the difference between: Ubuntu with Linux 3.11.0-19-generic
  and 3.13.0-24-generic (I don't know much about Linux as I am new to
  this stuff. But I know a thing or two about computers.)? Is this
  different kernels? Also I want to know if there is important
  difference between and if it is important which one I use to run
  ubuntu.

Yes, these are different kernels. In general, you should always use the most recent kernel, which is the one with the highest version number. But if there is some bug in the most recent kernel, then feel free to boot an older one if that works.

  So happily I again went into Display settings only to notice that I
  only get two displays. Desktops and some other with strange unfamiliar
  name: Chi Mei Optoelectronics corp. 15,6"

The Chi Mei display is your internal laptop screen. You can tell this from the fact that it is the only other screen, and it is 15.6". The fact that it is not being detected as the "Built-in Display" is probably a bug.

I suggest that you download the latest Ubuntu image (ubuntu-14.04-desktop-amd64.iso) and boot from it with your external monitor disconnected. Check whether your internal display works. Then connect the external monitor and enable it in the display settings. This will eliminate the possibility that your problems are being caused by any old config files from Ubuntu 13.10 that are still present on your system.

It sounds like a backlight issue. You may try this fix.


How do I disable overlay scrollbars? It looks like Ubuntu 11.04 will come with overlay scrollbars by default. I do like them, but I don't like the current mix of scrollbar types as many applications don't yet use those overlay scrollbars.

Is there a way to disable overlay scrollbars (without removing the overlay-scrollbar package)?

In 12.04 LTS there's a slightly cleaner way to do it. Just run

gsettings set org.gnome.desktop.interface ubuntu-overlay-scrollbars false

in a terminal. Apps opened afterwards will have the non-ayatana scrollbar.

To get the default behavior back, run

gsettings reset org.gnome.desktop.interface ubuntu-overlay-scrollbars

If you are using 12.10 or later, run

gsettings set com.canonical.desktop.interface scrollbar-mode normal

And to return to the default, run

gsettings reset com.canonical.desktop.interface scrollbar-mode

I was able to get rid of the overlay scrollbars using dconf-editor, by setting:

com.canonical.desktop.interface.scrollbar-mode='normal'

(Caveat, not sure about stepper buttons.)

Intuitively, if 'off' is normal, shouldn't it be the default? Someone deemed 'overlay-auto' the default. Just thankful to be rid of this horrifically unhelpful 'feature'. It cost me about two hours to find a solution. Hope to resolve the stepper-buttons issue based on the above information (thank you).


Someone accessed my computer and somehow disabled the Ubuntu bootloader. How can I get it back? I recently installed Ubuntu alongside Windows 10 on my Thinkpad. However, some idiot (who didn't know my password) accessed my computer while I was gone and must have messed with something because when I got back and opened my laptop, I had to type in my Bitlocker recovery key.

Now, instead of showing me an option to boot Ubuntu or Windows, it just goes directly to Windows (after the Thinkpad BIOS screen, of course)

This is really weird considering that all the guides on the Internet for uninstalling Ubuntu (that I could find) required a Windows Recovery disc.
How can I get back the Ubuntu bootloader?

The bootloader used in Linux and Ubuntu specifically is Grub

Boot from Ubuntu live USB , and follow the instructions for live recovery on failed update . It will allow you making changes to the system while booting from live USB. Essential steps are:

Boot the Ubuntu Live CD.
Press Ctrl-Alt-F1
sudo mount /dev/sda1 /mnt
sudo mount --bind /dev /mnt/dev
sudo mount --bind /proc /mnt/proc
sudo mount --bind /sys /mnt/sys
sudo chroot /mnt

Finally , you should be able to run sudo grub-install /dev/sdX where /dev/sdX is your hard drive. If you are not sure which one it is sda or sdb , run  the df or lsblk command and check which disk size corresponds to which device.

Sidenote: consider also changing  your passwords, just in case someone did break into your OS

You just need to make a bootable USB device. After that choose try ubuntu option. Then download boot repair & do the boot repair.visit this question
After above steps, reboot your system. You will get your boot menu back.


external hard drive not detected UBUNTU 12.10 My 1 TB external hard disk is not detected by Ubuntu 12.10.

**lsusb:**

Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0c45:6409 Microdia Webcam
Bus 002 Device 003: ID 046d:c03d Logitech, Inc. M-BT96a Pilot Optical Mouse
Bus 002 Device 004: ID 046d:c315 Logitech, Inc. Classic New Touch Keyboard
Bus 002 Device 007: ID 059b:0070 Iomega Corp.

**sudo fdisk -l:**

Disk /dev/sda: 640.1 GB, 640135028736 bytes
255 heads, 63 sectors/track, 77825 cylinders, total 1250263728 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0006ec0d

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048  1242566655   621282304   83  Linux
/dev/sda2      1242568702  1250263039     3847169    5  Extended
/dev/sda5      1242568704  1250263039     3847168   82  Linux swap / Solaris

**sudo blkid:**

/dev/sda1: UUID="9d449e79-8917-497f-aa4c-59fb3bcb21ee" TYPE="ext4"
/dev/sda5: UUID="ea2d407e-0b84-4d6e-9004-5b3536a899fd" TYPE="swap"

is the Hard Disk formatted with an MBR? some stock hard disks require formatting for use, but either way the driver should have been installed. if the disk came with a CD, use the cd to install the validation drivers. If it didnt, you may have a defective disk, or your memory controller is malfunctioning (most likely not but its still a scenerio). check with the manufacturer of your computer (Dell, HP, PowerPC ect) and ask for specs concerning how much physical memory the system can handle. Basic run through, check your device ports and drivers (and if the HDD has a power supply, make sure its plugged in).
references: I repair computer hardware and program software for over 8 years
Hope this helped you :)

Run in terminal:

dmesg

this will display the kernel messages, in my case I was having a problem with my hub:

hub_port_status failed (err = -110)

I connected directly and it worked like a charm.

Cheers!


MAAS 1.9 can't deploy OS I recently upgraded my MAAS server and found myself with MAAS 1.9.1+bzr4543-0ubuntu1. I saw that the old version of MAAS that I had been running was no longer supported, so no great loss there.

Unfortunately, every time I try and deploy Trusty to a node, it fails with the console message "DataSourceNotFoundException: Did not find any data source, searched classes: ()" on the node and the MAAS server eventually times out the deployment.

My system configuration is both very simple, and probably quite different from a common MAAS installation. In particular, I am not using the optional DNS and DHCP modules because I already have a perfectly good DNS and DHCP system. This worked great in 1.8, but I guess something has gone wrong in the new fancy network framework.

I can reproduce this easily with the following steps:

apt-get install maas
maas-region-admin createadmin ...
Power on the node to enlist it - that works
Commission the node - that works
Deploy Trusty to the node - that doesn't
Scratch head when the deployment fails

My MAAS server is 10.0.1.51/24, the nodes I am deploying are on 10.76.0.0/23, and I have a DHCP server that directs the PXE boot to fetch the PXE boot files from the MAAS server.

This all used to work fine with 1.8. Does anyone have any ideas about what might need to be poked or prodded to allow deployments to work?

Thanks

I have found the best way to figure out what is failing is to SSH to a node while it being commissioned and to check /var/log directory. There is a log for a cloud-init script. If that part did complete correctly then look for /var/log/juju and the logs inside it will give a you a clue on what might be failing.

You may expect quick and perfect answers if you post an issue in https://github.com/Ubuntu-Solutions-Engineering/openstack-installer


Why no menu bar in LibreOffice When you move your cursor to the top of the screen in Libreoffice you don't get a menu.  You do for other applications like Firefox and Thunderbird but not for Libreoffice.

Try:

  sudo apt-get remove libreoffice-gtk

It will remove the global menu bar and replace it with a basic one, but it might give you functionality. That worked for me anyways.

You can also try getting updates - there may have been a bug fix for it:

  sudo apt-get update

Or just use the GUI updater.

(I know this is an old question but happened to me again now)

For me, changing the Java Runtime fixed the problem, instead of using the Oracle one I choose the Ubuntu and the bar appears again.


Is there a software for writing anywhere on the system with a pen/stylus on the touchscreen? I'd like to write on top of my PDFs used for making presentations on my laptop with touchscreen. I do not need to save what I write, but I would like to circle or underline things, possibly write some equations, etc. and then erase them and move on.

Drawing tablets bring software of the sort I speak. Anything out there I could use with my Ubuntu 14.04? Thanks!

Since this question still comes up in the latest search results I want to let you know that it's possible to do more than one Freehand stroke with Okular.

You just have to double click the annotation icon (for example freehand stroke). This also works for the Highlight and Other Annotation Tools as well.

However, I still could not find out how to use the pen only for annotating and the touch screen for navigation through the document...

Unfortunately the freehand annotation for Okular allows only one continuous line at a time. Cannot write with a pen with Okular.

Allowing pen writing on Okular would be a killer feature for the program. Until that is implemented, I'm opening PDFs in Xournal, which is an amazing, stable, powerful notetaking program in its own right


Installing scipy in Ubuntu So whenever I try

pip install -U scikit-learn

I get:

ImportError: libatlas.so.3gf: cannot open shared object file: No such file or directory

I made sure I have atlas-base in my /usr/lib/ dir. What am I doing wrong?

Edit: clarifications, I'm doing this in a virtualenv.

Edit 2: Someone suggested me to use sudo apt-get install python-scipy and this is what I get when I try to import:

>>> import sklearn
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/scikit_learn-0.13-py2.7-linux-x86_64.egg/sklearn/__init__.py", line 32, in <module>
    from .base import clone
  File "/usr/local/lib/python2.7/dist-packages/scikit_learn-0.13-py2.7-linux-x86_64.egg/sklearn/base.py", line 9, in <module>
    import numpy as np
  File "/usr/lib/python2.7/dist-packages/numpy/__init__.py", line 137, in <module>
    import add_newdocs
  File "/usr/lib/python2.7/dist-packages/numpy/add_newdocs.py", line 9, in <module>
    from numpy.lib import add_newdoc
  File "/usr/lib/python2.7/dist-packages/numpy/lib/__init__.py", line 13, in <module>
    from polynomial import *
  File "/usr/lib/python2.7/dist-packages/numpy/lib/polynomial.py", line 17, in <module>
    from numpy.linalg import eigvals, lstsq
  File "/usr/lib/python2.7/dist-packages/numpy/linalg/__init__.py", line 48, in <module>
    from linalg import *
  File "/usr/lib/python2.7/dist-packages/numpy/linalg/linalg.py", line 23, in <module>
    from numpy.linalg import lapack_lite
    ImportError: /usr/lib/liblapack.so.3gf: undefined symbol: ATL_chemv

Edit 3: After fixing some dependencies issue with numpy, I now get:

   import fblas
ImportError: libatlas.so.3gf: cannot open shared object file: No such file or directory

To get the dependencies try
sudo apt-get install python python-dev libatlas3-base-dev gcc gfortran g++
Also, you should check that numpy is up to date:

>> import numpy
>> numpy.version.version
'1.6.1'

(for example). I think you want numpy > 1.5.0 for the latest scipy distribution.
Then you can try the sudo apt-get install python-scipy command suggested in the other answers.

I can work by

echo "/usr/lib/atlas-base" | sudo tee /etc/ld.so.conf.d/atlas-lib.conf
sudo ldconfig

Thanks for this thread:
https://unix.stackexchange.com/questions/52703/using-atlas-from-scipy


PCManFM custom directory icons I'd like PCManFM to show custom icons for my work folders;

for example to show the AndroidDev folder in this picture (italian locale here):

like this (Gimp used):

I saw the other folder icons are located in the /usr/share/icons/Humanity/places/ directory; for example the Image folder icon is folder_images.svg (or folder-images.svg).

How do PCManFM knows that for "Immagini" folder he has to use the folder-images.svg icon?
How can I instruct PCManFM to use for "AndroidDev" folder the folder-myicon.svg?

Install the package xdg-user-dirs and then run xdg-user-dirs-update. This will create the configuration files that will allow your icon theme to use the special folder icons.

See the Arch Wiki for more info https://wiki.archlinux.org/index.php/Xdg_user_directories


XUbuntu: Make Shift+NumPad work like Windows Ok, I've used Ubuntu with GNOME for a while, but now I'm using XUbuntu. In Ubuntu, there used to be a keyboard preference which makes the numpad more sane, it was called something like "Make Shift+NumPad work like Windows".

The problem this options solves is, that when you press NumPad 7, it acts like the "Home" key, which is all fine, but if you press Shift+NumPad 7, it acts like the "7" key, which is not fine because I'm on a laptop and the regular "Home" key requires me to pull of an anatomically insane move. Anyways, this option made Shift+NumPad 7 act like the "Home" key.

I can't find that option under XUbuntu. How do I set it?

Update: GUI or command line, doesn't matter.

After some grepping I found the solution: You need to add the numpad:microsoft option to the XkbOptions. On older Ubuntus, do that in your xorg.conf. On newer ones open the file /etc/default/keyboard and change this line:

XKBOPTIONS=""

to

XKBOPTIONS="numpad:microsoft"

Save and reboot (restarting X doesn't seem to work, at least not with RAlt+PrintScreen+K). You may need to run sudo dpkg-reconfigure keyboard-configuration for changes to take effect.

For me 'keypad:pointerkeys' option helped on Lubuntu 18.04 Bionic Beaver


How can I resize an ext root partition at runtime? How can I increase the size of the root partition of a system at runtime?

I have a partition that is not allocated after the root partition (which is also ext4), how can I add that unallocated space to the space allocated to the root partition without having to shutdown the server?

GUI (Ubuntu 14.04 and later):
GParted v0.17 and later provide a nice GUI for this. (Older versions will refuse to resize a mounted partition).

Command line (any Ubuntu version):
There are three steps to this.

Step 1.
The partition must first be resized. If you're using LVM, it's easy, and you presumably know how to proceed. If you're using classic partitions, it's a bit more complicated, and may require a reboot (though you never have to boot another system or live CD).

This is how I do it: Use fdisk to first delete the partition (the idea is that the data on disk will be preserved), then carefully recreate it with a larger size at the same position.

Example:

$ sudo fdisk /dev/sda

Command (m for help): p

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048     9437183     4717568   83  Linux

Command (m for help): d
Selected partition 1

Command (m for help): p

   Device Boot      Start         End      Blocks   Id  System

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4, default 1): 1
First sector (2048-10485759, default 2048):
Using default value 2048
Last sector, +sectors or +size{K,M,G} (2048-10485759, default 10485759):
Using default value 10485759

Command (m for help): p

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1            2048    10485759     5241856   83  Linux

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.

WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table. The new table will be used at
the next reboot or after you run partprobe(8) or kpartx(8)
Syncing disks.

Again, it is critical that the new partition starts at the same block as the old. The Id should also match (83 for Linux systems). Be prepared to lose all your data at the slightest typo.

To be on the safe side, you may also restore the boot flag (which according to Wikipedia is still required on some computers) by pressing a.

See the comment section for what to do if your swap partition is in the way.

By now it should be apparent why people recommend using a live CD. ;-)

Step 2.
As fdisk helpfully reminds you, you must reload the partition table before proceeding. The safest way is to simply reboot; but you can also use partprobe or kpartx (more information).

Step 3.
Once the partition is resized and the partition table reloaded, it's a simple matter of running resize2fs on the file system, and you can do this even when it's mounted as the root partition.

Example:

$ sudo resize2fs /dev/sda1

As stated before:

expanding live from a root system is possible.(no difficulties, as the boot section ain't to be moved)
shrinking a live root partition needs to be done from external boot device (boot from live system cd/usb-stick), as if there’s any fault, mismatch ..whatever..your system hangs, needs to be rebooted and will eventually not be able to boot correctly.

Any sort of "but I did it and it works" is pure luck.


"This account is currently not available" error when trying to ssh An error occurs when I try to make SSH connection:

$ ssh -p 22 www-data@x.x.x.x
This account is currently not available

While I agree with the others that allowing login through SSH through the www-data user is generally a bad idea, once you've logged in with a normal user it may be useful to run multiple commands concurrently with the permissions set of the www-data user. In that case, one can run

sudo su -l www-data -s /bin/bash

and you will be able to access your files as the www-data user.

The first question I would have to ask is, what are you trying to accomplish by doing this?

kraxor is 100% correct you should never be able to ssh into your server using your Apache/Nginx user. Doing so invites every hacker with half a brain cell into your server.

If you need to run a script or some program as that user you could try sudo -u www-data yourscript or you could temporally chown on the file to a user with login privileges. It's just a vary bad idea to allow this account that kind of access.


Problem with installing libtiff5-dev I am new to the whole Linux OS, and I have been having trouble installing some packages, including libtiff5-dev, libtiff5 , libjbig-dev and libmagickcore-dev. I keep getting the following message:

Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libtiff5-dev : Depends: libtiff5 (= 4.0.3-7) but 4.0.3-7ubuntu0.1 is to be installed
                Depends: libjbig-dev but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

However I do not know what to do. I'm running Ubuntu 14.04.

libtiff5-dev : Depends: libtiff5 (= 4.0.3-7) but 4.0.3-7ubuntu0.1 is
  to be installed.

Clearly the user had disabled trusty-updates and trusty-security repos at some early point after install.

So  libtiff5 4.0.3-7ubuntu0.1 (from trusty-updates or security repo), is installed but now the only available version of libtiff5-dev is the release version of 4.0.3-7.  The version of both packages must match exactly, that's why libtiff5-dev can not be installed.

Re-enabling those repos would have solved this issue..

Add the `Is not going to be installed packages to the main installation list

sudo apt-get install libtiff5-dev libtiff5 libjbig-dev


ssh -X "Xt error: Can't open display: :0.0" I'm trying to open xterm on my remote server (Ubuntu Server 10.04) with ssh:

ssh -X name@machine xterm

but the error returned is:

xterm Xt error: Can't open display: :0.0`

I googled and tried everything I found.
Still getting this error. The DISPLAY-variable should be set automatically, right?

Part of sshd_config:

X11Forwarding yes
X11DisplayOffset 10
PrintMotd no
PrintLastLog yes
TCPKeepAlive yes

Any advice?

If ssh is able to establish the connection, it will set DISPLAY to the proper value. Since you have X11DisplayOffset set to 10 (the default value), ssh will use the first available display starting at 10. If you see a value that's lower than 10¹, then something is interfering with the normal X11 forwarding set up by ssh, at least by overriding DISPLAY. The value :0 (or :0.0, the part after the dot is irrelevant) indicates the first display that was started on the machine, which in typical cases is the active session (or the graphical login prompt) on the machine's console.

The most likely explanation for the behavior you observe is that one of your shell configuration files sets DISPLAY. The most obvious culprit is ~/.bashrc (which due to a quirk of bash is executed whenever the parent of bash is rshd or sshd, even if the shell is not interactive). Another file that defines environment variables is /etc/environment. If that's the case, the solution is obvious: don't set DISPLAY there. (There are very few cases where you need to set DISPLAY manually.)

There are other exotic explanations. This might happen if you've changed your login shell to screen (a cute idea in theory, but not practical) and you have a shell initialization file that forcibly sets DISPLAY inside screen (not such a good idea). This could also happen if you configured the server to accept environment variables sent by the client (AcceptEnv directive in sshd_config), the client is sending DISPLAY, and the X connection couldn't be established. Or it could happen if you set an environment variable on the server via the command directive in ~/.ssh/authorized_keys. Or xterm could be a script.

¹  Or whatever the value of X11DisplayOffset is in the server configuration, but it's hardly ever changed from the default.

You should open first the connection,and once established open xterm.


Help, error "dpkg: error processing archive /var/cache/apt/archives/webmin_1.820_all.deb (--unpack)" I tried installing webmin through the apt-get method. Then I tried reinstalling it because I messed up the config without backing it up. So I removed it and then tried to install it.
My full log:

root@278420-1484:~# apt-get install webmin
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
  webmin
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/15.2 MB of archives.
After this operation, 161 MB of additional disk space will be used.
(Reading database ... 37754 files and directories currently installed.)
Preparing to unpack .../archives/webmin_1.820_all.deb ...
Port 10000 is already in use
dpkg: error processing archive /var/cache/apt/archives/webmin_1.820_all.deb (--unpack):
subprocess new pre-installation script returned error exit status 2
Errors were encountered while processing:
 /var/cache/apt/archives/webmin_1.820_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@278420-1484:~#

I already tried apt-get clean, apt-get update and other methods I found on the internet but nothing got it to work. Please help me.

Some process is listening on TCP port 10000 on your system, which means that other programs like Webmin can't listen on the same port at the same time. Unfortunately Webmin's installer script breaks if it can't listen on that port (imho the installer should succeed even if the installed service fails to run). The best solution is to find out what's listening on port 10000 and take it from there.

I had a similar problem last night while installing KDE desktop environment ....
try

sudo apt-get -f install

reference:-
Apt-get not working after attempting to install kde desktop


Live CD stalls when installing Ubuntu 13.10 Booting from Live CD Ubuntu 13.10 64bits, I can't get the installation page. Just a black page with a system prompt:

"numbers" BUG: Soft lockup - CPU#1 Stuck for 22s.

This repeats in a very short time. The only thing I can do is force a shut down. I tried USB installation with the same result.

This is all what it does: Start pc (laptop) with Live CD or USB, them, after BIOS screen, a black screen with two options:

0. NO Emulation System type 00
1. NO Emulation System type 00.

Notice both are the same except for the first number.

If you select number 1, the same options appear again but nothing happens.

If you select number 0, the cd starts to move and a new purple screen appears for a few seconds, then gives way to a new black screen with a blinking prompt, the cd stops and after about 20 seconds the following appears: [ 32.080003] BUG: Soft Lockup CPU#0 stuck for 22s [systemd -udevd:114]. Every 20 secs, it's repeat but first number is [ 60.080003], then [ 92.080003]..

Hardware: Intel(R) Core(TM)2 Duo CPU P8600 @ 2.40GHz [Family 6 Model 23 Stepping 6],
NVIDIA GeForce 9300M GS (256MB) driver: 327.02

you may try the old version, I've got the same problem on my laptop, and we have the same cpu.... I installed the 10.04 version, and it can work! So there may be something bug with  old machine and new linux kernel.


battery discharges in a strange way on Lenovo Ideapad Z500 I've a Lenovo ideapad Z500 laptop with Windows only energy management software (my battery stop charging at 60% for long lasting life).
Setting the threshold from Windows, it remains also with Ubuntu 13.10 64 bit, and that's ok.

In my case, battery is discharged in a strange way: it takes 30 minutes for consuming it from 60% to 40%, and then it suddenly drops to 5% in one second.
This behaviour is the same with various tools: laptop mode tools, TLP, powertop.

I'm using Bumblebee for dual gpu management (intel + nvidia), Gpu temperature is < 50° in normal situation.
What can I do for obtaining a longer battery duration? I explored some options but no results.. - Thanks and sorry for my poor English

Have you calibrated the battery recently?  After a while they need recalibrated by doing a full 100% charge, discharge to < 5%, recharge to 100% cycle.

Most laptops do this in Ubuntu, when the battery is dying. Ubuntu can not see what cells are still working so it suddenly takes a jump downwards when it gets to a cell thats not working. The reason why Windows does not do this, is that Windows takes the "100% battery" over the working cells only, not the complete amount of cells in the battery.


Ubuntu 14.04 64bit iso file can't be written on DVD-R (from Windows) I have downloaded the ISO file of Ubuntu 14.04 64bit. When I try and write the ISO with Windows to a DVD-R disk, it returns an error (Microsoft Error Code 0XC0AA0301):

I can write other kind of files to DVD, like images, videos, etc. This is happening with both Windows Disk Image Burner and Nero burning ROM.

Currently I'm using Windows 7, 64 bit. I don't want to install Ubuntu inside Virtual box. The DVD has enough space.

What can I do to burn the ISO to the DVD?

If you are having problem mounting files on dvd , you can use the live-usb to do that.
Just download win32 disk imager and install and then select the usb name(before that format the usb as fat32 or any other availible then ntfs) and burn the .iso or image file to the usb.
It is simple and effective.


What's the advantage of using Ubuntu One vs. other services like Dropbox? What features does Ubuntu One provide that others services do not have? Can I use Ubuntu One only on Ubuntu machines? What about sharing data/folders with others who do not have Ubuntu One?

Ubuntu One has several advantages over Dropbox and other services.

Synchronisation

Like other services, Ubuntu One allows synchronisation of files across machines and does this by synchronising any file you put in the ~/Ubuntu One folder. In addition, it allows you to synchronise all of the files in any folder in your home folder. However, it lacks the ability to synchronise files using symlinks.

A particular feature that Ubuntu One has that is lacking in other services is the synchronisation of your desktopcouch databases. Some applications use these databases to store data and settings. This allows automatic synchronisation between applications on multiple machines. Examples of such applications include Tomboy (which synchronises its notes) and Evolution (which synchronises contacts).

Storage Amount and Pricing

Ubuntu One provides a relatively generous 5GB of free storage compared to 2GB provided by Dropbox and SpiderOak and 1GB provided by Wuala. With Ubuntu One you can add 20GB increments for 2.99 USD/month. This allows flexible pricing that is more cost effective than Dropbox or Wuala. (See Comparison).

Platform Support

The Ubuntu One client is available on Ubuntu and Ubuntu based distributions and should theoretically work on most other distributions. A beta is available for Windows. There are also apps available for Android and iOS.

There is also a rudimentary web interface for accessing and publishing files. The publishing feature allows you to share files with people who don't have Ubuntu One.

This is not as many platforms as, for example, Dropbox so this may be a disadvantage if you use multiple platforms.

Music

Ubuntu One provides a music store and allows music streaming via smartphone applications. The music streaming costs money. Other services do not support this.

Freedom

The Ubuntu One client is free software, although the server is proprietary.

Dropbox is cross platform. It has a html folder for hosting webpages. I believe you can only use ubuntu one on linux machines.

Ubuntu one is good for sharing between ubuntu machines; but if you have a dropbox account, you should be good. :)


Default mount options on auto-mounted NTFS partitions (how to add `noexec` and `fmask=0111`?) I use auto-mounting of external USB devices, and it works as expected, except that NTFS partitions are mounted with executability flag on. For example:

/dev/sdb1 on /media/Elements type fuseblk (rw,nosuid,nodev,allow_other,blksize=4096,default_permissions)

All normal files are -rwxrwxrwx on this partition. I am not happy with the xs. I know I can have it mounted the way I want if I pass the fmask=0111 option.

Now I use Lucid, and suppose it uses some new auto-mounting mechanism (gvfs-mount?), but I don't really know how the default mounting options can be changed now. Gconf settings in /system/storage/default_options/ntfs/mount_options have no effect.

So, how do I make fmask=0111 the default automounting option for all NTFS partitions? (I'd be grateful also if someone explains how the current automounting mechanism works, how to configure it, and if the default mounting options are hard-coded, what I have to recompile to change them).

I know that I can put a line in the /etc/fstab and/or mount manually, but this is not the solution I want, because 1) I don't want to edit /etc/fstab for each and every external drive I use, 2) fstab records appear in the Places pane of Nautilus, even if the drives are not present. The questions is how to change the defaults.

Update: installing udisks 1.0.1+git20100614 or later gives more sensible defaults for NTFS, the problem which remains is how the user can specify arbitrary mount options.

if the default mounting options are hard-coded, what I have to recompile to change them

Edit the file device.c with your custom defaults:

mkdir -p build/udisks
cd build/udisks
apt-get source udisks
gedit udisks-1.0.1/src/device.c

Search for ntfs_defaults, edit, save and exit.
If the mount option isn't already on ntfs_allow list below ntfs_defaults, must also add that new option to ntfs_allow.

Build (see the other answer for a pbuilder way):

cd udisks-1.0.1
dch -l custom "Mount custom defaults fix."
dpkg-buildpackage -b -us -uc -rfakeroot

Install the newly compiled udisk:

sudo dpkg -i ../udisks_1.0.1-1ubuntu1custom1_amd64.deb

This is because NTFS drives aren't made for linux, they're made for Windows, and Windows makes everything executable by default.

The only way to have them set to non-executable by default is to edit the fstab for each drive, or switch them to fat32.


Ubuntu stuck asking to remove installation medium on Hyper V install I'm trying to install 16.04 on a virtual machine on my Windows 10 laptop.  Everything goes fine with the install with the only variance from defaults is the usage of third party video drivers.  I click ok to reboot and it then tells me to remove the installation medium and press enter. It's a virtual machine install, how do I do that without removing my keyboard?

Taken from https://www.eightforums.com/tutorials/5078-hyper-v-create-linux-virtual-machine-windows-8-a.html:

  When Ubuntu reboots and stops telling Please remove installation media, click Stop to stop and close vm. This ejects the installation media

  and now Restart vm, and you will be able to log in

i found that you just have to restart when you see that screen as it hangs on remove the media, even if i hit enter on my keyboard.  If I let it sit, eventually it runs through about a thousand lines of code on screen and errors out.  If I just hit reset then it restarts Ubuntu, and then brings me to the login screen.


How can I find *.desktop files? To the best of my knowledge, all shortcuts in the Unity Launcher have a corresponding *.desktop file. I have one shortcut (for skrooge) that doesn't have an icon. How can I find the *.desktop file corresponding to this shortcut so that I can add an icon to it?

It's probably sitting in /usr/share/applications/ but if you want to find every .desktop file on the system run this:

find / -name '*.desktop'

or

sudo updatedb
locate *.desktop

To find files with "skrooge" in their path or name, add a grep to the command:

locate *.desktop | grep -iR "skrooge"

I do not actually now which .desktop file becomes effective. My best guess is, from  https://wiki.archlinux.org/index.php/Desktop_entries , to make a script like this and run it:

#!/bin/sh

# try to find the effective desktop file
# (there seems to be no documented standard for this)

use_if_desktop_file () {
  if [ -r "$1" ] &&
     [ "$(xdg-mime query filetype "$1")" = application/x-desktop ]; then
       echo "$1"
       exit
  fi
}

for d in ~/.local/share/applications /usr/local/share/applications \
         /usr/share/applications; do
  use_if_desktop_file "$d/$1"
  use_if_desktop_file "$d/$1.desktop"
done

# no file found
exit 1


Overriding a executable to add a default flag Here's my boggle. I use gmplayer to play all my videos. 99.9% of the time everything works fine but in that 1-in-1000 case, a video might be corrupted. gmplayer plays the video but it cries like an angry, hungry baby, popping up windows left, right and centre. In really bad videos this actually slows down the whole system as it spawns hundreds of error windows (compiz applies effects, etc). It also steals focus and occasionally cancels Christmas.

In the command-line mplayer these messages are just throw out to the command line. Using mplayer-proper might be an option if I can't use gmplayer but it's not quite as good for my needs.

I have found a workaround. If you add -msglevel all=0 to the gmplayer call, errors are suppressed. Useless from a debug perspective but I'm not attempting to debug videos here, just watch them.

What I want to do is "alias" or "proxy" the gmplayer command so when you run gmplayer from the command line or by association, it actually runs gmplayer -msglevel all=0. I gather that just adding a bash alias won't work for associated (as in double clicking on a video in gnome) plays.

What are my options for hard-proxying the command. This only needs to work for one user but I'm open to system-wide changes too.

You can set this option in one f the mplayer option files, this will then be the default behaviour. For system wide change /etc/mplayer/mpplayer.conf of just for that user create ~/.mplayer/mplayer.conf and put it in there.

Adding this to ~/.mplayer/mplayer.conf works:

msglevel=all=0

You can create a symlink to your command. Create a command named mygmplayer, then verify where is your actual gmplayer command with whereis or which, then create a symlink to you command.
Here an example

 $ echo '#!/bin/bash' > /home/user/mygmplayer
 $ echo "gmplayer -msglevel all=0" >> /home/user/mygmplayer
 $ chmod a+x mygmplayer
 $ which gmplayer
 /usr/bin/gmplayer
 $ sudo mv /usr/bin/gmplayer /usr/bin/gmplayer.old
 $ sudo ln -s /home/user/mygmplayer /usr/bin/gmplayer

Bye.


I want to install 12.10 Clean but Retain Home from 12.04. Do I need to create separate Home partition? I have had major issues with upgrade to 12.10 and have reverted to 12.04. I want to install clean this time around, but would like to retain home.

Do I need to move home to a separate partition first?

I have an encrypted home, do I need to worry about this and make any special accommodations?

Is the tutorial: UbuntuReinstallation on help.ubuntu.com still relevant for 12.10?

I would extract everything in the encrypted home to somewhere else under /home or /srv and then make a new encrypted home upon installation. Then copy the files back in after reinstalling.

Use the manual partitioning option by selecting 'Something else' at the installation type screen, make sure your root partition is set not to format and is mounted to / like in the image below. The Use as: field should match the type of file system you first installed with, so ext4 by default.

**Pay no mind to the size field, yours will be different than the ones in my vm.*

Yes, you would have to move it on to a partition. But something like a USB drive. Or a CD.

I only know how to copy and paste on to a OS via CD/USB, not something like a partition. Although I think there is a way to copy and paste via partition.

I would think you would have to change the Home encryption type, but if it lets you, it's lets you.

Thanks.


Black screen with pointer visible in gnome with fglrx I'm running Ubuntu-gnome and tried installing both the repository fglrx driver as well as the new Crimson driver from AMD.  In both cases the driver installs and on reboot I am greeted with a black screen with a visible mouse pointer.  I know gnome-shell is running because I can press Alt-F2 and "r" and press enter and the mouse pointer disappears and re-appears, suggesting that its registering a gnome-shell "restart".

I tried going back down to the terminal and restarting gdm, with the same result.

(What version of ubuntu are you running?)

What worked for me was ssh'ing into my box and remove the fglrx drivers. But that only works if you have enabled sshd to run. (You could also try boot to shell and do the same thing.)

I could login with mesa drivers, but then I had a non optimal resolution and everything was slow. I installed the AMD opensource drivers and everything was ok back then.

Switch Monitor back to whatever it was before install.Proprietary or not,just reset it! It worked for me twice! On Ubuntu 16.04 and Lubuntu 16.04 !


How To Remove Ubuntu Without The Ubuntu Partition I would like to remove my Ubuntu which is dual-booting with windows 7.

I don't remember how I installed it, but the Ubuntu partition does not appear on the Disk Management. (Have a SYSTEM partition of 2GB, what is that?)

I installed the EasyBCD to remove Ubuntu from the boot menu, but after a restart the boot menu is still there with the Ubuntu option, and reappears in the EasyBCD after I deleted it.
I have no idea what to do now, can any one suggest anything. I really prefer not to format the drive.

Thanks for any help.

If you have a live-CD or live-USB of Ubuntu, you can boot into that and use GParted to remove the linux partition and extend into the unallocated space, as Nayanna has suggested or follow the same procedure and reformat the linux partition to NTFS or FAT .. something that Windows will recognize, effectively giving you two partitions, one for Win system files and one for storage (my personal choice is 2 partitions).

If you do have the live-medium available but GParted is not included, you can use the Ubuntu Software Center or the terminal command sudo apt-get install gparted to get it.
Here is a link to an informative tutorial on GParted, if you are not familiar: http://www.dedoimedo.com/computers/gparted.html

1)If you have installed ubuntu inside windows(using wubi)

Goto Control panel-> Uninstall a program and Uninstall ubuntu entry

2)If you insall ubuntu in dual- boot

Delete the Linux partition from disk management
Then Extend the partition to current windows partition
Boot windows from recovery disk
Choose "Repair Your Computer," go to "Troubleshoot," and then enter a Command Prompt. Type the following command

 bootrec.exe /fixmbr

Then reboot your computer
For more details refer this link
http://lifehacker.com/how-to-uninstall-windows-or-linux-after-dual-booting-508710422


No WIFI on Ubuntu 12.04 LTS after today software update I just got new dell inspiron3537 with Ubuntu 12.04 LTS (no windows O/S).  It got some wireless (hard block) yesterday. So, this morning, I ran the software update all the security update.

After that I can't see "Wireless" in system setting. So, I updated all the software update and looked thru several web site and found sudo lshw -c network command.  I tried and found the result below.

  *-network
       description: Ethernet interface
       product: RTL8101E/RTL8102E PCI Express Fast Ethernet controller
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:01:00.0
       logical name: eth0
       version: 07
       serial: 74:86:7a:40:5d:48
       size: 100Mbit/s
       capacity: 100Mbit/s
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=full ip=192.168.1.10 latency=0 link=yes multicast=yes port=MII speed=100Mbit/s
       resources: irq:60 ioport:4000(size=256) memory:c0700000-c0700fff memory:c0400000-c0403fff

  *-network UNCLAIMED
       description: Network controller
       product: QCA9565 / AR9565 Wireless Network Adapter
       vendor: Qualcomm Atheros
       physical id: 0
       bus info: pci@0000:02:00.0
       version: 01
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list
       configuration: latency=0
       resources: memory:c0600000-c067ffff memory:9fb00000-9fb0ffff

Please suggest what I should do to fix it.

I had the same problem.
The solution is here http://ubuntuforums.org/showthread.php?t=2103062 (Compaq has the same adapter). I followed the instructions and now wi-fi works properly.

...we install the prerequitites needed to compile:

sudo apt-get install linux-headers-generic build-essential

Now we download the package, extract it and install it:

wget http://www.orbit-lab.org/kernel/compat-wireless-3-stable/v3.6/compat-wireless-3.6.6-1-snpc.tar.bz2
tar xvf compat*
cd compat-wireless-3.6.6-1-snpc
sudo su
./scripts/driver-select ath9k
make
make install
modprobe ath9k
exit


Create a bash alias for several commands, some requiring sudo I know there is lots of information on this around, but I still find it confusing. Please help me with this quick one liner.

What do I need to write and where to make this a permanent feature of my system?

This is the command:

sudo apt update &&\
sudo apt upgrade -y &&\
sudo flatpak update &&\
conda upgrade --all -y

Maybe call it with sudo updateall

Slight digression: I asked a question about upgrade appimage and snap a while ago. There exists appimagehub but it pooly supported at the current time and snap by design updates without user involvement and there is no way to change this I believe. The others here can be manually updated.

In your .bashrc using vim ~/.bashrc add:
makealias() { echo "alias $1"="'${@:2}'" >> ~/.bashrc; }

Next time you want to add a bash alias just type in the terminal:
makealias name command

Example: makealias brc vim ~/.bashrc
EDIT
This method does works with sudo, &&, || and other operators like ; if you enclose them in single quotes when making the alias.
Example: makealias updateall sudo apt-get update '&&' sudo apt-get upgrade
Do yourself a favor and use ; instead of &&, that is good practice.

To make it available to all users who have sudo privileges(needed for the commands)

sudo nano /etc/bash.bashrc

To make it available for your user only sudo nano /home/yourusername/.bashrc

Go to the bottom of the file and add your aliases like so, I included the commented out (#)ALIAS LIST title

#ALIAS LIST

alias updateall='apt update && sudo apt upgrade -y && sudo flatpak upgrade && conda upgrade --all -y'

alias sudo='sudo '

Save the file, then run exec bash from the terminal.

The first alias is your command, the second alias allows you to use sudo with aliases.


Lenovo's disable touchpad button not working So I have a Lenovo u310 with Ubuntu 13.10 on it and whenever I try to disable my touchpad with the special button on my F6 key, it does nothing.

All the other special keys work, like plane mode and refresh page but only the touchpad button is not working.

What might be wrong with it?

It does not work for me too(Ubuntu 13.10 Sony Vaio).

But I use following command(with shortcut key)

First determine the device id

xinput list

Then disable it, (this command as shortcut key action)

xinput set-prop 15 "Device Enabled" 0

Replace 15 with your device id.

SOURCE : https://help.ubuntu.com/community/SynapticsTouchpad

I think this site will answer your question.
I do not own any lenovo to answer it
SITE
http://mydevelopedworld.wordpress.com/2013/11/30/how-to-configure-new-lenovo-x240-touchpad-on-ubuntu-13-10/


upgraded to 12.04 Boots straight into command line I just upgrader to 12.04 from 11.10. The install appeared to go well but the computer goes through the usual boot with splash but the goes to the command line without a GUI. How do I open the GUI and fix this issue?

There appears to be issues with the nouveau drivers. I suggest reinstalling 11.10 as I couldn't get 12.04 to work on my system either.


Why can't I open the "root" folder in Xubuntu? After I finished installing Xubuntu I tried opening the Folder "Root" which has a cross next to it (I didn't know what was that) I already know that Root is my hard drive so i opened it and I got this:

Any help would be appreciated.

The /root folder is the home folder of the root user (the administrator). That is, you (as a normal user) cannot see the personal stuff of the administrator which is fine and is the right thing to happen. Now, the root partition is just /. I guess you just misinterpreted the meaning of the folder /root and the root partition /.

The root partition (and corresponding folder) is called /. So if you need to see your file system you just need to type / in the locations bar.

Also, notice there is an item (in the image you uploaded) which reads File System under DEVICES. Click it and see what reads on the locations bar.

the "root" folder is located in / not /root/ that is the root user or "superuser" s home folder, as such you need root access to open it


Resize linux partition and merge NTFS I am trying to clean up my partitions and wondering the best way to do this without making my computer unbootable or having to resinstall Ubuntu.

Here's what my current partition setup looks like:

I dual boot into Windows and would like to keep that partition active (/dev/nvme0n1p3). Otherwise I'd like to collapse all of the other partition, except for swap, into a single linux ext4 partition. Is there a way to convert and merge the large ntfs partition (Media) into the current ext4 / partition and recapture the unallocated space?

I'd recommend getting a separate drive. You really only need a 250GB for the NTFS partition to fit on.
Then create an image of that partition on the new drive dd will work but it's slow. Maybe try:

Clonezilla Live: http://clonezilla.org/
The tutorial for Clonezilla can be found here. I've never used this tool though, so I can't speak to it.
I found the info from How to make a disk image and restore from it later?

Once you have your backup, I'd recommend creating a your new partition, pro tip -- go with XFS, not ext4, for better performance, and then copy your current EXT4 partition data over, making sure to preserve permissions/ownership, and then extract or merge your old NTFS data over.
If you created an image just mount it using mount -o loop ...iso /mnt/yourMountPoint

By the way XFS can be shrunk but it's a real pain, so just plan on expanding/extending it later if you need to.

Good luck!


Is there an application indicator for CPU usage by core? I love System Load Indicator (indicator-multiload), but it doesn't reflect the usage of the individual CPU cores, just the overall CPU usage.  Sometimes I'll have an application max out a single core (ahem, Eclipse), but when I glance at the CPU usage graph, everything looks acceptable.

I know I can just open Htop, but the whole point of an application indicator is being able to get the information you want with a glance, not keystrokes.  Thanks.

This is for Ubuntu 14.04 and later.

Install indicator-sysmonitor

sudo add-apt-repository ppa:fossfreedom/indicator-sysmonitor
sudo apt-get update
sudo apt-get install indicator-sysmonitor

Run it
Click on its indicator → Preferences → Advanced tab
Change label from cpu: {cpu} mem: {mem} to cpu: {cpu0}{cpu1} mem: {mem}. Add whatever as CPU cores you have.
Save

References:

Ubuntu AppIndicator That Displays Bash Scripts Output On The Panel: Sysmonitor Indicator

Gnome System Monitor shows system load per core for me,

It should have come with your installation, but if not then:
sudo apt-get install gnome-system-monitor

resources tab


Installing LBP 2900 printer -> libs folders wrong? I am trying to get my Canon LBP2900 printer to work on Ubuntu 11.10 64 bit.

What I have done is try to follow the steps on https://help.ubuntu.com/community/CanonCaptDrv190

So I downloaded the version 2.3 driver and tried to convert the rpm files to debian and installed them

sudo alien cndrvcups-capt-2.30-1.x86_64.rpm cndrvcups-common-2.30-1.x86_64.rpm
sudo dpkg -i cndrvcups-capt-2.30-1.x86_64.deb cndrvcups-common-2.30-1.x86_64.deb

restarted cups and try to install the printer with lpadmin:

sudo service cups restart
sudo /usr/sbin/lpadmin -p LBP2900 -m /usr/share/cups/model/CNCUPSLBP2900CAPTK.ppd -v ccp://localhost:59787 -E

What I noticed however that on the step with lpadmin it goes wrong with the error:

lpadmin: Bad device-uri scheme "ccp"

After trying to trace what has gone wrong, I think I nailed it to the fact that dpkg installed a file /usr/lib64/cups/backend/ccp instead of /usr/lib/cups/backend/ccp

Checking the original rpm with archive manager shows indeed that /usr/lib and /usr/lib64 are used, with the backend/cpp file only installed in lib64. As I understand correctly, Ubuntu 11.10 uses /usr/lib32 and /usr/lib instead so the files are installed in the wrong place.

Is there an automated method of converting the rpm/deb files with the wrong lib structure to one with the right lib structure for ubuntu 11.10? Or am I completely on the wrong track for getting my printer installed?

What I noticed however that on the step with lpadmin it goes wrong with the error:
  lpadmin: Bad device-uri scheme "ccp"

It is because you didn't generated the scripts associated with the rpm files.......

Use

  sudo alien cndrvcups-capt-2.30-1.x86_64.rpm cndrvcups-common-2.30-1.x86_64.rpm --scripts

OR

  sudo alien *.rpm --scripts

instead of

  sudo alien *.rpm

You can solve this error

  lpadmin: Bad device-uri scheme "ccp"

All the best from RJK

I do not own this particular model from Canon but i never find any trouble when installing a new printer on my system, also Canon declares this driver as working under all the latest versions of Ubuntu and many other GNU/linux distribution.

http://software.canon-europe.com/

Here you can download driver for both 32 and 64 bit operative systems, also there are the source included in the package so you can build your own driver from the scratch.

Do not use the rpm as first resource especially on a deb based system.

to find out what libreries are used by a specific executable run this command

ldd [path to exec]

Sometimes there are scripts available to start the program and they are not executables, to find out where the real executable is located you have no choice other than investigate the source of the script.

For example to know which libraries are used by java you can use ldd combined with which that is a command that gives you the full path of an keyword command ( only which works for both scripts and exec, ldd need an exec ):

ldd $(which java)

I suggest to completely remove those installed packages and compile from the source, if you can't remove those packages safely try to do something with ldd and verify that all the required libraries are linked to your executables, you can also run this command sudo apt-get install -f to try to fix some missing packages.

EDIT: i almost forgot this, to update all the linking between the libraries and the executable you have to run sudo ldconfig and this is useful after you have installed new libraries.

Apparently there are good links with this search http://www.google.com/search?q=compile+cndrvcups-common and some good ppa too.


is there any way to create a hidden hotspot from ubuntu? I would like to create a hidden hotspot from my Ubuntu for my phone, is there any way to do this? I want that only people who know the SSID can connect to the WiFi.

Yes, you can do this with this script https://github.com/Daniyal-Javani/AP-Hotspot

You can run this with downloading ap-hotspot file and do chmod 777 ap-hotspot or install with sudo apt-get install ap-hotspot Then change codes in /usr/bin/ap-hotspot with my script!

There is no way known to create the access Point hotspot with hidden SSID. However to do Wifi hotspot without hidden SSID:

http://www.howtogeek.com/116409/how-to-turn-your-ubuntu-laptop-into-a-wireless-access-point/

With screenshots.


Cannot access windows partition from ubuntu Upon clicking the windows partition in nautilus, i get this error thrown at me.

Error mounting /dev/sda4 at /media/zalgo/D8649C54649C36EA: Command-line `mount -t "ntfs" -o "uhelper=udisks2,nodev,nosuid,uid=1000,gid=1000" "/dev/sda4" "/media/zalgo/D8649C54649C36EA"' exited with non-zero exit status 14: The disk contains an unclean file system (0, 0).Metadata kept in Windows cache, refused to mount.Failed to mount '/dev/sda4': Operation not permitted The NTFS partition is in an unsafe state. Please resume and shutdown Windows fully (no hibernation or fast restarting), or mount the volume read-only with the 'ro' mount option.

I do not have fast boot or hibernation enabled on windows, if there are any commands that i should post the output of to help, please comment that.

This is not a duplicate of How can I access windows 10 partition in ubuntu when i cant get it to shut down in a "safe state"?, as the solution used there does not work here.

The solution I found that worked was a program called ntfsfix.

Install ntfs-3g with:

sudo apt-get install ntfs-3g

Then run the ntfsfix command on your NTFS partition.

For example:

ntfsfix /dev/sda4

Well, it appears that your ntfs partition has problems! Possibly physical damage on disk. If you have a initialization device I suggest you try to use it to enter in administration mode and try to run something from Windows to fix the disk problem at first. After that, reinstall Windows and restore your Linux bootloader(grub or whatever) or you can reinstall Linux(after fix and/or reinstall Windows) without to format all system(depends how you organized your partitions).


How to download flash (streaming) videos from sites like youtube, dailymotion, vimeo, etc.? I have read this thread but please hear me out.

I use Ubuntu 10.04 LTS (32-bit) and I didn't bother to install the Flash plugin for Firefox as I am using a netbook and sometimes Flash caused firefox to crash. What I would like to ask is if I had the link to the video, is there some way I can download it and watch it offline (via VLC) so that I don't need to install Flash plugin? Command line or GUI techniques is welcome.

Based on what I have read, using the /tmp technique requires Flash plugin to be installed and the video to be loaded before I can go scavenge it in the said directory. Note that I also want to dload videos from site aside from youtube.

I would recommend ClipGrab, it downloads videos from many popular video sites including:

YouTube
Clipfish
College Humor
Daily Motion
MyVideo
MySpass
Sevenload
Tudou
Vimeo

It also allows you to transcode the video into multiple formats including audio formats such as mp3 and ogg vorbis.

You can install it from the ppa:clipgrab-team/ppa PPA.

For the YouTube videos, I use the Greasemonkey script YouTube Video Download


Can't Install Ubuntu on my iMac Apparently, my late-2009 iMac screwed up, and ruined everything. I was forced to reformat and I decided to use the Ubuntu 12.04 LTS. My iMac's SuperDrive is a jerk, so I plugged in my USB on my mother's MacBook, downloaded the ISO of Ubuntu and used the dd trick.

Installing Ubuntu resulted in a black screen of nothingness, and then the monitor would die out and I have to reset. I browsed through the Ubuntu forums and luckily found out about the nomodeset trick. Success was on my side, and I braced myself to shout victory. Unfortunately, the install hangs on this certain part with the OKs and fails.

I looked closer into it and found out that it was "Starting restore sound card(s') mixer state(s')" that failed.

What should I do?

@Goldgum Installing Ubuntu on a mac is sadly not as straight forward as it is for many windows based PC's. Since your particular mac computer does not appear to have a version that is officially supported by Mactel (https://wiki.ubuntu.com/MactelSupportTeam/CommunityHelpPages) this means you are doing an Unsupported Version install. it looks like the problems you are experiencing are fairly common and addressed here. I would start with the support page and see if that has what you are looking for.


How do I install nagios? I keep hearing about Nagios, a really powerful tool for monitoring servers. How do I install it?

First of all, I'm assuming that you're doing this on a stock, brand-spanking new install of 12.04. Nothing special happening here.

Install nagios:

sudo apt-get install -y nagios3

It will go through, and ask you about what mail server you want to use:

Pick one based upon your needs.

It will then ask you about the domain name you want to have email sent from. Again, fill that out based upon your needs.

It will ask you what password you want to use - put in a secure password. This is for the admin account nagiosadmin.

And then you'll need to verify your password.

Once the install is all done, you can head over to localhost/nagios3 (or whatever the IP address/domain name of the server you installed it on is) and you'll be asked to enter your password:

Once you've done that, you're in!

Little ugly, huh?

Nagios automatically adds in the 'localhost' to the config, and does load, current users, disk space, http and ssh checks.

Now there is one more thing we need to do before nagios is all ready - we need to have it accept external commands so we can acknowledge problems, add comments, etc.

To do that, we need to edit a few files. Start by opening /etc/nagios3/nagios.cfg with the following command:

sudo nano /etc/nagios3/nagios.cfg

Search for check_external_commands, and turn the check_external_commands=0 into check_external_commands=1.

Now, restart apache by running

sudo service apache2 restart

Not done yet! We need to edit /etc/group. There should be a line like this in there:

nagios:x:114

Change it to

nagios:x:114:www-data

Save and close this file.

Now, we need to edit the /var/lib/nagios3/rw files permission with:

sudo chmod g+x /var/lib/nagios3/rw

And then (because of how permissions work) we need to edit the permissions of the directory above that with:

sudo chmod g+x /var/lib/nagios3

Now, restart nagios with:

sudo service nagios3 restart

If you use Apache as your web server, restart that also:

sudo service apache2 restart

And you should be good to go! Happy monitoring!

To have alerts emailed to you, see this question and answer.

I recommend follow Nagios official Quickstart guide, which does not use apt-get, but download the source code, compile and then install.

This would ensure your Nagios is installed at /usr/local/nagios/

I find the advantage that Nagios installed at /usr/local/nagios/ when I try to install Nagios Service Check Acceptor, a add-on for Nagios.


How to install strings in Ubuntu server I installed Ubuntu server 16.04.3 LTS but I cannot find the strings command:

$ sudo strings /data/storage
sudo: strings: command not found

$ man strings
No manual entry for strings

How am I supposed to install it?

You need to install binutils:

apt-get install binutils

That should do the job.

It may be already installed but under the name strings-GNU instead of strings.  You'll need to create a link in /usr/bin.

ln -s strings-GNU strings


What is the difference between Vi and Vim? I would appreciate it if someone can let a newbie know what the differences are between vi and vim. I've heard Vim is a successor to vi but whenever I try to open vi in Ubuntu it opens vim instead.

Functionally, vim is almost a proper superset of vi. Therefore, everything that is in vi is available in vim.

Vim adds onto those features. Here are a some of the extended vim features:

Vim has been ported to a much wider range of OS's than vi.
Vim includes support (syntax highlighting, code folding, etc) for several popular programming languages (C/C++, Python, Perl, shell, etc).
Vim integrates with cscope.
Vim can be used to edit files using network protocols like SSH and HTTP.
Vim includes multilevel undo/redo.
Vim allows the screen to be split for editing multiple files.
Vim can edit files inside a compressed archive (gzip, zip, tar, etc).
Vim includes a built in diff for comparing files (vimdiff).
Vim includes support for plugins, and finer control over config and startup files.
Vim can be scripted with vimscript, or with an external scripting language (e.g. python, perl, shell).

There are many more differences. Refer below sources which are few of good places to start finding out more.

Source: Vim.Org, Vim on Wikpedia.

Hope it helps! :)

To add to what @gen said, it is easier to read it straight from vimhelp.org, if you don't wish to test things yourself.
The reality is most people use very little of "real" vi's capabilities and even less of vim's or nvi's.
https://vimhelp.org/vi_diff.txt.html
https://vimhelp.org/options.txt.html#%27compatible%27
https://vimhelp.org/vi_diff.txt.html#posix-compliance
The biggest thing I notice is how undo / re-do has been brok.. er.. "improved" in vim, the non-classic behavior of the "BACKSPACE" key, and how slow vim-tiny is compared to n/vi at times.
One append of 50,000 repetitions can lock a session up for almost an hour in any vim version I've ever tested.
A 2,000,000 append of the same data in nvi takes less than 5 seconds.
The vim Devs know about this bug but do not think it is worth fixing.
^[50000aUse vim or nvi or vi?^[
Better not try that in vim on a Production box.  Just sayin'
If you don't know, ^[ is the code for the "ESCAPE" key.  You SHOULD know that.
Generally your basic vim skills of ^[ibla foo bar^[:wq! will transfer enough to "real" vi if you need to support a real UNIX such as AIX, HP-UX, or Solaris.
But if you rely on arrow keys to "move around" while in Insert mode then you are going to be in for a rough time.
You should not be moving the cursor around in Insert mode, arrrow keys or otherwise, 1980's or not.  Movement is meant to be done in Command mode.  It is faster and allows you to use the actual power of vim|n/vi.
Otherwise you might as well be using MS Win Notepad.
If you use vim|n/vi as intended then the hjkl and/or arrow keys --in Command mode-- will still be your last resort for getting around in a file.  It is too inefficient and slow.
You type "new" text in Insert mode, while almost all movement and text editing is done in Command mode.
This is the part many people don't seem to get.
Arrow keys don't work in Insert mode and type "garbage" when they are pressed because they are literally telling vi to "insert" the control code for your arrow key, so it does: ^B.  Then people complain that UNIX/vi is doing what they told it to do!  If you don't want vi to Insert the character then stop telling it to. Simple: Movement is done in Command mode.
Also, vim|n/vi have 2 modes in common:  Insert mode and Command mode.
There is no such thing as "Escape" mode.  ^[ just puts you in Command mode.
n/vi does not have a "Visual Block" mode, which is specific to vim.
But since marks have served that purpose in vi since the late 1970's then I question why a Visual Block mode is necessary.  Maybe for people who actually use the COLUMN selection feature?
Not knowing what vi marks and named buffers are, or how to use them demonstrates that people have not went through some of the most basic vi tutorials that have been around since the 80's or even read the man pages.
Finally, to all the people who think "vi" is on Ubuntu, or almost any GNU/Linux system, for that matter -
:version
The name is almost certainly a symlink to some vim binary somewhere.
All of this information has been publicly available about vi for around 40 years now.
-EDIT-
I just thought of 2 other ways that vim is not POSIX vi:

CTRL+R is expected to redraw the screen, not vim's "redo"
Q (which is outright DISABLED in some vim builds, apparently) is supposed to switch you back to ex.


newly installed 12.04 cannot connect to internet I am a Comp Sci student and I had to replace my dev laptop with an old Dell Inspiron 1150. First tried loading Ubuntu 13.10 but it wouldn't render graphics correctly on this old machine, so I put on 12.04 LTS instead.

During install from DVD, it recognized internet connection (I had an ethernet cable plugged into my wireless router and the linksys wireless-G adapter plugged into the bus, so I don't know which connection it was using). But now that the OS is installed, it says Network Disconnected and I can't get it to recognize either connection.

the output of

sudo ifconfig

is:

Link encap:Local Loopback
inet addr:127.0.0.1 Mask 255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:192 errors:0 dropped:0 overruns:0 frame:0
TX packets:192 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:15744 (15.7 KB) TX bytes:15744 (15.7 KB)

and the results of

sudo lshw -C network

is:

*-network UNCLAIMED
description: Ethernet controller
product: BCM4401 100Base-T
vendor: Braodcom Corporation
physical id: 1
bus info: pci@0000:02:01.0
version: 01
width: 32 bits
clock: 33MHz
capabilities: pm bus_master cap_list
configuration: latency=32
resources: memory:fcffe00-fcffffff memory:fd000000-fd003fff

I manually typed this in, so hoepfully no typos

try requesting a new IP from the DHCP

sudo dhclient -r

releases current

sudo dhclient eth0

Renews IP-address of device.


Can I upgrade to Linux 3 Kernel on Ubuntu 10.10? I need to use Linux 3, becasue with Linux 2.6.x has display problems  with my SandyBridge integrated graphic. On the other hand, I need to downgrade to Ubuntu 10.04/10 because Betavine packages for running my mobile broadband modem work only with Ubuntu 10.04 (and 10.10). Hence I need to make a compromise. I appreciate your hints.

Or, as a last-ditch effort you could compile a new kernel from kernel.org and use that.

To get an ubuntu-styled kernel:

apt-get source linux-image-$(uname -r)
cd linux-image-$(uname -r)
make menuconfig #Then hit exit and save the configuration
cd ..
wget http://www.kernel.org/pub/linux/kernel/v3.0/linux-3.2.6.tar.bz2
tar -xjf linux-3.2.6.tar.bz2
cd linux-3.2.6
make menuconfig
cp ../linux-image-$(uname -r)/.config .
rm -R ../linux-image-$(uname -r)*
make
make install

Maybe. There is an Ubuntu kernel PPA:
https://launchpad.net/~kernel-ppa/+archive/ppa

You can try download the Linux kernel 3 for Oneiric, maybe it will work.
http://kernel.ubuntu.com/~kernel-ppa/mainline/


How do I recover data from a partition I resized with GParted? I have an external hard disk with two partitions. I wanted to merge the two partitions with GParted. So I followed the procedure:

I saved the data on Partition A.
I deleted Partition A.
I extended the size of Partition B to the whole drive.

So far so good, but when I re-opened my drive all the data on Partition B was gone! Is there any way to recover it?

if that window or other than linux os .. just delete the partition and format to what kind of partition you love to have.. but if that linux partition emmm .. read this http://gparted.sourceforge.net/display-doc.php?name=help-manual


Extensions are turned off after reboot I am running Ubuntu Gnome 13.10 with Gnome 3.10. My problem is that every time I reboot the OS all the shell extensions are turned off. The weird thing is that their settings are kept. They are just turned off and I have to re-enable them every time. How can I make them persistent.

Thanks

Update

Today Ubuntu 13.10 was officially released and after I upgraded, my problem is still there. Here is my system info:

$ uname -a
Linux ubuntu-desktop 3.11.0-12-generic #19-Ubuntu SMP Wed Oct 9 16:20:46 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

Any ideas?

Sidenote - Can someone please tell me at least were the settings of the state of the extensions (on/off) are stored? I have removed all the extensions

rm -r ~/.local/share/gnome-shell/extensions/*
rm -r /usr/share/gnome-shell/extensions/*

and I installed the ones I use. So I am thinking of creating a cronjob and enabling all of them everytime the system boots. At least until i find how to fix this.

This works in Gnome 3.8.4, and should work later versions.

Set all the extensions you want to be on.
Then run:

gsettings get org.gnome.shell enabled-extensions

This should come up with something like

$ gsettings get org.gnome.shell enabled-extensions
['user-theme@gnome-shell-extensions.gcampax.github.com', 'status-area-horizontal-spacing@mathematical.coffee.gmail.com', 'CoverflowAltTab@palatis.blogspot.com']

Copy the output, and then run gnome-session-properties

Press add, and then enter the output of gsettings get org.gnome.shell enabled-extensions "['use... ...blogspot.com']" - However, as has been kindly pointed out, change get to set when entering in the command box, like in the picture below. PUT THE DOUBLE QUOTES IN, OTHERWISE THIS WILL NOT WORK (If not sure, test the command in the terminal first - if no feedback is given, it worked).

EDIT: For newer versions without gnome-session-properties, you need will probably need to manually make a .desktop file in ~/.config/autostart - some GUI tools may be available via Gnome Tweak Tool or similar.

For Example:

Then make sure that this is on:

Now, every time you login, it should run a command to restore all the extensions!

N.B. If you make changes to your activated extensions, this would need to be updated.

To automate this process, this script seems to work:

#!/bin/bash
active_extensions=$(gsettings get org.gnome.shell enabled-extensions)
autostart_file=$HOME/.config/autostart/restore-extensions.desktop
echo -e "Currently active extensions:\n\e[34m$active_extensions\e[0m"
echo -e "[Desktop Entry]\nType=Application" > $autostart_file
echo Exec=gsettings set org.gnome.shell enabled-extensions \"$active_extensions\" >> $autostart_file
echo -e "Hidden=false\nNoDisplay=false\nX-GNOME-Autostart-enabled=true\nName=Restore Extensions\nComment=Restore enabled extensions on login" >> $autostart_file
echo "Command to restore currently active extensions added to $HOME/.config/autostart/restore-extensions.desktop"
exit

Save the script to ~/.local/bin/extension-update, make it executable (either set it in the file's Properties window, or run chmod +x ~/.local/bin/extension-update).

Then every time you run extension-update, it will update an autostart file at ~/.config/autostart/restore-extensions.desktop (it will likely be different a different autostart entry if you created one manually as above, so if you created one manually you may want to delete that) - you can check in gnome-session-properties to make sure.

I fixed the problem (in openSUSE, but may be the same for you) by deleting the dconf key for enabled extensions, restarting the shell or logging out, and then re-activating the extensions in tweak tool.

Some extensions in dconf weren't actually installed... seems to have been the problem, since it's working now...

Hope that helps.


How to install VLC in ubuntu 12.04 64-bit? Can anybody help me to install VLC media player in Ubuntu 12.04 64-bit?

The simple way is, open the Ubuntu Software Center and in the search box type "VLC". There you can find the player and and you can install it by clicking on "Install", but you need Internet connection to install it, I hope you have it.

Another way is using Synaptic. Open it and type VLC in the search box as you would do for the Software Centre. Among the search results, select VLC and it will automatically select the required dependencies and install them for you.

These are the simple ways.

Try this.

sudo add-apt-repository ppa:videolan/stable-daily
sudo apt-get update
sudo apt-get install vlc

Source: http://www.noobslab.com/2012/03/install-vlc-201-on-ubuntu-1204.html


How To Make Partiton For Windows 10 I am using Ubuntu as my main OS and windows 10 is my secondary OS. I have a 500gb hdd.i want to create a new partition or resize my main Ubuntu partition.

How can I do it? Gparted partition don't give me access to resize my main partition.

To resize partitions it is necessary before dismounting the partitions.
Padlock may not be appearing in GParted.
Boot the system using a live-pendrive.

I had the same problem had to boot in windows and use the windows partition manager.


Install 32 bit from USB, not a COM32R, then no PAE, 64 bit doesn't work either I hope someone can help me install a linux system of some sort please, have gotten a bit stuck. I have an old laptop (DEll Latitude D500, currently running Windows XP professional version 20012, Intel(R) Pentium(R) M processor 1300MHz 1.30GHz, 512 MB RAM, 18.5 GB hard drive). I am trying to install a nice light operating system on it, like Lubuntu or Xubuntu and have been trying to get rid of Windows and install the new system using a bootable USB which I am creating on my PC running Ubuntu 14.04.

When I try to boot the 32 bit version of either Lubuntu or Xubuntu, I first get the message:

Missing parameter in configuration file. Keyword: path
gfxboot.c32:not a COM32R image

I tried a solution I found on these forums of hitting tab, then typing 'live' then enter. At which point it starts to complain that PAE is disabled and says I should 'use parameter 'forcepae'. However I can't actually type anything after this, the laptop just beeps if I try to.

When I tried to install 64 bit versions of either operating system it came up with this:

This kernel requires an x86-64 CPU, but only detected an i686 CPU. Unable to boot – please use a kernel appropriate for your CPU

Starting to feel that no kernel is appropriate for my CPU! Sorry I'm still a beginner, it is a crappy old laptop but would be really handy to be able to use it for a few things. Any help appreciated. Thanks!

type "live" and hit enter. I had the same problem and it worked for me.

Source: http://ubuntuforums.org/showthread.php?t=2262661

The 64-bit version of Ubuntu requires a 64-bit CPU. This error simply means that your CPU only supports the 32-bit architecture. To fix this, you should install the 32-bit edition of Ubuntu.


Dropped laptop, now get "PXE-E61: Media test failure, check cable" error I dropped my laptop (toshiba satelite) and now I can only boot up with CD (ubuntu 13.04). Otherwise I come to a black page with text. Text laptop:

PXE-E61: Media test failure, check cable
PXE-M0F: Exiting PXE ROM.
Reboot and Select proper Boot device or Insert Boot Media in selected Boot device and press key

Questions:

Is my hardrive completely destroyed now?
I was going to format and reinstall but it says I don't have enough space!! Is it possible to format the hardrive some other way, thereby making more room and then reinstalling Ubuntu?

The hard drive could have disconnected when it dropped to the floor or if the computer was running whilst it fell to the floor you could have damaged the hard disk. If you don´t know how to open the laptop and check if the SATA cable is connected take it to a shop, if it is the hard drive I recommend the new drive you buy is an SSD, you will never have that problem again as it doesnt have mechanical parts(and you will fly loading OS and apps), hope it solves your issue.

try:

sudo fdisk /dev/sda

it should display something like this:

/dev/sda1   *        2048   201328639   100663296   83  Linux

/dev/sda2       201330686   209713151     4191233    5  Extended

/dev/sda5       201330688   209713151     4191232   82  Linux swap / Solaris

Command (m for help):

try the 'd'.  It will ask for the partition number.  In my case 1,2,5 will work.  If you have problems with fdisk /dev/sda try fdisk -l to see all disk


Why is it necessary to add locally attached printers? I seldom have to print anything on paper anymore, so my knowledge about printers is really limited. Last weekend, I demoed Oneiric to my father, who still prints stuff, and even though his printer is attached using USB, I had to select the printer from a list. Why is that? I mean, if I attach a memory stick, I don't have to select it. It just works. Why is that no so with printers? For network printers, I understand why they have to be added, since a company can have thousands of printers when one user only needs to use a couple of them. But shouldn't directly connected printers just work?

According to Ubuntu docs, things are supposed to happen exactly as you expect:

  Plug your printer into your computer and power it on. Most printers
  will automatically be detected an configured. Once detected, a printer
  icon will appear in the notification area and after waiting a few
  moments, you should get a popup with the text "Printer is ready for
  printing.

Unfortunately, setting up a printer may be more difficult than mounting a flash drive, so sometimes auto-detection fails. In this case you need to add the printer manually.

You could always print to a file instead, or tell the system to use  a printer in the network, which isn't automatically seen.

And since Linux evolved from a networking-server-system, having multiple printers available was very common for Unix systems.


Opera will not play Twitter videos (and others) Here is an example above. It also does the same thing on other sites with other video players, but I figure this is one of the more well known ones.

Any help?

Run this command in a terminal (Ctrl+Alt+T):

sudo apt-get install chromium-codecs-ffmpeg-extra

Then restart Opera.

I'm using Linux Mint cinammon 20.0 and Opera 71.
I tried copying the libffmpeg.so from Chromium, but as I didm't install it y found another in whatsapp.
I opened /usr/lib as root.
Foud the opera libffmpeg.so (about 1.8 MB) and renamed it as libffmpeg-opera.so as a safety measure.
Then copied libffmpeg.so from whatsapp (about 3.2MB) and pasted into opera.
Reinitiated Opera and problem solved.


Unable to install filezilla in Ubuntu 14.04 The following packages have unmet dependencies:
 filezilla : Depends: libdbus-1-3 (>= 1.9.14) but 1.6.18-0ubuntu4 is to be installed
             Depends: libfilezilla0 but it is not going to be installed
             Depends: libgnutls30 (>= 3.4.2) but it is not installable
             Depends: libnettle6 but it is not installable
             Depends: libpugixml1v5 (>= 1.7) but it is not installable
             Depends: libstdc++6 (>= 5.2) but 4.8.2-19ubuntu1 is to be installed
             Depends: libwxbase3.0-0v5 (>= 3.0.2+dfsg) but it is not installable
             Depends: libwxgtk3.0-0v5 (>= 3.0.2+dfsg) but it is not installable
E: Unable to correct problems, you have held broken packages.

How can I fix this?

You can install the package.

make sure the repo sources are up to date

sudo apt-get update

To Install the package:

sudo apt-get install packagename

Once the package determines that you have some missing dependencies, run the following command to fix broken or missing dependencies.

sudo apt-get install -f

Above command will only download the missing dependencies if you have already installed the package.