How to use inotifywait in a non-blocking way and mail the results? I've tried several times to test my script, but with no success. This is the script:

zenity --question --text "my text"
if [ $? -eq 1 ]; then
    zenity --warning --text "my text"
else
    ping -n -c1 192.168.180.112
    # print result (0 se existir)
    echo $?
    if [ $? -eq 0 ]; then
        scp -r ~/Documents/Processo/CONCLUIDO/* posto-ensaios@192.168.180.112:/home/posto-ensaios/Documents/Processo
        fileName=$(inotifywait -e moved_from /home/posto-11v/Documents/Processo/CONCLUIDO | sed -r 's/^.*MOVED_FROM(,ISDIR)*\s+(.*)$/\2/g')
        mail -s "$fileName" USER@MAIL.HOST < ~/Documents/personaproject/Programa/scripts/mail.txt
        mv --backup ~/Documents/Processo/CONCLUIDO/* ~/Documents/personaproject/processos_terminados
        zenity --info --text="my text"
    else
        zenity --warning --text "my text"
    fi
fi

I've tried to run with the sleep command with "pipe" after sed and to change the order of the commands. When running the script in their terminal the problem is that inotify always keeps waiting for an action...

I need to guarantee that files are copied, moved and the $filename is sent in email...

Any help?
Thanks!

If you'd like to send a mail everytime a file has been moved from the watched directory, you'll need to set up a different process monitoring this and sending the mail.

For the reasons you have just described, it doesn't matter where you put the inotifywait command, since the mv command does not happen at the same time, you won't catch the required event.

But if you watched the directory from another process, the moving takes place while you're watching and you can detect any changes.

By building on the previous example, you can start with the following sample script.

while true
do
    fileName=$(inotifywait -e moved_from /home/posto-11v/Documents/Processo/CONCLUIDO | sed -r 's/^.*MOVED_FROM(,ISDIR)*\s+(.*)$/\2/g')
    mail -s "$fileName" USER@MAIL.HOST < ~/Documents/personaproject/Programa/scripts/mail.txt
done

Please fill in the required details, it works basically the same as the previous example.

Note:
There are a few caveats, for example it might miss some moves while the mail is sent. It depends on the quantity and frequency of moves.

zenity --warning --text "my text" &

run as a background command, non blocking


How do I get the shutdown option back on my menu? When I click at the top to shutdown, the popup window no longer has the shutdown or reboot option but instead only log out or lock. When I click log out nothing happens. I keep having to execute the sudo poweroff command.

I'm an Ubuntu NOOB so please be gentle.

That seems to be a known problem. The solution varies depending on if you use Gnome or Unity. If you use the search engine on this site you'll get pointers. Different possible solutions are mentioned but the following two are mentioned often.

In Unity it seems to work if you type in the terminal:

unity --reset

In Gnome it seems to work if you type in the terminal the following commands:

gconftool-2 --shutdown
rm -rf ~/.gconf/apps/panel
pkill gnome-panel

Some users however report that neither works.

I have had the same problem and this hint did not work for me.

In my case, some setting in unity-tweak-tool must have messed around here. I did not find the specific option but when I click reset to default on every single page of unity-tweak-tool, Shutdown option was back.


How do I open .jar files without using terminal in manually installed java? How do I open .jar files without using terminal in manually installed java? . I tried open with dialog but java is not there .so How do I manually create it?

Edit

I want some thing like this

Install Ubuntu Tweak.

Go to the 'admins' section, open the File Type Manager, Select 'All' file types, find and select Java Archives in the long list, choose edit, choose the Add button, click on the 'custom command' twisty at the bottom and type the custom command you need it to use to open the file the way you desire.

Here's a picture I did for another question

right-click on it, go to "permissions" tab and check "allow executing file as program"


What does it mean to run gedit in standalone mode? I was reading man gedit, when I stumbled upon this:

-s, --standalone
              Run gedit in standalone mode.

The official gedit documentation on this subject did not make me much wiser. So...

What does standalone mode really mean?
When would I need this?

Looking it at the source, -s makes gedit always start a new process and a new window, rather than adding a tab to an existing gedit window that's already running. Useful if you're worried about one window crashing taking down the other. You can do the same thing with gnome-terminal with the "--disable-factory" switch, which is useful, as g-t has been known to crash, and take down the processes running in all your tabs and windows with it!

Edit: And the docs you linked above point out that it's also useful if you're invoking gedit from a batch file, or from a mail program, etc. - "gedit -s" will create a new process that won't exit until the window is closed, whereas plain "gedit" will return immediately if there's already a gedit process running.

My guess is that standalone mode will not use your settings and profile to start, so it can be usefull if you have a corrupted profile or settings that avoid you from starting the application.


how to display quota info on lock screen? Is it possible to display user quota info on lock screen or any message at least?
because every time user lock in or unlock the first window he/she will look at is going to be lock screen.

Till now there is no option to do that. If you wish you can download the source code of the unity-greeter and lightdm and try to do it yourself. But This is not a valid option right now.


Colored boxes on around the folder name in terminal I gave local user to read and write permission to a particular folder using command

       chmod 777 /data/folder/

Now I am seeing a colored box hovering the folder's name which I really bugging me.Is there any way I can remove it ?
I can't attach the image because I don't have reputation of 10.

chmod 777 sets permissions so that the owner, group and others can read, write and execute. The highlighting is shown if others can write to it. If you don't need that, just chmod o-w /data/folder. Also, if you are the only one who needs to use the folder, I would suggest 700 or 755.


How to connect the stderr in netcat? Suppose i have two shells (A and B). And i execute command below for first shell:
nc -lvp 7777 -e /usr/bin/bash

And in the second shell i execute :
nc localhost 7777

After that, i type 'something' in the first second shell but the stderr is in the first shell below:
bash: line 1: something: command not found

I want to put stderr in the second shell not the first shell.
What should i do?

The idea is applicable. I just did some tests but couldn't make it work because of quotes. Maybe someone can make this work?
Listener:
nc -lvp 7777 -e '/usr/bin/bash -c "bash 2>&1"'

But you can do it manually. From the already open shell you start another shell with stderr redirection.
So after you establish a connection and have a shell you run the following.
bash 2>&1

It opens another shell but this time stderr redirected to stdout.

This works on windows. Based on this example you should find a way to make it work on linux. It runs two cmd.exe but it gets the job done.
ncat 127.0.0.1 4444 -e "cmd /c (cmd 2>&1)"


How to obtain a white background for vim (not gvim)? I've downloaded a variety of colorschemes for vim, but none of the white background colorschemes that I've tried have worked in vim, only in gvim. I expect this has to do with the color limitations of the terminal.

I don't need 256 colors, but I would like a decent looking white background that gives some syntax highlighting in the regular Ubuntu 11.04 terminal window.

Suggestions?

See:

https://stackoverflow.com/questions/1117526/vim-background

The lightest background possible is a light gray.

:highlight Normal ctermfg=blue ctermbg=gray

Use

:highlight Normal ctermfg=blue ctermbg=none

to get a white background


How to change the date format? Presently the date is showing as mmm dd hh:mm:ss. Is there any way that I can change it to as per my liking. For example : dd mmm, hh:mm:ss.

Terminal method

First you need to tell the indicator to use a custom format. To do so, run this from a gnome-terminal:

gsettings set com.canonical.indicator.datetime time-format "'custom'"

Then you need to tell the indicator which format to use. This has to be done in a format understood by the strftime function. You can look it up here.

For example, if you want the date/time to look like this: Fri, 20. May 08:25, the format string for it would be %a, %d. %h  %H:%M. Now let's set it:

gsettings set com.canonical.indicator.datetime custom-time-format "'%a, %d. %h  %H:%M'"

GUI method

You can also set those keys using a GUI called dconf-editor. It's part of the package dconf-tools, which you'd need to install first by running sudo apt-get install dconf-tools. Then open dconf-editor, navigate to com.canonical.indicator.datetime, and set the two keys.

Ubuntu 14.04. I don't want to install dconf-editor.

I just tried the following in a terminal:

$ gsettings set com.canonical.indicator.datetime custom-time-format "'%a %Y%m%d-%H%M%S'"
$

As you can see, there are no error messages or anything.

I then log out and log back in, but there has been no change to my clock display, which is currently %a %b %e %Y %T.


Ubuntu 14.04 - changing Intel graphics driver configurations? I am running a graphics toolbox using Matlab called Psychophysics. I am this close to getting everything working, but I'm having drama with synchronization errors which has to do with my driver settings. Check this post out:

He says the error below is most likely due to a few options needed to be reset, most notably

Option "TripleBuffer"    "off"
Option "SwapbuffersWait"  "on"

My question is how do I even reset these values? He mentioned the xorg.conf file, but I've read in many different places that this file isn't used anymore. I can't find it using the 'find /usr -name xorg.conf' unix command on my system either (and that would take forever). I'm also afraid I will ruin my graphics card if I don't talk to someone who knows their stuff.

Here is my error message:

 PTB-INFO: No low-level controllable GPU on screenId 0. Beamposition
 timestamping and other special functions disabled.

 PTB-DEBUG:PsychOSGetSwapCompletionTimestamp: This likely means a
 driver bug or malfunction, or that timestamping support has been
 disabled by the user in the driver!

 PTB-INFO: OpenGL-Renderer is Intel Open Source Technology Center ::
 Mesa DRI Intel(R) Sandybridge Mobile  :: 3.0 Mesa 10.1.3 PTB-INFO: VBL
 startline = 768 , VBL Endline = -1 PTB-INFO: Will try to use
 OS-Builtin OpenML sync control support for accurate Flip timestamping.
 PTB-INFO: Measured monitor refresh interval from VBLsync = 16.682734
 ms [59.942213 Hz]. (297 valid samples taken, stddev=0.322476 ms.)
 PTB-INFO: Reported monitor refresh interval from operating system =
 16.646968 ms [60.070999 Hz]. PTB-INFO: Small deviations between reported values are normal and no reason to worry.

 WARNING: Couldn't compute a reliable estimate of monitor refresh
 interval! Trouble with VBL syncing?!?

 ----- ! PTB - ERROR: SYNCHRONIZATION FAILURE ! ----

 One or more internal checks (see Warnings above) indicate that
 synchronization of Psychtoolbox to the vertical retrace (VBL) is not
 working on your setup.

Create a new file in /usr/share/X11/xorg.conf.d called any-name.conf. Put options in there. They get merged into the auto-generated xorg.conf when X starts.

Here's something from my machine:

% cat /usr/share/X11/xorg.conf.d/20-intel.conf
Section "Device"
  Identifier  "Intel Graphics"
  Driver      "intel"
  Option      "AccelMethod"  "sna"
  Option      "TearFree"    "true"
EndSection

Make sense?

I think I solved the issue relating to this.

I'll just walk through the steps here in this answer (I don't know if there's a better way though)

Get the latest intel drivers here and just click on the deb that opens the package manager and click install there. (This could take a lil while)
Go to the terminal and execute

intel-linux-graphics-installer

Once done, reboot

Now we have to make the xorg.conf file. For this:

Create a file called xorg.conf in /etc/X11/. If xorg.conf already exists, back the old one up and create a new one. You will need superuser (sudo) access to edit this file
The contents of the xorg.conf follow

Section "Device"
    Driver      "intel"
    Identifier  "PTB: generic TripleBuffer off"
    Option      "AccelMethod" "uxa"
    Option      "TripleBuffer" "off"
    Option      "SwapbufferWait" "on"
EndSection

Now log out and log in again.

Follow these steps and you must be good to go :) Let me know if you face any issues

SC


"Failed to download repository information" error, what to do? Well, some sources of softwares aren't working; mostly all the universe and multiverse sources' applications are not installable... shortly the problem has shown in the picture in the link below. Please help!

If possible, could you edit your question to show the two lines in full that we can see part of in your screenshot?  I don't think this in an internet connection-related problem. If it was, ALL of the repositories would have failed to download if this was the case, not just one or two.  There are a couple of possibilities that I am aware of that could cause this.

As mentioned in Tareq's answer, perhaps the Ubuntu server for your area is temporarily having problems.  If this is the case, there should be mention of a 404 error at the end of each line that failed to download.  Things like this should be fixed in a matter of only a day or two in most cases.
Try running an update from the terminal and see if you get the same (or different) errors.  Simply open a terminal and run the following command:

sudo apt-get update

Wait for it to finish and then see if you still have errors.

Perhaps for some reason you are missing one or more GPG Keys.  These keys are a security function that helps to keep the repositories safe.  If this is the case, you should see something like NO_PUBKEY or something similar to this screenshot at the end of each line:

The best way to make sure you have all of your correct GPG Keys is to install launchpad-getkeys from the WebUpd8 repository.  Do that by entering the following lines in the terminal:

sudo add-apt-repository ppa:nilarimogard/webupd8
sudo apt-get update
sudo apt-get install launchpad-getkeys

After that, simply run the command:

sudo launchpad-getkeys

You will see something like this:

As it says, you shouldn't see anymore missing key errors.  When the program finishes, simply run Update Manager again or use the above commands to update from the Terminal.

sudo apt-get update

again and see if you still have the same problem.

Once again, I do NOT believe this is an internet issue unless it is on the other end.  Only one or two of your repositories failed to download, not ALL of them, and you can still use the internet, so if this is an internet-related issue it is on the end of the repository servers, as far as I know.  Hope this helps!

That's an internet problem! Are you able to access internet? if yes , and this still happens, then may be you're behind proxy with authentication.  You'll then need to provide proxy with password.


Firefox is slow after upgrade from Xubuntu 17.10 to 18.04 Firefox is much slower after the upgrade, and htop tells me that Firefox mostly uses only one CPU core, instead of distributing the load. Most importantly, Facebook is next to unusable after the upgrade to 18.04.

Steps I've already taken:

Enabling hardware acceleration in about:config
Using uBlock Origin to mitigate requests and traffic from third-party sites (as I did before)
Installed intel-microcode
Installed the Nvidia GPU drivers through Settings Manager

Incidentally, Core 4 seems to carry most of the Firefox load. I've never seen it jump to another core.

Go to the firefox > Edit > Preferenses > privacy & security panel and under permissions check the setting to prevent accessibility services from accessing your browser

I turned off Bluetooth found below Wi-fi settings. That fixed it for me.
Os-Ubuntu 18.04 LTS.


*.desktop files opening in Kate I've downloaded and am playing with the new Neon release of KDE. When I activate an item from the Kickoff menu, though, it opens up a *.desktop file in the Kate text editor instead of launching the item. What's the issue?

Background

I encountered this bug with a clean installation of 32-bit Kubuntu 16.10. After allowing updates to the system:

with Dolphin I browsed to remote: (Network)
I opened Add Network Folder
I expected a launch of knetattach (Network Folder Wizard – KDE Network Wizard)
instead, a .desktop file was opened by Kate.

I installed Thunar 1.6.11, browsed /usr/share/applications/ and found files, with representative names such as KNetAttach, behaving as expected.

Browsing the same directory with Dolphin, I found org.kde.knetattach.desktop and other .desktop files misbehaving; Dolphin failed to execute the required files.

Unix & Linux Stack Exchange

There's the accepted answer to KUbuntu 10.04 / Dolphin File Manager: Is there a way to make .desktop files display the filename the same as the NAME= in the metadata? – relevant to one of the symptoms that were observed in my case, but not a solution to the execution problem.

Super User

There's the accepted answer to KDE launcher opens .desktop files in Kate but what's suggested there did not work around the execution problem in my case.

The solution in my case

The reply to .desktop files are opened with text editor • KDE Community Forums refers to a 2015 topic:

How do I unset default to open .desktop in a text editor?

– I took a hint from a 2016 reply from mfrandsen.

nano ~/.config/kiorc

The file comprised two lines,

[Executable scripts]
behaviourOnLaunch=open

I edited the second line to read:

behaviourOnLaunch=execute

– then saved the file.

Immediately after the save, Dolphin behaved as expected.

@Ryan-muller I've been testing this with a *.desktop file.

Here's the contents of my *.desktop file.

[Desktop Entry]
Name=Gedit
Comment=Gnome Text Editor
Icon=/usr/share/icons/gnome/256x256/apps/text-editor.png
Exec=/usr/bin/gedit
Terminal=false
Type=Application
NoDisplay=false
Name[en_US]=Gedit
GenericName[en_US.UTF-8]=Gedit
Comment[en_US.UTF-8]=Gedit


Is it possible to exclude a file or folder from being synced, while it is in a directory that was synced? I synced a folder called "travel".  I want to exclude a file in this folder from being synced.  Is this possible?  Do the other big syncers, like dropbox and mozy, have this feature?

Ubuntu One does not currently support this; a workaround would be to move the folder out from the folder it is currently in (and point a symlink at it from the synced folder if necessary), or rename it to something unique and add that name to the 'ignore' pattern list (this second way is rather tricky; please read the note below).

Here's how to do the first: assuming travel is in a directory called misc, and that the subdirectory of travel you don't want synced is called huge, open a terminal (Applications » Accessories » Terminal) , and type:

 cd misc
 mv travel/huge .travel_huge
 ln -s ../.travel_huge tavel/huge

note that .travel_huge is a hidden directory, so you wouldn't normally see it in the nauitlus and file pickers.

Here's how you do the second, asuming the unique name you chose for huge is huge-pics-of-acorn-trees-february-2011: first, edit ~/.config/ubuntuone/syncdaemon.conf (you can use Applications » Accessories » Text Editor) and add the following to the __main__ section (if the file doesn't exist, prepend the following by a line containing just [__main__]):

ignore = \A#.*\Z
         \A.*~\Z
         \A.*\.py[oc]\Z
         \A.*\.sw[nopx]\Z
         \A.*\.swpx\Z
         \A\..*\.tmp\Z
         \Ahuge-pics-of-acorn-trees-february-2011\Z

or you could simply rename the folder to something already covered by the current ignore list, such as huge.tmp or huge.pyc, but I doubt you'll like that.

Please do note, however, that the second method described is rather fragile: make sure you've updated the configuration file and restarted syncdaemon (with u1sdtool -q; u1sdtool -c) before creating the toplevel directory. If the directory already exists, do not move it to the ignored name with the syncdaemon running; rather, stop syncdaemon, rename the folder, edit the ignore list, and start syncdaemon. Alternatively move the folder out of the synced hierarchy, and rename it before moving it back in. Otherwise it might not work as you'd expect it to, if at all.

I understand dropbox has the feature (I've seen a video explaining how to use it), but I haven't checked and it might only be in a beta or something like that.

In answer to your question about the other big syncers: Dropbox doesn't appear to have a way to selectively ignore specific files/file types, but this post by Dylan R. provides a way to selectively ignore folders.

In a nutshell, it goes like this:

Back it up, just in case :)
Quit whatever application may be using/writing to the folder
Move the folder that you want to not sync out of dropbox
Let that sync
Make a folder with the same exact name in the same exact place
Use Selective Sync to stop syncing that (empty) folder.
It will remove the (now-empty) folder.
Move your original folder
back in.

It'll get a gray minus icon, and is no longer syncing. (the
    empty folder has to remain on Dropbox, but it's empty, so not taking
    up space)


Can't use USB adapter 0846:9014 NetGear, Inc. in Ubuntu 16.04 I have just installed Ubuntu 16.04 alongside with Windows 10 and when I am trying to connect to WiFi, i can´t even see it there as an option.
This is what I see

I have disabled Secure Boot in Bios and after running sudo lshw -C network, all I see is this

Despite searching online on how to install or update the wifi drivers, I haven't found anything that works for me. Any help will be much appreciated.

UPDATE

I followed the suggestion of @Mahesh and as you can read in my comment below, on the top right corner where I was seeing the icon to connect to the internet ( the first picture of my question), I cannot see anything now, and I am freaking out. Can you please help?

Output of lspci here:

00:00.0 Host bridge: Intel Corporation 4th Gen Core Processor DRAM Controller (rev 06)
00:02.0 VGA compatible controller: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller (rev 06)
00:03.0 Audio device: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor HD Audio Controller (rev 06)
00:14.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 04)
00:16.0 Communication controller: Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #1 (rev 04)
00:16.3 Serial controller: Intel Corporation 8 Series/C220 Series Chipset Family KT Controller (rev 04)
00:19.0 Ethernet controller: Intel Corporation Ethernet Connection I217-LM (rev 04)
00:1a.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #2 (rev 04)
00:1b.0 Audio device: Intel Corporation 8 Series/C220 Series Chipset High Definition Audio Controller (rev 04)
00:1c.0 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 (rev d4)
00:1c.3 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #4 (rev d4)
00:1d.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #1 (rev 04)
00:1f.0 ISA bridge: Intel Corporation Q87 Express LPC Controller (rev 04)
00:1f.2 SATA controller: Intel Corporation 8 Series/C220 Series Chipset Family 6-port SATA Controller 1 [AHCI mode] (rev 04)
00:1f.3 SMBus: Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller (rev 04)
02:00.0 PCI bridge: Integrated Technology Express, Inc. IT8893E PCIe to PCI Bridge (rev 41)

output of lsusb:

Bus 002 Device 002: ID 8087:8000 Intel Corp.
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:8008 Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 005: ID 093a:2510 Pixart Imaging, Inc. Optical Mouse
Bus 003 Device 004: ID 1a40:0101 Terminus Technology Inc. Hub
Bus 003 Device 003: ID 04b3:3025 IBM Corp. NetVista Full Width Keyboard
Bus 003 Device 002: ID 0846:9014 NetGear, Inc.
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Restart network manager.

  sudo service network-manager restart

Restart the nm applet.

  killall nm-applet && nm-applet &

then

  sudo lshw -class network

output look like this

  *-network
       description: Wireless interface
       product: Wireless 7265
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: wlp2s0
       version: 59
       serial: 60:57:18:78:f9:92
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=iwlwifi driverversion=4.4.0-28-generic firmware=16.242414.0 ip=192.168.1.20 latency=0 link=yes multicast=yes wireless=IEEE 802.11abgn
       resources: irq:49 memory:f7000000-f7001fff

With the above information available to us we can go to work and try to solve the resume from suspend issue.

sudo vi /etc/pm/config.d/config

In this file, paste the following

SUSPEND_MODULES="iwlwifi wlp2s0"

Now, issue a restart of the network manager

sudo service network-manager restart

that's it.


UUID=xxx does not exist. Dropping to a shell Because of a hardware failure my motherboard has just been replaced. After the replacement, my system (Ubuntu 17.10) doesn't boot:

  ALERT! UUID=dd84f4b3-d5bf-42e4-9b5e-ec685a461fad does not exist.
  Dropping to a shell.

I've used a Live USB Ubuntu to debug this problem. Here are some results:

/etc/fstab

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/nvme0n1p3 during installation
UUID=dd84f4b3-d5bf-42e4-9b5e-ec685a461fad /               ext4    errors=remount-ro 0       1

# /boot/efi was on /dev/nvme0n1p1 during installation
UUID=B38D-559B  /boot/efi       vfat    umask=0077      0       1
# swap was on /dev/nvme0n1p4 during installation
UUID=f4134c38-10b9-478f-b550-54650a9f5140 none            swap    sw              0       0

blkid

/dev/nvme0n1p1: SEC_TYPE="msdos" UUID="B38D-559B" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="98be6c97-c354-49a6-a432-9201d56a421b"
/dev/nvme0n1p2: LABEL="OS" UUID="B39E-7035" TYPE="vfat" PARTLABEL="fat32" PARTUUID="d3006358-8d82-4e0b-99f8-87a5261cf7e8"
/dev/nvme0n1p3: LABEL="UBUNTU" UUID="dd84f4b3-d5bf-42e4-9b5e-ec685a461fad" TYPE="ext4" PARTUUID="24e5b96d-f20c-43dd-9e48-672760b0e6f7"
/dev/sda1: LABEL="UBUNTU 17_1" UUID="88D4-322D" TYPE="vfat" PARTUUID="3d0a270b-01"

fdisk -l

Disk /dev/loop0: 1.3 GiB, 1427259392 bytes, 2787616 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 /dev/nvme0n1: 477 GiB, 512110190592 bytes, 1000215216 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
Disklabel type: gpt
Disk identifier: 43E35EBE-2A73-404A-9D4A-851815F33F9A

Device             Start        End   Sectors   Size Type
/dev/nvme0n1p1        34     488281    488248 238.4M EFI System
/dev/nvme0n1p2    488282    5934980   5446699   2.6G Microsoft basic data
/dev/nvme0n1p3   5935104  933576703 927641600 442.3G Linux filesystem
/dev/nvme0n1p4 933576704 1000214527  66637824  31.8G Linux swap

Disk /dev/sda: 28.7 GiB, 30752636928 bytes, 60063744 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
Disklabel type: dos
Disk identifier: 0x3d0a270b

Device     Boot Start      End  Sectors  Size Id Type
/dev/sda1  *     2048 60063743 60061696 28.7G  c W95 FAT32 (LBA)

It looks like the UUID's in fstab  are correct, but I still get that error message.

How can I repair my Ubuntu installation?

I've tried the given solution in ALERT! /dev/disk/by-uuid/xxxxxxxxx does not exist. Dropping to a shell, but unfortunately that didn't help (I mounted /dev/nvme0n1p3). Still the same problem.

Update:
When I select UEFI boot mode in system setup, I still get this problem. But when I select legacy boot I got 'no boot device found'. But here comes the tricky part: when I select legacy mode and use F12 to select UEFI/Ubuntu, it starts without a problem.

When I tried to use a pendrive Ubuntu to figure out this problem, I finally found out that the hard drive wasn't recognized when Legacy Boot was disabled. This explained why manually choosing UEFI did work.

The problem was that the new motherboard had the default settings, so RAID was enabled. Switching to AHCI solved my problem. This were the steps needed to change it: (borrowed from This answer)

Boot into BIOS (F12 at startup)
Select Bios Setup
Move to System Configuration→SATA Operation and select AHCI

I had this problem too where blkid confirmed the UUID in the alert was correct.  Fixed it by changing my EFI partition to 500 MB and my root partition to 20 GB.  Apparently some older BIOS don't like root volumes over 25gb

Edit: actually I was able to expand root to 100gb in GParted after successfully booting into the OS.  Perhaps it was the 500 MB EFI partition that actually fixed it. Not sure.


How do I get turbo boost working? I have a HP Pavilion dv6-2190us Notebook, its got 8GB DDR3 and an i7 processor with 1.60GHz (Turbo Boost up to 2.80GHz)

I'm not sure if I'm doing something wrong or missing step or what but I can't for the life of me figure out how to get the turbo boost working.

It's a real pain because 8x 1.6GHz really sucks, I'm starting to wish I had an i5 with less cores but more clock speed per core...

Is there anything I can do either enable speed step/turbo boost or maybe just keep it overclocked all the time?

Oh, I'm running Ubuntu 10.10 64-bit.

THANKS!

Edit I followed the procure here but my results don't change at all when I execute the loop.

cpu MHz     : 1600.000
cpu MHz     : 1600.000
cpu MHz     : 1600.000
cpu MHz     : 1600.000
cpu MHz     : 1600.000
cpu MHz     : 1600.000
cpu MHz     : 1600.000
cpu MHz     : 1600.000

Try installing turbostat (from the linux-tools package) and run sudo modprobe msr ; sudo turbostat and see what that says for the processor speed.

The frequency shown in /proc/cpuinfo is always capped to the "normal" CPU speed when in fact turbo boost is working fine.

Like sad David Gardner best solution it's turbostat which in additional Linux-tools it show real frequency. It works with cpu on Ivy Bridge where cat /proc/cpuinfo can't show real info. I can also recommend to use this script

cd && wget -O .laptop-mode.sh http://goo.gl/AH0tvj
chmod +x .laptop-mode.sh && ./.laptop-mode.sh

It help tune cpu and force turbo boost to work constantly. I should notice that turbo boost not gonna work with max frequency for all cores. For frequency arrange check official information specs for you cpu.


Two different workspaces for two monitors I know this question has been asked before in the last 5 years or so, but my situation seems to be different.

I recently aquired a new monitor for my laptop and I'd like to view a separate workspace on each monitor. I managed to have an extended workspace, but I had to replicate the panels and this seems to create a few problems, particularly with the clock and the notification area and I have a few other reasons to prefer separate workspaces instead of the extended workspace.
A few informations about the setup:

OS: Ubuntu MATE 15.04
Graphics card: NVIDIA GeForce GT 540M
Graphics card driver: nvidia-304 (NVIDIA Legacy Binary Driver)
Changed to nvidia-346 (NVIDIA Binary Driver) - no improvement.
Laptop: Acer Aspire TimelineX 4830T

Seeing previous questions, I have to add that I installed Bumblebee to reduce battery consumption and heat production and a change in this direction is acceptable only if it achieves the same results, i.e. switching off the graphics card for most of the time. There is a list of different drivers, in particular nvidia-346 is recommended, but I must admit I never dared to change it, because until now the current driver worked perfectly.

I couldn't find this question answered for my particular case (MATE+Bumblebee), only a few old questions (~2011) that say it's not possible. Did it became achievable? And if yes, how?

Thanks for the answer and for your time.

Edit: I also tried to upgrade the driver to nvidia-346, but nothing changed. I noticed nvidia-settings is almost completely empty.

Easy. All you have to do is to run Displays in the MATE menu. Then choose expand desktop.
Then, according to this link, all you have to do is:

Right-click the panel you wish to move and select “Properties”.
Uncheck the “Expand” option under the “General” tab.
Grab one of the edges of the panel by clicking on the left or right end (top or bottom end for vertical panels)
Drag the bar to the desired screen and position
Check the “Expand” option in the “Panel Properties” window and click “Close”.


What does "sudo apt-get update" do? I am wondering what sudo apt-get update does?

What does it update?

In a nutshell, apt-get update doesn't actually install new versions of software. Instead, it updates the package lists for upgrades for packages that need upgrading, as well as new packages that have just come to the repositories.

apt-get update downloads the package lists from the repositories and "updates" them to get information on the newest versions of packages and their dependencies. It will do this for all repositories and PPAs.
From http://linux.die.net/man/8/apt-get:

  Used to re-synchronize the package index files from their sources. The indexes of available packages are fetched from the location(s) specified in /etc/apt/sources.list(5). An update should always be performed before an upgrade or dist-upgrade.

apt-get upgrade will fetch new versions of packages existing on the machine if APT knows about these new versions by way of apt-get update.

From http://linux.die.net/man/8/apt-get:

  Used to install the newest versions of all packages currently installed on the system from the sources enumerated in /etc/apt/sources.list(5). Packages currently installed with new versions available are retrieved and upgraded; under no circumstances are currently installed packages removed, nor are packages that are not already installed retrieved and installed. New versions of currently installed packages that cannot be upgraded without changing the install status of another package will be left at their current version. [Emphasis mine] An update must be performed first so that apt-get knows that new versions of packages are available.

apt-get dist-upgrade will do the same job which is done by apt-get upgrade, plus it will also intelligently handle the dependencies, so it might remove obsolete packages or add new ones. See here: What is "dist-upgrade" and why does it upgrade more than "upgrade"?

From http://linux.die.net/man/8/apt-get:

  In addition to performing the function of upgrade, this option also intelligently handles changing dependencies with new versions of packages; apt-get has a "smart" conflict resolution system, and it will attempt to upgrade the most important packages at the expense of less important ones, if necessary.
  The /etc/apt/sources.list(5) file contains a list of locations from
  which to retrieve desired package files. See also apt_preferences(5) for a mechanism for over-riding the general settings for individual packages.

You can combine commands with && as follows:

sudo apt-get update && sudo apt-get install foo bar baz foo-dev foo-dbg

or to get newest versions possible as per version requirements of dependencies:

sudo apt-get update && sudo apt-get dist-upgrade

You need sudo both times, but since sudo by default doesn't prompt you within 5 or so minutes since the last sudo operation, you will be prompted for your password only once (or not at all).

Let's consider the example of installing VLC media player on Ubuntu:

sudo apt-get update

It will check the repositories for available updates.

Whereas

sudo apt-get install vlc vlc-plugin-pulse mozilla-plugin-vlc

will install VLC media player from the repositories which we searched for.

If you had logged in as a root user (administrator), you don't have to use sudo, because you already have the super user privileges.


Ubuntu 14.04 running very slow after upgrade 32 bit to 64 bit I just upgraded my Ubuntu 14.04 32 bit to 64 bit. I find right after I boot it the first time that the machine is running really slow, even slower than when I had the 32 bit version.

I find that when I run top command, the compiz process is occupying 90% of the CPU. I tried to resolve that somehow, but no success yet. I also saw a message from the system saying that 3D at this time is being done in software and X is not using hardware acceleration to achieve it.

I want to ask if someone else also faced this issue, and how could I bring my machine up to speed.

I have i7 processor with 16 GB of RAM.

see the post for ubuntu 12.04 and solving memory issues with compiz

Compiz using 8% - 25% cpu continually

most of the fixes are backup/delete setting file or changing compiz settings

For 64 bit O.S you must have more than 4GB RAM, in other case will be very Slow !!! I had the same problem, finally reinstalled 32 bits and my laptop is fast again.


Gnome-terminal doesn't refresh Gnome-terminal works just fine when I am running Unity, but when I run Gnome shell,
terminals don't work properly and have to be constantly refreshed.
This is particularly annoying when using "vi" to edit text files.  In the old, old
days, I saw problems like this when the ".profile" file didn't have the correct
setting for TERM.  But I thought that modern distributions had pretty much
solved this issue.

In anyone else seeing this behavior?  Hard to believe that it's only me
with this problem.

For what it's worth, I have this issue on every one of my four Ubuntu 11.10
installations, so I know it's not a hardware issue.

This has been reported as a bug:  https://bugs.launchpad.net/ubuntu/+source/nvidia-graphics-drivers-180/+bug/303224

A possible fix is presented in that bug report.  I can confirm that it helps in my case.  The fix is to install compizconfig-settings-manager and then run ccsm.  Use advanced search to change the following settings, then log out and log back in.

Texture filter: best
Lighting: checked
Detect refresh rate: unchecked
Refresh rate 200
Sync to vblank: unchecked

Try guake if you use terminal a lot. It's dead handy :)


How to prevent running out of disk space? Often an automated process will completely fill up the main drive and I won't even be able to login over SSH to fix it.  How do I prevent all the space from being used, so that I can always login to my headless server with SSH and delete something?

can't create socket: No space left on device

(There are an infinite number of things that could fill space. A good answer will not care which of them is doing it, but will prevent them from using the space that ssh needs to function.)

Several Linux filesystems, including the most common one ext4, have a feature to deal with this exact problem: by default 5% of the space on the drive is reserved for the root user. This ensures the administrator can always log in to fix out-of-space problems.

TL/DR:

Enable the root account in Ubuntu
Configure the SSH daemon to allow root login
Login with the root account whenever lack of space is preventing normal login

A security note is in order: allowing root logins should be done with care. In particular, it's recommended to allow root login via certificates only, no password logins allowed. In any case, make sure when you define the root password to make it a strong one (it should rarely be needed interactively anyway, so go to town on the password length).

Well first try to figure out what is filling up your space. Try to remove any bloatware or background processes which might be filling up your space.
You can use: sudo iotop -a or any df commands.
Then if there is necessary application which can't be stopped then make a cron job or a habit of regular cleanup of cache and temprary files.
There are many ways to clear up your cache.Try:
du -sh /var/cache/apt/archives
sudo apt-get clean
sudo apt-get autoremove --purge
sync; echo 1 > /proc/sys/vm/drop_caches
sync; echo 2 > /proc/sys/vm/drop_caches
sync; echo 3 > /proc/sys/vm/drop_caches


How do I install ATI Radeon HD 3650 driver on my pc? I need help on this.

I want to try using Ubuntu so I downloaded the 11.10 version over the net.

Well after the installation my desktop, I have run the the additional drivers. It installed about 70+ items I think and after a while a window pops up and asks me about the radeon driver, something about the 2 options, the propriety drivers I think.

I tried installing the 1st one but I got an error, and I tried the 2nd one and I installed it. After installation it asked me to restart. After I restart, I cant see the Ubuntu interface anymore. All I get to see is a black screen with a message moving around saying:

Input Not Supported.

So can I ask how can I install the graphics driver for my PC? I want the cool effect of Ubuntu.

I'm a super newbie in using Ubuntu so please bear with me:)

First of all, uninstall the proprietary driver to see a desktop again. Press ALT+CTRL+F1, login and type following commands:

Removing proprietary driver

sudo sh /usr/share/ati/fglrx-uninstall.sh
sudo apt-get remove --purge fglrx fglrx_* fglrx-amdcccle* fglrx-dev*

Install open-source driver again

sudo apt-get remove --purge xserver-xorg-video-ati xserver-xorg-video-radeon
sudo apt-get install xserver-xorg-video-ati
sudo apt-get install --reinstall libgl1-mesa-glx libgl1-mesa-dri xserver-xorg-core

sudo mv /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
sudo rm -rf /etc/ati

If you receive: "$ E: Internal Error, No file name for libgl1-mesa-dri..."

Change third command above so:

sudo apt-get install --reinstall libgl1-mesa-glx:i386 libgl1-mesa-glx:amd64 libgl1-mesa-dri:i386 libgl1-mesa-dri:amd64 xserver-xorg-core

Now reboot your computer with:

sudo shutdown -r now

Now your default open-source driver will be used.

To install newest Catalyst driver, following this step-by-step guide from here:

http://wiki.cchtml.com/index.php/Ubuntu_Oneiric_Installation_Guide

Mmm... Your problem is very strange, probably you need to reinstall the Ubuntu installation, you can try to enter in text-console (like recovery) mode, selecting it on the grub options (options displayed at the start after boot Ubuntu) and if this work, you most log in specifying your username and password, next tray to download the official driver, typing the next commands:

x86/x64:

wget http://www2.ati.com/drivers/linux/ati-driver-installer-11-9-x86.x86_64.run
sudo chmod +x ati-driver-installer-11-9-x86.x86_64.run
sudo ati-driver-installer-11-9-x86.x86_64.run

If this not work, you must reinstall Ubuntu completely, and before to logged in, download and install manually the package described up (driver).


Samsung ML-1865 printer not working Ubuntu 17.10 I have been trying to install the drivers for my Samsung ML-1865 printer since I installed Ubuntu 17.10 but have had no luck yet.

I downloaded the Ubuntu drivers from here:
https://support.hp.com/us-en/drivers/selfservice/samsung-ml-1865-laser-printer-series/19134664,
but every time I try to print something I get a blank page with the message:

INTERNAL ERROR - Please use the proper driver.
POSITION: 0x0 (0)
SYSTEM: h6f2_5.49/xl_op
LINE: 180
VERSION: SPL 5.49 10-20-2010.

I have no idea how to solve this problem. Any help is more than welcomed :)

so if I were installing the driver; I would download uld_v1.00.36_00.91.tar.gz from your link and then open a terminal and paste in the commands below

cd Downloads
tar -zxvf uld_v1.00.36_00.91.tar.gz
cd uld
sudo ./install.sh

and that should install the driver; please tell us if you did that

for ml-1860 you can solve it installing "printer-driver-splix" and this ppd --> https://mega.nz/#!9kcz2Cbb!xwTwiaD-RJTtEDu19V1NFSxZiAcRLapId0HO82Rs3Vc it could work to ml-1865 too...


How can I play video file with .vmw extension? I tried VLC and mplayer, but both failed to play video file with .vmw extension. I have given the following message

Required plugin could not be found
Python (v2.7) requires to install plugins to play media files of the following type: video/x-asf-unknown decoder

There is no .VMW video file extension. After a detailed research I found what you meant is .WMV extension. This is simply a video compression format launched by Microsoft just for market competition. To see all the available video encapsulation formats click here.
For the above reason, this type of files is proprietary and Windows didn't allow open source software, such as Ubuntu, to read this codecs until recently. Follow this link to get full information on what these files are and how to open them inside Ubuntu.
The steps comprise of installing VLC, which I understand you have, and unlocking the "Restricted Extras" package from Ubuntu to unlock WMV files.
For the purpose of clarity, see the encapsulation formats we have in VLC in this screenshot.
.
I hope this clarifies and takes out all your doubts in the Q&A. Success!

You can go here and add the ppa. Then type in the terminal sudo apt-get update once done open the software center and search for w32 codecs or w64 codecs which ever your computer needs, also search in the software center for Ubuntu-Restricted-Extras install these and I am sure this should fix your issue


How to switch language keyboard combination? I would like to type Hebrew in Ubuntu. I tried downloading the Hebrew language pack and then setting alt-shift as my layout-change shortcut in the Options section of "Keyboard Layout".

However, when I actually press alt-shift, nothing happens. How can I switch my keyboard layout to Hebrew?

Ubuntu 17.10 and newer (GNOME Shell)
From this answer: After adding the desired languages (by navigating to Settings -> Regional & Language), you can use the default keyboard shortcut which is Super+Space ("super" is another name for the Windows key), or you can click on the top bar menu:

Ubuntu 13.10 to 17.04 (Unity)
As of Ubuntu 13.10, it is now called Text Entry Settings instead of Keyboard Layout
It can be reached through either of these methods

Going through System Settings -> Text Entry
Using the App Indicator as shown in the screen-shot below.

Ubuntu 13.04 and older
Seems you forgot an important step.

Download Hebrew language support. You can do this from the Install/Remove Languages section of "Language Support".
System Settings -> Keyboard Layout -> "+" -> "Hebrew" -> Add
System Settings -> Keyboard Layout -> Options -> Keys to Change Layout -> mark [alt]+[shift] (this step is optional, only if you want that custom keyboard shortcut)

An icon like this should appear in the upper-right after step two:

If you installed language support after keyboard installed you may be experiencing no action on selected combinations (like @OndrejCertik reported above).

You should reset keyboard layout defaults in that case by System Settings -> Keyboard Layouts -> Reset To Defaults and setup Key(s) to change layout again under Options... there.


Ubuntu Wine - cannot find C:\\windows\\system32? I have installed wine 1.8 and winetricks on my Xubuntu 16.04 but I have the error below when I try to install an exe file:

wine: cannot find L"C:\\windows\\system32\\Set-up.exe"

Any ideas why and how I can fix it?

Run the Configure Wine application from the launcher or open a terminal with CtrlAltT and issue the command winecfg Either way you will get a Configuration Window for Wine. Insure that you are emulating the right version of Windows for your application and that the settings on all the tabs are sane. Drive Mapping Example Below:

Note: In a typical installation of Wine The directory noted in your question can be found at ~/.wine/drive_c/windows/system32 and you can examine the content with the command.
ls ~/.wine/drive_c/windows/system32
You can find the location of the Set-up.exe file in your question with the terminal command find ~/.wine -name Set-up.exe provided it's anywhere close to where it's supposed to be.
On the off chance you've placed it somewhere outside the Wine drive mapping environment you should be able to locate it with the command sudo find / -name Set-up.exe
If anything in this answer is unclear please leave me a comment and I'll do my best to clarify.

Related to this issue>
This is regarding a wine bug https://bugs.winehq.org/show_bug.cgi?id=39403 described in this link
https://www.reddit.com/r/wine_gaming/comments/3vuuu9/steam_store_cant_connect_giving_me_black_screen/ .  I want to show installing wine/windows steam games from The Linux Terminal is possible despite the black screen.This allows them to appear in your steam games Library.

There is one problem that must be fixed first and is shown is my work/ research:

In terminal issue:

wine steam.exe

you get this:
wine: cannot find L"C:\windows\system32\steam.exe"

Wine wants any windows executable programs to be installed there for some reason. In my case steam.exe

Solution:

wine start /d "C:\nameoffoldercontainingexecutable" example.exe

For example:

  steamsetup.exe is installed in  C:\Program Files where i like it to be.

Therefore the magic key to issue a command for installing any windows game from the  Linux terminal in wine steam is:

wine start /d "C:\Program Files\steamfoldername" steam.exe -applaunch steamappID#

The steam app ID is found in the URL of the steam game's web page.

wine start /d - Sets the working directory for the executable.

I apologise for combining multiple subjects but to me this is my first post to help others and this is a complicated issue but I hope my idea can be used effectively in a post.

Thank you

NOTE For some very rediculous reason when i finish editing this post the windows command line bars shows only 1   \   at a time. They should have 2 for each typed. I can't explain this otherwise.


How do I provide a username and password to wget? I've tried to connect to a server via wget:

wget http://<user>:<pass>@serveradress

But wget responds: invalid port

I know that the server accepts incoming traffic at port 80.
How can I fix this issue?

Wget interprets <pass>@serveraddress as port. To specify a username and password, use the --user and --password switches:

wget --user user --password pass http://example.com/

From man wget:

  --user=user

  --password=password

  Specify the username user and password password for both FTP and HTTP file retrieval. These parameters can be overridden using the
  --ftp-user and --ftp-password options for FTP connections and the --http-user and --http-password options for HTTP connections.

The command could have used --http-user and --http-password instead of --user and --password. In case of ftp request the options are --ftp-user and --ftp-password.


Playing WMA files with cmus produces static and distortion in 14.04 I use cmus as a media player and after upgrading to 14.04, all WMA files in my collection have become unplayable. When I try playing them, I get static in my left speaker and a staticky distorted version of the music in my right speaker.

How can I fix this issue? Maybe have cmus use a different codec for wma? (WMA files still play fine in mplayer.)

Problem is apparently related to the libavcodec/ffmpeg fork: https://github.com/cmus/cmus/issues/139

I fixed cmus by installing libswresample-dev and the rest of the ffmpeg dev libs from this PPA (replacing the libavcodec libs):

https://launchpad.net/~jon-severinsson/+archive/ubuntu/ffmpeg

Then ./configure CONFIG_FFMPEG=y to make sure that ffmpeg.c works and building and replacing cmus.

I solved the problem by going to https://github.com/cmus/cmus and compiling the program from source..  I am using Ubuntu 14.04.1 LTS...


Unable to connect to remote server via SSH (requires public key) So i've been given access to ssh a server. I have the username/password, but server apparently requires a public key (now bear in mind that i am a noob in ssh). When I do:

ssh -p 52 user@server.com

terminal says Permission denied (publickey). So I went using

ssh-keygen -t rsa

and got myself the id_rsa and id_rsa.pub files in /root/.ssh. Chmoded /root/.ssh to 700 and /root/.ssh/* to 600. Tried sshing server.com again, same error.

What am I missing? I've been given a Putty Pagant Key file (.ppk) by the SYSADMIN of server.com. Apparently, other users (all Windows) can connect using Putty Pagant.exe. Please help :)

If you have been given the .ppk file by the sysadmin, you can use puttygen to create the ssh key files (install putty-tools from software centre)

Install putty:
sudo apt install putty putty-tools
Create the public key file:
puttygen /path/to/puttykey.ppk -L > ~/.ssh/id_rsa.pub
Create the private key file:
puttygen /path/to/puttykey.ppk -O private-openssh -o ~/.ssh/id_rsa

also, there are some mac instructions  which should also work

Note that when running command

puttygen /path/to/puttykey.ppk -O private-openssh -o ~/.ssh/id_rsa

it may ask for password to decrypt the key, plus you should run it as the user which will make the ssh connection so that it stores the key in the correct directory (the ~ symbol is equivalent to the home directory of the current user)
Then after checking the chmod permissions are correct you can use

ssh -p 52 user@server.com

Dear, you did a good job but lost your concentrate, there is two
steps, whatever, thanks for the great idea, I just over come.

ssh-keygen -t rsa
ssh-keygen -t dsa
cd /root/.ssh/
cp **** /etc/ssh/

now replace 4 the respective files


PulseAudio is not working at all I installed PulseAudio two weeks ago and since then I've been trying to open it and it doesn't.

Does anyone have any solution?

P.S. I have a horrible Speaker set.

PulseAudio is included and configured for you already in Ubuntu by default, you don't have to run it manually. So, if you have some problems with sound, I don't think that is because of PulseAudio. It could be a bug or maybe a hardware problem.

You can check it if is working ok with pulseaudio --check in a terminal - produces no output on the console except for errors to stderr.

See man pulseaudio for more informations.

Also, for more help, you can follow this question: Sound problems after upgading to 13.04 and this Sound Troubleshooting Procedure.

You could try to remove it with:

sudo apt-get autoremove pulseaudio

and update and reinstall with:

sudo apt-get update && sudo apt-get install pulseaudio

If this does'nt work, maybe you can find some help in one of these steps:

Ubuntu Sound Troubleshooting


Wifi doesn't detect any networks on 16.04 I'm having troubles with wifi. I'm using a MacBook Pro 7,1 with a Broadcom 4322 wireless interface, and it theoretically works, but it's not showing any networks.

rfkill says that nothing is blocked, the module is up, and iwlist says that there are 32 channels available but doesn't find any networks when it scans.

Any help would be appreciated. Thanks!

UPDATE: So if the laptop is plugged in via ethernet, and then I reboot, I can get a wireless connection. If it's not, though, then I can't get anything. Very odd.

UPDATE II: Scratch that, it appears to be entirely random... buh.

Have you try adding additional drivers? open up Software & update and choose Additional Drivers from here you should be able to add the necessary divers needed to get your machine connected

If possible try connecting your machine with a wired connection then scan using the method I provided above. I've never use a Mac but I'm guessing it can't be much different connecting to a WiFi connection

kill and restart NetworkManager. I have this or a similar problem as well, since upgrading to 16.04 LTS. eg:

sudo killall NetworkManager

sudo NetworkManager &


How to open OLE2 file format document I received a file that is .OLE2 format by email and I can't get it open.

When I try to open it with Document Viewer (default pfd program Ubuntu) it says it can't support it. I searched in the Software Center for OLE2, and it returned a program called RipOle. It says it opens that format, but you have to run it in the terminal and I don't know how.

Does any one know how to open OLE2 documents? Or do you know how to work ripole?

No experience with ripole or .OLE2 documents, but from the man page it doesn't seem too hard to run from the terminal.

Have you used the terminal at all before? If not have a quick read of this

All I think you need to do is open a terminal then assuming the file is in /home/user/, make a new directory where you want the file to be extracted to (eg tmp) then run

ripole -i file.ole2 -v -d tmp

Just replace file.ole2 with your filename and tmp with the directory you want the contents to be extracted to.

Hope that helps

A co-worker renamed a spreadsheet and according to her, the file format changed from .xls to .ole2.
In this case, I found that opening the file using OpenOffice Impress works, too.


How do you change the default Unicode shortcut CTRL SHIFT U to something else? How do you change the default unicode shortcut CTRL + SHIFT + U to something else?

Open System Settings -> Language Support and change Keyboard input method system to None.

Log out and in again.


Nvidia X-server setting is blank After changing to Intel (Power Saving Mode), Nvidia X-server setting is not showing anything. I need to active GPU now but can't activate it.
$ sudo lshw -c display
  *-display
       description: VGA compatible controller
       product: HD Graphics 5500
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       version: 09
       width: 64 bits
       clock: 33MHz
       capabilities: msi pm vga_controller bus_master cap_list rom
       configuration: driver=i915 latency=0
       resources: irq:50 memory:99000000-99ffffff memory:a0000000-afffffff ioport:5000(size=64) memory:c0000-dffff
  *-display
       description: 3D controller
       product: GK208BM [GeForce 920M]
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:04:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:16 memory:9a000000-9affffff memory:b0000000-bfffffff memory:c0000000-c1ffffff ioport:3000(size=128) memory:9b000000-9b07ffff

$ sudo nvidia-settings

ERROR: Unable to load info from any available system

(nvidia-settings:45705): GLib-GObject-CRITICAL **: 16:53:23.943: g_object_unref: assertion 'G_IS_OBJECT (object)' failed
** Message: 16:53:23.948: PRIME: No offloading required. Abort
** Message: 16:53:23.948: PRIME: is it supported? no

I fixed this issue by installing another version of Nvidia driver. I am not sure about whether this error will appear again.

Your graphics isn't recognized.
I just reinstalled OS and mark "install third party software".
After that, do not install any other graphic driver. You will run on Intel choosen by Ubuntu.  Nothing other works like this solution.
PS: When you reinstall, you can choose in Nvidia x server settings " Power saving mode".
Hope it helps.


Is it safe to install Linux kernel 3.12? Linux kernel 3.12 has been released but it's not available in Ubuntu's Software Updater. I can install it using this guide, but is it safe to install? I mean will it be as stable as 3.11? My current system is Ubuntu 13.10 64-bit with kernel 3.11.

Anything you install outside of Ubuntu oficial repositories you are on your own.

If it works for you, good.

According to the Ubuntu wiki on mainline builds

  The mainline kernels builds are produced for debugging purposes and therefore come with no support. Use them at your own risk.

They don't include the extra patches/drivers included in Ubuntu kernels, so you may experience some issues.

Yes, kernel 3.12.1 has been officially released and is no longer an rc.


Kanex Thunderbolt 2 Express Dock I am using the following setup:
Dell XPS-15-9550 4.4.0-31-generic #50-Ubuntu SMP Wed Jul 13 00:07:12 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

Dell XPS 15" Notebook Ubuntu 16.04 LTS --> USB-C/Thunderbolt3 to
Thunderbolt 2 Adapter from Kanex --> Kanex Thunderbolt 2 Express Dock --> Apple Thunderbolt Display

So far the Apple Display works fine. But from the Kanex Dock I only see

06:00.0 PCI bridge: Intel Corporation Device 1576
07:00.0 PCI bridge: Intel Corporation Device 1576
07:01.0 PCI bridge: Intel Corporation Device 1576
07:02.0 PCI bridge: Intel Corporation Device 1576
08:00.0 System peripheral: Intel Corporation Device 1575

but nothing "behind" like the ethernet-port or usb-ports. also from the Apple Display (this works fine !) I can not see any of the ports (no ethernet,usb,firewire).
Any idea how to start to get this things to work ? I would also write a drive as soon some could give me a starting-point (documentation,hints...).
Any kind of help would be fine !

Martin

i have an OWC thunderbolt dock attached to my dell precision m3800 (which is mostly the same as yours) via its thunderbolt 2 interface. I just plugged it in and it worked.

Thunderbolt is hot plug pci which has been in the linux kernel for some time (2.6 i think) as its used by some big storage systems , however accessing it via a usbc port is new.

heres my lspci with the dock

 00:00.0 Host bridge: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor DRAM Controller (rev 06)
 00:01.0 PCI bridge: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor PCI Express x16 Controller (rev 06)
 00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06)
 00:03.0 Audio device: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor HD Audio Controller (rev 06)
 00:04.0 Signal processing controller: Intel Corporation Device 0c03 (rev 06)
 00:14.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 05)
 00:16.0 Communication controller: Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #1 (rev 04)
 00:1a.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #2 (rev 05)
 00:1b.0 Audio device: Intel Corporation 8 Series/C220 Series Chipset High Definition Audio Controller (rev 05)
 00:1c.0 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 (rev d5)
 00:1c.2 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #3 (rev d5)
 00:1c.3 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #4 (rev d5)
 00:1c.4 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #5 (rev d5)
 00:1d.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #1 (rev 05)
 00:1f.0 ISA bridge: Intel Corporation HM87 Express LPC Controller (rev 05)
 00:1f.2 SATA controller: Intel Corporation 8 Series/C220 Series Chipset Family 6-port SATA Controller 1 [AHCI mode] (rev 05)
 00:1f.3 SMBus: Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller (rev 05)
 00:1f.6 Signal processing controller: Intel Corporation 8 Series Chipset Family Thermal Management Controller (rev 05)
 02:00.0 3D controller: NVIDIA Corporation GK107GLM [Quadro K1100M] (rev ff)
 06:00.0 Network controller: Intel Corporation Wireless 7260 (rev bb)
 07:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS5249 PCI Express Card Reader (rev 01)
 08:00.0 PCI bridge: Intel Corporation Device 157e
 09:00.0 PCI bridge: Intel Corporation Device 157e
 09:01.0 PCI bridge: Intel Corporation Device 157e
 0a:00.0 System peripheral: Intel Corporation Device 157d
 0b:00.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0c:00.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0c:01.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0c:02.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0c:03.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0c:04.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0c:05.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt [Falcon Ridge]
 0d:00.0 USB controller: Fresco Logic FL1100 USB 3.0 Host Controller (rev 10)
 0e:00.0 Ethernet controller: Intel Corporation I210 Gigabit Network Connection (rev 03)
 0f:00.0 USB controller: Fresco Logic FL1100 USB 3.0 Host Controller (rev 10)
 10:00.0 FireWire (IEEE 1394): LSI Corporation FW643 [TrueFire] PCIe 1394b Controller (rev 08)

Your kernel will enable the usb c port if it has the drivers for it , if so it will appear in the output of this command

lspci -d ::0c03 -k

try newer kernels until you find one that can enable it, the intel chipsets should be fully supported in the upstream kernel but seem not to have made it to the ubuntu ones.

There should be entries in your logs related to attempts to enable the port, please post them here.

Update:

in theory you should be able to run the following command to rescan the pci bus which might help to wake up your dock.

echo "1" | sudo tee /sys/bus/pci/rescan > /dev/null

really new hardware requires really new software.
this is a good and honest approach.
in this case, thunderbolt is the new technology while your kernel is months old.

prior to try any other fix, prior to deeply investigate the issue, upgrade your kernel (latest kernel version is 4.9...)


Is there any Window Manager like the Windows 7's for Ubuntu? In Windows 7, if you drag a window to the top of the screen, it will maximize, and if you drag to the side, it will restore to half size of the screen on that side.

Is there any window manager or plugin for Nautilus with this features?

Unity, the default desktop for 11.04, does the top-screen maximize and the left/right screen thing by default, however it is not available for 10.10.

Gnome 3 comes with these features. Drag to the left or right and it fills that half of the screen, drag to the top and it maximizes, and drag a maximized window anywhere and it becomes normal size again. Unfortunately I can't seem to find a good link detailing this, but I'm using it right now.

Apparently GNOME 3 doesn't come with Ubuntu 11.04 by default, but there's a GNOME 3 PPA available according to this GNOME blog post.

GNOME 3's interface is a lot different than Windows though, so you may not like it. You can always remove it if you don't though.


Creating a bootable usb or cd with Windows from Ubuntu I've searched quite a lot but yet didn't found any solution to burn a bootable usb flash or cd/dvd with Windows from Linux having an iso file with Windows. I've tried dd if= of= ... but when I tried to boot from that usb flash, it just didn't boot.

Is there a reliable solution?

You can try Unetbootin for usb's. They generally work!

Or, you can check here to do CD/DVD's:
http://howtoubuntu.org/how-to-burn-an-iso-to-a-cd-or-dvd-in-ubuntu

Hope this helps!


Global Installation of Composer (manual) I followed composer manual (global installation of composer (manual)) to install composer on Ubuntu.

$ ll /usr/local/bin/
total 4760
drwxr-xr-x  2 root root    4096 2012-03-29 08:29 ./
drwxr-xr-x 10 root root    4096 2011-04-26 00:50 ../
-rwxr-xr-x  1 root root  410324 2012-03-29 08:28 composer.phar

Other scripts from /usr/local/bin/ works, but composer gives:

$php composer.phar update
Could not open input file: composer.phar

It works only if I enter absolute path to composer.phar.
How to fix this?

TLDR;

As described on the Composer website:

curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer

Manual Method

I found an easier way to globally install composer than the manual proscribed in the github readme.md. It's actually on the getcomposer.org website:

curl -s http://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/

And if you're even more lazy, like me, you can create an alias:

alias composer='/usr/local/bin/composer.phar'

This way you can invoke composer with just composer

This might work for you. Note that sudo is used two times here.

sudo curl -sS https://getcomposer.org/installer | sudo php


Apple Keyboard fn not working with Bluetooth but works with USB Apple Magic Keyboard (Wireless) does not function correctly, Fn-key does not work, F1-F12 are no media-keys by default which they should.

The following does not solve it:
echo 2 | sudo tee /sys/module/hid_apple/parameters/fnmode

I figured it is not using the same driver for USB & Bluetooth, and this is indeed the case:

USB uses: usbhid
Bluetooth uses: hid-generic

I stumbled upon this driver repo hid-apple which seems to solve a problem described exactly as the one I have. But it's from 2011 and I'm not sure it will fix it because I already have it running:

$ lsmod | grep hid_apple
hid_apple  16384  0
hid        122880  7
hidp,usbhid,hid_apple,hid_generic,hid_logitech_dj,hid_logitech_hidpp

So it seems Bluetooth should use the hid_apple or usbhid driver?

If so:
How can I configure which driver my Bluetooth keyboard uses?

I also found the following bug which seems to have been fixed in the past.
https://bugzilla.kernel.org/show_bug.cgi?id=99881#c41

I'm using Ubuntu 18.04 with kernel 4.17.0-rc4. I am using this kernel because its the only one that makes my Realtek 8822be bluetooth/Wi-Fi chip function.

The fn key on my Apple bluetooth keyboard model A1644 would turn down the screen brightness (keysym was XF86MonBrightnessDown).  My interest was to change tabs in Firefox with Ctrl+PageDown and Ctrl+PageUp which requires fn and the up/down arrows for (PageUp/PageDown).  The solution (inspired by this exchange) was to change fn to a modifier key (Shift, AltGr, or Shift+AltGr) and then set the corresponding keysym for the up/down arrows.  I used xev to figure out that the keycode for fn is 232 (and 111 and 116 for up and down arrows, respectively).  As mentioned in the link, the first keysym (character or function key name) after the equal sign is the one corresponding to the bare key, then comes the one corresponding to the key with Shift, then AltGr, and finally with Shift+AltGr.  Then I used the following for mapping and setting up modifier:

xmodmap -e 'keycode 232 = Mode_switch'
xmodmap -e 'keycode 111 = Up Up Prior'
xmodmap -e 'keycode 116 = Down Down Next'

Instead of the up (111) and down (116) arrows, you could use this for F1-F12.

Following similar steps mentioned here, I upgraded my Ubuntu kernel to 5.6.3 (5.6 has wifi connection issues), and now my keyboard works smoothly.

Steps mentioned in the above link are as follows (for upgrading to 5.6.3):

Depending on your OS type, download and install the packages in turns:

linux-headers-5.6.3-xxxxxx_all.deb
linux-headers-5.6.3-xxx-generic(/lowlatency)_xxx_amd64.deb
linux-modules-5.6.3-xxx-generic(/lowlatency)_xxx_amd64.deb
linux-image-xxx-5.6.3-xxx-generic(/lowlatency)_xxx_amd64.deb

  Select generic for a common system, and lowlatency for a low latency system (e.g. for recording audio), amd64 for 64bit system, or armhf, arm64, etc for other OS types.

Alternatively, you can download and install the kernel binaries via terminal commands ( open terminal via Ctrl+Alt+T):

For 64-bit OS:

cd /tmp/

wget -c https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.6.3/linux-headers-5.6.3-050603_5.6.3-050603.202004080837_all.deb

wget -c https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.6.3/linux-headers-5.6.3-050603-generic_5.6.3-050603.202004080837_amd64.deb

wget -c https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.6.3/linux-image-unsigned-5.6.3-050603-generic_5.6.3-050603.202004080837_amd64.deb

wget -c https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.6.3/linux-modules-5.6.3-050603-generic_5.6.3-050603.202004080837_amd64.deb

sudo dpkg -i *.deb

I used this to sign my kernel because it was complaining about the invalid signature on booting up (due to having the Secure Boot activated). A similar and more detailed instruction for signing modules has been mentioned in the ubuntu blog in here.


Password not accepted at login I had tried to setup kerberos authentication to log into some ADS thing at my new university, however that didn't work and resulted in me having to enter my password twice for everything.

So I did: sudo apt-get remove libpam-krb5

Then some authentication tool came up asking if I wanted to ignore local changes(?) to which I entered yes. Then I restarted, now I can't login.

I tried to do recovery mode and enter into the root prompt, but apparently it is in read-only mode.

In recovery mode try making the root directory writable:

sudo mount -o remount,rw /


Minimal server installation I am currently running Ubuntu Server 10.10 through a virtual machine to use as a stack for web development and a chance to get to grips with the Ubuntu command line, however I'd really like to set up a clean, minimal install with only the bare minimum of core utilities so I can get only what I need as I go along.

The Ubuntu Server iso seems to install a lot of extras already and I'd prefer just the bare minimum so I can spend more time aquainting myself with the installation and set up of the packages I need. Can I obtain an image that does this?

This is what the ubuntu-minimal images are for. ~15MB of lean, mean Ubuntu. But if you're anything like me, you'll likely just end up installing it all back. Quite a few things require ubuntu-standard which layers on most of what the server disk installs.

You can read more about ubuntu-minimal and download it from the official help page.

Edit: Okay I've just done a minimal install. It does download extra packages as part of the installation and it's more that it really needs to run a base system.

The output of du -sh / is 632MB. It's a bit heftier than the previously advertised 15MB but it does install ubuntu-standard which I'm sure there is some way of avoiding. I've experienced it first hand because one of my server companies offers bare-minimal Ubuntu installs without ubuntu-standard.

I'll keep looking.

Have you tried any of lightweight ubuntu based distributions like lubuntu or xubuntu or lxle?
There is a lot of information about these distributions on askubuntu
and on other sites e.g.
http://www.techdrivein.com/2011/05/top-4-lightweight-official-ubuntu-based.html

Also consider looking for other lightweight linux distributions:
https://en.wikipedia.org/wiki/Lightweight_Linux_distribution


What's exactly the point of the sudo command, in terms of security? This question is actually non Ubuntu-specific. My understanding is that sudo is to prevent non-authorized users from doing administrative and other potentially harmful operations. The premise is that someone is here in front of my PC using it... or maybe remotely (but in that case they should know my login password to connect to the computer, and this is usually the same as my sudo password...) So someone is in front of my PC and she cannot delete certain important files or dirs or install harmful software without knowing my sudo password, but she can do a lot of other harmful and privacy-violating things without sudo. So, wouldn't it be better instead asking for admin privileges each time before opening the file manager or the terminal? I know this may be time-consuming and exhausting...

First off, you need to understand the concept of the users in linux, with special regards to the root user. In order to keep this answer below the character limit (and on topic), I'd suggest you read this page followed by this one. Really, all you need to know is the following:

Linux is a multi-user operating system with each user having limited power and scope as defined by their user group. Every Linux system has something called the root user (UID 0, also known as the superuser), who is the total and completely authoritative administrator. root knows all, root sees all, root controls all.

The concept of sudo came from the old UNIX command su (from switch user), which allowed any user to log in to any other user on the system. Anyone with administrative privileges would type su root (or just su) to escalate to the root user for any admin task. This, regrettably, had a few problems. In systems with multiple admins, everyone shared the root password. Meaning, if an admin left the company, the root password would need to be changed and redistributed to all of the other administrators. This can be extremely time-consuming at times, and otherwise just be a great pain.

Now, enter sudo. sudo works on a different principle. Instead of requiring users to know the root account login, sudo would be used to allow users to escalate themselves into the root account (or any other account, for that matter) based on the rules of the /etc/sudoers file. Now, revoking or adding an administrator is simple -- just add or remove a user from a group or the file. Because of this, the root account can be "disabled", thereby blocking access to anyone except actual admins.

For almost all cases, this is all sudo is used for. It grants root power to administrators (members of group admin or sudo) based on the rules defined in /etc/sudoers.

(Un)intentionally, this also comes with a massive security benefit. Administrators can run in an unprivileged mode just like any other user. They can then escalate or "enable" administrative privileges when they're needed, and revoke them immediately afterwards. Usually, this is only used for a single command (e.g. sudo apt install cowsay), but it could also be a full-blown root shell.

This isolation in turn also protects the system at large (remember, *NIX was originally a multi-user environment used by many people) from malicious code executed from an admin's account, be it through malware or someone logging on to an admin's active terminal. Similarly, sudo allows every admin action to be logged and reviewed at any time. Contrast this to the old su method, where you realistically had no idea who ran what command.

Also, based on the permission model of Linux, sudo can prevent a user from making potentially dangerous mistakes like accidentally uninstalling a critical program, erasing a hard drive, or any other number of nasty things that should never be done without some confirmation.

TL;DR:

Really, sudo is just a (very useful) holdover from the true multi-user environments of old *NIX installations. However, it still retains its usefulness by protecting the system from malware or session hijacking. In typical *NIX mentality, protection of the admin's actual account is an exercise left to the admin.

If you're worried about someone sitting down at your computer while you're away and messing with your privacy, just lock your screen/session. Even so, physical access is a killer.

So as you stated it yourself, the sudo command is doing its job perfectly, it is taking care of what it suppose to:

Based on definitions it decides who is permitted to do what kind of stuff ?

based on/etc/sudoeres or /etc/sudoeres.d
e.g: is user bob permitted to run rm using user root on ALL machines?

Then It will check to make sure that the user actually is who he claim he is.

By asking for password

What is wrong here is that your are allowing an untrusted user to use your system, that's where that cause the damage (Not to system, to your account).

You shouldn't allow anybody you don't trust to use your computer, it's like running a malicious program and excepting to nothing happen.

Use sudo, don't allow anybody to use your account you are safe to go...


Repeated 'authentication required' for wifi I recently upgraded to 14.04 and over the last few days, I'm having frustrating problems while connecting to my home wifi network, one I've been connecting to without a problem (with earlier Ubuntu versions) for over a year. Windows computers and Android devices have no trouble connecting either.

The problem is that whenever I connect to the network and enter the correct password, it tries connecting for a little while, and simply gives the the 'Authentication required' dialog box again.

I have a Lenovo Z400 laptop (wifi works perfectly on Windows 8 on the same machine, by the way), and a Linksys EA4500 router.

The 'wireless' page in the router configuration looks like this (SSID and passphrase removed): http://imgur.com/0PWHRpo.

sudo lshw -class network

*-network
       description: Ethernet interface
       product: RTL8101E/RTL8102E PCI Express Fast Ethernet controller
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: eth0
       version: 05
       serial: 20:89:84:f1:32:3c
       size: 10Mbit/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=half firmware=rtl_nic/rtl8105e-1.fw latency=0 link=no multicast=yes port=MII speed=10Mbit/s
       resources: irq:42 ioport:2000(size=256) memory:d3404000-d3404fff memory:d3400000-d3403fff
  *-network
       description: Wireless interface
       product: Centrino Wireless-N 2230
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:03:00.0
       logical name: wlan0
       version: c4
       serial: 68:17:29:be:21:2f
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=iwlwifi driverversion=3.13.0-24-generic firmware=18.168.6.1 ip=192.168.1.149 latency=0 link=yes multicast=yes wireless=IEEE 802.11bgn
       resources: irq:46 memory:d3500000-d3501fff

sudo lsusb

Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 004: ID 0bda:0129 Realtek Semiconductor Corp. RTS5129 Card Reader Controller
Bus 001 Device 003: ID 8087:07da Intel Corp.
Bus 001 Device 005: ID 046d:c077 Logitech, Inc.
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 002: ID 13d3:5170 IMC Networks
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

also, during while trying to connect, dmesg | grep wlan0 tells me I've been deauthenticated from <address> (Reason: 2).

I've also tried deleting all my saved networks, reboting and then reconnecting, which sometimes works, but sometimes doesn't.

Can someone please tell me why this is happening, and what I can do to fix it?

Changing the router's configuration helped. Changed the mode to Wireless-G and security mode to WPA2 Personal. Problem seems to be solved.

I had a very similar problems, and I would like to reccommend (even if you nave already) to double and triple check that your password is identical. In my case, the problem was fixed after I realized that sixes and nines aren't the same number. Your router will request the password more times if it is incorrect.


Wubi error about "invalid tag data" I tried to install Ubuntu 10.10 and 10.04 through Wubi in Windows 7.

Even after I disable the firewall and antivirus I get this error again and again.

Invalid Tag data . check len(D=1,(ord(d) & 128)==128. recvd -> (<>

It becomes unable to install. I tried to install to c drive and e drive also.

Though it's Mint Linux oriented, maybe this help: https://bugs.launchpad.net/linuxmint/+bug/576166

If you read the tread it's about a workaround to disable internet connection during install or using --skipmd5check switch.

However I am not sure it's the really same issue, but they seems to be similar.

You have to disconnect the internet conection while installing (unplug your LAN cable or switch your wireless lan off).


How do I download the command-line emacs instead of the GUI one? I used sudo apt-get install emacs to download emacs. I expected the command-line emacs to start when I ran emacs but instead the GUI emacs started.

How can I download the command-line emacs?

That would be emacs-nox I believe.  This is the meta-package that currently points to emacs24-nox .

  Description: The GNU Emacs editor
  (without X support)

So, just as before but with that package:

sudo apt-get install emacs-nox

or alternatively

sudo apt-get install emacs24-nox

For cases like this, where you wonder what's in what package, try this :

apt-cache search ^emacs

then

 apt-cache show <whateverpackage>

You already have installed it.

Just run emacs with:

emacs -nw


How can I access directly to my backup files, without having to restore them? I've allways made "simple" backups, saving all my files normally in folders on my external hard drive. I've already used the tool that Windows 7 (on my desktop computer) offers to make backups, but it isn't realy diferent from copying them manualy.

Yesterday, I decided to give a chance to Deja-Dup, and I made a backup from my netbook, and them I restored them to a virtual machine, just for experiment. And I felt realy amazed when I saw that Deja-Dup, because it backups all my home folder, was capable to restore not only my files, but also all my apps configurations and even my background! I think this app is incredible, and it deserves to be used on my computer! :D

But there is one problem. I have about 100GB of data, and I want to have it on both netbook and desktop (Ubuntu and Windows. I don't use it on my desktop because of some games I bought and wich I can't play on Ubuntu). It's a lot of data to duplicate.

If I skip some files from Ubuntu backups, like pictures, my Background will disappear, and I will have to put those files separatly, which will take much more work than backing up everything. I just wanted to know: Is there a way of accessing those files without having to restore them, from Ubuntu/Windows? I mean, to open the backup files like 7zip would open a zipped file, so I can take just what I want from the backup files, on any OS.

I want also to say THANK YOU to Ubuntu developers and to the comunity that make this OS so freaking amazing. Ubuntu is the best OS I've ever used, specially with Unity desktop. Please continue with the great work!

Yes, it's possible. Go to the directory where the file used to be, (eg: Pictures), open the folder in Nautilus, and click "Restore Missing Files..."

If a file or directory has since changed, and you want to restore previous versions, right click on the file itself, and choose "Revert to Previous Version..."

the fies will be in a .gz format. you can open them without restoreing them. if you open the volume dir. you can use "file-roller"


What's the easiest way to install OpenSSH 7.4 on Ubuntu 16.04? On Ubuntu 16.04 (Xenial) box, what is the easiest way to install OpenSSH (openssh-client) that is higher than 7.2?
I am aware that I could compile from source, but I was wondering if there's a way to avoid that.
Is there an officially maintained ppa for that?
I also tried sudo apt-get install -t xenial-backports openssh-client, but that doesn't have it either.

An alternative approach is installing the debian packages (although this approach is not ppa related)

https://gist.github.com/stefansundin/0fd6e9de172041817d0b8a75f1ede677

Just bear in mind that by doing this outside of apt then future installation management is messed up. To see what this would affect you can run

apt-cache rdepends openssh-client

and then going forwards when installing one those affected packages you will most likely see an error about the original version of openssh-client being missing . At least that is the behaviour I observed during the writing of some ansible scripts (Initially I upgraded the openssh-client last in the scripts to get around this)

In the error output in that scenario I noticed the output suggested to

apt-get -f install

without specifying a package. I did this, it installed a few bits (which apparently were not to do with openssh-client), and somehow future installs which depend on openssh-client now go through fine without complaining about the fixed version dependency.


Filesystem filling up due to large uvcydnctrl-udev.log file Now my installation of Ubuntu costs me more than 100 GB of the hard drive space. And whenever I try fslint and fdupes, they say Permission denied to delete the duplicates. Please help me guys.
Additional Info
Output of df:
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda1             296G  191G   90G  68% /
udev                  993M  4.0K  993M   1% /dev
tmpfs                 401M  824K  401M   1% /run
none                  5.0M     0  5.0M   0% /run/lock
none                 1003M  552K 1002M   1% /run/shm
/home/zipro/.Private  296G  191G   90G  68% /home/zipro

The faulty file is a 174GB /var/log/uvcydnctrl-udev.log

1. Step: Find out what problem you actually have

When your filesystem is unexpectedly full, there are a lot of possible causes. See Eliah Kagan's answer for some more about this. In the vast majority of cases it should be easy to identify (and eventually repair) the real cause, so reformatting/reinstalling would not be necessary.

So the first step is to find out, what exactly is the problem, i.e., where has the missing space gone. So first execute

df -hl -x tmpfs -x devtmpfs

This shows a list of all the used partitions of the disks in your machine, their size, how full they are and their mount point. From this list, take the one which you think is too full and note its mount point. In your case, it is the root file system which is mounted at /.

Now we analyze where inside this file system the space is used. Execute

 sudo du -xhsc /* 2> /dev/null

(Replace / with the mount point identified above.)
It needs sudo because not all directories might be readable for your user. It may take some time (especially on large file systems) because it needs to visit every single directory on them.

What this command does is to show you each file and directory inside the given directory together with its size (including subdirectories).
So from this list take the one(s) which you think is larger than it should be, and call the command again on this directory. (That is, run the command again, but with the name of a big directory from a previous listing replacing /.)

For example, in your case it was clear /var was the only big directory, so you would need to execute

 sudo du -xhsc /var/* 2> /dev/null

Continue with these steps until you have either found a single file which is so big, or you have found a directory with lots of files that together take up all that space.

In your case the next step was to execute

 sudo du -xhsc /var/log/* 2> /dev/null

because /var/log was so big, and this showed you that there was a single log file named uvcdynctrl-udev.log with 174GB (which is obviously bad).

2. Step: Identify why the files are there and why there are so big

Now we need to find out why the identified are there, or why they are so big, if they are expected to be there.

In your case, a log file in /var/log is nothing suspicious, but its size surely is. Fortunately, a Google search simply with the file name brings up the following bug report as the first hit, which is clearly the same problem as we have:  http://bugs.launchpad.net/ubuntu/+source/libwebcam/+bug/811604

3. Step: Solve the problem

In this case, a log file of some webcam-related stuff seems not to be interesting, so we can easily delete it with the command sudo rm /var/log/uvcdynctrl-udev.log and free all the space.

Unfortunately, the bug report is still open, and there are no solutions or workarounds in the comments, so you probably have to live with this bug for now. You can delete the log file from time to time to free some space.

I think the best thing here is to just reinstall, considering the apparent amount of damage, the fact it's fairly unclear what's actually happened, and your low comfort level in manually repairing it.

Preserve your home directory (do not reformat or repartition) and reinstall and that should clear out the system directories.


i3wm, adjust brightness through command line I've got a Precision 5510 running Ubuntu 16.10 with kernel 4.8.4. In unity, my function keys for brightness work correctly. But xbacklight commands don't do anything. xbacklight -get comes up empty. Is there a way to increase / decrease brightness through the command line? I need this for it to work in i3wm.

You may modify the value in /sys/class/backlight/{may vary}_backlight/brightness

example:

sudo nano /sys/class/backlight/intel_backlight/brightness

This tool does that https://github.com/multiplexd/brightlight
then use it like this:

bindsym XF86MonBrightnessUp exec --no-startup-id brightlight -i 20
bindsym XF86MonBrightnessDown exec --no-startup-id brightlight -d 20

I am using now i3wm with Ubuntu and i love it. I have a similar problem and i solved this adding this lines in my ~/.config/i3/config file:

# Sreen brightness controls
bindsym XF86MonBrightnessUp exec echo $((`cat /sys/class/backlight/intel_backlight/brightness` + 10)) | sudo tee /sys/class/backlight/intel_backlight/brightness
bindsym XF86MonBrightnessDown exec echo $((`cat /sys/class/backlight/intel_backlight/brightness` - 10)) | sudo tee /sys/class/backlight/intel_backlight/brightnes

and add the /etc/suduers.d/tee file with this:

myuser ALL=(ALL) NOPASSWD: /usr/bin/tee

where myuser is really my user name. My laptop is an HP Spectre x360 with Intel graphics, I know that i need to check the min and max limits but at least in my machine ... no problems ...


How to setup WiFi network to access internet I am new to Ubuntu/Linux. After some efforts I got the Internet working with pppoeconf.

Now I have desktop setup with Ubuntu + D-Link DSL 2730U ADSL modem router + brodband internet(BSNL india) connection. I would like to share and use this connection with mobile/laptop as well. Could someone please guild me how can I do this under Ubuntu.

I checked some other threads and checked lspci|grep -i wireless command output. So this does not get any output on my terminal.

check below link it will help you

https://help.ubuntu.com/community/WifiDocs/Adhoc


Mouse and trackpad stopped working on an Asus Eee1215n I have an Asus Eee 1215n.

I upgraded to Ubuntu 12.04 and the USB mouse and trackpad just stopped working. What could've caused that? How do I go about debugging it?

Have a look at the following link too, which was also a similar issue with a hp mini netbook.

do you use lightdm? give gdm a try

sudo dpkg-reconfigure gdm
and choose gdm as default.

I hope this helps anyone.


Is file permission secured when it transferred from Ubuntu to Windows? I am having 9GB text file which is encrypted .

This file contains some confidential data . Which is on my system(Ubuntu) and my external HDD (ntfs) . This file get daily updated and then encrypted . But it has to be shared among 2-3 (Windows) person. I defined permission so that no other person can  even read this file(chmod 660). It is too large file, so I can't upload it anywhere and it get updated daily basis.

But this file travel on Windows OS and Ubuntu also. Even I am having copy of this on my personal computer. Recently it was deleted by some other user over Windows . I just want to know how can I set permission over that file so that it cannot be deleted from any other operating system. If someone delete this file, then I am having data old for couple of days, which is only on my system.

I gone through this question it says there is nothing.
And from this question I am not able to understand how can I protect it.

Can I do anything for preventing this file from being deleted.

Then how can I secure this files from getting deleted any suggestion or software or ideas.

Maybe I sound silly or this is stupid question. Please don't close it,
thanks for any suggestion or solution.

NTFS supports permissions, you just need to tell Ubuntu where and how to enable them via the /etc/fstab file.

Follow bodhi.zazen's instructions in your second link (the one answered Dec 28 '11 at 16:31). Those instructions tell Ubuntu to automatically mount the external drive using the options from the fstab file. Once you do that, and remount the drive, your chmod will work.