How do I find out if a configuration setting is running?

It is not a solution to 3. but a workaround, and faster than opening nautilus again and again:

I now open a console and look at its font-scaling. In the beginning it is still with a tiny font, I now wait until the console switches to the bigger scaled font.

In fact, I added the dropdown console tilda to my autostart programs so I automatically have a console at start and just wait some seconds until the font-size is loaded


updating ubuntu while dual booting with windows 8

if you wish to update, do so normally, it wont affect your dual boot
updates are mainly to perfect what is on system, updating is usually to improve performance + features already installed and people try to do that without loss of performance
if done through update manager its done for you affecting ONLY ubuntu installation itself


Redirect requests mapped to a DNS IP Address

If you want to redirect DNS quries you can try this.

iptables -t nat -A PREROUTING -i ethX -p udp --dport 53 -j DNAT --to $(get lan_ipaddr)
iptables -t nat -A PREROUTING -i ethX -p tcp --dport 53 -j DNAT --to $(get lan_ipaddr)
iptables -t nat -L -v -n # shows nat table

and if you try to forward port 80 to another ip. Here is the rule and a example of it.

iptables -t nat -A PREROUTING -p ${PROTOCOL} -i ${INTERFACE} -d ${LOCAL_IP_ADDR} --dport ${LOCAL_PORT} -j DNAT --to ${DESTINATION_IP_ADDR}:{DESTINATION_PORT}
iptables -t nat -A PREROUTING -p tcp -i eth0 -d 192.168.1.10 --dport 80 -j DNAT --to 192.168.2.2:80

Please let me know in case of queries or if it was the answer of your question.


Yes. Ubuntu Touch has the same version numbers.


I have a ghost folder in my left bar in nautilus

Those Ghost folders happen when you change around the names of the different top entries by hand in terminal. Usually it is enough to right-click on the ghost entry and choose to remove it from the side bar.

But before that make sure the entries in ~/.config/user-dirs.dirs match the actual folder names you are using right now and do a reboot. The actual folder names should how up on the top part in nautilus, then right-click the ghost entries and choose remove which will remove them from the view.


Can I have different desktop folders in each workspace?

No.

Every workspace contains the same desktop, the same panels, and the same menus of your operating system. It's like cropping your office desk in pieces; each piece is the same as the other and you can run different procedures at each.

However everything you change at each workspace will remain untouched and not effect the other workspaces. For instance if I open Terminal at the 1st workspace it will remain as I left it when I changed workspace.


You can use below “make” command to link lib and include,

make <filename_without_extension> LDLIBS="-l<lib1> -l<lib2>"

suppose you have server1.cpp file to compile using make command,

make server1 LDLIBS="-lcpprest -lpthread -lssl -lcrypto" LDFLAGS="-L/usr/lib/" CXXFLAGS="-I/usr/include/"

Output will expand the compilation command as,

g++ -I/usr/include/  -L/usr/lib/  server1.cpp  -lcpprest -lpthread -lssl -lcrypto -o server1


Cannot upgrade my Ubuntu installation from 18.10 to 19.04

After reinstalling some packages I was able to fix the problem.

Here is what I have done

Remove update-manager-core and update-manager

sudo apt remove update-manager-core update-manager
sudo apt autoremove

Install them again

sudo apt install update-manager-core update-manager

Then you should be able to upgrade your Ubuntu distribution using do-release-upgrade from terminal or the GTK tool if you prefer.


Can't uninstall any apps from Ubuntu Software

You attempted to install Oracle Java 7 at some point, which seemingly has failed and left the package oracle-java7-installer in a broken, half-installed state.

This package is actually just a downloader/installer, which tries to download the real software from Oracle's website during the installation. This failed though, because the files to download seem to have been (re)moved by Oracle and now it fails with a 404 "Not found" error.

To remove this package, running the command below should be sufficient:

sudo apt purge oracle-java7-installer

After that, I suggest to also run these other commands below to make sure your package system is in best shape. It will update your list of available packages (happens automatically every day anyway), check if any of your installed packages can be upgraded (and do so), and remove some no longer needed packages, which were listed in the output you showed in your question, like a few Python libraries and an old kernel:

sudo apt update
sudo apt upgrade
sudo apt autoremove


It's a file like device, so you can do things like cat it or copy from it. For instance:

dd if=/dev/urandom of=~/urandom_test count=4 bs=1024

Creates a file containing 4K of random bytes.

cat /dev/urandom > ~/urandom_test2

Will continue to write random bytes to that file until you hit Ctrl-C. Don't do this on a low performing system...

head -30 /dev/urandom > ~/urandom_test3

Will write 30 lines of random bytes


Having similar trouble. Screen blanks out if the mouse or keyboard are idle for less than 10 seconds!

Anyone see behavior like this?


How to resolve "No suitable download server found" when updating?

To update by terminal ,open Terminal by ctrl+alt+T
Type

 sudo apt-get update

It will ask password, give password.
Packages will be automatically updated.

To Update by Synaptic

open synamptic , Click on reload.... It will show you list of packages that are available in new version. So are newbie to ubuntu, install synaptic by

Open Terminal,
type
sudo apt-get install synaptic


How to run mysql commands through shell script?

mysql -u root -pmysql << eof
SELECT TABLE_NAME AS "Table Name", table_rows AS "Quant of Rows", ROUND((data_length + index_length)/1024/1024,2) AS "Total Size Mb"  FROM information_schema.TABLES WHERE information_schema.TABLES.table_schema='database_name';
eof


I am going to assume you are using Ubuntu 12.04LTS. I looked on ubuntuforums.org and found this thread: http://ubuntuforums.org/showthread.php?p=11926504

Scroll down four posts to Derek Karpinski. He has a very organized response. Follow that and it should fix your suspend issue.


Logout or reboot your system. When you select your username on the login screen change the session to "Ubuntu Classic". When you are on the Desktop go to "Applications menu -> Accessories -> Terminal" then type "unity --reset" in the terminal and hit Enter.

Reboot your system again. In the same location you switched to Classic, you have to choose Unity again.

In Unity you can access your terminal or any other application with the dash.


Why do Filenames created under UTF-8 not match the UTF-Codepage layout?

The sort order is controlled by the LC_COLLATE category of the locale settings. It doesn't depend on the character encoding.
Note that some programs, especially command line programs, may not use the locale settings for sorting.


Quality with the screenshot tool isn't good

Shutter
My suggestion would be to use a screen capture tool such as Shutter.
sudo apt-get install shutter

If you look in the preferences - you can define what the compression ratio is together with the graphical format.


How do I report a bug in a kernel if it won't boot?

There are two fantastic pages from The kernel Team:

Introduction : https://wiki.ubuntu.com/KernelTeam

Kernel Debugging : https://wiki.ubuntu.com/Kernel/Debugging

Debugging Scenarios
Debugging Guides
Debugging Tools/Information

Note : To determine which guides are relevant to your problem see the Kernel/Debugging/Symptom based debugging guide .


MATE dictionary not listed on accessories menu

The MATE Dictionary is located in Office category. Please check it out:

The warning message may be removed by

sudo rm /etc/X11/Xsession.d/99mate-environment

(this file is a leftover from 16.04 LTS and should be removed on 18.04 LTS - see bug)


How can I make a mini English-Chinese dictionary for Ubuntu?

There are many ways which are used to store internationalized strings depending on the GUI toolkits or specifications.

The ones shown in the screenshot are from menu .directory files. Use same standard as .desktop from freedesktop project. See Desktop Entry Specification: Localized values for keys

Here a script to extract them

Create a shell file

nano extract_zh_translation.sh

Add

#!/bin/bash

for f in $(ls $1)
do
        name_en=`sed -n -e '0,/Name/{s/^\s*Name\s*=\s*//p}' $f`
        name_zh=`sed -n -e '0,/Name\[zh_CN\]/{s/^\s*Name\[zh_CN\]\s*=\s*//p}' $f`

        case `echo ${#name_en}/8 | bc` in
        3|2)    echo -e $name_en'\t'$name_zh
                ;;
        1)      echo -e $name_en'\t\t'$name_zh
                ;;
        0)      echo -e $name_en'\t\t\t'$name_zh
                ;;
        esac
done

Make it executable

chmod +x extract_zh_translation.sh

Run it on menu directory entries

./extract_zh_translation.sh "/usr/share/desktop-directories/*.directory"

Here is an output sample
If you want application menu entries too

./extract_zh_translation.sh "/usr/share/applications/*.desktop"

Here is an output sample

Other translations of Unity GUI is using gettext.

Files having the .gmo or .mo extension, are the final binary format. Check:

locate -br .mo$ | grep zh_CN

The source files have .po extension, you can download them from https://translations.launchpad.net/ or by downloading the complete source, example:

apt-get source unity

Other GUI toolkits like Qt & Java are using different formats.


Looks to me like either the storage device is

Unformatted
Not properly formatted
Corrupted
Not formatted in a file system recongizable by Ubuntu.

For Option 4 I cannot exactly give you an example of which filesystems Ubuntu or the computer wouldn't recognize. But, that's still a possibility.

However, Options 2 and 3 I can relate to. I was just having a similar issue with an SD card reader. I needed to reformat it because a Windows computer was saying it was corrupt. Gparted could see the SD card, but PCManFM or Nautilus (file explorers) could not detect it or even read the contents. I ended up reformatting it just fine.

Because your PC can see the storage device, you should be able to run Gparted and reformat it. If you have files you need to get off of it, keep trying to read the contents using a file explorer, or, if you have access to one, try using a different computer, even a Windows PC if you must.

If no other system can read the contents, it is likely the storage device fits within Options 2 and 3.

Could you comment here with your results if you tried this?

Edit: In my SD card situation, my PC (or any other PC for that matter) could not do so much as tell me its storage space limits or how much space is taken up.


13.10 indicator-sound only preferred-media-players

Okay, it is not a bug. I found it here . If I understand correctly this is the designed behaviour:

Is this bug about having the players in the menu at all, or about that each player item is showing playback widgets?
If it is the latter, I agree that this is a bit weird, but it is in accordance with the current sound menu spec: "The playback item should be present if the player can be controlled externally (CanControl)."

Read on that bugreport for some more info. Also looks like that "bug" is in Triaged status so things may change in the future.


Giving ownership of the directory to the apache user?

Do not use the database user as the UNIX user. Use www-data.

sudo chown -R www-data:www-data /var/www

There is a difference between the database user and the Apache user. The Apache User is the only one who can actually read the files. The database user is only meant for giving/taking database read/write permissions.

In addition, keep the default permissions from the webapp install. Do not change those, except for the owning user/group. If you are instructed by the webapp, change permissions.

If you are more concerned about security, you could instead run the following commands:

sudo chown -R $USER:www-data /var/www
sudo chmod -R 640 /var/www

This makes the actual files owned by your user, so that only you (and root) can modify them. The reason www-data is referenced is so that Apache can still READ the files, but not actually write to them.

The 640 allows you (the file owner) to read and write, while allowing the www-data group to read files. It also blocks anyone else from possibly reading the file contents.

(The above is only one possible (untested) method. More good ways are available here.)


12.04 Keystone charm fails to deploy: How do I debug it?

You can find the answer to this in our debugging hooks section of the docs.

What you'll need to do is launch debug-hooks from the Juju client machine, then resolve the error with the --retry flag (or retry from the Juju Gui if you are using it). This will re-execute the hook and trap the event in the debug-hooks window. From there you will be in the right directory to run the hook file by typing hooks/<name-of-failed-hook> to get output. When you are done, simply press Ctrl D to exit the terminal and signal to Juju that the hook is finished executing.

(Taken from another answer to really the same problem).


How to recover manually deleted boost library files?

You should check which Boost-related packages do you have installed.

For example with dpkg -l | grep boost and then reinstall all of them with

sudo apt-get install --reinstall \
$(dpkg -l | grep ^ii.*boost | awk '{print $2}')


vmware-vix vmrun command error: "unable to connect to host ... version not found"

SOLUTION

ok, just solved this one as well
in case anyone else encounters this issue, here is the solution:

vmrun command is ignoring its own config file:

/usr/lib/vmare/vixwrapper-product-config.txt

I am not sure why, but even when you use the command as follows:

vmrun -T player start /path/vm.vmx

... it is checking & finding vmware workstation NOT player (even if the config file has the correct version of player listed), and then complaining that workstation is not installed.
So, here is how I got around it:

Uninstall vmware player: vmware-installer -u vmware-player
Uninstall vmware-vix: vmware-installer -u vmware-vix
Install vmware workstation: same process as player (remember to chmod +x the bundle)

Surprisingly, what you will find is that you now have both player AND workstation installed, even though if you try installing workstation while player is already installed, the installer will tell you that it cannot do it.
It has also reinstalled VIX as part of workstation, and VIX has this time correctly picked up vmplayer ... so you may now start it at the command line with vmrun
note

I was unable still to vmrun via ssh login from another computer
Like myself, you may want to start this vm automatically when ubuntu boots (which it should do fine, and that is my next step also)


Nvidia driver updated - mixed versions of 304.88 and 319.32

Instead of installing the latest version, I recommend you to install Kernel which is meant for Ubuntu 12.04.3 LTS that is Linux Kernel 3.8.0.30. It is available in the repository so no need to go to some other place. Here is the steps to install Kernel 3.8.0.30 for Ubuntu 12.04.3 LTS.

Execute following commands in series(one by one, if you get any error in any command just comment for the command for which you got the error with the error message)

Execute this to update repository:

sudo apt-get update

Execute this to install Kernel 3.8.x(be careful, don't miss any character)

sudo apt-get install linux-generic-lts-raring linux-headers-3.8.0-30 linux-headers-3.8.0-30-generic linux-headers-generic-lts-raring linux-image-3.8.0-30-generic linux-image-generic-lts-raring

Execute this to update grub:

sudo update-grub

Execute this to re-configure all installed packages(It would take some time, so wait. If it fails, gives some error just proceed to next step)

sudo dpkg-reconfigure -a

Execute this to restart your system:

sudo reboot

While restarting, you would see one more entry in Grub Entry for Linux Kernel 3.8.0.30 chose that.
See what happens.. Reply for further assistance..

Now Removing nvidia-304 and re-configuring nvidia-319

Follow these steps to do so.. I am assuming that nvidia-319 is currently installed in your system.

Open terminal and execute following commands to completely nvidia-304

sudo apt-get autoremove nvidia-304*
sudo apt-get --purge remove nvidia-304*
sudo apt-get autoremove
sudo apt-get autoclean

Then execute these commands to re-configure nvidia-319

sudo update-grub
sudo dpkg-reconfigure nvidia-319

if above command shows some error then try to replace nvidia-319 with nvidia-319*

sudo update-grub
sudo update-initramfs -u (it would take some time)

Then restart your system

sudo reboot

Reply..


Does installing Ubuntu from itself on a flash drive install it on my hard drive?

That file will present you options for where you want to install it.  When you get to that point, make sure you select to install it on the thumb drive and leave the MBP's hard drive alone.  Probably the MBP's hard drive will show up as sda, but make sure the size numbers add up.

When Ubuntu asks you if you want it to write to the master boot record of the primary drive, DO NOT SAY YES.

I would suspect however, that Ubuntu is already installed on the thumb drive and that Install Ubuntu file just wasn't deleted since you didn't install Ubuntu through "traditional" methods.  You may not need to do anything at all besides delete the file.


iptables (or ufw, which is just a front end for iptables) would do what you want. The default response timeout for UDP packets is 30 seconds (or very close to it). So you would just need to allow the answer related packet back in and DROP the rest (the below assumes your external IF is eth0):

sudo iptables -A INPUT -i eth0 -d your_external_IP_address -m state --state ESTABLISHED,RELATED -j ACCEPT
sudo iptables -A INPUT -i eth0 -d your_external_IP_address -j DROP

Note that this not the entire answer. If want to use iptables you will have to consider your overall requirements and deal with possible other use requirements accordingly.

There was a similar minimal use case the other day, which you could refer to.


How to install Ubuntu 13.04 or later on Dell inspiron 17 and remove windows 8

Just run the standard Ubuntu installer, and at the "Installation type" step, choose
Erase disk and install Ubuntu (2nd option on the screenshot below)


Ubuntu fresh install always starts in guest session

Trying again and again, I found out that downloading updates during installation may be one of the reason. I didn't connect wifi during installation and OS (Ubuntu 14.04) properly installed. Now I am able to get the admin login option along with guest login.


USB Keyboard not recognized during installation

I have heard ppl having luck unplugging the usb when the issue happens and plugging it into a different sub port


"The disk drive for / is not ready yet or not present" message on boot

I think I had the same problem going from 10.04 to 12.04.1. Here is how I fixed it. During the upgrade the packages got all messed up and when it rebooted it came up with the "Disk Dirve for / not ready".

I pressed M to go in to manual recovery.

Turns out the root partition was mounted read only. So I remounted as readwrite by

chroot /
mount -n -o remount,defaults /dev/sda1 /

Then to fix the broken packages I did a

apt-get install -f

The upgrade then proceeded and all seems okay now. Phew (for me anyway).


How to check which version of a product is available in repositories for different ubuntu versions?

Browse to http://packages.ubuntu.com/. There, you can search for any package within any Ubuntu version. That will tell you what version of a specific package is available in what Ubuntu version.

There is no release schedule, as packages are added or updated when ready/necessary.

However, there is a changelog that you can check. For instance, if you go to: Ubuntu – Details for package redmine in raring, you will find a Changelog link at the right under Ubuntu Resources.

Within your particular Ubuntu version, you can check which versions of a particular package are available, and which one will be installed, using the command apt-cache policy. For instance:

$ apt-cache policy redmine
redmine:
  Installed: (none)
  Candidate: 2.3.1-1
  Version table:
     2.3.1-1 0
        500 http://de.archive.ubuntu.com/ubuntu/ saucy/universe amd64 Packages


How to make Files use file-roller again?

Try this:
Set a password to encrypt data in a new archive by following these steps:
Start creating a new archive.
At the bottom of the file chooser dialog you can choose a File Format and enter a password into the Password field in Other Options.
Choose an archive type that can be password protected before setting a password.
Continue with creating a new archive.
Protect an existing archive by setting a password:
Open an archive.
Click Edit ▸ Password….
Type a password into the Password field.
If you want to encrypt the list of files tick Encrypt the file list too.
Click OK to continue.
Archive Manager will encrypt only new files which will be added to the archive!
The following archive formats are well supported, and installed by default in File Roller:
Tar gzip bzip bzip2 LZMA ZIP JAR CD images
The following formats require additional packages to be used. They may have incomplete support, with some requiring non-free software to have full support.
7zip shar ARJ ACE RAR LRZ LHA lZO
Source


what is the file /var/lib/dpkg/status about and why do I need it

Some details can be found at https://www.debian.org/doc/manuals/debian-reference/ch02.en.html#_the_dpkg_command

As best as I can tell from reading that, the status file contains status information (of course) about packages.

Based on looking at my own status file, most packages seem to have "Status: install ok installed" (I've found thousands of these). I assume this means that those packages are installed properly. I have a couple dozen or so packages that have some other package.


The shown screenshot is somewhat misleading by its statement "Size 2.0 KB"
which should rather be "Size 0". Elsewise the CD-R seems to be correctly
recognized as unwritten (aka "blank").

The run of wodim only produces a help text about outdated device classes.
Use /dev/sr0 as address and ignore the "not supported" (which is not true
for "sg" anyways).

If you want to go on with the command line, you'd need to tell what kind of
CD you strive for: CD-DA for music playing, CD-ROM for data storage. Further
you'd need to tell by which file name paths the input files are accessible
on your hard disk.

If you rather prefer to stay with K3b or Brasero, then you need to tell
which error messages they emit. "K3b didn't like" does not contain enough
information for guessing what might be wrong.

I tested what wodim has to say about an empty medium:

wodim dev=/dev/sr0 -toc

It reported:

Device type    : Removable CD-ROM
Version        : 0
Response Format: 2
Capabilities   :
Vendor_info    : 'ASUS    '
Identification : 'BW-16D1HT       '
Revision       : '1.01'
Device seems to be: Generic mmc2 DVD-R/DVD-RW.
Using generic SCSI-3/mmc   CD-R/CD-RW driver (mmc_cdr).
Driver flags   : MMC-3 SWABAUDIO BURNFREE
Supported modes: TAO PACKET SAO SAO/R96P SAO/R96R RAW/R16 RAW/R96P RAW/R96R
Errno: 5 (Input/output error), read toc scsi sendcmd: no error
CDB:  43 00 00 00 00 00 00 00 04 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 05 00 00 00 00 0A 00 00 00 00 24 00 00 00
Sense Key: 0x5 Illegal Request, Segment 0
Sense Code: 0x24 Qual 0x00 (invalid field in cdb) Fru 0x0
Sense flags: Blk 0 (not valid)
resid: 4
cmd finished after 0.002s timeout 40s
wodim: Cannot read TOC header
wodim: Cannot read TOC/PMA

This is not very re-assuring because an inappropiate SCSI transaction
is reported and no info about the medium status is reported.

Better results yields

xorriso -outdev /dev/sr0 -toc

which reports for me

Drive current: -outdev '/dev/sr0'
Media current: CD-R
Media status : is blank
Media summary: 0 sessions, 0 data blocks, 0 data,  703m free
Drive current: -outdev '/dev/sr0'
Drive type   : vendor 'ASUS' product 'BW-16D1HT' revision '1.01'
Drive id     : 'K9CF92A5012 '
Media current: CD-R
Media product: 97m34s23f/79m59s73f , Mitsubishi Chemical Corporation
Media status : is blank
Media blocks : 0 readable , 359846 writable , 359846 overall
Media summary: 0 sessions, 0 data blocks, 0 data,  703m free

We see that the medium is a CD-R, is blank, offers room for 703 MiB
(= 737 MB) of data, and was actually made by Mitsubishi (aka "Verbatim").


How do I stop one of my installed fonts from overriding other web fonts?

Install the font-manager using following command

sudo apt-get install font-manager

Run the font-manager and there you can disable the fonts you want.


gdebi-gtk Segmentation fault (core dumped)

Probably this happens due to bugs in the gdebi package. There are several open bug reports about gdebi crashes: https://bugs.launchpad.net/ubuntu/+source/gdebi


Java programs cannot be relaunched from launcher side bar

I have almost the same problem with SmartGit and any java/mono application like Eclipse by the way. And it seems I have found the solution here. But I will be able to try it latter.

Update:
I have tried it and this method works great for me. I have made shortcuts for eclipse, keepass and smartgit. Try it.


How to add unused partition of the first disk to /home in the second disk

Add a line in /etc/fstab for that disk and it will be mounted automatically i.e.

/dev/sdXY /mnt/data   ext4 noatime,noexec

You can mount it somewhere else and create a soft link to a folder under your home with big files (say downloads or something) and spread the files between the two

ln -s /mnt/data /home/alifish/downloads

with

df /home/alifish/downloads

you should see the true location of the directory


The mouse and "being invisible" when I type

There is an application named Unclutter on Ubuntu which will hide the mouse pointer after a certain time of inactivity1. Run the following commands to install the application.
sudo add-apt-repository universe
sudo apt update
sudo apt install unclutter

The default is 5 seconds. Run the following command to see a list of options:
unclutter --help

Here are some options you may be interested in.
First, hide the cursor after 1 second of inactivity:
unclutter -idle 1

Alternatively, you can use keystrokes instead of inactivity:
unclutter -keystroke

You can also try combining some of these options to see what works well for you and there are some options for setting unclutter to work on certain specified windows or displays.
Also, if you need the command to release when you run it in the terminal, you can append an ampersand to the command like in this example:
unclutter -idle 1 &

and, of course, to kill unclutter, you can run the following:
sudo killall unclutter

Additionally, I would recommend adding this to your startup applications. Just search for "startup applications" on your Gnome desktop and add your preferred command like unclutter -idle 1 so it will startup automatically.
1: Auto-Hide Mouse Pointer in Ubuntu When Idle – OMG! Ubuntu!


.xprofile and startup applications' scripts stop working after a few minutes in Ubuntu 16.10

Haven't found a reason for why the scripts that used to work suddenly stopped working, other than I performed updates on Ubuntu and switched to Kernel 4.10.

However, I got a way around that by putting all of my scripts into a .sh file. I made it executable by running

chmod +x filename.sh

And I call that from startup applications.
I also modified that startup application file (in my case it's called start_script.desktop and it is located in .config/autostart/), and added the line:

X-GNOME-Autostart-Delay=3

Finally, another thing that I noticed is that my commands used to be something like:

sleep 20; setxkbmap -layout us -option ctrl:swapcaps

So maybe now it is not allowed to have multiple commands in one line?


In Ubuntu 18.04 using Thinkpad, how Settings application is launched when Fn + F9 is pressed?

Looking at the symbol on keyboard there is settings icon on it.. which is may be resulting in opening the system settings..

you can get the keycode of this particular behaving with below command

xmodmap -pke | grep XF86Tools

Once you got the result with keycode.. you can assign your functions to it with xmodmap

for example if the keycode is 191

make the keycode to do nothing when pressed with below command

xmodmap -e "keycode 191 = "

then with xbindkeys tool you can bind the command gnome-control-center keyboard for this key press Fn+F9 like below

"gnome-control-center keyboard"
m:0x0 + c:179


All you need to do is

Copy file to your Home directory (partition of Ubuntu)
add execute permission to that image you are using by

  chmod 751 filename

It won't change when you restart!


Can multiple users remotely use X windows at the same time?

Yes. Multiple users can run programs remotely. However, I would not say that users are using remote XWindows, because they aren't.

You have to run XServer on your computer, from where you login to remote computer. Remote computer does not need to run XWindows and its graphics card is not neded at all. It can be in text mode. It is a basic function of X11 present long before network and remote  connections became so popular.

When you login remotely with X11 forwarding, your computer acts as an XServer. The program runs on a remote computer, but graphics commands are sent to XServer. Xserver receives X graphics commands and executes them. Executing X graphics commands, means drawing application's window and its content. The X protocol is so "smart" that it does not send the picture like VNC or other remote desktop applications. It sends X graphics commands to draw content, like draw line, arc, font, etc. That means, that the amount of network traffic is usually smaller than when sending the whole picture. The application will send only the window content. Your window manager needs to take care of window borders, title bar, etc.

When running a graphics program in linux/unix, you can always specify on which display you want to run it. That means that program logic will be executed on the computer, where it was started, while graphics commands will be sent to another computer, where XServer is running. The command

DISPLAY=remoteIP:0 xclock

will run xclock on the cumputer where command was executed. DISPLAY=remoteIP:0 means that graphics commands will be sent to display number 0 on remoteIP. You have to allow remote graphics connections on remoteIP, of course. If you want to try, xhost + on remotIP computer should allow any X graphics remote connections. Type

set | grep DISPLAY

on your computer and on computer where you login remotely with ssh -Y or ssh -X. You will probably see DISPLAY=:0 on local computer, which means programs will be displayed on default computer on display 0. When logged in with ssh, you will see something like DISPLAY=:11, which means X protocol is redirected via ssh to you computer. If you set the $DISPLAY variable to some other display (XServer), applications will be opened on another display.

You can log in remotely from Microsoft Windows, too. In that case, you have to run a XServer on your MS Windows.

As many users as can login remotely with SSH can therefore run graphics applications and show them on their screens as long as they use X11 forwarding and have running XServer on their computers.

If you would like to use the graphics card on remote computer, then you can use multiseat setup (https://wiki.ubuntu.com/Multiseat, https://www.freedesktop.org/wiki/Software/systemd/multiseat/). Multiseat setup means that more XWindows sessions are running on one computer. Each XWindows session typically has its keyboard, video and mouse hardware. In that case you can make VNC or similar connection to each Xwindows session. Then graphics card on a remote computer is used.


Videos requires to install plugins to play files of the following types: • MPEG-4 AAC decoder • H.264 (High Profile) decoder

Unable to locate package ubuntu-restricted-extras?
Make sure that all Ubuntu repositories are enabled.

Open a terminal and execute :

sudo add-apt-repository main
sudo add-apt-repository universe
sudo add-apt-repository multiverse
sudo add-apt-repository restricted

Now install the packages :

sudo apt-get update
sudo apt-get install ubuntu-restricted-extras

Note :

Maybe the ttf-mscorefonts-installer lets the installation process hang, because the license agreement is hidden in the background. So make sure to accept the Microsoft license agreement.


Black screen when in nvidia mode after updating to kernel 3.13.0-45

I was having exactly the same problem with nvidia-346 and kernel 3.13.0-45 on Ubuntu 14.04 amd64. After too many hours of searching and experimentation, I managed to fix it. I explain the whole problem along with a solution in detail here: http://vxlabs.com/2015/02/05/solving-the-ubuntu-14-04-nvidia-346-nvidia-prime-black-screen-issue/

In short, try the following:

Switch to console (Ctrl-Alt-F1) and stop lightdm: sudo service
lightdm stop
Disable gpu-manager by commenting out everything in
/etc/init/gpu-manager.conf
Switch to nvidia mode by doing sudo prime-select nvidia
Change your /etc/X11/xorg.conf to look like the one at the bottom of this answer,
making sure that the nvidia BusId is correct (check with lspci):
Start X up again with sudo lightdm start

If after this you still get a black screen, please double-check that your xorg.conf has not been reset to the configuration without modesetting. If so, make sure that lightdm has been stopped and gpu-manager disabled before you edit the xorg.conf to change the intel driver to modesetting.

Switching back to Intel you will have to stop lightdm, re-enable
gpu-manager, activate intel mode with sudo prime-select intel and
then restart X with sudo service lightdm start.

It's very possible that later versions of gpu-manager might have
fixed this behaviour.

Here's the correct xorg.conf:

Section "ServerLayout"
  Identifier "layout"
  Screen 0 "nvidia"
  Inactive "intel"
EndSection

Section "Device"
  Identifier "intel"
  Driver "modesetting"
EndSection

Section "Screen"
  Identifier "intel"
 Device "intel"
EndSection

Section "Device"
  Identifier "nvidia"
  Driver "nvidia"
  BusID "PCI:1:0:0"
EndSection

Section "Screen"
  Identifier "nvidia"
  Device "nvidia"
  Option "UseDisplayDevice" "None"
EndSection


Sound output doesn't change automatically after connecting to Bluetooth headset

I had the same problem on Ubuntu 18.04, and I solved it by just copying the file default.pa from /etc/pulse/ into /home/username/.config/pulse/ and it's working.

And now everytime you connect or disconnect the sound output will be changed automatically.

cp /etc/pulse/default.pa /home/username/.config/pulse/


I figured it out. Had to go into software updater settings and delete a few things. I eventually deleted the correct thing, so the upgrade worked fine after that.
Oh, I think the correct thing that I deleted was under "Other Software" heading, but not 100% sure.


In order to optimise command lookup, bash keeps a cache, per bash process, of where it found files. So if you typed python and it found it in /usr/bin/, then changing the PATH to provide another python earlier in the PATH will have no effect. You need to also give the bash command:

hash -r

to forget the optimised cached.  See help hash. (Of course, I assume you reread the .bashrc or set the PATH explicitly in your shell as well).


No Installation candidates found for gitolite

For Xenial Xerus:

andrew@athens:~$ apt-cache search gitolite
gitolite3 - SSH-based gatekeeper for git repositories (version 3)
git-notifier - git commit email notification script
andrew@athens:~$

So your command should be:

sudo apt-get install git gitolite3

This has changed from older versions of Ubuntu...


Screen doesn't resume after putting on sleep mode after installing NVidia drivers, how to fix it?

Somebody from the nvidia forums found a solution to this issue:

https://devtalk.nvidia.com/default/topic/1044633/driver-does-not-wake-gpu-properly-after-suspend-ubuntu-18-10-with-branch-390-410-and-415-/

The user mentions that for him it only works with lightdm, but I use gdm3 and it works fine.
I will paste here the fix (a grub configuration):

GRUB_DEFAULT=0
GRUB_TIMEOUT_STYLE=menu
## GRUB_TIMEOUT=0
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="nosplash"
GRUB_CMDLINE_LINUX="nouveau.blacklist=1 acpi_rev_override=1 acpi_osi=Linux nouveau.modeset=0 pcie_aspm=force drm.vblankoffdelay=1 scsi_mod.use_blk_mq=1 nouveau.runpm=0 mem_sleep_default=deep"

Only the last two lines are important.

To change the grub configuration edit:

/etc/default/grub

And then updated the grub:

sudo update-grub

My config:

Ubuntu 18.04.1 LTS
4.20.3-042003-generic
Driver Version: 415.27


Can someone explain what these messages are REALLY telling me?

init: Failed to spawn hwclock main process: unable to execute: No such file or directory will show up when your disc is seriously messed up.

I found 2 ways of getting this to happen:

When you use rm -r in your root directory and then reboot.
A broken disc/partition table.

The 1st is solved by re-installing. The 2nd might not be solvable; formatting from a live cd with gparted might answer this.

Either way... if you need to rescue files from the system I advice starting up a live cd and backup them up first.


How can I make the sudo GUI work without the admin group?

These applications are likely using Polkit, not sudo (or gksudo or a similar frontend), for authorization. The default rule on Ubuntu for Polkit uses membership in sudo or admin groups:

$ cat /etc/polkit-1/localauthority.conf.d/51-ubuntu-admin.conf
[Configuration]
AdminIdentities=unix-group:sudo;unix-group:admin

Just create a new configuration file in /etc/polkit-1/localauthority.conf.d, say 60-local-admin.conf, containing:

[Configuration]
AdminIdentities=unix-group:<your-group>


How to fix: “Partition does not start on physical sector boundary”

Sectors are the minimum unit of data that the disk hardware can read (what is actually on the disk platters or the SSD memory cells is a different question, but is not relevant at this point). When space is allocated on disk for a file, it is allocated in sectors; if your file is smaller than an (integral) multiple of the sector size, the last remaining bytes of a sector are wasted. In the old days when disks were a lot smaller, a 512-byte sector was a good compromise between the average file size and the acceptable waste (do not confuse the physical sector size with the filesystem block size). With increased density, 512-byte physical sectors have not made sense in the last 10-20 years; spinning drives have had 4KB (8 * 512 byte) sectors for a long time now. Even though you can access stuff on disk at pretty much arbitrary offsets, operations are slightly faster if you access them at sector boundaries.

You can change the partition start and end offsets to be a multiple of 8 sectors (or 4096 bytes, whichever unit gpart uses; I use parted) and remake the partitions, and everything will be happy!


Please help me install my Brother DCP-7040 laser on Ubuntu 14.04

This page lets you download a .deb file, that you can easily install on your system. Download it, go to the download folder and open it.
The Ubuntu Software Center will show up and you'll be able to install the drivers, no terminal or complicated stuff to do :)

Be sure to have enabled partner repositories. If you don't, go to Software & Updates -> Other Software tab and enable Canonical Partners and Canonical Partners (Source Code).


Whilst installing Ubuntu the hard disk was formatted as Ext4, and windows does not recognise Ext4 or your hard disk.

You need to format the disk using a file system that windows recognises such as NTFS or FAT.

The simplest solution is to boot your computer using the Ubuntu live install disc,
 select Try Ubuntu,
and then use Disc Utility or Gparted to format the hard disc as NTFS or FAT.

Once that is done windows will recognise the disc and allow you to install windows XP.


Maybe it will help you: I'm currently running KDE but have LXDE installed, and I managed to launch LXDE panel and some services with just typing startlxde command. However, this doesn't close KDE's panels, so I would have to kill them manually (with killall plasma-desktop or so).

I also managed to launch RazorQt with startrazor.

Unfortunately, I'm not sure whether all DEs provide such bootstrap commands. Xfce4, for example, provides startxfce4, but it can't be run within an existing X session.

Anyway, I think you don't need to run the whole DE. Try starting just window manager and desktop, e.g. kwin --replace and plasma-desktop for KDE.

P.S. Kubuntu is not a DE. KDE is a DE. :-)


How can I disable the global menu in Firefox?

I just updated to Firefox 22.0 under Ubuntu 12.04 / Unity. The add-on is indeed gone.

There is a config setting that appears to disable the (tremendously annoying) global menus.

Open firefox.

Enter about:config in the address bar (like you're trying to go to that URL as a website).

Use the Search field to find the use_unity_menubar setting.

Right-click on it. Choose TOGGLE on the popup dialog. That should turn off the global menus and restore the top-of-window menus. (The full name of the preference is ui.use_unity_menubar.)


Is it safe to remove old vmlinuz.* files from /boot

They will be removed automatically if you run the following:

sudo apt-get autoremove

Update: I found a VM where I haven't run those commands in a few weeks.  Here is the output, showing that autoremove cleans up files in /boot, going from 127M in size down to 96M in size:

stephane@steph-dev-vm ~> du -hs /boot/
127M    /boot/

stephane@steph-dev-vm ~> sudo apt-get install -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  linux-headers-3.16.0-30 linux-headers-3.16.0-30-generic linux-image-3.16.0-30-generic
  linux-image-extra-3.16.0-30-generic
Use 'apt-get autoremove' to remove them.

stephane@steph-dev-vm ~> sudo apt-get autoremove
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  linux-headers-3.16.0-30 linux-headers-3.16.0-30-generic linux-image-3.16.0-30-generic
  linux-image-extra-3.16.0-30-generic
0 upgraded, 0 newly installed, 4 to remove and 0 not upgraded.
After this operation, 281 MB disk space will be freed.
Do you want to continue? [Y/n] y
...
Found linux image: /boot/vmlinuz-3.16.0-31-generic
Found initrd image: /boot/initrd.img-3.16.0-31-generic
Found memtest86+ image: /boot/memtest86+.elf
Found memtest86+ image: /boot/memtest86+.bin
done

stephane@steph-dev-vm ~> du -hs /boot/
96M /boot/


Prevent Bleachbit from wiping in the terminal

Please note the distinction:

"Wiping free disk space": can take hours because it basically fills
up the hard drive
"Overwriting existing files": adds a little extra
time as it deletes specific files, such as cache and logs

In the case of #1, simply do not use the system.free_disk_space option on the command line. This seems so simple so maybe you mean #2.

In the case of #2, if it is enabled in the GUI, turn it off in the GUI or edit ~/.config/bleachbit/bleachbit.ini. If it is not enabled in the GUI, it will be off in the command line unless specified with the --overwrite option.

For your use case (freeing disk space) you want to disable both #1 and #2.


digitalocean page and nixCraft page explains how to install MySql 5.7 on Ubuntu 16.04

The steps are:

  update your system

sudo apt update
sudo apt upgrade

  Install both - mysql client & server

sudo apt install mysql-server mysql-client

    Note: You need to type the password for the MySQL root user:

  Run mysql_secure_installation to secure your installation

sudo mysql_secure_installation

  Testing MySql

systemctl status mysql.service

  You should see that it is running

Please review the full instructions in the provided links.


Copy file from buffer "a" in vim to new txt file

Once you have copied the lines ("a30yy), open the new file (:e some-file - open in current split/window, :tabe some-file - open in new tab, :vs some-file - open in new vertical split/window, etc.), navigate to the position where you want to paste it, and do "ap (or "aP if you want to paste before the cursor).

Technically, a here is a register, not a buffer. Registers are where text that's copied (yanked) or cut (deleted) get stored. Buffers in Vim are the entities which represent files. So when you open a file in Vim, a new buffer is created, which represents that file. The buffer is displayed in a window (aka split), and tabs contain arrangements of windows. The same buffer can be displayed in multiple windows. See this Vi & Vim post.


How do I install the SSH2 extensions of PHP?

The Ubuntu package index lists libssh2-php packages for several tastes (lucid to oneiric). You can look if your system has all the required software, download the libssh2-php.deb from Lucid and install it

sudo dpkg -i libssh2-php*.deb

or use gdebi.

If this don't work you can download the source code from libssh2.org and compile it for yourself.


Realtek RTL8221ce Wireless driver / adapter [Answered]

Apparently, tomaspinho's driver is not working on Kernel version 5.3; check yours:

~$ uname -a

In any case, this driver is, according to its README.md, "being developed for Arch Linux and Ubuntu 18.10. No support will be provided for other Linux distributions or Linux Kernel versions outside of that range". I wouldn't recommend this driver for 18.10 users either, since there is a better solution:

Solution

Try the new driver available in the ubuntu repos. For this, first unistall tomaspinho's and then do:

# Perform the following AFTER UNINSTALLING tomaspinho's driver
sudo add-apt-repository universe
sudo apt update
sudo apt install rtl8821ce-dkms

This solution may only work in Ubuntu 19.10. Consider ditching the 19.04 version in favor of the 19.10.

Working for me in an ASUS fx505dy-bq024 with the Realtek RTL8821CE wifi card under Ubuntu 19.10.


How do I enable direct rendering for Steam games with ATI?

You need the graphics drivers for your card.
Run this command to get your graphics card model.

lspci | grep -i --color 'vga'

Afterwards make sure to look up a decent guide to installing proper graphics drivers for your model of video card.

Here are a few good guides for AMD and NVIDIA cards.

NVIDIA: https://help.ubuntu.com/community/BinaryDriverHowto/Nvidia
AMD: https://help.ubuntu.com/community/BinaryDriverHowto/AMD


Unity quick launch icon opens another program icon on program start

NO, not easily.

This will often occur after an update, where Ubuntu / Unity no longer thinks this is the exact same application.  I also often get this with LibreOffice.

Suggested workarounds:

(1.) Lock the icon that opens to the Unity bar, and remove (detach) the other.

OR

(2.) Recreate your custom launcher, based on the default launcher.  See my posting: How can I edit/create new launcher items in Unity by hand?


1. Enable Synchronize drawing to the vertical blank

You can find this option under your System Settings -> Window Manager Tweaks -> Compositor if you have Xubuntu. I don't know where in other distros. This option basically means some kind of vertical synchronization when drawing.

2. Create & edit xorg.conf

Create /etc/X11/xorg.conf if it doesn't exit and add:

Section "Device"
    Identifier "Intel Graphics"
    Driver     "intel"
    Option     "AccelMethod"    "sna"
    Option     "TearFree"       "true"
EndSection

3. If first 2 steps didn't work

While setting up a Nvidia Graphics Card for a friend I noticed that the xorg.conf is not always enough. Sometimes changing the compositor helps. In his case I switched the standard Xubuntu compositor to "compton". Things worked fine after that.

Restart and you should be fine.


Take a look at bounce email generated by your sendmail

OR

As user root send a test message with SMTP session tracking:

#!/bin/sh
RECIPIENT=email@aol.co.uk
SENDER=jd@example.net
/usr/sbin/sendmail -Am -i -v -f$SENDER -- $RECIPIENT <<END
To: $RECIPIENT
From: $SENDER
Subject: test!

test!
END


install Modem Driver BCMWL for a specific Kernel only out of many

The easiest way is to remove the 5.9 kernel, then install bcmwl-kernel-source, then install the 5.9 kernel back.
Another way would be to extract the contents of the bcmwl-kernel-source package and install the dkms driver manually. But this looks more complex to me.


Ubuntu Server install via USB. No Install option, only Test Memory and Rescue

I've just experienced the same exact issue.  I also used ubuntu-13.10-server-amd64.iso and Universal-USB-Installer-1.9.4.8.exe.  I'm using a 1GB flash drive that also worked fine with the ubuntu-13.10-desktop-i386.iso installer.

Turns out UUI 1.9.4.9 was released on 20-Nov-2013, with "Fix broken Ubuntu Server options." in the changelog, so that answers your question of where the problem lies.  I just downloaded Universal-USB-Installer-1.9.5.0.exe and it worked like a charm.


You may wish to give a chance to Evolution (Available in the Software Center), which is one of the various alternatives to Outlook in Ubuntu.

This video shows the easy steps for how to process a .pst file in order to import your Address Book the same as your Mail, Appointments, Tasks and Journal entries in the same process for a created account in Evolution, after which you can work with your data with ease from within Evolution.

Please notice that the picture was taken as a screenshot in the video.

I am aware that other software, such as Thunderbird offers the same workarounds but I prefer Evolution.

Evolution integrates in Ubuntu so that you'll receive notifications of new email (if properly configured), appointment's reminders and/or birthdays/anniversaries from your contacts (as you wish).

If you need further support, don't hesitate to drop a comment.

Good luck!


How can I enable the wifi connection on HP Pavilion Notebook 8216 83.13?

ensure index of packages/drivers up to date

sudo apt update

update Ubuntu PCI IDs

sudo update-pciids

find your driver and then

sudo apt install (package name)

in my case for my broadcom wireless adapter

sudo apt install bcmwl-kernel-source

but the BIG problem, with a simple solution was to ensure that in bios 'secure boot' was DISABLED, otherwise no wireless network options appeared and sometimes for some reason bios reset to enabled so I had to check 'secure boot' was disabled.  If you have tried all the previous solutions then I would check the secure boot option is disabled.


Here are pre-existing questions/answers on the site.

Using a PPA to install a version of a program other than the version in the Softeware Centre

How to install software in Ubuntu


Can I make grub not show up despite multiple OS being present and continue directly to boot the default one?

You can set the grub timeout to 0. Just edit the file /etc/default/grub and set

GRUB_TIMEOUT=0

This leaves us with the question of how to boot Windows. In the same config file set

GRUB_DEFAULT=saved

After that you can set the default entry to select. If your Ubuntu is the first entry run

sudo grub-set-default 0

This way grub will always select the first entry if you don't specify something else. If you want to start Windows now, you have to start Ubuntu first. Open a terminal and run e.g.

sudo grub-reboot 1

if you want the second entry to be selected on reboot. There you have to enter the number of the entry that is your Windows. Keep in mind that the index is zero based, so the first is 0, the second is 1 and so on.

When using grub-reboot your system reboots and the given entry will be selected default instead of Ubuntu. Since your timeout is 0 it will boot directly. Technically grub still shows but so shortly that you don't see it. I suggest you try out grub-reboot before setting the timeout to 0.

Almost forgot: After every edit of the config file you have to run

sudo update-grub

for the changes to become effective.


Ubuntu upgrade from 16.04 to 18.04 is taking too long

I got the same message. Pressing Enter got it going. Not sure what the message means, but pressing Enter did the upgrade from there.


Based of from this thread, you can disable the sleep process through the duration of your program by calling to idle inhibition via DBus:

org.freedesktop.ScreenSaver.Inhibit

Or you can ping it periodically:

org.freedesktop.ScreenSaver.SimulateUserActivity

If you need to prevent the computer to sleep at all, you can disable temporally (again through dBus) the behavior and then reinstate it. This will kick the screensaver but won't let the computer sleep:

  $ sudo -u gdm dbus-launch gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type 'nothing'


TP-Link T4U v3 AC1300 - Kubuntu 19.10 - Driver not working

TP-Link T4U works fine with driver from here.
Tested on Ubuntu 19.10 and 20.04.


Is there a driver for canoscan D646U scanner?

According to Canon:

  There is no driver for the OS Version you selected. The driver may be
  included in your OS or you may not need a driver.

Also you can checkout the Sane Project, that also shows that the scanner is not supported.


Wifi connects to network but not connects to internet

I have solved this problem, following these steps:

I installed Wicd from software center
Then I uninstalled the network manager with:

sudo aptitude uninstall network-manager

reboot, and connected and it´s connect to the internet well


Getting lines between special char pattern

Here's one solution:

awk '/^---/ {mark++; next} mark == 1 {print}' $FILE_PATH

Which produces:

{
  "date":"2015-09-24",
  "title":"Getting Started with Git",
  "template":"post",
  "thumbnail":"content/thumbnails/test.jpeg",
  "slug":"getting-started-with-git",
  "categories":[ "cat1", "Focus", "Mustang" ],
  "tags":[ "Fiesta", "Focus", "Mustang" ]
}

This increments a variable named mark every time it encounters the --- line. We only print lines when mark == 1. This is a nice solution because it will let you extract abitrary chunks of --- separated text.  That is, if we wanted the second chunk of --- delimited text, we could run:

awk '/^---/ {mark++; next} mark == 2 {print}' $FILE_PATH

Which gives us:

#Hello


Why does Ubuntu refuse to execute files from an NTFS partition?

I had the exact same problem and the solution in my case was to write de exec mount option after the users option. That's because the users option implicitly activate the noexec option, so you have to explicitly specify exec.

I got this from "Why can't I run programs on another partition in Linux?" on Unix & Linux Stack Exchange.


No Legacy BIOS setting/Ubuntu not detecting Windows 8.1

just disabling secure boot will work just fine

if it doesn't detect windows just shrink your volume however you want via diskmgmt.msc and choose something else within your installation, you can repair your windows boot via boot-repair later on


For reasons unclear to me gdb uses SHELL environment variable.
If I run it like this:

$ env SHELL=/bin/bash gdb a.out

gdb stops at breakpoints as expected.


id (mandatory)

    Identifier for the style. This is used in the current language to refer to this style and must be unique for the current document. It can contain a string of letters, digits, hyphens ("-") and underscores ("_").

You can also find more information here.

Hope that helps.


I had the same problem, and after looking around a lot I found that updating the BIOS it works, and, if I am not mistaken the sound bottons will work too.

You need to update it to the 208, and it will work, dual finger scroll and everything, just one problem, if the laptop go suspended you will need to reboot to use it again.

Go to the end of this page

touchpad does not work on Asus X450L


Shell script now working on post/get request

You need to cd to the correct directory first. Scripts run by the webserver generally run in the document root (/var/www). Also, the directory must be writable for the webserver (user www-data).


read only + browseable issue: configured in smb.conf - not showing in testparm

Finally found the answer to the problem. I made a big mistake with the server address on my clients. I was pointing to the directory /export/music, but should've been pointing to the share itself [music], which is mentioned in  /etc/samba/smb.conf

Problem = smb://192.168.0.200/export/music

Solution = smb://192.168.0.200/music

Anyway, it's all working now :-)


Why do some python scripts begin with #!/usr/bin/env python?

Using env in the shebang of a script
Python scripts are not different from scripts in any other language on this.
Either the usage of #!/usr/bin/env python or #!/usr/bin/python plays a role if the script is executable, and called without the preceding language. The script then calls the language's interpreter to run the code inside the script, and the shebang is the "guide" to find, in your example, python.
Using #!/usr/bin/env python instead of the absolute (full path) #!/usr/bin/python makes sure python (or any other language's interpreter) is found, in case it might not be in exactly the same location across different Linux- or Unix -like distributions, as explained e.g. here.
Although #!/usr/bin/python will work on a default Ubuntu system, it is therefore good practice to use  #!/usr/bin/env python instead.
About env
env is an executable in /usr/bin, or, as mentioned by @hvd (thanks for the hint!), available as a compatibility symlink in /usr/bin to env, in pretty much all Linux distributions.
From Wikipedia:

env is a shell command for Unix and Unix-like operating systems. It is used to either print a list of environment variables or run another utility in an altered environment without having to modify the currently existing environment. Using env, variables may be added or removed, and existing variables may be changed by assigning new values to them.
and in relation to your question:
In practice, env has another common use. It is often used by shell scripts to launch the correct interpreter. In this usage, the environment is typically not changed

More on env is to be found here, and, as always, in man env (from a terminal).

Additional information on the shebang; why doesn't #!python work?
In a comment, it was asked why we cannot simply use #!python as a shebang. Since the interpreter is in $PATH, the idea is understandable.
The reason is that an executable is executed by execve, as we can read here. Specifically the lines:
An interpreter script is a text file that has execute permission enabled and whose first line is of the form:
#! interpreter [optional-arg]
The interpreter must be a valid pathname for an executable....
explain that execve demands a full (valid) path to the interpreter. That makes sense, since scripts (in any language) can e.g. be run at any moment during startup as well, possibly before $PATH is set at all.


Man, its been years since I used a floppy disk.

I would check if the write protect tab is in the correct position, and try with another disk to ensure that it is not a problem with the drive.

(I'm assuming this is a 3 1/4 inch floppy. If its a 5 1/2 inch floppy it needs to be covered by tape, and if its an 8 inch floppy, it belongs in a museum.)


How do I rename files without a right-click?

Select (click on) the file, and press F2
The filename will be highlighted as shown below; simply type the new name and press Enter to rename the file.


Wireless and Bluetooth are not working - Lenovo Y700

Your Intel wireless card isn't supported by the kernel you are currently using.  To fix this we can install backports
sudo apt-get install linux-headers-generic build-essential
wget https://www.kernel.org/pub/linux/kernel/projects/backports/2015/11/20/backports-20151120.tar.gz
tar -zxvf backports-20151120.tar.gz
cd backports-20151120
make defconfig-iwlwifi
make
sudo make install
wget https://wireless.wiki.kernel.org/_media/en/users/drivers/iwlwifi-8000-ucode-25.30.13.0.tgz
tar -zxvf iwlwifi-8000-ucode-25.30.13.0.tgz
cd iwlwifi-8000-ucode-25.30.13.0/
sudo cp iwlwifi-8000C-13.ucode /lib/firmware/

Reboot and wifi should work since you blacklisted ideapad-laptop already, if you deleted ideapad-laptop from the blacklist, please add it back


Test this:

Download the drivers:

http://download.brother.com/welcome/dlf101533/dcp1610wlpr-3.0.1-1.i386.deb
http://download.brother.com/welcome/dlf101532/dcp1610wcupswrapper-3.0.1-1.i386.deb

Install the drivers:

Turn on the printer and connect the usb, network or parallel cable.

Go to the directory where the drivers are.

Run it:
sudo -i
dpkg -i --force-all dcp1610wlpr-3.0.1-1.i386.deb
dpkg  -i  --force-all dcp1610wcupswrapper-3.0.1-1.i386.deb
nano /etc/printcap

Edit the /etc/printcap file according to your connection.

For USB Connection:

Check if the parameter of :lp is :lp=/dev/usb/lp0

For Network Connection:

Replace :lp line to the following 2 lines:

:rm=(ip address of your printer)\
:rp=lp\

Restart the PC.


How do I disable showing the "Activities overview" forever?

You may use a GNOME shell extension called Hide Activities Button. This extension hides the Activities button from the top bar.

Note that you'll still be able access the Activities overview by pressing the Super key (usually the key with Windows logo).

Similar extension: Hide Activities Button (same name, different extension)


This is your wireless device:

Network controller: Intel Corporation Device a370 (rev 10)

We note this error in the message log:

  kernel BUG at
  /build/linux-vxxS7y/linux-4.15.0/drivers/net/wireless/intel/iwlwifi/pcie/rx.c:425!

Congratulations! You are the subject of an official bug! https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1809483

The similar bug report at Red Hat here suggests that the bug is fixed in kernel versions 4.17 et seq: https://bugzilla.redhat.com/show_bug.cgi?id=1574679

I suggest that you download and try the live session for Ubuntu 18.10 which uses kernel version 4.18 to see if the bug is present. If not and, as I suspect, the wireless is working as expected, install it.


Trying to setup multiple primary partitions on Ubuntu linux

Shrink some space as per your requirement from your logical drive having 285.8 GB. Use free space for making Primary partition for ubuntu server.You can use gparted tool for that.
This post will help you.


Where are the packages within an installation DVD?

DEB packages are a transport mechanism, not a runtime medium.  The Ubuntu image has already had the packages installed, so they don't need to explicitly be kept around any more, and in the interest of saving space (and download bandwidth), they're not included in the image.

The package metadata is still stored so that packages can be updated or removed at a later date.  If you want to find the actual debs the image was built from, though, you'll have to go to the Ubuntu archives and download them from there.


Ubuntu 11.04 uses the new Compiz 0.9. This is quite a significant change, and simple-ccsm simply hasn't been updated yet.

Bug #738168 has been reported on Launchpad.


You didn't ask a question, but as to whether it's possible to achieve a 60-40 split with a keyboard command in a default configuration, the answer is no.

You could hack something together, but it might be easier just to grab and drag the window borders like usual. To speed this up, make the window borders thicker.

If you're on KDE, you have more options. There's a command called "Pack Window to the Left" to which you can assign a global shortcut under global shortcuts. Depending on your application, it may help do the trick even faster.

If it's always the same two programs, you get even more options: go into KDE's Special WIndow Settings for that window (right-click the title bar -> More Actions) and you get set the default dimensions, location, and much more, of the respective window.


Ubuntu 12.04 installer not detecting extra hdd

The problem seems to be rooted in the left-overs of a previous employment of RAID1.
The problem was solved by installing the alternative installer ("Text-based installation") that can be found on the Ubuntu Releases page.

When asked to activate RAID configuration, select "No" and installer should detect the affected drive.


The problem is that you have changed the permissions of /usr/local/celtx which is a very bad idea but have not also changed the permissions of wherever it is supposed to save your work.

Anyway, please don't do it this way. Changing the permissions of system folders is never a good idea. Instead, set up sudo to let you use this command with no password. Run sudo visudo and add this line:

youruser ALL=NOPASSWD:/path/to/celtx

So, assuming your username is bob and the celtx executable is in /usr/local/bin, you would add this line:

bob ALL=NOPASSWD:/usr/local/bin/celtx

Now you will be able to run sudo celtx without being prompted for a password, If even writing the sudo is too much, just add this line to your ~/.bashrc:

alias celtx='sudo celtx'

You can now simply run celtx and you will actually run sudo celtx without entering a password. I also suggest you put the permissions back to the way you found them.


Wireless Lan driver for Toshiba Satellite C850-A823 PSKCCV-02300XAR

Without an internet connection, you will need to download several packages on another computer and transfer them on a USB key or similar. Please go here and download the following: http://packages.ubuntu.com/

build-essential, libc6-dev, gcc, g++, make, dpkg-dev,
linux-headers-generic and linux-headers matching your running kernel.

Find out your running kernel with:

uname -r

For example, if you get 3.5.0-19-generic, then you will need to download and install linux-headers-3.5.0-19-generic. When you have all these packages downloaded, move them to the desktop of the Ubuntu machine and install them with:

sudo dpkg -i Desktop/*.deb

The wildcard * means install all the .deb files. Be sure to download 32- or 64-bit as appropriate. At the download site, 32-bit are called i386 and 64-bit are amd64.

Now get the driver package here: http://dl.dropbox.com/u/57056576/DRIVERS/REALTEK/rtl_92ce_92se_92de_8723ae_linux_mac80211_0006.0514.2012.tar.gz

Transfer it to your desktop, too. Right-click the tar.gz and select Extract Here. Back in the terminal, do:

cd ~/Desktop/rtl_92ce_92se_92de_8723ae_linux_mac80211_0006.0514.2012
make
sudo make install
sudo modprobe rtl8723e

Let us know if you get stuck.


Restart when I go to /home or run certain programs

Solved: I read NVIDIA drivers not working after upgrade. Why can I only see terminal?. So I've  removed all files xorg.config*.* from  directory  /etc/X11/  and restart... and  problems has gone!


polkitd: unrecognized service [Ubuntu Server 16.04.3]

The command you're looking for is systemctl restart polkitd.service


Edit : Follow this link to fix the unmet dependency problem.

Go to your Terminal ( Ctrl+Alt+T ) and type the following commands :

sudo apt-get update
sudo apt-get install ubuntu-restricted-extras
sudo apt-get install vlc

This will install vlc, it's dependencies and you should be able to play videos without any problem.


Putting some lines in a script to execute them in gdb

You can use Here Documents of bash (<<) to pass the interactive commands to gdb:

#!/bin/bash
firefox --debug  <<'EOF'
handle SIGPIPE noprint nostop pass
handle SIGSEGV noprint nostop pass
run
EOF

Check the Here Documents section of man bash to get more idea.

Example:

$ cat scr.sh
#!/bin/bash
firefox --debug <<'EOF'
help
quit
EOF

$ bash scr.sh
GNU gdb (Ubuntu 7.7.1-0ubuntu5~14.04.2) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/lib/firefox/firefox...(no debugging symbols found)...done.
(gdb) (gdb) (gdb) (gdb) (gdb) (gdb) (gdb) List of classes of commands:

aliases -- Aliases of other commands
breakpoints -- Making program stop at certain points
data -- Examining data
files -- Specifying and examining files
internals -- Maintenance commands
obscure -- Obscure features
running -- Running the program
stack -- Examining the stack
status -- Status inquiries
support -- Support facilities
tracepoints -- Tracing of program execution without stopping the program
user-defined -- User-defined commands

Type "help" followed by a class name for a list of commands in that class.
Type "help all" for the list of all commands.
Type "help" followed by command name for full documentation.
Type "apropos word" to search for commands related to "word".
Command name abbreviations are allowed if unambiguous.
(gdb)

$  ##Back to prompt


starting and killing evince process in a loop

Note that you don't have to kill all: you can kill the specific instance:

for file in *.pdf; do
    echo "$file"
    evince "$file" &
    sleep 20s
    kill $!
done

$! is the pid of the most recently backgrounded process. (http://www.gnu.org/software/bash/manual/bashref.html#Special-Parameters)


Gnome-Screenshot error in Ubuntu GNOME 13.10

There should be an entire section of the keyboard settings designated to screenshot:

(Run gnome-control-center keyboard shortcuts)

If that fails, gnome-screenshot itself has a control window

(Run gnome-screenshot --interactive)

Using Gnome 3.8.


Web-apps preview always goes to same Hulu page

As of now, the "homepage" for a given integration is set as the url at the moment of integration and can be any page that is a child (in the TLD sense) of the point of integration (unless specified otherwise by the integration script).

There is no convenient way to change that for now (unless you mess up a bit w/ the internals), but we are working on a mechanism for that.

In the meantime, you can force the integration to happen again (navigating to the proper URL) by either:

(provided that you use the latest chromium): go to "chrome://settings", then go to the "Desktop Integration" section, then make sure the "Allow integration" checkbox is checked and remove the websites you want after clicking "Exceptions...",
Same thing as above, in Firefox, in the General section,
the last option would be to used dconf-editor under "com>canonical>unity>webapps" and remove the websites you want,


What's the difference between a Portable VM and live USB?

A virtual machine's performance is better when it is run from a hard drive than from a USB drive due to much less latency, especially if the hard drive is an SSD. The poor performance of running a virtual machine from a USB drive manifests itself as dimmed or gray screen windows of open applications that take a long time to respond. Frequent lagging by itself can cause a virtual machine to be worthless. The good performance of running a virtual machine from an SSD manifests itself itself as performance almost as quick as running the operating system on a physical machine, assuming that the virtual machine has been configured optimally.


I had a similar problem getting into recovery mode, have you tried using the escape key rather than the shift key during boot-up? The whole internet says that it is the shift key, but it only worked for me when I pressed the escape key. Then from there, a dpkg tool is there for broken packages and you can open a shell as root if you have lost any privileges. Besides this I'm not sure what else to say but good luck.


How to customise GRUB after moving OS to thumbdrive

I use "grub-customizer" to do the same thing, though I am using dd to copy the filesystem over to the usb drives. Grub-customizer can install grub to the mbr of other drives, as well as customize entries on other drives easily. It's a great tool, and works with BURG as well.

PPA here: https://launchpad.net/~danielrichter2007/+archive/grub-customizer


Lock builtin laptop keyboard but keep an external USB keyboard functioning

Yes, this should be possible, with the use of xinput.

To start, run xinput list in a terminal. You should see something similar to the following:

zachary@MCServer:~$ xinput list
⎡ Virtual core pointer                          id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎣ Virtual core keyboard                         id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]
    ↳ Power Button                              id=6    [slave  keyboard (3)]
    ↳ Power Button                              id=7    [slave  keyboard (3)]

Now, you'll probably see two keyboards, instead of just one, since you have two keyboards plugged in. I recommend unplugging the USB keyboard and running the command.

Take note of the ID of Virtual core XTEST keyboard. In my case, it's 5.

Plug in the USB keyboard, since you're about to disable the internal one.

Run this command:

xinput set-prop 5 "Device Enabled" 0

and replace 5 with your device ID.

To re-enable the keyboard:

xinput set-prop 5 "Device Enabled" 1`

replace 5 with your device ID.

You can also put these in separate scripts if you want, and run those from the terminal (or create .desktop files to the scripts you make).

Edit:
If you want, I've made a script that will check the state of the specified device in xinput and toggle it (to on if off, to off if on). You will need to change the device variable to the corresponding ID.

#!/bin/bash

device=5 #Change this to reflect your device's ID

output=$(xinput list-props $device | awk '/Device Enabled/{print $4}')

if [ $output == 1 ]
  then
    xinput set-prop $device "Device Enabled" 0
elif [ $output == 0 ]
  then
    xinput set-prop $device "Device Enabled" 1
else
  echo "Something's up."
fi

Edit 2:
Improved script - automatic device ID detection (provided its name is fixed) and desktop notifications.

#!/usr/bin/env bash

# name of the device - we hope this will not change
DEVNAME="AT Translated Set 2 keyboard"
# here we find the device ID corresponding to the name
device=$(xinput list | grep "${DEVNAME}" | sed "s/.*${DEVNAME}.*id=\([0-9]*\).*/\1/g")
# here we get the enabled state
state=$(xinput list-props $device | awk '/Device Enabled/{print $4}')

if [ ${state} == 1 ]; then
    # if it is enabled, disable it and show a notification
    xinput set-prop ${device} 'Device Enabled' 0
    notify-send -u normal "Keyboard lock" "Keyboard \"${DEVNAME}\" (id=${device}) was disabled."
elif [ ${state} == 0 ]; then
    # if it is disabled, enable it and show a notification
    xinput set-prop ${device} 'Device Enabled' 1
    notify-send -u normal "Keyboard lock" "Keyboard \"${DEVNAME}\" (id=${device}) was enabled."
else
    # some weird state - do nothing and show critical notification
    notify-send -u critical "Keyboard lock" "Keyboard \"${DEVNAME}\" (id=${device}) is neither enabled nor disabled. State is \"${state}\""
fi


Menubars missing in libreoffice when used in unshare session in 18.04

The problem is caused by apparmor denying access to DBUS socket.

This can be seen in dmesg output:

audit: type=1400 audit(1542789068.289:1060): apparmor="ALLOWED"
operation="connect"
info="Failed name lookup - disconnected path"
error=-13 profile="libreoffice-soffice"
name="run/user/1000/bus" pid=9545
comm="soffice.bin" requested_mask="wr"
denied_mask="wr" fsuid=1000 ouid=1000

I didn't find out how to fix the actual problem with the apparmor rules, but here is how one can disable the apparmor completely for libreoffice. This has some security risks if you open untrusted files.

sudo ln -s /etc/apparmor.d/usr.lib.libreoffice.* /etc/apparmor.d/disable/
sudo apparmor_parser -R /etc/apparmor.d/usr.lib.libreoffice.*


How do I hide / remove a ZFS dataset from the Nautilus left panel?

Try creating /etc/udev/rules.d/80-udisks2-zvol.rules:

# ZFS volumes
KERNEL=="zd*", ENV{UDISKS_IGNORE}="1"

(from https://blog.vx.sk/archives/238 )


GDbus.Error:org.openobex.Error.Failed: Unable to request session problem

If you run "bluez-simple-agent" (terminal or Alt + F2) you can send files.


Okay. I got the answer. I had to update my VirtualBox software to the latest version and there is checkbox for PAE support.


Have set up a file server. How to make it accessible from anywhere?

Unless the college reconfigures their router to port forward to your computer it cannot be done. The best you can do is host the files on a server outside the college and sync files between that computer and yours


Unity launcher won't update the shortcuts after update-desktop-database (only after log out)

the "standard" situation is that the launcher reads it's information from the .desktop files, located in /usr/share/applications. That is, unless the same application is represented by a local version of the .desktop file in ~/.local/share/applications.

However, when you copy a .desktop file to ~/.local/share/applications/ directory, the system still links to the global one, until next login.

From then on, the launcher links to the local .desktop file, and the changes you make in that local .desktop file take effect instantly.
A Standalone quicklist (a "home made" .desktop file, not calling an existing installed application in its native execute line) is best located in the local directory.


Networkmanager should use another DNS Server in VPN Tunnel

For anyone who stumbles upon this problem, I finally solved it on my own.

The newest Ubuntu versions no longer use DNSMasq, but Systemd-resolve. However, Systemd-resolve does not get informed by the NetworkManager to update the DNS settings when a tunnel is opened. To overcome this issue, one can create a dispatcher script like this:

#!/bin/bash
UUID='uuid-of-vpn-connection-file'
VPNIF="$(nmcli -t connection show "$UUID"| sed -n '^GENERAL\.DEVICES:/{s/^[^:]*:\([^\s]*\)}/\1/;p}
[[ "$1" =~ ^tun -a "$2" = 'up' ]] && systemd-resolve --set-dns xxx.xxx.xxx.xxx --interface "$VPNIF"


Try changing theme [System Settings -> Appearance -> Look -> Theme]


squid3 runs as the user proxy, so you set the owner user (and group) as proxy and then set permissions accordingly.

You can do the following to change recursively the owner and owner group of all files under /var/cache/squid3 to user proxy and group proxy respectively:

sudo chown -R proxy:proxy /var/cache/squid3

Also make sure the owner has the right permission, the permission you currently have i.e. 0755 will do.

In your case, as you can see the directory /var/cache/squid3 is only writable by root, hence you were getting the permission denied error.


Does Ubuntu support engineering software applications?

Generally, the software you are looking to use should indicate what operating systems they support.  Many do not support Linux.  That leaves 2 options.  One is to find a free Linux alternative that does what you want.  The other is to run the Windows version of the software through Wine.  Whether the software runs properly, you can check Wine's website to verify this.  For instance Autocad is reported to work fairly well: Autocad Support.  For things not listed on their website, you would have to experiment and see what happens.


How to solve missing libmng.so.1 in Trusty (14.04) Package is no more available

When the major version number of a library changes, it usually means the library is no longer compatible with the previous interface that it provided. Previous versions of Ubuntu had libmng1, but now libmng2 is provided and all Ubuntu packages in 14.04 have been rebuilt to use libmng.so.2. Third-party applications, as in this case, may need to be rebuilt to work with the updated libraries in 14.04. Until then, you can try installing the library package from the most recent Ubuntu release that had libmng1.

To install libmng1 alongside libmng2, first find the most recent version in supported Ubuntu releases from http://packages.ubuntu.com/libmng1. Then download and install the appropriate package for your architecture. For example:

wget http://archive.ubuntu.com/ubuntu/pool/main/libm/libmng/libmng1_1.0.10-3build1_i386.deb
sudo dpkg -i libmng1_1.0.10-3build1_i386.deb

Note that you will not get updates for this package since it is not in the Ubuntu 14.04 repositories.

Of course a far better solution would be to get the application developers to provide a new build of SoulseekQt that works with Ubuntu 14.04 now that it is released.


You have no ext4 or ext2 partitions at all, but you do have 5 NTFS partitions.  Is one of them where you installed Ubuntu?  If it's /dev/sdc1 then you should follow these instructions to re-install grub.

It really is better to use an ext4 partition when you install Ubuntu or any other Linux distro.


Completely messed up grub/efi/gpt dual boot

First, you're missing an EFI System Partition (ESP), which is used to hold EFI boot loaders. Most computers that ship with Windows 8 use /dev/sda2 as the ESP, and your /dev/sda2 is about the right size for that; but your /dev/sda2 holds a Linux filesystem and has no EFI boot loaders. My hunch is therefore that you've accidentally trashed your ESP, rendering the computer unbootable.

Related to the first point, you don't seem to have any EFI boot loader programs on either your hard disk or your SSD.

Your /dev/sda11 is about the right size to be an ESP and does have a FAT filesystem (which an ESP must have), but it's marked as a BIOS Boot Partition.

As a first step, you must create a proper ESP. There are two relatively easy ways to do this:

Adjust the type code on /dev/sda11. In GParted, you can do this by removing the "bios_grub flag" and setting the "boot flag." In gdisk, you'd do this by setting the type code to EF00.
Adjust the type code on /dev/sda2 and make it FAT32. In GParted, you'd do this by setting a "boot flag" and creating a FAT32 filesystem on it. In gdisk, you'd set the type code to EF00 and then use the separate mkdosfs utility to create a FAT32 filesystem on the partition.

Once that's done, you can begin recovery. In theory, you can use Boot Repair to do the task, at least for Linux; but as it appears it led you down the wrong path before, you might want to do something different:

Download and prepare a bootable USB flash drive or CD-R version of my rEFInd boot manager.
Boot with rEFInd. It should show you at least one option for booting Linux.
Boot to Linux.
Open a Terminal window.
Edit your /etc/fstab file to mount your ESP (/dev/sda2 or /dev/sda11) to /boot/efi.
Type sudo mount -a.
Type df -h and ensure that there's a line for /boot/efi, showing the correct partition mounted. If not, go back to step #5.
Download and install the Debian-package version of rEFInd.

At this point, rEFInd should enable you to boot Linux. Your Windows installation will remain unbootable, though, until you run a Windows recovery tool. You should be able to download something from Microsoft's site to repair the Windows boot loader, but I don't happen to have a URL or instructions handy. I recommend you ask on a Windows site if you have problems with this part of the task. Note that after you're done, the Windows boot loader will be set as the default, so you'll need to change that. You can either follow steps 2 and 10-11 in this procedure or use the USB flash drive to boot to Linux and then re-install rEFInd from there. Alternatively, you could repair Windows before you repair Linux, but you'll need to fix the ESP before you do either OS-specific repair.


The solution appears to be enabling commands. In compizconfig-settings-manager, tick the first box, 'Commands'. Has the default changed?
Somewhat mysterious how the commands 'left behind' from 16.04 worked, but new or modified commands failed.


MultiROM claims to support this use scenario.


On my system it worked when i made a script in the folder /etc/network/if-up.d/ called script with execute permissions 755:

#ls -la /etc/network/if-up.d/script
-rwxr-xr-x 1 root root   46 Okt 15 11:46 script

There you can add command to execute when the connection is established, in your case:

#cat /etc/network/if-up.d/script
#!/bin/bash
# Check for specific interface if desired
[ "$IFACE" != "eth0" ] || exit 0
# Adding additional routes on connection
route add -net 31.135.208.0/21 gw 192.168.2.1 dev eth0
route add ...
route add ...

You don't need to add something in /etc/network/interfaces besides auto eth0 and iface eth0 inet dhcp or whatever you have there. NetworkManager invokes the scripts in this directory by exec run-parts /etc/network/if-up.d in the script /etc/NetworkManager/dispatcher.d/01ifupdown.
You can test this by (in my case):

# run-parts --test /etc/network/if-up.d
/etc/network/if-up.d/000resolvconf
/etc/network/if-up.d/avahi-autoipd
/etc/network/if-up.d/avahi-daemon
/etc/network/if-up.d/ethtool
/etc/network/if-up.d/ip
/etc/network/if-up.d/ntpdate
/etc/network/if-up.d/openssh-server
/etc/network/if-up.d/openvpn
/etc/network/if-up.d/script <---- your script here
/etc/network/if-up.d/upstart
/etc/network/if-up.d/wpasupplicant


Getting Ubuntu to recognize a BCM43231 network card what is up with terminal

This may be a lost cause, as others have given up and used an alternate device.

How to install Netgear N-300 UAB adapter WNA3100 on Ubuntu 12.04 (CLOSED)

Not sure how to proceed ..

The STA driver does not list supporting the Broadcom BCM43231.

Linux Wireless driver doesn't either: Broadcom brcmsmac(PCIe) and brcmfmac(SDIO) drivers

The Windows driver (ndisrapper) method may work: UbuntuForums >> need help with Broadcom BCM43231

SourceForge just refers to UbuntuForums (above): NetGear, Inc. WNA3100(v1) Wireless-N 300

To remove / blacklist older drivers: (adapted from Broadcom Linux hybrid wireless driver >> README.txt)

Check to see if ssb, wl, b43, or bcma are loaded:

lsmod | grep "ssb\|wl\|b43\|bcma"

Blacklist these drivers, to prevent them from loading:

echo "blacklist ssb" >> /etc/modprobe.d/blacklist.conf
echo "blacklist b43" >> /etc/modprobe.d/blacklist.conf
echo "blacklist bcma" >> /etc/modprobe.d/blacklist.conf


Is it possible to use Overlay Scrollbars in Lubuntu?

Yes it is possible...

... at least for GTK apps such as lxterminal, pcmanfm and abiword.
Whether on Lubuntu, Xubuntu or Ubuntu, Chromium/Chrome, Firefox, Opera and Seamonkey are browsers that do not currently support overlay scrollbars. Midori and Web (Epiphany) do. LibreOffice, the office suite, also doesn't support them.
how-to
Just install the overlay-scrollbar package, logout and login
sudo apt-get install overlay-scrollbar


How to check if my Wine prefix is 32 bit or 64 bit?

All you have to do is, Browse the PlayonLinux's Virtual Drives. Go to the WINEPREFIX/drive_c/ folder and look for Program Files folder.

If you only see the Program Files and no ProgramFiles(x86) Then you are using 32 bit Wine Prefix. If you see both then you are using 64 Bit Wine Prefix.
Hope this helps !!


Weird (and annoying) screen flicker on Compaq Presario CQ50

This flickering is a persistent issue; I've experienced it on a Compaq Presario and on a Toshiba Satellite. I've tried a few “solutions” which have not worked for me; maybe one of these will work for you. A) At a terminal, type gstreamer-properties; if nothing happens, install with sudo apt-get install gnome-media; once installed, try tweaking the video properties. B) On my Toshiba, I tried installing updated intel drivers using these instructions (Ubuntu 14.04 - changing Intel graphics driver configurations?); surely there's something similar for your Compaq. C) I tried resetting the resolution and refresh rate as described here (http://www.youtube.com/watch?v=UHZ5n9pHohI). D) I had some kind of success when I used nomodeset (What does `nomodeset` do); there was no flickering, but performance was slowed down in so many other ways that this “solution” is like shooting your foot when you have a toothache to take your mind off the pain in your mouth.

**

I eventually solved this issue by using a newer (3.18) kernel.


Windows drive shows all icons with a "X" tagged!

This means you don't have the necessary permissions to write to the files on the Windows drive. Ubuntu has a wiki on file permissions. However, there is a great program called pysdm that makes changing the file permissions for drives quick and easy. It is avalible through the Ubuntu repositories, and therefore can be installed through sudo apt-get installed pysdm. A screenshot:

More information can be found on the project's homepage here. Hope that helps!


Can you just use system-monitor (pre-installed), its closer to Windows task manager but can start/stop services

Or open a terminal and run

top

another I found is Boot-Up Manager (BUM) It looks simple, may suit your needs

sudo apt-get install bum

I know it says boot up but can stop start services too.

There is also jobs-admin, says it is like bum but simpler

sudo add-apt-repository ppa:jpeddicord/jobtools && apt-get update

sudo apt-get install jobs-admin jobservice

Can't find much about that one.


Neither Windows 7 or Ubuntu will boot after installing 16.04. Any suggestions on how to fix my mistakes?

I had a system with a mix of UEFI and MSR installs. Big mess.

You can have either UEFI or MBR (aka UEFI Legacy), never both.

It is possible to convert the drive to either using Windows Repair CD's 'diskpart' command. Use diskpart in the console and type help, its documented good enough to get you through. Thats the princpile use:

diskpart
> list disk
> select disk 0
> ICanNotRememberCommand MBR

It erases your disk, though. You need to copy all partitions and you will need to run Windows Repair through all stages to get it back. When it does not detect your Windows installation, install Linux onto another partition and put grub into the MBR. After that windows repair showed me the partition and the automatic install ran 3 cycles and I got windows back to run.

Its a very bad situation. To avoid to be ever in such a situation again I made the rule:

all systems with system disk <2GB NEVER use UEFI, always use Uefi Legacy.
all system with system disk >2GB only use UEFI.

Hope it helps,
CatMan

PS: When you try to take images with Clonezilla, it will not work when it finds a mismatch between MBR and GPT. I guess you will get this. In that case Clonezilla suugests the use of a 'sgdrive' command. I had nothing valuable to loose, so I tried it and it worked find, but it could have deleted the data on the drive as well. I did not try other backup tools.


How do I get my QML program to utilize Unity7 notifications? Is there an API I can use?

As far as I know, no such API exists to call libnotify from a QML component.

To avoid creating a C++ plugin just to get notifications for a desktop application, I would use pyotherside to call a small python module to do the job:

Prerequisite:

Install pyotherside: sudo ap-get install pyotherside

First the QML:

import QtQuick 2.0
import Ubuntu.Components 1.1
import io.thp.pyotherside 1.2

Rectangle {
    width: 200
    height: 200

    Button {
        text: "press"
        anchors.centerIn: parent
        onClicked: {
            py.call('notify.pressme', [], function() {});
        }
    }

    Python {
        id: py
        Component.onCompleted: {
            addImportPath(Qt.resolvedUrl('.'));
            importModule('notify', function() {});
        }
    }
}

And the python code (keep both in the same directory), a file named notify.py:

#!/usr/bin/env python3

import subprocess

def pressme():
    subprocess.call(["notify-send", "hello", "world"])

After pressing the QML Button, you'll get a notification like this one:

Please read the notify-send man page for further options.


First of all: you don't have to know the root's password, use your own with sudo command.
For shutdown: sudo shutdown -P now, for example.

If you need a password for root, then issue:
1. sudo su
2. passwd root, and change the password.


cat <script here> | /bin/bash.

This will print the contents of the script and pipe it to /bin/bash.
Note that if you use this method, the shebang (#!/path/to/shell) will not work. Replace /bin/bash with the shell of your choice.

If you want to launch the application from the GUI, make a .desktop file for it.

[Desktop Entry]
Name=<Name>
Exec=<command>
Terminal=false
Type=Application
StartupNotify=false

Place the .desktop file in the same directory as your script.

By the way, chmod works if you are the owner of the script (and chmod is executable).


Turn partition-less disk into partitioned

In theory, I suppose you could shrink the filesystem on the disk by a small amount (say, 2 MiB), then use tricky dd commands to shift it all 1 MiB to the right, then use gdisk or parted to create a partition table with a partition that begins at 1 MiB.

In practice, I do NOT recommend attempting this because there's too much chance of a slipup that will trash everything. It might be OK to risk it if you had a backup, but you say you don't have a backup. Thus, my recommendation is:

BUY ADEQUATE BACKUP HARDWARE! Once that's bought, back up the disk, partition it, and restore. In fact, you could simplify things by buying a similar-sized disk as your backup hardware, partition it normally, copy the files, and begin using the new disk in place of the original and the original as your backup.


serious error while trying to mount partition xxx ignore skip mounting manual recovery

I had the same error until I changed the corresponding line in fstab to the following:

UUID=59B1C23E4CFCC9F3                 /mnt/shared     ntfs-3g defaults        0       0

See the answers to the following questions for more details.


The solid gray bar is your task bar. Right click it and click 'Panel Settings'.
You'll have to manually add everything you had on it.

EDIT:
 The default LXDE panel file is stored at /usr/share/lxpanel/profile/LXDE/panels
Copy this to ~/.config/lxpanel/LXDE/panels to restore the default configuration.


You need the library, not the source I believe.

Please do this

sudo apt-get install libtiff4 libtiff5

EDIT:

sudo ln -s /usr/lib/x86_64-linux-gnu/libtiff.so.4.3.6 /usr/lib/libtiff.so.3

This should fix your problem


Yes, this is intentional. You have to enable those folders to be synced on other computers. You can do that in the Ubuntu One control panel, under Cloud folders. You may wish to have some folders synced on all your personal computers and others on your office computers, for instance.


Is it normal for nm-applet to use 1,5Gig of ram?

Did you recently get an update for network-manager? There's a known problem with the latest upgrade that causes a memory leak in nm-applet.

Search for network-manager-gnome and see if you have the 0.8.2 version. If you have it, revert back to 0.8.1 and block that version for not being upgraded.


Ubuntu 14.04 LTS - Need ppa for libdlib-dev

Here are 64-bit Trusty packages for libdlib18, libdlib-data, and libdlib-dev (source packaging here but using the one straight from Xenial works too if you're willing to tolerate some lintian warnings). Use at your own risk, etc. No, I cannot provide 32-bit packages.


The error is self explanatory.  Basically, what your command that you say you're running, and the actual command you are running are different, and you need to double check the exact command you're running.

In the command you are running, you've got /etc/apt/ssources.list.d/, which doesn't exist anywhere and shouldn't, so the command errors out.

What you need to be running is exactly what you pasted and said was the code you were using, which uses /etc/apt/sources.list.d/ which is the correct directory to use for the owncloud.list file.


Ubuntu Server 18.04.1: mount raid 1 as /boot partition

I switched to the Ubuntu 18.04.1 LTS alternate server image. Here it works!


I use remmina without problems, have you tried that?

I like it as it stores all my servers settings so I can simply switch from one to another.


Unfortunately it's not possible to do this at the minute and there seems to be no hidden settings that come to light when using gsettings or dconf-editor to examine the available schemas and keys. However, to show the available schemas and keys, enter

gsettings list-recursively | grep -i shotwell

It seems that Shotwell always loads the library as the first item; there is no way to workaround the feature at the moment.

A new version of Shotwell (0.13) came out very recently, but there is no mention of this as a feature in the changelog or in any of the other previous release details.

Looking through the feature requests, there is one similar request to yours from 2 years ago here at yorba.org, which proposed that Shotwell should 'show events on startup instead of photos'. There has been no action taken on the request, so I don't think it is a priority with the developers.

At the present minute there doesn't seem to be a way of doing it unfortunately, and one of the developers, Eric Yorba, is a member of this site, so he will probably confirm this.


Video converter: ogv to avi (or another more common format)

You can use avconv to convert and optionally resize (it is included with ffmpeg):

avconv -i "input.ogv" -vcodec mjpeg -acodec mp2 -s 640x480 -vb 3000k -ab 160k "output.avi"

This converts your video to a .avi file with mjpeg and mp2 codecs for good compatibility.

avconv -i "input.ogv" -vcodec mjpeg -acodec mp2 -s 640x480 -qscale 5 "output.avi"

This converts your video using quality scale.


How do I check if I have the exact same deb as installed on a system

You could do a dpkg -l <packagename> and see if the package is installed and what version it is. This may not work if you don't have some sort of guidelines for version numbers and such (eg. when making changes to the code and releasing/installing, you should bump the version number)


Can't set 1280x800 screen resolution on Dell Inspiron 1501 laptop under Lubuntu 18.04

Removing "nomodeset" from grub command line surprisingly fixed the problem without breaking Lubuntu load process in most cases.
In some cases loading Lubuntu without "nomodeset" flag ends up with coloured stripes on display, but restart helps.


why fdisk doesn't show hard disk(/dev/sdf) while lsblk shows hard disk(/dev/sdf)?

The reason is that sudo fdisk -l-l, --list

From man page:

  List the partition tables for the specified devices and then exit.   If
                no devices are given, those mentioned in /proc/partitions (if that file
                exists) are used.

That means, only that devices are listed which are in the output of

less /proc/partitions