DNS errors with PHP script running via Apache2

Sounds like you're experiencing USN-3239-2: GNU C Library Regression where an Ubuntu security update broke DNS lookups.

The problem can be corrected by updating your system to the following package version:
Ubuntu 16.04 LTS: libc6 2.23-0ubuntu7
Ubuntu 14.04 LTS: libc6 2.19-0ubuntu6.11
Ubuntu 12.04 LTS: libc6 2.15-0ubuntu10.17
To update your system, please follow these instructions: https://wiki.ubuntu.com/Security/Upgrades.
After a standard system update you need to reboot your computer to make
all the necessary changes.

See also glibc update caused NSS ABI break on Launchpad.


32 bit program won't run on 19.04 64 bit

It seems that you are missing the x86 compatibility layer. To install it, you need to install some dependencies (IIRC the following):

sudo dpkg --add-architecture i386
sudo apt-get -y install lib32z1 libc6-i386 lib32stdc++6 lib32gcc1 lib32ncurses5

There may be other libs you'd need to install, but these are probably the most popular.


Shell Script : Focus already open terminal tab from second terminal tab

Manual Method

As per this Q&A: Is there a hotkey to switch between tabs in the default terminal app?
After opening the new tab you can return to the previous tab with Ctrl + pg up
Automated Method within script
In order to send the signal to Bash Shell (gnome-terminal) use
xdotool:
sudo apt install xdotool

In your script issue this command:
xdotool key Control+Page_Up

I've just finished installing and testing on Ubuntu 16.04 LTS and it works perfectly. It should work on all X11 desktops.

More conventional method
OP desires Wayland support and more importantly a POSIX method that works with many *NIX distributions.
From this Q&A:

Script to open terminal and show the output of the running commands

... comes this command:
gnome-terminal -e 'bash -c "sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade; exec bash"'

We will modify the example command to look like this:
gnome-terminal -e 'bash -c "second-script.sh; exec bash"'

This is what second-script.sh looks like:
#!/bin/bash

# AU question: https://askubuntu.com/questions/1134625/shell-script-focus-already-open-terminal-tab-from-second-terminal-tab/1135206#1135209

echo "Welcome to the second script."
echo " Run command 1."
sleep 1
echo " Run command 2."
sleep 1
read -n 1 -s -r -p "Press any key to continue"

touch /tmp/second-script-user-ack # signal parent to continue commands there
echo " Run command 3."
sleep 5
echo " Run command 4."
sleep 5

# Now terminates.
exit 0

Always remember to marks scripts executable using:
chmod a+x second-script.sh

Note: This opens a second terminal window that stays open until user closes it. This can be changed to auto-close.
Our first (Parent) script will look like this:
#!/bin/bash

# AU question: https://askubuntu.com/questions/1134625/shell-script-focus-already-open-terminal-tab-from-second-terminal-tab/1135206#1135209

file=/tmp/second-script-user-ack
if [ -f $file ] ; then
    rm $file
fi

window=$(xdotool getactivewindow)
# Launch second script running in background, don't wait
gnome-terminal -e 'bash -c "second-script.sh; exec bash"' &&

while true ; do
    if [ -f $file ] ; then
        break
    fi
done

xdotool windowactivate $window

echo "Child still running. Ready to run extra Parent Commands"
read -n 1 -s -r -p "Press any key to continue"
echo
echo " Parent Command 1."
sleep 5
echo " Parent Command 2."
sleep 5

echo "Parent program completed"
read -n 1 -s -r -p "Press any key to continue"

exit 0

Advantages of current approach:

You can see both windows running at same time. With second tab you can't see both scripts output.
After child process (second-script.sh) completes output is still visible until window is closed.

Wayland tools
There aren't many Wayland tools to control active windows.
I did find this: ydotool but you'll need to compile it by hand. There is no Debian/Ubuntu installation package. There is an Arch Linux installation package which some of your users can use.


Why can't Filezilla quick-connect to Sourceforge any more?

web.sourceforge.net does not support plain FTP (on port 21), only SFTP (i.e. FTP-over-SSH). There really is nothing listening on port 21, hence the ECONNECT error (nothing to do with the external IP).

You need to prefix the URL in QuickConnect with sftp://, i.e. sftp://web.sourceforge.net, and everything works great:


Why does ubuntu crash after resume from suspend

If you start following random links around the web, it's a good thing if you make a system back-up (you're definitely user type 4) before trying random stuff that ends up freezing your computer.

So unless you post an exact list of everything you tried to do, the answer to "Why?" is impossible to answer...

Sorry to be the harbinger of bad news.  :-(


The browser isn't being correctly identified and problems with Whatsapp Web

What worked for me on Ubuntu 17.04:

Removing web.whatsapp.com Data under Preferences > Advanced > Network > Offline Web Content and User Data

What did not work:

Removing WhatsApp cookies
Updating certificates as suggested by Elder Geek


Python - AttributeError with hashlib: no such attribute: "openssl_md_meth_names"

Most likely you still have the wrong hashlib (the one without openssl_md_meth_names) hanging around. It is being imported instead of the proper one.

Do this as a root:

# cd /
# find . | grep hashlib

Then remove (ok, rename ;-) ) any hashlib files not in /usr/lib/python2.7


Adding further variable to until command

If you mean you want to test both variables use && operator and another test

until [ $x  -eq 180000" ] && [ $y -eq  9999 ]; do


Maybe tell us what version of Wine you are using. Also on this page: http://appdb.winehq.org/objectManager.php?sClass=application&iId=2599 it says Retail CD have Bronze badge, so maybe download patch and try again.


What is virtualbox.service and is it safe to disable it?

If you don't use VirtualBox than you can disable it.  Also if your not using VirtualBox then you could just uninstall it.


I found that editing the /etc/bumblebee/bumblebee.conf to match your installed driver. Your file should look like this for your current configuration. When this is configured it will automatically enable and work when using the primusrun command and after exiting the program it will shut it off.

# Configuration file for Bumblebee. Values should **not** be put between quotes

## Server options. Any change made in this section will need a server restart
# to take effect.
[bumblebeed]
# The secondary Xorg server DISPLAY number
VirtualDisplay=:8
# Should the unused Xorg server be kept running? Set this to true if waiting
# for X to be ready is too long and don't need power management at all.
KeepUnusedXServer=false
# The name of the Bumbleblee server group name (GID name)
ServerGroup=bumblebee
# Card power state at exit. Set to false if the card shoud be ON when Bumblebee
# server exits.
TurnCardOffAtExit=false
# The default behavior of '-f' option on optirun. If set to "true", '-f' will
# be ignored.
NoEcoModeOverride=false
# The Driver used by Bumblebee server. If this value is not set (or empty),
# auto-detection is performed. The available drivers are nvidia and nouveau
# (See also the driver-specific sections below)
Driver=nvidia
# Directory with a dummy config file to pass as a -configdir to secondary X
XorgConfDir=/etc/bumblebee/xorg.conf.d

## Client options. Will take effect on the next optirun executed.
[optirun]
# Acceleration/ rendering bridge, possible values are auto, virtualgl and
# primus.
Bridge=auto
# The method used for VirtualGL to transport frames between X servers.
# Possible values are proxy, jpeg, rgb, xv and yuv.
VGLTransport=proxy
# List of paths which are searched for the primus libGL.so.1 when using
# the primus bridge
PrimusLibraryPath=/usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus
# Should the program run under optirun even if Bumblebee server or nvidia card
# is not available?
AllowFallbackToIGC=false

# Driver-specific settings are grouped under [driver-NAME]. The sections are
# parsed if the Driver setting in [bumblebeed] is set to NAME (or if auto-
# detection resolves to NAME).
# PMMethod: method to use for saving power by disabling the nvidia card, valid
# values are: auto - automatically detect which PM method to use
#         bbswitch - new in BB 3, recommended if available
#       switcheroo - vga_switcheroo method, use at your own risk
#             none - disable PM completely
# https://github.com/Bumblebee-Project/Bumblebee/wiki/Comparison-of-PM-methods

## Section with nvidia driver specific options, only parsed if Driver=nvidia
[driver-nvidia]
# Module name to load, defaults to Driver if empty or unset
KernelDriver=nvidia-340
PMMethod=auto
# colon-separated path to the nvidia libraries
LibraryPath=/usr/lib/nvidia-340:/usr/lib32/nvidia-340
# comma-separated path of the directory containing nvidia_drv.so and the
# default Xorg modules path
XorgModulePath=/usr/lib/nvidia-340/xorg,/usr/lib/xorg/modules
XorgConfFile=/etc/bumblebee/xorg.conf.nvidia

## Section with nouveau driver specific options, only parsed if Driver=nouveau
[driver-nouveau]
KernelDriver=nouveau
PMMethod=auto
XorgConfFile=/etc/bumblebee/xorg.conf.nouveau


How do run an arm lxd container on my intel host

Running arm containers on an intel host is possible using qemu but it does not work out the box and requires copying a qemu file onto the container rootfs

Steps for a 16.04 host.

Assuming lxd-client package is installed.

sudo apt-get install qemu-user-static
lxc launch ubuntu:15.04/armhf arm1

Should output:

Creating arm1
Starting arm1
error: Error calling 'lxd forkstart arm1 /var/lib/lxd/containers /var/log/lxd/arm1/lxc.conf': err='exit status 1'
Try `lxc info --show-log arm1` for more info

To fix run:

sudo cp /usr/bin/qemu-arm-static /var/lib/lxd/containers/arm1/rootfs/usr/bin
# then start it again.
lxc start arm1

then you can log in by:

lxc exec arm1 bash


Installed Fresh Ubuntu 18.04.3 LTS on Oracle VM Virtual Box Manager having issue connecting with Putty

From what I see, I assume that when you configured networking for your Virtual Machine, you chose NAT. NAT allows your VM to connect to the Internet, but it doesn't allow your Host to connect to your Guest. If you want that functionality, choose Host-Only in VirtualBox.

Shut down your Ubuntu VM.
From Preferences in VirtualBox, create a new Host-Only network.
From the VM Settings for your Ubuntu machine, change the network type from NAT to Host-Only.
Ensure that the chosen network is the one you created earlier.
Start your Ubuntu VM.
Note the IP address now, and try logging in with PuTTY.

For more details, refer here.


How to show dot symbol under the icon of the opened application when searching it using super key

Most probably you don't have a correct StartupWMClass entry in your manually created .desktop launcher for the application. To add one, follow the steps below.

Launch Firefox application in question.
Run xprop WM_CLASS in a Terminal window. The cursor should turn into a crosshair.
Place the cursor over the opened Firefox window and click. You should get a WM_CLASS string for the application in Terminal.
Open the manually created .desktop file in a text editor and add (or modify) the following line

StartupWMClass=OBTAINED-VALUE

In place of OBTAINED-VALUE put a value you got from step 3 without any quotes.
Save the .desktop file.


All Kernel image files are located in /boot. To find out which one you are currently using, run
uname -r

As en example, on my Xubuntu 12.04 machine, if I run

xuser@esr:/boot$ uname -r
3.2.0-53-generic

Now, to check in /boot:

xuser@esr:/boot$ ls -lha /boot | grep 3.2.0-53-generic
-rw-r--r--  1 root root 782K Aug 23 00:13 abi-3.2.0-53-generic
-rw-r--r--  1 root root 145K Aug 23 00:13 config-3.2.0-53-generic
-rw-r--r--  1 root root  14M Sep  9 16:46 initrd.img-3.2.0-53-generic
-rw-------  1 root root 2.2M Aug 23 00:13 System.map-3.2.0-53-generic
-rw-------  1 root root 4.7M Aug 23 00:13 vmlinuz-3.2.0-53-generic

As you can see, my kernel image file is called vmlinuz-3.2.0-53-generic is 4.7 MB big. The initial RAM disk it loads has 14 MB.


Honestly if you look here, people everywhere experience this (including me), on higher and lower end pc's, it's most probably something Adobe should add to the top of their priority list but HTML5 is also something web-publishers should start adding to theirs, too..

Sometimes my Firefox shuts down or experiences horrific lag and I'm on a dual core Intel with 4gb RAM.


First, to give access only to the Gitlab CI runner, you need to use a more restricted command:

xhost +SI:localuser:gitlab-runner

Second, /etc/rc.local runs way too early for this command to have effect, and further, you need to set $DISPLAY for it to work.

It depends on how your X server is being started. If you're using LightDM, I think you can make it work by adding the following line to /etc/lightdm/lightdm.conf:

greeter-setup-script=xhost +SI:localuser:gitlab-runner


100% CPU consumption with Adobe Flash videos in Chrome?

It seems to be the Chrome's plugin "sandboxing". In Chrome forums they recommend to clear cache, but that works in some cases...

You can try Chromium and install Adobe Flash separately (Chrome includes a customized version of Flash).


Alternatively you could install flash player from the terminal (press Ctrl + Alt + T) and type in the following:

sudo apt-get install flashplugin-installer


I'd personally stick with your gut feeling and reject their request for Flash buttons for a few reasons:

Search engines won't spider through them (essentially hurting the site's ranking).
Pages take longer to load because Flash adds a lot of overhead on low-powered systems. They won't work at all on things that don't support Flash (read: millions of smart phones).
Buttons are harder to edit and maintain.

The first two should be justification enough for the client.

If you need a button to do something fancy, I'd look to Javascript. Unless you're getting really whacky, you can do simple animations, even play sound (but a plea from the internet: please don't) in a nice, accessible way.

StackOverflow is probably a more helpful place for specific help on doing something like that though.


Are you starting sshfs from your shell, or from a boot-time script?

If you are starting it from your shell, and provided you have a running ssh-agent, it should just work:

$ ssh-add -l
2048 SHA256:XXXXX /home/ji/.ssh/id_rsa (RSA)
$ echo success > foo
$ scp foo ins:
  ...
$ rm foo
$ mkdir /tmp/j
$ sshfs ins: /tmp/j
$ cat /tmp/j/foo
success

If you are starting it from a location that does not already have SSH_AUTH_SOCK in its environment, and assuming the ssh-agent is already active and has the key, you can simply set SSH_AUTH_SOCK to the correct value, which you can either get by running ps uxeww | grep SSH_AUTH_SOCK and massaging the output, or simply looking at whichever /tmp/ssh-*/* socket you can access and using that! I assume you can write a simple shell script to do that!


The developer of this particular piece of software was lazy enough not to care about platforms other than Windows. It may or may not work at all.

First of all, you need to re-create the Makefiles, by running:

qmake -project
qmake

Then try running:

make

You will probably be missing a lot of libraries and header files on the first try. Go ahead and google each error you get, and hope for the best.

EDIT: By the way, there are a number of Sudoku games available for Ubuntu in the repositories. Look for them in the Software Center, or from the terminal:

apt-cache search sudoku

Then install by running, for example:

sudo apt-get install ksudoku


You can try these steps if not done already. In the bios menu:

Turn off secure boot
Choose manual as the preferred option instead of UEFI in the firmware option


Application does not display with Core i5 7400

Even if our machine has only one monitor, the SO maybe identifying a second monitor.

Open the display configurations and check If there is a second monitor identified as 'built in display'.
This display must be deactivated.
Hope it helps.


Here's a link to a solution for Ubuntu 12.04. Hope it helps. From the terminal:

Change to your home directory.

cd ~

Get Pygame source code.

sudo apt-get install mercurial
hg clone https://bitbucket.org/pygame/pygame
cd pygame

Install dependencies.

sudo apt-get install python3-dev python3-numpy libsdl-dev libsdl-image1.2-dev \
  libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsmpeg-dev libportmidi-dev \
  libavformat-dev libswscale-dev libjpeg-dev libfreetype6-dev

Build and install Pygame.

python3 setup.py build
sudo python3 setup.py install


Nvidia graphics drivers not installing properly

After installing 'nvidia-current' did you execute 'nvidia-xconfig' to overwrite your default video configuration? If you did not it will not know to use your new nvidia configuration. Give it a try and let me know the result.


how to block domains that pointing to my server IP in ubuntu 16.04LTS

For your catchall, delete the actual ServerName line entirely.

Consider to follow exactly the Ubuntu Serverguide and use a separate file for each virtual host or site, and then leave the /etc/apache2/sites-available/000-default.conf in its original form.


I'm running Windows 8.1 and Ubuntu 14.10, but I got the same error message when I was trying to install Ubuntu. The error occurs because your computer has Windows set as the default OS, so every time you boot your computer it tries to go into Windows no matter what.

It might be a little different for you, but I had to turn off fast boot, make Windows no longer my default OS, and then change the boot order. The first change was somewhere in the control panel, in the System Settings I believe. The latter two changes had to be done from the BIOS menu (which I access by pushing the DEL key when my computer starts up, but apparently this is different for all computers. As an alternative, you can hold down the SHIFT key when you click Restart and there you should find some option to change the UEFI preferences or boot into BIOS.)


Why are basic Gnome apps disappearing in 20.04?

There is fundamental difference between the ways the mentioned applications are shipped with Ubuntu 19.10 and 20.04. Those are apps are pre-installed as snap packages in Ubuntu 19.10 whereas in Ubuntu 20.04, they're shipped via a more traditional way (installed with apt).

It seems during the upgrade process, the updater couldn't deal with the change and thus simply removed the snap ones but didn't install the replacements via apt. It's very unlikely there is a conspiracy going on. To be safe, consider reinstalling the ubuntu-desktop meta-package once again.

P.S. GNOME Characters also falls under this category, you should see the same behaviour with that application too.


I need help writing a script that reads names from a file

Since this is pretty much a homework question, I won't give exact answer. However, here's some ideas that may lead you to solution.

Many tools allow splitting text into columns or "fields" at specific characters. In your case, you want to split text at commas, and extract field #2. Tools such as awk, allow specifying field separator with  -F option, and printing fields as $1, $2, $3 , etc. cut as Elder Geek mentioned, is another tool for such job, and can use -d for field delimiter and -fx for fields, where x is an integer number.

Having extracted those fields, you will want to pass each one of them to useradd or better adduser, which is a Perl script designed specifically for easy addition of users to the system. If you're outputing each name from previous command via pipe to adduser, you might want to use something like

command1 | xargs adduser

There's a bit of a problem however - you're going to be getting a string with first name and last name separated by space. Typical Unix username is done as single string, so I'd recommend you send the extracted name via tr -d ' ' command, which deletes spaces. That way you'll create a user ValerieAdams for example. Depending on your requirements this may or may not be acceptable, so review the requirements.

In addition, as Kaz Wolfe pointed out capitals in username are not allowed by default in adduser, however it's possible to use --force-badname flag as per karthic87's answer


I had a similar problem yesterday and I re downloaded the distribution.  Today's distribution was 1001MB as opposed to 961MB yesterday so there were some changes.  Today's distribution seemed to boot correctly in spite of the fact that error checking the squash filesystem showed errors in 2 files for both yesterday and today.


Using MS Excel Keyboard shortcuts on Ubuntu

The Trick is to Keep Alt Pressed when using the commands...
Have been working on Ubuntu for 2 years..Except for selection on Filters using Space bar..no issues.

PS : Macros do not work in Wine..


Why doesn't Network Manager use system network scheme?

You may find that there are issues with NM handling PPPoE connections, especially if through Wi-Fi.

However, to fix exactly what you're describing, you may want to try setting NetworkManager in "managed" mode by editing /etc/NetworkManager/nm-system-settings.conf and changing managed=true to false.

This tells NM to use the configuration in /etc/network/interfaces if possible (and if it understands the syntax in there, but the logic is getting better and better) and to create a connection that can be turned on or off. It's definitely worth a try ;)


Light locker no longer blanks screen or puts monitor into energy saving mode

Switch to xscreensaver.

$ sudo apt-get remove light-locker
$ pkill light-locker
$ sudo apt-get install xscreensaver

Edit the screensaver settings (click yes/okay if asked to start the daemon):

$ xscreensaver-demo

Open the XFCE Power Manager ("Power Manager" from the "Settings" menu) and  de-select "Handle display power management" in the "Display" tab.


Change User Profile Photo in UBUNTU 14.04

I got the same problem. User Accounts doesn't seem to detect webcam.

Use Cheese, take a photo of yourself, save it as a file and then add it to your account.

If that doesn't work change your user account photo without using Gnome Control Center ( as seen here) by running in terminal:

sudo gedit /var/lib/AccountsService/users/<replace_with_your_name>

and change the Icon setting under User with the path to a 96 by 96 pixel jpg file. Then Log out and in. Your name lowercase as the user folder in /home (tamil in your case)


How to chase and analyze the cause of a crash

At a teminal type cat /var/log/syslog | grep -i shutdown
For older syslog type cat /var/log/syslog.1 | grep -i shutdown
And you can swap out the word shutdown for other words like mozilla etc.
You'll get more that you want but if you know exactly when it happened it might give you a lead.


Command line tool to correct whitebalance of scanned PDFs

convert from imagemagick did the job in my case with commandline:

for file in *.pdf; do convert $file -normalize -level 98%,100% $file.pdf; done

then play with -level parameters in case you are not happy with the result


In principle, a user created in that way cannot do any damage outside his/her own home directory. As you noticed, a regular user does have access to various directories (e.g. in /, /usr/, /tmp). This is a necessity, because most user-accessible programs are located in /usr/bin and /bin. If the user didn't have (read-only) access to these directories, he/she wouldn't be able to run any programs.
However, a regular user doesn't have accesss to home directories of other users.

You can use the ls -l command to see permissions on a file or directory. See https://help.ubuntu.com/community/FilePermissions for more information on file permissions.

It is possible to limit an ssh user to only a few programs. See for http://www.pizzashack.org/rssh/ and http://www.cyberciti.biz/tips/linux-unix-restrict-shell-access-with-rssh.html for the rssh tool, which limits the user to only run copying tools like scp and rsync. Such users won't be able to log in normally to get a shell and run other commands.

Another option is to create a 'chroot' or 'jail' environment. See this AskUbuntu question.


removing unity and gnome panel in xubuntu

My opinion, the best way to do that is install from xubuntu media instead of ubuntu mainline media and installing the xubuntu-desktop package.  In my experience, removing the packages you're talking about leads to broken dependency chains or weird bugs when you try and get some other app/widget to work.  You can certainly do it, but I'm not a fan of doing so.


Is there some safe PS2 Emulator for Ubuntu?

You can use wine to emulate windows programs, there is also this thread which might help:
http://ubuntuforums.org/showthread.php?t=2021581


How to setup an access point for two wireless networks of which one ends on a VPN?

There are some ready made distributions that take care of your requirements. My personal favorite would be IPCop. In essence it is a Linux distribution dedicated to converting your system to a sophisticated, state of the art firewall/router appliance. To get a general idea of what is involved take a look at the documentation (both installation and administration) on the above link.

Another great resource is this wikipedia page that lists (almost all!?!) firewall distributions.


Want to start few services automatically during system boot

Ubuntu has a program where you can set certain programs to run at startup. I'm in KDE right now, so I can't get the exact name, but it should come up with a search of startup. Here, point to the script you use to start the services (make sure the script is executable) and apply. If you use commands to start the services, make a .sh file with #!bin/bash at the top and your commands below. If you start the two services with programs, find the paths to those and point the startup app to them.

If this is completely wrong, tell me: I'll delete it.


Try deleting this file:

sudo -H rm ~/.config/geany/geany_socket_*

if you want you can move them to some folder temporarily.


Dual booted Win10 with Ubuntu 14.04, always boots to Ubuntu, and can't switch back

Four things to do:

'sudo nano /etc/default/grub' to edit the grub configuration
Find the line 'GRUB_DISABLE_OS_PROBER=true' and change the 'true' to 'false'
Ctrl + x to save and Y
'sudo update-grub && sudo reboot'

All the best


What is the status of apt-get relative to apt?

Has apt made apt-get unnecessary for the vast majority of users? Short answer: yes. The apt command substitutes for apt-get and more.

Ubuntu is based on Debian, and as such also uses the Advanced Package Tool (APT, do not confuse with the apt command). This involves a variety of tools to interact with APT for installing, remove and managing software. These tools are partly integrated in higher-level tools for easier use. apt-get and aptitude are such tools. Next to apt-get, there are several other tools, including apt-cache, apt-config.

The more recent apt command is integrating core functionality for package management in one command, and aims to be a more user friendly command line tool for the end user.


How do I investigate boot and partition issues?

The boot info script it a great way to get information for what's going on, especially to troubleshoot what's going on with your boot and partitions.
###For 12.04 and newer:
sudo apt-get install boot-info-script pastebinit

And then run bootinfoscript.
If you need to share the information with someone to help you with your partitions (especially here on Ask Ubuntu, you can use it in conjunction with pastebinit to post your boot information on the web:
sudo bootinfoscript --stdout | pastebinit

This will automatically send the information to paste.ubuntu.com and return a URL for you. Take that URL and then edit it to your question.

###For 11.10 and earlier:

Download the Boot Info Script

Extract the zip file to a directory of your choice.

Open a terminal (Applications -> Accessories -> Terminal in Gnome) and type:
  sudo bash [path/to/the/download_folder]/boot_info_script.sh

For example if you downloaded the file to the desktop, use:
  sudo bash ~/Desktop/boot_info_script.sh

You will now have the file RESULTS.txt in the same directory as the script. But if the script is inside a system directory (like /usr or
/etc) RESULTS.txt will be in the home directory.

If you have pastebinit installed you can send the results directly to paste.ubuntu.com:
sudo bash boot_info_script.sh --stdout | pastebinit


Help Uninstalling Driver installed via dkms

You can uninstall this driver by this command:

sudo dkms remove rt3290sta/2.6.0.0 --all


How can I install packages from Debian's squeeze repo on Ubuntu 12.10?

general warning

In general mixing Debian and Ubuntu is not a good idea, because there are some slight differences.

Keep in mind the Ubuntu releases are not a branch of the current Debian stable.
Normally the packages are synchronized with Debian unstable some time before the Ubuntu release is finished.

Also some special Ubuntu patches may have been applied.

Mixing Debian and Ubuntu repositories will likely render your system unmaintainable.
The package dependencies may introduce contradictions which leads to a deadlock situation.

possible solutions

adding Debian repository to apt

You have been warned above.
If you insist to try it, you can add the Debian DVD to your /etc/apt/sources.list. See man sources.list for details

manual install with dpkg

Install the Debian package with dpkg --force-depends <package.deb>.
Afterwards try to resolve the missing dependencies with apt-get install -f.
If one dependency can't be satisfied by Ubuntu, go back to 1. and install it also this way.

This is better as the 1st approach, but over the time you can run in dependencies problems, if you update your system with apt-get upgrade.

use Launchpad ppa

My advice is that you create a Launchpad account and a ppa repository.
Also install the ubuntu-dev-tools package.

With the following command you can fetch a Debian source and try to compile it for Ubuntu:

backportpackage --upload=ppa:${LAUNCHPAD_USER}/${PPA_NAME}  --source=squeeze --destination=quantal   ${SOURCE_PACAKGE}

To install it, simply use apt-add-repository to add your ppa repository to your apt configuration.

This way is maybe a little bit more complicated, but will help you to ensure that the dependencies are not getting broken.

using ubuntu packages in debian

As above with switching debian with ubuntu and vice versa.

The warning applies as before.

Instead of using a launchpad ppa, you have to grab the sources manually from ubuntu and try to compile them with e.g. pbuilder yourself.

Likely it will fail, if you using debian squeeze because ubuntu quantal is as written above a "fork" from debian unstable.


The lsof command should work for you. Try

lsof | grep cwd

where cwd stands for current working directory.


The default java is java-icedtea.
It caused me a lot of problems/freezing for me to.

I installed Sun Java and the performance is drastically improved.
You should try with that, just follow the instruction and let me know if you have any problems


How to change permission in 11.04 version of ubuntu for root in the file system

You have to be root to be able to create a directory in /.

So if you have sudo installed you can just type sudo mkdir /<yourdir> and change the permissions afterwards with e.g. sudo chown $USER:$USER /<yourdir>. If you don't have sudo installed you have to login as root (type su in a terminal) and execute the commands without the preceding sudo.

If I understood you correctly you tried a to change the ownership of the root file system. Don't do that!


You cannot start Ubuntu at the same time while you're using Windows. You have to choose Ubuntu before entering Windows at the start of your computer.

Press any key at the three-second countdown when you boot your computer. There you must see the options 'Windows' and 'Ubuntu'. Choose Ubuntu.

Also see the link for details: http://www.ehow.com/how_6545352_dual-boot-ubuntu.html


Date set from terminal immidiately reverts

I think the issue you are having is that the time clock updateds automatically when online you can disable time.   "sc config w32time start= disabled"
The. Set time you want
    "date--set day month year time"
Then turn time back on (when done doing whatever)
    "sc config w32time start= demand"


Is there a way to make a file that would run a terminal command when you click it?

Open your text editor, and type the following line: #! /bin/bash. Leave an empty line and start typing your commands. Save the file, the extension doesn't matter.

Go to the file in your file manager, right-click it, open the properties dialog, go to the permissions tab in the dialog, check the "Allow execution of this file", and click the close button. Now you can double-click the file and choose to run it in a terminal window.


How to install Ubuntu on Macbook Pro 10.8.5

here's how to boot from usb : https://help.ubuntu.com/community/Installation/FromUSBStick
If you are wanting to make a Dual-Boot or replace the mac os with ubuntu this link explane
everything :
https://help.ubuntu.com/community/MacBookPro10-1/Precise
If you are wanting to install it on Virtual Machine   here's a youtube video
  http://www.youtube.com/watch?v=_42JLz2izBU


Simple update && upgrade crontab not working on Ubuntu Server [16.04.2]

I ran into a similar issue.  It looks like you need to set the PATH environment variable in order to make apt-get work correctly if it gets called by cron.

Add the following

PATH='/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin'

See this post for more details.


how reset keyboard binding ubuntu 15.04 to defalut on lenovo k2450?

one way is to click the dashboard, type keyboard, then select shortcuts tab. In left pane go to sound and media.

There you can see what is the current shortcut for volume down , volume up. To change these shortcuts, select the appropriate choice with mouse, it will change to "New accelerator" and then you can press the keys you want to select in your case fn +  volume up and fn + volume down.

Alternative have a look at these link1 , link2


Intel integrated graphics screen tearing

I was able to eliminate screen tearing by enabling DRI3 with SNA acceleration. According to the link below, option "TearFree" "true" is not necessary with option "DRI" "3".

https://wiki.archlinux.org/index.php/intel_graphics#Tear-free_video

Here is a method to turn on DRI3 by editing your xorg.conf file to something like this:

Section "Module"
    Load "dri3"
EndSection

Section "Device"
    Identifier  "Intel Graphics"
    Driver      "intel"
    Option      "DRI"   "3"
EndSection


For printing to labels, shifting PDF to align with labels at print time?

I was just able to do this yesterday with pdfedit. What I cannot seem to figure out how to do yet though is to script this from the terminal.

In pdfedit, load the document. Click on the set page transformation matrix icon.

On the first tab, click on Translate (shift) page and set which pages you want to operate on.

On the Page translation (second) tab, set the x and/or y translation values.

Click OK.

All the best!


Abnormal heat occurs due to CPU temperature issues normally. I do no know why it acts weird only in Ubuntu. BTW, try to open up terminal by holding ALT+CTRL+T (if you're in GUI) & type top then post the output. Also have a look at this post too...


How to get ethernet in Ubuntu 14 / Virtualbox 5.0.20 / Windows 7 to work

Answer:

Something was corrupted.  I started over and unziped a new VM .vdi copy

It works now


Windows 7 boot failure after Ubuntu 14.04 installation

I don't claim to be expert interpreting the boot-repair reports, but I don't see a surviving windows partition, so I honestly don't think you have windows anymore.  If it helps I can tell you a lot of things to make you feel better about that, and I can offer significant assistance helping you to set up WINE such that you will actually be able to run windows software under ubuntu BETTER than it ever ran under windows.

Now, just in case I misread that boot-repair report, please open the Ubuntu utility known as "disk utility" to verify the windows partition still exists.  If it does, it ought to be possible to fix it with boot repair, although personally I disliked the version of boot repair you install on the drive you are trying to fix.  I recommend that which runs from a live boot CD, as that's the only type which has worked for me.

Personally I suspect that as many such complaints I've read, you accidentally wiped out your windows partition and there's no getting it back, short of a restore from a full backup.


How can I get lp and lpr to run as if I were root?

Without knowing what is causing your problem it's hard to devise a good workaround.

I should add that I'm not sure applications normally execute the lp or lpr commands in order to print. I assume they use a library interface. An example would be this.

While it's not recommended for security reasons, you can set permissions so that when you run lpr or lp command, they run with the same permission as the user-id they belong to or the group they belong to (root):

sudo chmod u+s /usr/bin/lp /usr/bin/lpr

Whether or not it helps applications print it should help you use these commands without using sudo each time, assuming you decide to bear the risk. Wikipedia mentions those risks, and a reference, here.


KDE 4 opens up the items that were not closed at shutdown again

System Settings > Advanded > Session manager

There should be a setting for start with an empty session.


Gnome-panel white vertical lines between minimized apps

This normally happens if compiz has stopped working or if you are using metacity its composting is turned off.


How to reboot into ubuntu from Microsoft Windows without manually selecting the grub entry?

Take a look at: How can I choose which OS grub will reboot me into—before I reboot?

This looks excactly like what you want. Basically it proposes to use grub-reboot.


Where do files in shared folders go when deleted?

If You delete files, the files are gone forever

Assuming You're using samba as your sharing server.

There's a stackable VFS module in Samba called "recycle"

  What it basically does, is instead of actually deleting the file, it
  moves it to another directory that you specify. This allows you to get
  the file back to them that's as current as the time that they deleted
  it, rather than from the previous night's backup.

To install vfs:

sudo apt-get install samba-vfs

To enable it edit your /etc/samba/smb.conf and

[Docs]
read only = no
path = /mnt/array/docs
write list = @users
force directory mode = 770
force create mode = 660
valid users = @users
inherit acls = Yes
inherit permissions = Yes
vfs objects = full_audit recycle
config-file = /etc/samba/recycle.conf
recycle:repository = /mnt/recycle/%u
recycle:directory_mode = 770
recycle:keeptree = Yes
recycle:versions = Yes
recycle:touch_mtime = yes
full_auditrefix = %u|%I
full_audit:success = open mkdir rmdir write unlink rename
full_audit:failure = mkdir rmdir write unlink rename

and here's the /etc/samba/recycle.conf file contents:

##Recycle Bin Configuration File##
name = Recycle Bin
mode = KEEP_DIRECTORIES|VERSIONS|TOUCH
maxsize = 0
exclude = *.o|*.obj|~$*|*.~??|*.log|*.trace
excludedir = /mnt/array/misc|/tmp|/temp|/cache
noversions = *.dat|*.ini

Source


Why is half my root LVM SSD inaccessible?

I believe you are mistaken and that space was never available, since volumes don't shrink on their own.  You probably did not allocate the rest of the space in the vg to the lv when you set it up.  See the output of pvs.  If the vg has free space, then you can use lvresize -r -l 100%FREE vg/root to expand the volume to use the rest of the free space.  Of course, that means you won't have any free space left to create new volumes or snapshots.


In Dual monitor mode touch works on second monitor

Solved using device name from xinput:

xsetwacom set "Atmel Atmel maXTouch Digitizer" MapToOutput LVDS1


initramfs problem when out of disk space

100MB is sufficient for 2 kernels and a init ramdisk. You can view your current installed kernels by executing:

dpkg -l 'linux-image-*' | grep '^ii'

Example output:

ii  linux-image-2.6.35-28-generic        2.6.35-28.50                               Linux kernel image for version 2.6.35 on x86/x86_64
ii  linux-image-2.6.38-8-generic         2.6.38-8.42                                Linux kernel image for version 2.6.38 on x86/x86_64
ii  linux-image-generic                  2.6.38.8.22                                Generic Linux kernel image

After confirming that the latest kernel works, you can remove the previous ones. In this case, there is only one redundant kernel:

sudo apt-get purge linux-image-2.6.35-28-generic

If this process does not complete because of previous installation triggers, try adding -f (--fix-broken) before purge.


Connecting to WLAN freezes system on Asus eee pc 1001p

I just solved it on my own! :D

As I wrote above, the solution of 'linux_one' in the ubuntuforums didn't work out for me, since the image.deb wouldn't install properly. But her/his solution was right after all.

So this is how I stopped the WLAN from crashing my system:

Go to http://kernel.ubuntu.com/~kernel-ppa/mainline/daily/current/
Download the following files:

linux-headers-3.0.0-999-generic_3.0.0-999.201106141052_i386.deb
linux-headers-3.0.0-999_3.0.0-999.201106141052_all.deb
linux-image-3.0.0-999-generic_3.0.0-999.201106141052_i386.deb

(or the newer files, depending on the date of your download)
And download this file: http://launchpadlibrarian.net/73208056/module-init-tools_3.13-1ubuntu1_i386.deb
Install gdebi, a graphical installer for deb files
Open Gdebi (press [Alt]+[F2], type 'gdebi-gtk' and press enter)
With Gdebi open and install the downloaded linux-headers of step 2
Install the module-init-tools of step 3 using gdebi
Install the linux-image of step 2 with gdebi
Reboot your system. It should automatically boot the new kernel.

And that did the trick for me. Special thanks to 'linux_one' and 'nighthawk77' of ubuntuforums, who did the heavy work on this solution.


When you type:

 sudo <command>

you are running  as root user, the requested password is your password. Only your uid is changed and the environment is the same as your user.

When you type:

 su

su command without parameter allow user to become superuser. In this case the requested password is about root.

When you type:

 sudo su

you are running su as root user, sudo ask your password and su does not. So you can become root without knowing the password.

Caution: It is strongly recommended to not use this command unless you really know very well what you are doing

If you want exec command as another user login shell environment:

 sudo su - <user> -c <command>

or

 sudo -u <user> -i <command>

Here is useful link


Hidden files won't stay hidden in Ubuntu 14.04 LTS

You have set the option Show hidden and backup files in the Edit -> Prefererences. Just clear the checkbox and the hidden files will stay hidden after you re-open the file manager.


Thunderbird does not delete mails on the server

Go into server settings, and un-check Leave message on server.


Installing Ubuntu without touching the rest of corrupted drive

I think, first you should create a image on a external HD of your whole disk using dd, and after that you can try to recover your data from that image. any change of partition map can affect data loss.

hope this helps
Jason


How to find what executable provides a dbus service?

Despite what the other answer says you do not need plasmashell to use KDE Connect.
TL;DR You can ignore the error
kuiserver provides a way for applications such as KDE Connect to report progress for jobs (such as file transfers) to Plasma. Plasma then embedds a progress bar in the panel.
When kuiserver is not available, i.e. when not using Plasma, KDE Connect falls back to displaying the transfer progress in a standalone window. Not as pretty as the progressbar integrated into Plasma, but perfectly functional.
Source: I am a KDE Connect and Plasma developer


How to monitor paths of incoming network requests directly?

The requirements make this one difficult. A crude solution would be to use tcpdump (or wireshark, if preferred), to examine the network traffic directly:

$ sudo tcpdump -n -tttt -i br0 port 80 -A | grep -A 1 GET

Where br0 is my interface name (a bridge). I don't host multiple sites on that test server, but tested via it's name (s15) and ip address (192.168.111.112). The actual web page is just the default apache web page:

doug@s15:~$ sudo tcpdump -n -tttt -i br0 port 80 -A | grep -A 1 GET
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on br0, link-type EN10MB (Ethernet), capture size 262144 bytes
2020-02-16 09:11:56.885246 IP 192.168.111.101.62720 > 192.168.111.112.80: Flags [P.], seq 1:481, ack 1, win 1026, length 480: HTTP: GET / HTTP/1.1
E...<.@...[...oe..op...P....J..)P.......GET / HTTP/1.1
Host: 192.168.111.112
--
2020-02-16 09:11:56.997078 IP 192.168.111.101.62720 > 192.168.111.112.80: Flags [P.], seq 481:920, ack 3526, win 1026, length 439: HTTP: GET /icons/ubuntu-logo.png HTTP/1.1
E...<.@...\...oe..op...P....J.$.P...._..GET /icons/ubuntu-logo.png HTTP/1.1
Host: 192.168.111.112
--
2020-02-16 09:12:25.021292 IP 192.168.111.101.62726 > 192.168.111.112.80: Flags [P.], seq 1:469, ack 1, win 8212, length 468: HTTP: GET / HTTP/1.1
E...<.@...[...oe..op...PC.1..L.CP. .H...GET / HTTP/1.1
Host: s15

You mentioned you didn't want to look at the logs, but that would be way easier:

doug@s15:~$ tail /var/log/apache2/access.log
192.168.111.101 - - [16/Feb/2020:09:05:05 -0800] "GET /icons/ubuntu-logo.png HTTP/1.1" 304 180 "http://s15/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:05:20 -0800] "GET / HTTP/1.1" 200 3525 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:05:21 -0800] "GET /icons/ubuntu-logo.png HTTP/1.1" 200 3623 "http://192.168.111.112/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:05:21 -0800] "GET /favicon.ico HTTP/1.1" 404 493 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:06:15 -0800] "GET / HTTP/1.1" 200 3525 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:06:15 -0800] "GET /icons/ubuntu-logo.png HTTP/1.1" 304 180 "http://192.168.111.112/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:11:56 -0800] "GET / HTTP/1.1" 200 3525 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:11:56 -0800] "GET /icons/ubuntu-logo.png HTTP/1.1" 304 180 "http://192.168.111.112/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:12:25 -0800] "GET / HTTP/1.1" 200 3525 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"
192.168.111.101 - - [16/Feb/2020:09:12:25 -0800] "GET /icons/ubuntu-logo.png HTTP/1.1" 304 180 "http://s15/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0"

Of course, the simple GET string filtering the tcpdump output is prone to false triggering on that string being in the returned content.


You can do this in Ubuntu the same way you do it in Windows:

Start your file browser.  The default one is Nautilus.  You'll see a file folder at the top of the launch bar.

Click on Browse Network.

There you should see the various computer servers that have shared resources.  Click on the desired server, then click on the desired resource.  Answer the login criteria and you're in.


accessing usb drive for storage after making it bootable with 16.04

You can try this if you don't want to wait the whole time..
type dd if=/dev/zero of=/dev/sbd for some seconds
wait until it corrupts current filesystem. (only a few seconds)
On gparted, it will state you have a corrupt MBR or GPT (up to you)
Go to Gparted -> Devices -> Create a Table of Records
choose beetween MBR or GPT.
After that, create a new partition.
There are probably smarter ways, but this one is pretty fast.


How to downgrade OpenCV 3.2 to 3.1 on Ubuntu 16.04?

go to the build folder in your opencv folder. There should be a cmake_uninstall file. If so, just write

sudo make uninstall

and the installation gets removed. Use then

http://www.pytorials.com/how-to-install-opencv340-on-ubuntu1604/

to reinstall openCV properly again.


Mouse wheel doesn't scroll in emacs 23.4.1 in Ubuntu 13.04

Have you loaded library mwheel.el[c], where mouse-wheel-mode is defined?

Make sure the library is in your load-path:

(add-to-list 'load-path "/your/path/to/dir/where/mwheel.el/is/located/")
Then load it:

(require 'mwheel)


How to download 11g express edition on Ubuntu Server?

Its a huge process . you can find it here.

you can download the oracle from here
http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html?ssSourceSiteId=ocomen

link 1 :http://www.makina-corpus.org/blog/howto-install-oracle-11g-ubuntu-linux-1204-precise-pangolin-64bits

link 2: https://forums.oracle.com/thread/2461988


"Cannot initiate the connection to in.archive.ubuntu.com:80" when trying to run "sudo apt-get update" behind proxy

I also face the same problem. To overcome it, you need to change the server to the main server.

Just go to Software & Updates and change the server to the main server next to Download from.


Installing and Creating Themes in the Gnome Desktop

Where can I get the application that 9.x used? It was so convenient

Nowhere, that application was used to and with  GTK 2 Themes, those themes used an XML like structure. GTK 3 was a big leap from that, it uses CSS making them different enough that porting a Theme is really making a new one. Thus Gnome Appearance is no longer of any used in Gnome 3.

Granted that it was easier to change things like colors before it is not that hard now, if you want to change the colors of theme just open the file gtk.css located inside the Theme folder.

You will find colors are in hex, and the lines are pretty self explanatory so you know what you're changing.

Also installing theme snow isn't that hard, just drag n' drop the theme folder inside the hidden themes folder in your Home (.themes/).


How do you install Pantheon on Ubuntu 16.04?

Edit: I installed Pantheon on Ubuntu 16.04 a week ago and it has been working fine so far. Though it does freeze up sometimes for a second or two right after I log-in. (Then again, Pantheon wasn't designed and isn't technically compatible for Ubuntu). But other than that, it is working just fine. This is how I installed it:

To install the Panteon desktop on Ubuntu go to the terminal and type, (These are packages from daily and testing PPAs):

sudo add-apt-repository ppa:elementary-os/daily
sudo add-apt-repository ppa:elementary-os/os-patches
sudo add-apt-repository ppa:elementary-os/testing
sudo add-apt-repository ppa:mpstark/elementary-tweaks-daily
sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install elementary-theme elementary-icon-theme elementary-default-settings elementary-desktop

To install the latest elementary-tweaks:

sudo apt-get install libgconf2-dev libpolkit-gobject-1-dev
git clone https://github.com/elementary-tweaks/elementary-tweaks
cd elementary-tweaks
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr ../
make
sudo make install

// run

switchboard

To install Pantheon desktop on Ubuntu from the official Elementary OS PPA, type:

sudo add-apt-repository ppa:elementary-os/stable
sudo apt-get update
sudo apt-get install elementary-desktop

There you go! Reboot and select Pantheon as your desktop on the login screen!


Test this:

Open a terminal,Press Ctrl+Alt+T

And run:

sudo -i
apt-get update
apt-get remove --purge libpam-smbpass
pam-auth-update
apt-get install gstreamer0.10-ffmpeg
apt-get autoremove
apt-get clean


Tried to disable guest account and now Ubuntu isn't working

I suppose that /etc/lightdm/lightdm.conf didn't exist previously, so now you have an incomplete configuration file.

This is what I suggest:

Try to open a TTY terminal using Alt+Ctrl+F1.
Type your username + Enter + password + Enter to log in.
Remove the file with sudo rm /etc/lightdm/lightdm.conf
Reboot: sudo reboot

Once logged in normally again, check out this page in the official documentation about how to disable the guest session feature.


How to use CLI to start/stop openvpn that works with NetworkManager

Find out what your VPN is named. Look in the TYPE column:

$ nmcli connection
NAME                UUID                                  TYPE      DEVICE
Wired_conn_name     dd87a04c-4a53-3414-8287-190c4c870fb3  ethernet  enp5s0
My_VPN_name         d338359f-447b-4be4-92ff-f3d2e7199275  vpn       --

Start the VPN client using it's name

$ nmcli connection up My_VPN_name

Stop the VPN client using it's name

$ nmcli connection down My_VPN_name


You need a PowerPC iso. Have a look to https://wiki.ubuntu.com/PowerPCDownloads


Yes, it is possible, and there are many ways to do it.

The easiest way, which isn't exactly what you want, is to use a clipboard manager to bind middle-clicking to pasting.  Glippy, which I use, allows me to do this.  It has a setting that makes anything you highlight automatically copied to the clipboard and whatever is in the clipboard pasted by midle clicking.  I'd don't use this because it's incredibly annoying, but the option is there.  Glippy: https://launchpad.net/~bikooo/+archive/glippy

To do exactly what you want you can use xte.  Xte is part of the "xautomation" package:

sudo apt-get install xautomation

Assuming you're using Compiz, open the Compiz Config Manager.  Go to the "Commands" section, then enter something like this as a command:

xte 'keydown Control_L' 'key c' 'keyup Control_L'

The go to the "Button Bindings" tab and map the command to Ctrl+Button3.

Now holding Ctr and pressing the right mouse button will act as pressing Ctrl+C.

To also get this behavior in a terminal the command would be:

xte 'keydown Control_L' 'keydown Shift_L' 'key c' 'keyup Control_L' 'keyup Shirt_L'

To learn more about how to emulate key presses with xte type

man xte

Into a terminal after you install xautomation.


What packages are installed by `sudo apt-get install r-base`?

r-base is a metapackage.

apt-cache show r-base

  ...
  This package is a metapackage which eases the transition from the
  pre-1.5.0 package setup with its larger r-base package. Once
  installed, it  can be safely removed and apt-get will automatically
  upgrade its components  during future upgrades.  Providing this
  package gives a way to users to  then only install r-base-core if they
  so desire.

The base R installation files are in package r-base-core:

apt-cache show r-base-core

  ...
  This package provides the core GNU R system from which only the
  optional  documentation packages r-base-html, r-doc-html, r-doc-pdf
  and r-doc-info  have been split off to somewhat reduce the size of
  this package.

You can view the dependencies of the R packages on their Ubuntu Packages pages:

r-base
r-base-core
r-base-dev


Why is xterm installed when trying to uninstall gnome-terminal?

That's because of dependencies. On a standard Ubuntu installation, the Ubuntu Desktop depends on X.Org which further depends on either GNOME terminal or XTerm or X term emulator which is basically a virtual package.

If you run

aptitude why gnome-terminal

the output will be

i   ubuntu-desktop Depends xorg
i A xorg           Depends gnome-terminal | xterm | x-terminal-emulator

Here i means package is installed, A is automatic and | is OR.

Arguably a terminal shouldn't be a dependency of display server such as X.Org.  This has been already reported on launchpad as Bug #1116791 in 2013.

According to Comment #7 by Bryce Harrington:

  For the xorg source package it looks like the dependency was added long ago just as a convenience to ensure a terminal program was included. Possibly there might be a debian failsafe session that pops it up, but I'm not spotting evidence of such; in any case that wouldn't be important to us.

Moreover, as per Oliver Grawert's comment #8:

  i guess at least using x-terminal-emulator as the dep would help so it is enough to have only one terminal installed

Bryce Harrington later changed the status of the bug to triaged stating

  Perhaps that's a good thing to experiment with in S? I'm reticent to drop it from raring given how late in the game we are, since we don't know exactly what that'd break...

And then it's status was never updated. However in May 2019, Daniel van Vugt changed the status to won't fix just because 13.04 reached EOL in 2014. I believe that wasn't specific to the release version any way.

On the other hand, as pointed out by Jörg W Mittag in their comment, Alacritty should also provide X term emulator. But Alacritty isn't maintained and provided by Ubuntu, so I'm not sure if it is a bug or intended to work like that. As of now, according to x-terminal-emulator - Ubuntu Packages, x-terminal-emulator virtual package is provided by 22 packages.


I found the solution. Here is the problem. Since I am running the rsync daemon with another user, not root, I needed to give rsync the following capabilities:

setcap cap_net_bind_service,cap_setgid=+ep /usr/bin/rsync

cap_net_bind_service - this is needed so the daemon can bind to the system ports(lower than 1024, the default port rsync is binding to is 873)
cap_setgid - this is what caused the setgroups failed error.

Hope this helps someone in the future.


Can I open Microsoft Word and Excel files?

Yes, LibreOffice, or previously OpenOffice.org, can read and write word documents and excel worksheets.


I don't think the warnings are important (unless you need the accessibility bus). Apparently forwarding the accessibility bus over SSH isn't supported yet.

However, you could try the following to suppress the errors if it annoys you:

Prepend the following to any commands:

NO_AT_BRIDGE=1

Or (a long-shot) try using the -Y option with -X in SSH to enable trusted forwarding.


If I remove a partition that was there first, does my second partition get access to the whole drive?

Never used OS-Uninstaller, but I guess it will leave the unallocated space; then you can move/resize the Ubuntu partition.

From what I get of the OS-Uninstaller wiki page, it will just format the partition; in this case you can delete this partition (e.g. using gparted) and resize your existing Ubuntu partition.


Following up on @JEL's answer, there is a permissions issue where snap doesn't allow vlc to access the /dev/video devices.

$ snap connections vlc

    Interface               Plug                        Slot                     Notes
    audio-playback          vlc:audio-playback          :audio-playback          -
    audio-record            vlc:audio-record            -                        -
    camera                  vlc:camera                  -                        -
    desktop                 vlc:desktop                 :desktop                 -
...

To fix this, run: snap connect vlc:camera :camera

This creates a connection between the interface and the slot:

$ snap connections vlc
Interface               Plug                        Slot                     Notes
audio-playback          vlc:audio-playback          :audio-playback          -
audio-record            vlc:audio-record            -                        -
camera                  vlc:camera                  :camera                  manual
desktop                 vlc:desktop                 :desktop                 -
...

see: https://snapcraft.io/docs/interface-management


I fixed it by myself by removing all the java versions and installed 1.7.x again.
Guide which I followed: http://ubuntuforums.org/showthread.php?t=2218888


Downgrade to 4.13 or upgrade to 4.18 from 4.15 kernel

I prefer a tool called ukuu

It allows upgrade and downgrade of any mainstream kernel available.

Install it by:

sudo add-apt-repository ppa:teejee2008/ppa
sudo apt-get update && sudo apt-get install ukuu

Please note this may not always provide super stable releases of your kernel, but I've never had issues


How to install ubuntu in Intels i9 line of processors(7920 &7960)

Disabling secure boot in the bios worked for me.  Was able to install.
But my wifi and network adaptors are not visible.


Has anyone successfully installed CUDA 5.5 on Ubuntu 13.10 64-bit?

I have successfully installed CUDA-5.5.22 on Ubuntu 13.10 64-bit.

$ uname -a
Linux bagchi62 3.11.0-14-generic #21-Ubuntu SMP Tue Nov 12 17:04:55 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

My GPU is GeForce GTX 650Ti. Below are the steps of my installation:

Step 1. Purge the existing NVIDIA driver installations. I had to install the latest NVIDIA driver (331.20) for CUDA-5.5 to work. [I later found that you need at least v319.37 for CUDA-5.5.22 - the toolkit that supports Ubuntu 12.10]

sudo apt-get purge nvidia*

Step 2. Download the latest NVIDIA driver from here: http://www.nvidia.com/Download/index.aspx, and the CUDA toolkit from here: https://developer.nvidia.com/cuda-downloads [I download the .run file for 64-bit Ubuntu 12.10]

Step 3. Create a blacklist for existing video drivers in /etc/modprobe.d. I created a file named /etc/modprobe.d/blacklist-file-drivers.conf with the following content:

blacklist nouveau
blacklist lbm-nouveau
blacklist amd76x_edac
blacklist vga16fb
blacklist rivatv
blacklist rivafb
blacklist nvidiafb
blacklist nvidia-173
blacklist nvidia-96
blacklist nvidia-current
blacklist nvidia-173-updates
blacklist nvidia-96-updates
alias nvidia nvidia_current_updates
alias nouveau off
alias lbm-nouveau off

Step 4. Install the dependencies. [Note: CUDA-5.5.22 needs gcc-v4.7.2 or below for compilation. If you install gcc-4.7, then v4.7.3 is pulled from the repositories, and you cannot install the toolkit. Hence, I used gcc-4.6]

sudo apt-get install freeglut3 freeglut3-dev build-essential libx11-dev libxmu-dev libxi-dev libgl1-mesa-glx libglu1-mesa libglu1-mesa-dev gcc g++ gcc-4.6 g++-4.6 linux-headers-generic linux-source
sudo ln -s /usr/lib/x86_64-linux-gnu/libglut.so.3 /usr/lib/libglut.so

Step 5. Configure your gcc for alternatives. You will need latest gcc for NVIDIA driver and gcc-4.6 for CUDA toolkit. [I have gcc-4.8 as the latest. You have to change accordingly]

sudo update-alternatives --remove-all gcc
sudo update-alternatives --config gcc
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.6 10
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 50

Step 6. Prequisites done. Reboot and drop into a text console (Ctrl+Alt+F1). Kill your display manager. For un-tweaked Ubuntu 13.10, it is lightdm

sudo service lightdm stop

Step 7. Install NVIDIA driver. Navigate to your download directory, and choose your latest gcc. [Note: Do not copy-paste the following code. Change the name of your driver file accordingly]

sudo update-alternatives --config gcc          #choose 4.8
sudo chmod +x NVIDIA-Linux-x86_64-331.20.run
sudo ./NVIDIA-Linux-x86_64-331.20.run

Follow the text instructions. Initially, it would give warnings about unsupported distribution. Ignore and continue.

Step 8. Install CUDA toolkit. [Note: Do not copy-paste the following code. Change the name of your toolkit file accordingly]

sudo update-alternatives --config gcc          #choose 4.6
sudo chmod +x cuda_5.5.22_linux_64.run
sudo ./cuda_5.5.22_linux_64.run

Follow text instruction. Do NOT install the CUDA driver that comes with the toolkit.

Step 9. Add the binaries and lib files to your path. Reboot.

Step 10. Done! You can make the sample files now. Enjoy your CUDA.


Aicrack-ng problem.... monior mode enabled on wlan0mon but airodump causes system log out

airmon-ng check kill .

In Aircrack-ng v1.2 RC2

Airmon-zc looks like will replace airmon-ng.


As a workaround, the activities overview gives a somewhat gridlike list. Alt+F1 invokes it, but you can change it according to this AskUbuntu answer.


When an SQL query fails to return anything, how can I tell the shell to return a "false" instead?

-v option for verbose mode should give you more output. I can't try this right now, since I don't have a SQL server running.


How to copy files from a folder using the find command with the -exec action, or with xargs, to another folder

I'd expect this to work:

find . -type f \( -size -2M -o -size 2M \) -exec cp -t ~/Pictures/test_folder {} +

(I took out the common -type f test.)

With +, the {} is expected to be the last item in an -exec command. From the GNU find manual:

  Only one {} is allowed within the command, and it must appear at the
  end, immediately before the +. A + appearing in any position other
  than immediately after {} is not considered to be special (that is,
  it does not terminate the command).

If you use find and xargs, remember to use the -print0 and -0 options:

find ... -print0 | xargs -0 cp -t ...

With -print0, filenames are delimited with the ASCII NUL character, the only one not allowed in paths. Without this, xargs could split filenames on spaces, so a ./file1 - foo.txt would be seen as ./file1, - and foo.txt by the cp command.


How can I keep a command I started from the shell running if I logout from the shell?

To put the application into the background, use &:

command &

If you wish to close the terminal, and keep the application running, you can use several options: screen ,  dtach  and nohup.

nohup command &

Screen is helpful as you can re-start a session and dtach is fun as well.
Look at the following links for more informations

Screen
Dtach


I have U1 on ipad.  However,  the app is not yet optimized for ipad sized screen.  It still works though.  Just download it and use it.


Can I eliminate windows 8 as I install ubuntu studio?

Your best bet is to download the version you need for your machine using the torrents available on distrowatch.org and force a re-ckeck when it has completed the download to make sure it's all there...  Then burn to dvd at the slowest speed or create a bootable usb flash drive and select the option that suits you during install...  It should easily allow you to wipe the whole hard-drive with a complete install or use a single partition with the install alongside windows option...


The application DISKS from GNOME utility for dealing with storage devices.


How to programmatically swap the caps lock and esc keys?

You can do this through the GUI by open the Keyboard Preferences control panel (under System -> Preferences), and select the Layout tab.  Click on the Options... button to open the layout options dialog.  Expand the Caps Lock key behaviour section and select Swap ESC and Caps Lock.

There are a few ways you could script this kind of thing.

Directly via Xkb

We can make the change directly with the following:

setxkbmap -option caps:swapescape

You can disable all the current layout options (which will return caps lock to its default behaviour) with:

setxkbmap -option ''

Via GConf

The keyboard preferences control panel stores its configuration via gconf, with the layout actually being applied by gnome-settings-daemon.  Therefore, you can cause gnome-settings-daemon to adjust the layout by updating gconf yourself.

The relevant setting in this case appears to be /desktop/gnome/peripherals/keyboard/kbd/options.  So you can set the option with:

gconftool-2 --set /desktop/gnome/peripherals/keyboard/kbd/options \
    --type list --list-type string \
    '[caps<tab>caps:swapescape]'

In the above, <tab> should be a literal tab character rather than spaces.  You can disable the behaviour again by setting the gconf key to an empty list.


Is it possible to update my graphic card drivers?

Intel has not additional drivers (restricted drivers) available for Linux. The drivers are all open source.

If you want to update the driver for Intel graphics card you can add a PPA where the newest drivers included and update from there.

Example . Ubuntu X - Team

sudo apt-add-repository ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get dist-upgrade

If you want to revert back (undo)

sudo apt-get install ppa-purge
sudo ppa-purge ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get dist-upgrade


Why even bother linking it? You can simply add /opt/Eclipse to your PATH. In your ~/.bashrc:

PATH="/opt/Eclipse:$PATH"

and then

source ~/.bashrc

then you should just be able to run

eclipse


How to determine how much time a command takes to finish?

Use time command before your command:

time command

What does it do?

  time (1)             - run programs and summarize system resource usage

For your situation:

time openssl aes-256-cbc -a -salt -in abc.zip -out abc.zip.enc

It will output something like:

real    0m2.199s
user    0m0.008s
sys     0m0.008s

The time in user section is what you are looking for, the time that user space worked on your process.

The sys is related to kernel and the real is what you are getting right now with your echo solution, your clock time from running to the end with the time you spend for entering the password.


What will the workflow be if we execute the scripts as follows

The workflow is unpredictable as asked like this: script3 could finish before script1 or script2 are finished unless there is logic in script3 to test the state of script1 and script2. Same for script4: all it tells right now is that it will start after script3 is done but script 1 and/or script2 could be done or still be running unless there is logic in script4 to test the state of script1 and script2.

This will run them sequentially in background:

(script1; script 2; script3; script 4) &

or if 1/3 and 2/4 are independent:

(script1; script3) &
(script2; script4) &

nohup at the beginning if you don't want it to stop when you exit command line

If would execute the scripts from within the other scripts though. Cleaner and nobody will forget to run the 2nd script after the 1st one has finished.


How to move physical partition into extended partition?

You can just use parted to edit the partition table until it looks like what you want - it would need to mean that you expand the extended partition as well.  Unlike Windows partitioning tools, the regular Linux tools don't wipe the first few KB of a partition (destroying data).  The change to the partition name will mean a different device name so you'll need to account for this in your mount table.  If it's the root or boot partition you'd need to account for it in your initramfs and maybe regenerate grub - all of which can be tricky when you need to be able to boot to it to do it but it's not out of the question.

Make sure you have it backed up in case.

Edit: That said, consider whether you really need to do it as it could reduce flexibility to resize or move in the future - at the moment it's really easy for sdc3 to expand into the free space after it, but if the extended partition ends right after it, you'll have to go into raw partition editing again to do so.


Set different blank screen timeouts when on battery or ac

Install "dconf Editor" tool.
search with the keyword "sleep".
go to the filed "sleep-inactive-ac-timeout"
Give your preferred amount of time in seconds.
go to the filed "sleep-Inctive-ac-type" and choose the preferred value. (i have set it to blank)
same thing do it for "battery mode" also.


How to insert the Interpunct character in ubuntu?

Simply press Ctrl+Shift+U, then type "00b7Enter", i.e. the unicode value of interpunct character.


There seems to be a bug as of the release of QEMU 4.2.0 that causes XV6 to bootloop.

This has been reported on QEMU's Launchpad (LINK).

EDIT 1: Please see xv6 github's pull request #115 for a workaround to the boot loop issue


Same document is printing differently to 2 different printers

All printers have their default settings and no two printers print exactly the same.  If you want them to print the document out exactly I would start by looking at each of the printers Margin settings.


Auto-connect to hidden wireless without elevating privilege

If even after all warnings about using a hidden SSID you still want to use it, this is how you can do it.

Create a script, e.g. ~/bin/nm-connect-me.sh with the follwing contents:

#!/bin/sh
#
# Automatically try to connect to 'MyWiFi' when WiFi is enabled
#

# the output of nmcli should be in English
LC_ALL=C

# loop for a while until NetworkManager is accepting commands
while [ "$(nmcli -t -f WIFI,STATE nm)" = 'enabled:disconnected' ]
do
 nmcli con up id MyWiFi
 sleep 5
done

exit 0

Then add it to your list of startup applications.

Of course you have to replace MyWiFi by your SSID name.

This information has been extracted from: http://blog.nixpanic.net/2011/01/connect-automatically-and-immediately.html


Failed to stop postfix.service: Unit postfix.service not loaded

This Worked for me:

After creating a postfix file, run this command:

sudo apt-get purge postfix

And then reinstall postfix:

sudo apt-get --reinstall install postfix


Go to System > Preferences > Keyboard, tab Layout, click on Options, go to Miscellanous compatibility options and then click on Shift with numeric keypad keys works as in MS Windows.

I don't have a numeric keypad so I can't test if it works but it should.


Secure way to use GUI to ask for network password when using sshfs?

You can use SSH_ASKPASS environment variable. There is package ssh-askpass which provide GUI application, which can be used to request password from a user, if the script is running under the user X. You can try that in this way:

export SSH_ASKPASS=/usr/lib/ssh/x11-ssh-askpass
sshfs [mount arguments]

In this case, you should see the GUI prompt jumping up and letting you enter the password.


Try to uninstall it completely and install it again with the command you have been told to.

Uninstalling: sudo apt-get purge python3-pip


When you're building a command line, always use arrays. It saves a lot of trouble in quoting:

column_names=(--column=TargetDir --column=TargetPage_ID --column=TargetTitle)
row=("Target Dir 1" 1 "TargetTitle 1")

Note how only the necessary quotes (to protect the spaces) are left now.

When using an array a, "${a[@]}" will expand the elements exactly as is, without causing problems with whitespace.
So:

zenity --list --title="list" "${column_names[@]}" "${row[@]}"

Try running printf instead of echo using your original variables, you might see what breaks:

printf "%s\n" $column_names $row

I'm not even going to try to explain what broke in the original quoting. :shudder:


Software to Copy a scratched CD/DVD/Blueray to an ISO file

safecopy

sudo apt-get install safecopy

  safecopy is a data recovery tool which tries to extract as much data
  as possible from a problematic (i.e. damaged sectors) source - like
  floppy drives, hard disk partitions, CDs, tape devices, ..., where
  other tools like dd would fail due to I/O errors.

  Safecopy includes a low level IO layer to read CDROM disks in raw
  mode, and issue device resets and other helpful low level operations
  on a number of other device classes.

http://safecopy.sourceforge.net


Switch to another tty by pressing Ctrl + Alt + F2, then type

sudo killall cinnamon


Installed Ubuntu 15.10 after Windows 10 - boots straight to Ubuntu

You should try boot-repair

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair && boot-repair


Change
plughw:0
and put
plughw:1,0
I think you just need to do that.


Ubuntu 18.04 dropbox-client items cluttering up Status Notifier list

I can confirm this behavior, but I don't know who's bug it is. Anyhow, left below the Known Items list there is a button "Clear Know Items" where you can get rid of them


Server keeps asking for password after I've copied my SSH Public Key to authorized_keys

On the server side, the ssh daemon will log errors in /var/log/auth.log, so check that file to see what's being reported.

From the client side, when establishing the connection you can add the -v flag (or -vv or -vvv) to increase verbosity. You might be able to identify your problem this way.

Here are other things to check.

Make sure /home/git/.ssh/authorized_keys is owned by git.
Make sure /home/git/.ssh/authorized_keys has a mode of 600
(-rw-------).

Also check the /etc/ssh/sshd_config file.

PubkeyAuthentication should be set to yes
There is also the AuthorizedKeysFile directive which determines the
path where the authorized keys should be located. Ensure it's
commented out or on the default of %h/.ssh/authorized_keys.


Since this bug still exists in Ubuntu 14.04 LTS, I post the following solution that I actually found on the link you posted in your last comment :

  try comment=x-gvfs-show instead of comment=gvfs-show (instead of x-gvfs-show)

For people using Disks utility, just uncheck "Show in user interface" in the Mount Options of the partition, and then add comment=x-gvfs-show in the list of options below Symbolic Icon Name :

This should fix the issue.


Ubuntu freezes on boot after upgrade to 14.04

You can try booting 14.04 off a USB stick as a live session. If that gets you a working display, a fresh install from the same USB stick should just work.

If it doesn't boot up a workable live session, you need to give more information about the hardware, like video card type etc.


How do I enable Nepumuk on Lubuntu? - "the nepomuk backup service does not seem to be running"

I don't think that Nepomuk is a default Lubuntu app. It comes with KDE apps/system.

Did you at some point have a KDE app installed which you've then removed ?

$which nepomuk
$
$nepomuk
nepomuk: command not found
$


Here is how I managed to get PlayOnLinux running with both python 2.7.9 (installed alongside POL) and 2.7.12 on the same machine:

First, you have to locate where python 2.7.9 is installed, mine is /usr/bin/python

After that, edit /usr/share/playonlinux/bash/find_python (you might need root-privileges)

Replace these lines:

next_python "python"
next_python "python2.7"

with next_python "/usr/bin/python".

Save & exit. Run playonlinux again.

Voilà.


Upgrading Ubuntu 13.04 to 13.10 stuck during "Installing the upgrades" -- what to do?

Same thing happened to me. I typed sudo killall dropbox on a different terminal and it worked for me, too. Basically why it works is because it stops the process that updates dropbox, then its update is skipped and it continues the os update.


Paint Supreme 3d not opening in Xubuntu 18.04

Looking at the error message, it looks like you have some missing modules that need to be installed: "gail" and "atk-bridge"

So we use apt-cache to locate the relevant packages:

apt-cache search gail

This gives us a few options, but the one we are looking for is:

  libgail-common - GNOME Accessibility Implementation Library -- common modules

And now the atk-bridge:

apt-cache search atk-bridge

Which returns something we want:

  libatk-bridge2.0-0 - AT-SPI 2 toolkit bridge - shared library

Now that we know what packages you need, time to install:

sudo apt install libgail-common libatk-bridge2.0-0

You should now have the required modules to run your program. Enjoy!


Is there any offline application for Kanban or Trello?

There are 3 applications I could find:

https://greggigon.github.io/my-personal-kanban/
http://virtualkanban.net/
http://dmitryivanov.net/

or you can use your evernote as kanban with:
http://www.kanbanote.com/
Also feel free to vote on trello for offline support.
Edit: Trello app now comes with an offline feature:

Trello works offline! Add information to your boards and cards at any
time and it will be saved for when you need it. We got your back.


Toshiba Satellite 875D S7105 - monitor, keyboard, mouse issues

This thread on Ubuntu Forums helped me.

I also switched to using the fglrx drivers instead of the open source drivers. I am not sure that this is needed but I did it before modifying the GRUB configuration file as below (and as per the mentioned post).

Passing two kernel boot parameters i8942.nomux and i8042.reset gets rid of the problem.

To be able to get Ubuntu to load I had to start the laptop and press f8 to get to the GRUB menu, then press e to edit and go down to the line with ro (second to last) and add the i8042.nomux i8042.reset parameters there it, then press f10 to boot. You only have to do this once.

After booting, to set the parameters permanently, edit the file /etc/default/grub, for example using

sudo nano /etc/default/grub

Find the line that starts

GRUB_CMDLINE_LINUX_DEFAULT=

and add the two extra parameters so that after your changes it looks something like

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i8942.nomux i8042.reset"

Save and exit, then run

sudo update-grub

to make the changes effective, then reboot.

After installing the flgrx drivers, I think the monitor worked as expected. After the boot settings, everything else worked as expected. Even the suspend feature works now.

One more thing - in the BIOS of the laptop I set the display to LCD only as per another forum thread. Again not sure it is necessary.


the correct way is this:
Edit your /etc/apt/apt.conf and add this:
Acquire::http::Proxy "http://192.168.43.104:44355";


I would suggest to disable 802.11n protocol by this command

sudo tee /etc/modprobe.d/iwlwifi-opt.conf <<< "options iwlwifi 11n_disable=1"

It will be applied after a reboot.


Cannot play files over samba share on MATE 15.04

A year later... I just discovered that VLC does not use whatever connection the desktop supplies, whether it's Gnome or KDE.
It creates its own using credentials defined in the settings:

Tools > Preferences

Show settings: All

Input / Codecs > Access Modules > SMB

Thanks to Joris for the information.

If it's missing install a plugin:

apt-get install vlc-plugin-samba


How do I run a graphical application on a remote server when logged in through SSH?

So you are connecting from your home pc (let's call it your machine) to a server (let's call it server) via ssh? You want to start a program with a graphical window on the server via your machine? If that is correct than by all means read on.
Let's call the program to start gedit but the process is the same for all. Depending on where you want to see the graphical window skip to the right heading.
Window on your machine's  screen
If you want to see and use gedit's window on your remote machine but start in on the server, you will want your shell session to look like this:
user@remote-machine:~$ ssh -X user@server
Last login: Tue Aug 14 13:47:04 2012 from clientXX
*******************************************************************************
M O T D (Message Of The Day)
*******************************************************************************
user@server:~$ gedit .bash_aliases

** (gedit:7851): WARNING **: Could not load theme icon gtk-home: Icon 'gtk-home' not present in theme

(gedit:7851): Gtk-WARNING **: Attempting to store changes

Don't mind the warnings, they are normal - the gedit window will pop up on your remote machine's screen like it would look on the server. The trick is to use the "-X"-option as in ssh -X which enables X-tunnelling and sets the DISPLAY variable right.
This assumes that you're using an SSH client that supports X11 and that your server has an X-server running (some without a need for GUIs don't run an X-server). Especially on windows this might be an issue as most windows terminal programs don't have X. As izx stated the MobaXTerm is one of the many SSH clients for windows that has an X-Server though.
For a server lacking X11 however, you'd have to install it.
On the server's screen
You can also start an instance on the screen of your server by calling gedit like this:
ssh user@server
DISPLAY=:0.0 gedit

You have to substitute the right value instead of :0.0 though to get it on the right X-screen (only important if multiple screens are connected to your server or if it's somewhat peculiar in its configuration).
Here the most common scenario for that not to work would be if the Server lacked an X11-Server but than it wouldn't have a monitor connected to it or have no graphical user interface and you'd not be reading this :D.
A bit of theory
I'm no expert in this, but the way I think it works is, that each physical screen, i.e. each monitor connected to an individual computer gets a running number in the form of 0.0, 1.0, 2.0,...
This number is assigned by the X-Window-System aka X11. That is a layer to provide a network and basic graphical interface that Unity, Gnome, KDE and the like can build upon.
You can see how many displays a given machine has and what numbers are in use by running for x in /tmp/.X11-unix/X*; do echo ":${x##*X}"; done on the machine in question.* Then each computer that is configured to make its screens available and runs an X server has a hostname. You can use a hosts screens from any machine in the same network by setting your DISPLAY variable accordingly to DISPLAY=hostname:0.0. Ssh does this for you in a sensible way if you provide the -X option.
*Note: I suppose there is a better way than this for-loop.
If all else fails
Use a shell text editor. vi, vim, nano and emacs are the most common and at least one of them will be installed and operational. Of them nano is the easiest and most self explanatory.


Blind shot: You need to enter a password even if you select automatic logins. It used to perform administrative task and as the key to encrypt sensible things.


Ubuntu 13.04 on macbook pro retina boots to black screen after apt-get upgrade

Dont use nvidia current as you are on a Hybrid system with iGPU + dGPU you need to install the following:

sudo apt-get install nvidia-319 nvidia-settings-319 nvidia-prime

The nvidia-prime is what bumblebee used to be and it's called nvidia optimus.

Hope you get your problem fixed.


/etc/passwd file is corrupt and i cannot change it i also cannot login as root

If you lose access to an install like this where you have no physical access to, you're completely at the mercy of your host, their feature-set and how willing to bend-over backwards they are for you.

If you have virtual console access (or your host has it - ask them), they might be able to log in as root, either directly or through recovery mode. Some hosts (Linode for one) have this as a feature but some will require a real person at their end.
Or you could beg them to do a local fix where they mount your filesystem for you and do the fix. I have no idea whether or not they'd even be willing to do this, let alone how much it would cost.
If that doesn't pan out you could ask them for a disk dump. You send them a disk, an image to it and send it back and you fix the file... And send it back and they restore from it. This is not a standard arrangement that hosts have with their customers. Expect to pay for postage in 4 directions and at least ~$100 for their time.

It's still a long-shot with some hosts.
Basically this process is going to teach you how good your host really is. Good hunting.


xbox burner to backup my xbox360 games isnt recognizing game in dvd drive right?ubuntu 12.04

It is discouraged, difficult, unnecessary, and illegal in some locations.
From here:

The Xbox has a specific function: Non-booting or non-reading from CDs and DVD-Rs as a method of game copy protection. Also, the Xbox is said to use a different DVD file system (instead of UDF). It has been theorized that the discs have a second partition that is read from the outside in (opposite current standards thus making the second partition unreadable in PC DVD drives) which give the tracks the appearance that the disc was spun backwards during manufacture. The Xbox 360 copy protection functions by requesting the DVD drive compute the angular distance between specific data sectors on the disc. A duplicated DVD will return different values than a pressed original would.

This is meant to keep users from copying disks. It is, in a nutshell, made so that you can't use CD-R's and need disks that were manufactured to have special layouts of sectors upon the physical surface. This is done as such copies are not generally legal. Also, the fact that a proprietary filesystem is used means that discs cannot be read using normal drives and filesystem utilities.

Legal disclaimer: This is not meant to be legal advice. The author of this answer and Stack Exchange, Inc will not be responsible for any damages, incidental, or consequential, that may arise due to the use of these guidelines. These guidelines are based on US laws and regulations. Laws and regulations in your area may differ so check with a lawyer or local authorities.


gnome-screenshot not making sound with -f option

I don't know the reason but here's a workaround assuming it fits your workflow for taking screenshots:

gnome-screenshot -f $HOME/Pictures/"$(date +%Y%m%d%H%M%S)".png & paplay /usr/share/sounds/freedesktop/stereo/screen-capture.oga

should bring back the sound and save a time-stamped .png file in the specified location which is ~/Pictures in the example above.

Notes:

you may need to include the code in a script and then assign a shortcut keyboard combination to the script because, in some cases, certain codes don't work when used directly in keyboard shortcuts. (See the comments to the answer in How can I save and copy a screenhot at the same time?.)
I used & instead of && to get the sound to play without a lag. && is normally used to ensure the previous command completes successfully.


How do I format a TrueCrypt-encrypted flashdrive?

Using Disk Utility or Gparted, delete the partition and create a new one, format it to your choice of filesystem.  Disk Utility may have a problem deleting partitions it doesn't understand which may include an encrypted partition.  If Gparted also has this problem, open a terminal window and use the following command:

sudo dd if=/dev/zero of=/dev/sdX bs=512 count=1

Where /dev/sdX is the device name of the USB drive.  Make sure you have the right device because there will be nothing left on the target device after you press enter. It deletes the partition table entirely.

You can then re-commission the USB device by using Gparted to create a new partition table then create the primary partition and format it as before.


Ubuntu 18.04 not detecting any wifi network but detects mobile hotspot

I found this from here
Doing this solved the poblem in my ubuntu 18.04
git clone https://github.com/rtlwifi-linux/rtlwifi_new.git
cd rtlwifi_new
make
sudo make install

and reboot.


Ubuntu 12.04 and Firefox 23 - how to turn off JavaScript?

The option was intentionally removed in Firefox 23, on the logic that blocking all javascript makes a significant fraction of sites unusable, and so blocking all javascript, everywhere, is seldom desirable behaviour. As the bug report linked by edwin notes, this was a controversial change.

You can blanket disable javascript by going to page about:config and setting the key javascript.enabled to false.

However, if you want to block javascript an extension like NoScript which gives you fine grained control over which scripts run is a better choice.


I wouldn't want to mess with power settings inside the computer just to make the fan run at 100% all the time.  (you did specify 'without fan control')

If your BIOS doesn't support running fans at 100% all the time (it does on some HP servers) I would definitely go for an external fan!


How to grep output of ls -lhR / for particular owner (ex. root)?

find should answer:

sudo find / -user root

To search a specific directory, just replace / with the full path. You can drop the sudo part of the command if you don't mind warnings about being unable to read special files.

For group ownership finds, use:

sudo find / -group root


The kernel driver for this adapter is not very good.

There is a better driver from Realtek. You can install it this way

 sudo add-apt-repository ppa:hanipouspilot/rtlwifi
 sudo apt-get update
 sudo apt-get install rtlwifi-new-dkms

Then reboot.


This link: https://wireless.wiki.kernel.org/en/users/drivers/iwlwifi includes information regarding the download and installation for Intel HW.

According to that link, installation is simple and done by: cp iwlwifi-*.ucode /lib/firmware.
I recommend you read it first.

Generally speaking, for a tarball included .tgz file, which is essentially an archive (like RAR, ZIP etc), you may use the following:

Using GUI go to the folder you've downloaded it in, and right click your mouse to select 'extract here'.
Then using CLI (the terminal), go to the directory in which it was
extracted (cd [directory]) and input ./configure, make and
make install - in that order.


Add Wireguard vpn to Ubuntu Network Settings

There is currently no integration with Network Manager and the Settings application and Wireguard.  Wireguard does not have a Network Manager plugin to handle it, and in fact requires other Kernel modules to be compiled in, such that it's not readily available on systems.
The only way to configure Wireguard is to do it manually with the wireguard utilities on the command line and with its configuration files - there is no GUI integration with Network Manager at this time.
(Note I am not familiar with GNOME Network Manager upstream, and do not know if Wireguard integration as a plugin is on the radar - that's something you'd have to talk to Network Manager upstream about)


I am not aware that such a solution exists. The closest I see is using the pam module faillock, which locks a user account after a a number of failed login attempts. I guess one could write a pam module that does what you specify.

But this solution would not be secure at all. Lets assume I am an evil secret agent, I want access to some of your super secret data and I have managed to steal your laptop. In that case I would simply take out your hard drive plug it into an other computer and access it from there. Or I would boot your laptop from a flash drive.

Ubuntu offers an easy way to encrypt your home directory, which means unless you are logged in, I - as an attacker - can not access your data. This provides more security AND can not by accident destroy all your data

What could still be useful is a program that destroys data, when you want it. E.g. you know an evil secret agent will steal your laptop soon. and you are afraid they might be able to brake your encryption. But I think then shred ~ would do the job


Create , Write and Save file from a Shell script

For more complex sequences of commands you should consider using the cat command with a here document. The basic format is

command > file << END_TEXT
some text here
more text here
END_TEXT

There are two subtly different behaviors depending whether the END_TEXT label is quoted or unquoted:

unquoted label: the contents are written after the usual shell expansions
quoted label: the contents of the here document are treated literally, without the usual shell expansions

For example consider the following  script

#!/bin/bash

var1="VALUE 1"
var2="VALUE 2"

cat > file1 << EOF1
do some commands on "$var1"
and/or "$var2"
EOF1

cat > file2 << "EOF2"
do some commands on "$var1"
and/or "$var2"
EOF2

The results are

$ cat file1
do some commands on "VALUE 1"
and/or "VALUE 2"

and

$ cat file2
do some commands on "$var1"
and/or "$var2"

If you are outputting shell commands from your script, you probably want the quoted form.


How to complete a dpkg cuBLAS Patch Update to CUDA 8 installation in 16.04?

Open the terminal and type:

sudo dpkg -i cuda-repo-ubuntu1604-8-0-local-cublas-performance-update_8.0.61-1_amd64.deb
sudo apt-get update
sudo apt-get install cuda

Update the PATH variable to include the CUDA binaries folder. To update it, edit the /etc/environment file.

sudo nano /etc/environment

After editing the /etc/environment file will look like this.

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/local/cuda-8.0/bin"

If there are other locations in your PATH don't remove them, leave them in the PATH too.

The instructions for using nano editor are always found at the bottom of every page. The only two nano keyboard shortcuts that you need to know are for WriteOut and Exit. Press the keyboard combination Ctrl+O and after that press Enter to save the file being edited. Press the keyboard combination Ctrl+X to exit nano.

Validate the CUDA installation.

nvcc --version

The results of nvcc --version should show that NVIDIA Cuda is installed.


I ended up purging many packages from my installation to finally be able to do a error free sudo apt-get dist-upgrade and reinstalling many modules.

khelpcenter was just one of many I had to purge and reinstall.
I had to also ude dpkg --configure -a a few times in between.

To be honest I can't remember all the steps.
I am now left with a slight issue unresolved in this question: Ubuntu boots to “Read Only Filesystem” after Upgrading from 16.04 > 16.10


python-pip and python-regex packages are in universe repository. Enable that using:

sudo add-apt-repository universe
sudo apt update

Then install regex:

sudo apt install python-regex #For Python 2
sudo apt install python3-regex #For Python 3

If you want to install regex using pip:

Install pip:

sudo apt install python-pip #For Python 2
sudo apt install python3-pip #For Python 3

And then regex:

 pip install regex #For Python 2
pip3 install regex #For Python 3


Add individual user to sudoers file using SSSD in Ubuntu?

The command to add a user to sudoers is:
sudo adduser <username> sudo

You need to run this command from a user who already has sudo privileges.
Otherwise, you need to run the command adduser <username> sudo as the root user.