Printer share keeps asking for password and I can't authenticate from any machine. Why?

I have rarely had luck configuring a CIFS-reachable printer within Ubuntu.  I've done it, but I don't do it every day: it's possible, with subtleties.

However, I've been able to share printers via http and https routes.  The quick description of this method:

    [US] (= Ubuntu "Server")    example IP = 10.0.0.1
    [WC] (= Windows "Client")

On [US], install a printer, ensuring that it is "Shared" via the GUI (e.g. the system-config-printer interface) or manipulation of /etc/cups/ files.
On [WC], use a web browser and point to CUPS on [US].

e.g. http://10.0.0.1:631/

This should show you the web interface provided by CUPS.  "CUPS is the standards-based, open source printing system ..."  This also serves as a test to make sure that the machines can even talk, and that you don't have a more basic problem (e.g. firewall) to solve.
The upper-right tab on this web page is a link to the Printers list.
Right-click-and-copy the URL to the printer in question, and you can paste that into the Windows "Add Printer Wizard" interface for a network printer.

As asked, this should solve the authentication issue by bypassing Samba (CIFS).  However, note that this method allows anyone on your local network to print to the shared printer, and it relies on a stable network IP address for [US].

It is also possible to restrict through authentication who can print, but that is for a different question.


Transfer browser tabs from Firefox to Google Chrome

Following the idea given in the comments (getting the links from the sessionrestore.js file in the FF profile dir), here is a Bash script with embedded Python to open the current tabs in Google Chrome:

google-chrome $(cat ~/.mozilla/firefox/*.default/sessionstore.js | python -c """
import sys, json
jsobj = json.loads(sys.stdin.read())
for tab in jsobj['windows'][0]['tabs']:
        print tab['entries'][0]['url'],
        """)

Please note that although the script works alright, it isn't verifying anything. But a more robust version of this would check the existence of file sessionrestore.js, verify the result of loading the JSON file and its contents, and so on.


How is my internet browser able to write files into my "Downloads" file if the default permissions do not allow to "write"?

Programs run with the privileges of the user who invoked them.
So when you launch your browser, the browser process has the rights you have to read, modify and execute files.

And as you are the owner of your Downloads folder, your user account has (usually by default) full read/write/execute rights. Therefore your browser has them too.

To clarify the stat output (d rwx r-x r-x):

The first letter (here: d) describes the type of the file system object you are examining. d means that you are showing the permissions of a directory. If you are examining a file, you will get a - instead. There are other possibilities too, like l for a link. Further there are (according to @Atsby's comment) b for block devices, c for character devices, p for pipes and probably even more...
See * for note about directory permissions!
The first three letters rwx stand for the owner's permissions. A letter means that the respective access type is granted, a "-" means denied. --> full access
The second three letters r-x represent the permissions users have who are members of the owner's group. It's the same "rwx"-format as above. --> only read and execute permissions, no writing
The last three letters r-x represent the permissions of any other users who is not the owner itself and is not a member of the owner group. Still same "rwx"-format. --> also only read and execute permissions, no writing

* Directory permissions:
Note that directory permissions have different meanings than file permissions. For directories...
read access (r) means listing the files (ls command),
write access (w) means changing the directory content (creating, deleting, renaming files) and
execute access (x) means entering the directory (cd command or opening with the file manager)

Advanced execute permissions:

Sometimes you find an S, s, T or t where you would expect an x.

There are SUID (Set User ID) and SGID (Set Group ID) permissions which replace the normal x if the file should always be executed with the permissions of its owner (SUID) or its owner group (SGID). For SUID, the x of the user permissions (first block) gets replaced, for SGID, the x of the group permissions (second block) gets replaced. A capital letter S stands for a - (permission denied) while a small s equals to x (permission granted).

If the x of the third block (others' permissions) gets replaced by a T/t, this means that the "Sticky Bit" is set. Nowadays, it is mostly used to prevent deletion of the file by non-owner users who have write permissions. Again, a capital letter T equals a - (no execute permission for others) without "Sticky Bit", while a small t stands for granted execution access (x) for others.

Octal notation:

The permissions can also be represented by 3-4 digits (values 0-8), which is called octal notation.
Normally you have 3 digits or 4 digits with the first digit set to 0 (e.g. 755 or 0755).

The first digit (which can be omitted if it is 0) represents the advanced permission flags. Flag values: SUID=4, SGID=2, Sticky=1.
The second digit represents the state of the owner's permission flags (rwx; first permission block in string formatting). Flag values: r=4, w=2, x=1.
The third digit represents the state of the owner group's permission flags (rwx; second permission block in string formatting). Flag values: r=4, w=2, x=1.
The fourth digit represents the state of all other's permission flags (rwx; third permission block in string formatting). Flag values: r=4, w=2, x=1.

To calculate the digit value, just sum up the flag values of all set flags. Examples: rwx=4+2+1=7, r-x=4+0+1=5

 Source and additional references:
http://www.zzee.com/solutions/linux-permissions.shtml
http://www.informit.com/articles/article.aspx?p=1822622&seqNum=6
Please visit those links for more detail, especially about advanced permissions.


How to delete any file with Terminal Ubuntu LTS 18.4.4

To remove all files you could use:

rm -r /somefolderpath/htdocs/*

Read about rm usage in its man page:

$ man rm
[...]
   -r, -R, --recursive
          remove directories and their contents recursively
[...]

If you've got Permission denied and you really know what you do, then use sudo to remove files and directories belonging to other user. This command will be executed with super user (root) permissions:

sudo rm -r /somefolder/htdocs/*


Unable to change file attributes (e.g. immutable) on /etc/resolv.conf

/run is a tmpfs (ramdisk) filesystem, and doesn't support extended attributes:

% df -T /run
Filesystem     Type  1K-blocks  Used Available Use% Mounted on
tmpfs          tmpfs    393016  6416    386600   2% /run

On how to avoid /etc/resolv.conf being changed by NetworkManager, I found a possible solution at the Arch Linux forums.

Create a resolv.conf file containing the settings you wish to keep somewhere in your system (say in /etc/resolv.conf.DNSoverride) and put this script in /etc/NetworkManager/dispatcher.d:

#! /bin/sh
cp -f /etc/resolv.conf.DNSoverride /etc/resolv.conf

The script, quoting man networkmanager:

  [...] should be a regular executable file owned by root. Furthermore, it must not be writable by group or other, and not setuid. [...]

Quoting man networkmanager:

  [...] NetworkManager will execute scripts in the /etc/NetworkManager/dispatcher.d directory or subdirectories in alphabetical order in response to network events. [...]

This means that the script will copy /etc/resolv.conf.DNSoverride overwriting /etc/resolv.conf each time a network event takes place, overriding possible changes made to /etc/resolv.conf.


Ubuntu froze then when restarting failed to load

Lets first check your file system for errors.
For 17.10 or older...

boot to the GRUB menu
choose Advanced Options
choose Recovery mode
choose Root access
at the # prompt, type sudo fsck -f /dev/sda5
repeat the fsck command if there were errors
type reboot

For 18.04 or newer... (or if the above steps don't work for you)...

boot to a Ubuntu Live DVD/USB
open a terminal window by pressing Ctrl+Alt+T
type sudo fdisk -l
identify the /dev/sdXX device name for your "Linux Filesystem"
type sudo fsck -f /dev/sda5, replacing sdXX with the number you found earlier
repeat the fsck command if there were errors
type reboot

Then backup your important data!


Which video player ?
VLC can have trouble with pulseaudio : setup vlc preferences to make him using alsa


artful release does not have a release file

There aren't any packages for Ubuntu 17.10 in ppa:ehoover/compholio, so remove this ppa from your software sources:

sudo add-apt-repository --remove ppa:ehoover/compholio
sudo apt update

Download the latest VMware Workstation Player for Linux version from the official VMware website.
Change directories using cd to the directory that the VMware .bundle file that you download is in:

cd /path/to/directory/that/contains/VMware-bundle

Make the VMware Player bundle file executable.

chmod +x VMware-Player-14.1.1-7528167.x86_64.bundle

Install VMware Player.

sudo sh ./VMware-Player-14.1.1-7528167.x86_64.bundle

Install Open VMware Tools for virtual machines hosted on VMware. It is a suite of virtualization utilities and drivers to improve the functionality, user experience and administration of VMware virtual machines.

sudo apt install open-vm-tools-desktop


Rename great number of files in ubuntu terminal

Use the rename function. It's basic(prototype form) is $ rename s/"SEARCH"/"REPLACE"/g  *. This replaces the file "SEARCH" with "REPLACE". The /g means global, so if you had a "SEARCH SEARCH.jpg", it would be renamed "REPLACE REPLACE.jpg". The * is the extension type like .mp3 or .pdf. So, your example would be:

$ rename s/'test_026542_time0663550.5.jpeg'/'test_0663550_.jpeg'/g *

This should help.


Is it safe to update ubuntu over public Wifi?

Should be safe yes. As all packages are signed by the maintainers of the repository you are downloading from, which should prevent the files being tampered with.

If you want to be extra safe you can use HTTPS for downloading packages, with apt-transport-https.


Create multiple directory and subdirectory from multiple txt files

Here is a script that would do the same

#! /bin/bash

cat years.txt | \
        # Read years.txt line by line. Each line is stored in $folder1.
        while read folder1; do

                cat type.txt | \
                        # Read type.txt line by line. Each line is stored in $folder2.
                        while read folder2; do

                                cat month.txt | \
                                        # Read month.txt line by line. Each line is stored in $folder3.
                                        while read folder3; do
                                                # Create/modify $path variable.
                                                path="$folder1/$folder2/$folder3"

                                                # Create the directory.
                                                mkdir -p "$path"
                                        done
                        done
        done

Some help taken from: https://stackoverflow.com/questions/4642191/read-line-by-line-in-bash-script


JAGS (Just Another Gibbs Sampler) installation from Terminal

Ubuntu uses apt as a package manager.  A package manager is software that helps you to manage other software installed on the system.  Instead of downloading binaries from a website, you typically use the package manager to install software from repositories. This is the safest and easiest way to install software on Ubuntu, so since JAGS is available in the Ubuntu repositories, you should install it with APT.

Update Available Software

In order for apt to work, it needs to know which versions, and what software is available.  apt only knows which packages are available by creating a database local to your machine.  You need to update this periodically, and typically before installing new software.

sudo apt-get update

Install a package

sudo apt-get install jags

Remove a Package

sudo apt-get remove jags

Search for Packages

sudo apt-cache search jags

Update (Upgrade) Installed Software

Once you have updated your list of software available on the repositories using apt-get update, you can tell apt to upgrade your packages.  This means that you want apt to install the latest available versions of software installed on your system

sudo apt-get upgrade

So, typically in order to install something, one may do something such as:

sudo apt-get update && sudo apt-get install jags

To update your system and installed software:

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

See Ubuntu Community Documentation as well as apt man pages.


Not listing .gitkeep file in tree listing command and also unrecognized charset

This particular combination of options: -P --charset UTF8 does not make sense. -P is used for setting a pattern for directories that tree should print:

-P pattern
      List  only  those files that match the wild-card pattern.

You have set the pattern to --charset, which .gitkeep does not match, of course. That leaves UTF8 as a non-option argument, which tree interprets as a directory name, hence the error you get.


ubuntu 18.04 not mounting usb flashdrive without rebooting with flashdrive installed in USB port

I used the steps given in this article.

Open a terminal and connect the USB. Then type at the command line:

lsusb

Find that your USB is detected. Once it is known, then enter at the command line:

sudo fdisk -l

This will give the location of the mount for the USB. Now enter:

 sudo mount /dev/<location like sbd> /mnt/

This will mount all types of USBs. Files will be visible in the file manager under the name of the USB.

This will be alive till you switch of the computer. You can change USB.
Please remove them with eject button.

In the end enter at command prompt:

umount /mnt

This works for me.


How to ensure a Pharo VM is running with systemd

Take a look at systemd service, in particular Restart and its conditionals (to decide when an abort should be restarted or not).

Furthermore the doc you listed certain actions to be taken as prep/folow-up to a restart. For that ExecStartPre and co might help.

The workload as-is might not be suited for it (yet), but generally in addition you'd want to consider is to have the service to keep some keep-alive up and also check on that.


Lubuntu on Netbook Cannot Display Native Resolution

Had the same issue, solved by installing the correct video driver, so for my NC10 I did:

sudo apt-get update
sudo apt-get install xserver-xorg-video-intel


Unable to ping, nothing except askubuntu opening

Well, it seemed to have been a region-wide issue with the ISP. Everything is up and running now.


Booting from live Linux DVD on Dell Latitude D830

Reboot the machine and for a few seconds after it has started to reboot you should see on the screen "Press F1 or Press F2 or Press Delete to enter the BIOS." After you get into the BIOS set the DVD Drive to boot priority 1 then save and exit the BIOS. If the Startup Disk was made properly it should work. After installation remember to set the HDD to boot priority 1.


I don't think this has anything to do with C shell - and in fact, as noted in the comments, what you have is a sed script (a simple text file of sed commands) rather than a shell script, and the #!/bin/csh -f shebang is superfluous and will be treated (by sed) as a simple comment.

What you seem to be observing is that sed appears to not re-evaluate the $ (last line) address, so that if one of your previous commands happens to delete the last line of the file, then a subsequent attempt to append1 after that address fails. We can see that with a simple test (using the bash shell, for what it's worth) as follows:

# delete line 3 then append after $
$ printf 'line %d\n' {1..3} | sed -e '/3/d' -e '$a\new line'
line 1
line 2

whereas

# append after $ then delete line 3
$ printf 'line %d\n' {1..3} | sed -e '$a\new line' -e '/3/d'
line 1
line 2
new line

I find this somewhat surprising but don't know if it's the desired behavior or should be considered a bug.

Note:

[1] Techically, the a command doesn't append, but rather

  Queue[s] the lines of text which follow [ ... ] to be output at the end of the current cycle, or when the next input line is read.


Is a window created with other console downloaders? (wget, aria2).

start any long download and run in terminal ps -C xterm,axel ww.Also you can try to run xterm from terminal xterm.
Try the following variants:

'Alt+Tab' to take out the hidden window. Sometimes it helps. But I don't know if this combo works in lubuntu.
Write down a command line for axel manually in the flashgot options.
Reinstall flashgot.


Newbie: How to use QMAKE to compile and install FaustLive on Ubuntu Studio 20.04? Can't create Makefile with qmake w/ linux-g++

Using PKGBUILD from ArchLinux we can get the following method for Ubuntu:
sudo apt-add-repository universe
sudo apt-get install build-essential qt5-default faust qrencode libjack-jackd2-dev \
libmicrohttpd-dev liblo-dev libsndfile1-dev libasound2-dev libcurl4-openssl-dev

cd ~/Downloads
git clone https://github.com/grame-cncm/faustlive.git
cd faustlive
git submodule update --init
cd Build

make

sudo cp FaustLive/FaustLive /usr/local/bin
sudo mkdir -p /usr/local/share/applications/
sed "s|Icon=Faustlive|Icon=/usr/local/share/icons/hicolor/256x256/apps/FaustLive.png|" -i rsrc/FaustLive.desktop
sudo cp rsrc/FaustLive.desktop /usr/local/share/applications/
sudo mkdir -p /usr/local/share/icons/hicolor/256x256/apps
sudo cp ../Resources/FaustLive.png /usr/local/share/icons/hicolor/256x256/apps

As the result you will be able to run FaustLive using its shortcut.


are you Confidence your cd is bootable iso ? you can download ubuntu iso from http://www.ubuntu.com/download/ and then (in windows ) right click on iso file and choose burn disk image waiting for burn complete and verify disk
for verify :
insert disk and wait for run autoplay if you see a window like show install ubuntu this mean your disk is bootable the you can install ubuntu after restart and boot from disk


I bought an album yesterday with 22 tracks on it, but only 10 show up for download

I had the same issues with Rythmbox, It has to do something with the "tags" of the tracks. To make my mp3's shown under the corresponding Album and not scattered around, I had to fix those files with a program called EasyTags.
Ultimately, I had to switch to Banshee Media Player...


You can use my PPA with PHP 5.5: https://launchpad.net/~ondrej/+archive/php5


Get information from virtual machine manager using php

From http://php.net/manual/en/function.exec.php:

You'll need to use an array to get output.

So, use the following code:

$result=[]; // Create an array
exec('your command line', &$result);  // Remember the & before the result as it ***IS A REFERENCE***
//DO whatever with your result

The problem is that you didn't pass your result array as a reference.

Or, use shell_exec, where your return value is everything returned:

$return=shell_exec($command_line);

You can also use backticks:

$result=`cmdline`

Or, use popen(:

Create a new pointer with:

$handle = popen("/bin/ls", "r");

and then read it:

$read = fread($handle);

and close with:

pclose($handle);

It will block execution until the output stops.


If you want to divert files associated with packages that are installed (or that you intend to install), so that you can replace them with your own files but restore them later, you should use the dpkg-divert command.

Since I don't have all the details of your situation, it would be hard for me to recommend specific syntax, beyond the information provided in that manual page.

Other than the package manager and the tools that are part of it (including dpkg-divert), there is no part of Ubuntu that modifies the files in /usr, though if you download and run installer executables, or you build software from source and specify an installation prefix of /usr, then files will be added or overwritten. Most software you build from source and install with sudo make install will, by default, have PREFIX=/usr/local, but some software defaults to PREFIX=/usr so it's worth checking by running ./configure --help or reading the Makefile, before you build and install the software.

The other exception is parts of /usr like /usr/local that are intended to be changed by facilities other than the package manager. But you don't seem to be asking about that. The contents of directories like /usr/bin and /usr/lib should only be modified by the package manager, unless you modify them manually or tell a third-party installer or build process to put files there.


Permission denied error when I back up to an external drive using grsync

That directory is owned by root on my machine, hence the "Permission denied" error. But regardless of what's causing the issue, the whole ~/.cache directory doesn't have any data that would require backing up, so could/should be excluded from the backup. For details, see What files and directories can be excluded from a backup of the home directory?


How do I make GVim use the icon in my icon theme?

It is a known issue.
The workaround is mentioned in the gnome-look.org Faenza page:

  Some applications are configured to always use the same icon regardless of the selected theme: e.g. vim,  emacs23, gcolor2, bluefish, hardinfo, defcon, gufw, pithos, goldendict, rssowl, picasa, netbeans, gazpacho.
  To display the Faenza icon, edit as root the /usr/share/applications/application_name.desktop file and locate the line beginning with 'Icon='. Replace the fullpath icon name by the one of the Faenza icon (usually, it's the name of the application itself) without the extension.
  Don't forget to make a backup before changing one of those files.
  In some cases, you need to reinitialize the item in Gnome menu editor to display the new icon.
  Vim desktop file is /usr/share/applications/gvim.desktop


Ubuntu 18 NetworkManager causing boot problem

From the comments...

The problem is not with NetworkManager.

It's a video driver problem.

Installed Nvidia 418.56 and the system seems to be working well. At this time, there may even be a newer Nvidia driver for your video card. Check at https://www.nvidia.com.


Why do I have new and strange networks (_not wifi_) in my network manager? 14.04

Answering the question

One of the people in the area around you is hosting a hotspot using their iPhone, and another person is broadcasting a hotspot using their Samsung Galaxy Note 3. You shouldn't be worried about the networks that you are unfamiliar with, because people make their own networks for different purposes.

Hacking

It is very unlikely that a mobile or tablet would be used for hacking, because the hardware on most portable devices is simply not powerful enough to make the hacker's time worthwhile.

About being not able to edit the networks

You won't be able to edit them because if you haven't connected to them with a password, the network details are not able to be given to your computer. However the names of those networks will still be there. This is so Network Manager has an idea of how to connect to the network next time the user requests to connect to the remembered network.


I couldn't get it to work myself.
From the article:
https://bugs.chromium.org/p/chromium/issues/detail?id=251288

we need to use --enable-speech-synthesis and the speech dispatcher
apt-get install speech-dispatcher

Since that did not work I tried also installing libspeechd & espeak
but still chromium(58.0.3029.110) seemed unable to pickup any speech engine.

Also just to cover my basis I have tried all of this with the flag mentioned above --enable-speech-dispatcher which gave me a "you are using an unsupported command-line flag" warning.

All of this on x64 and arm64 ubuntu 16.04.2.


How to change drain order of laptop batteries?

For a couple of years, I serviced the laptops of a larger German car manufacturer. I've seen all kinds of Toshibas, Compaqs, IBMs / Lenovos and HPs.

On some (I can't recall the brand though), you could see a read-only BIOS entry, listing the "battery order", but it was neither changeable through the BIOS nor the system.

On none of all these laptops it was possible to change the battery usage order.


5GHZ wifi is not showing on Ubuntu 18.04

The  Broadcom Limited BCM43142 802.11b/g/n wifi card is not a Dual-Band card.  That is, it only operates on the 2.4GHz band of wifi network technologies, even though the system says it can support 5Ghz frequencies.

If you have confirmed 5GHz networks are in your area, but still cant' see the networks, then the card is not able to support 5Ghz and the card is falsely reporting 5GHz support.

You would need a Dual Band wifi card in your computer to be able to use 5Ghz connections.  (The 'n' designation of wifi standard on the card doesn't indicate that you have 5GHz capabilities)


Display audio metadata while streaming music over A2DP?

Metadata is sent over AVRCP profile, not over A2DP. If your phone does AVRCP 1.0 then it will not send any metadata info. If it does AVRCP 1.3 or above then you should see metadata. Google play music player does not support sending track number and controlling repeat and random.


How to get launcher in this Ubuntu with xfce?

This dock is a big XFCE panel. You can manually create one, set its size, and add Launchers to it.
Instead, you can use a dedicated dock like docky.
Open a Terminal and enter the following command.
sudo apt install docky


Remove symbol from Desktop thing in KDE Plasma

With reference to the image below:

Click on the ☰ symbol in the top-right corner and select Unlock Widgets. (This step is not needed if you haven't locked widgets in the first place.)
Then click on the ☰ symbol in the bottom-right corner. Hover your mouse pointer over the widget you wish to remove and click on the red "Close" button.


ssh-keygen .ssh/id_rsa: No such file or directory

From man ssh-keygen:

-y      This option will read a private OpenSSH format file and print an
        OpenSSH public key to stdout.

so it fails because there is no existing id_rsa file.

If you want to create a new RSA key pair, run the command without the -y option, i.e.

ssh-keygen -t rsa


Can I replace the Android OS with Ubuntu on the Zeki 7.0" Android Tablet?

I think you can download an ARM image at cdimage.ubuntu.com. See http://www.ubuntu.com/download/arm

Download the images at http://cdimage.ubuntu.com/releases/12.04.1
Place the SD card at your host computer.
Make sure the SD card is not mounted (just umount it if needed)
Identify the correct raw device name (like /dev/sde - not /dev/sde1)
Run the following command to write it:
(replacing omap4 and sde with the right values i.e. just omap for a beagle image.)

zcat ./ubuntu-12.04-preinstalled-desktop-armhf+omap4.img.gz |sudo dd bs=4M of=/dev/sde ; sudo sync

Warning /!\ Some people have reported issues with this method. If this doesn't work, try the following commands:
2. gunzip ubuntu-12.04-preinstalled-desktop-armhf+omap4.img.gz
3. sudo dd bs=4M if=ubuntu-12.04-preinstalled-desktop-armhf+omap4.img of=/dev/sde
4. sudo sync


I have found the issue and resolved it.

I had followed the guide linked above which suggested this file needed to be edited:

/etc/apache2/sites-enabled/default-ssl.conf,

Actually it didn't exist - I though I had deleted it so I recreated it.

What I should have done was edited this file

/etc/apache2/sites-available/default-ssl.conf

Thats sorted it out


Fonts DPI problem in Firefox and Open Office

I just had to log out. Now everything look fine.


A simple google search ----

Disable overscan

Edit the boot/config.txt file to make the change:

   sudo nano /boot/config.txt
      Change this line:
          #disable_overscan=1
                  to:
          disable_overscan=1

Then, save the file and exit.

Reboot your Pi


Ubuntu 20.04 - apache does not start at boot

I had the same problem
Ubuntu 20.04 work with libphp7.4.so and apache2 work with libphp7.2.so
so to fixe it you need to change the configuration of apache2 and this is how i did it :
1- you can check this problem by testing the apache and writing : apache2ctl configtest
The output message :
apache2: Syntax error on line 146 of /etc/apache2/apache2.conf: Syntax error on line 3 of /etc/apache2/mods-enabled/php7.2.load: Cannot load /usr/lib/apache2/modules/libphp7.2.so into server: /usr/lib/apache2/modules/libphp7.2.so: cannot open shared object file: No such file or directory
Action 'configtest' failed.
The Apache error log may have more information.
2- open the file php7.2.load by gedit /etc/apache2/mods-enabled/php7.2.load
you can see
LoadModule php7_module /usr/lib/apache2/modules/libphp7.2.so
3- go to /usr/lib/apache2/modules/ and check the version of libphp by ls
, it will be libphp7.4.so
4- back to the file and change the version :
LoadModule php7_module /usr/lib/apache2/modules/libphp7.4.so
save it and restart apache2
systemctl start apache2.service

check the status :
systemctl status apache2.service

That's all :)


In my case, pulseaudio only showed dummy devices, it stop showing my Intel audio devices after installing some packages.

So I followed these steps:
The only device shown is "dummy output" or newly connected cards are not detected

To see which application is responsible for direct access to the sound card through alsa, run the following command:

sudo fuser -v /dev/snd/*

In my case it was timidity-daemon:

                     USER        PID ACCESS COMMAND
/dev/snd/controlC0:  root        659 f.... alsactl
                     timidity    762 F.... timidity
/dev/snd/pcmC0D0p:   timidity    762 F...m timidity
/dev/snd/seq:        timidity    762 F.... timidity
/dev/snd/timer:      timidity    762 f.... timidity

So i just uninstall the conflicting package and thats it.


How to install Kubernetes Locally via Minikube

I finally found a working solution removing the snap package (sudo snap remove minikube) and then following one of the official guides keeping kubectl:

curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 \
&& sudo install minikube-linux-amd64 /usr/local/bin/minikube

Tested with kubectl version and

$ kubectl get nodes
NAME       STATUS   ROLES    AGE   VERSION
minikube   Ready    master   25m   v1.12.4

To run the dashboard just

minikube dashboard

I wonder what other people say about installing with LXD


dpkg: error processing package install-info

sudo mv /var/lib/dpkg/info/install-info.postinst /var/lib/dpkg/info/install-info.postinst.bad

Fixed the problem.


What does greater than shape mean in Unity Launcher?

It means the corresponding application is running, but its window is not on the current workspace :)

on the current workspace:

on another workspace:

If you click on the icon, the workspace usually switches to the one with the application's window on it.


Multimedia running very slow & weird ( In Virtualbox )

Appears to be a common problem for many Linux guests, regardless of host operating system.

A workaround/fix was identified by someone using Ubuntu 9.04 was to stick the following into /etc/modprobe.d/sound.conf (might need a .conf extension, or might not):

options snd-intel8x0 ac97_clock=48000
options snd slots=snd-intel8x0
# CvwD.FAMlirE10w6:82801AA AC'97 Audio Controller
alias snd-card-0 snd-intel8x0

The above worked like a charm (ie: I didn't analyze it very deeply, just "had faith, copy/paste") for me in Ubuntu 13.10.

The key must be setting the clock to 48000, IMHO. I'm not sure about the rest of the stuff having to do with "intel" things. That #-commented line is probably doing nothing, but who am I to question it? Maybe someone else will come along and help clarify these minor concerns.

For reference:

VirtualBox Forums #20254
VirtualBox Forums #4605
Ubuntu Forums #1341984


I've found by trial and error after 20 minutes. Right-click the .desktop file, click on "Properties", go to tab "Open With" and select "Run Software". Click the button "Set as Default" and close the window. Right-click again the .desktop file and click on "Allow Lauching". Jesus, I feel so dumb now; of course it's Run Software!
Thanks for the answer, it may help MATE desktop users who have the same problem.
Edit: the answer (that someone posted) related to MATE desktop was deleted.


In Pycharm 2016
Tools => Create Desktop Entry


How to type half Hindi character with Hindi (Bolnagri) layout?

To get half स you have to type स and then virama (hasnt) ् so that it looks like स् then type व. In Bolnagri the ् is typed by X.

To get और type Shift+Alt Gr+O and then R. Where Alt Gr is the Alt key on the right of Space Bar.

In general, where the picture below shows two columns of characters on the same key, the bottom row of the left column is entered by THAT KEY itself. The bottom row of the right column is typed by Alt Gr+THAT KEY. While Shift types the upper row characters.

Thus, Alt Gr+O results in ओ and Shift+Alt Gr+O results in औ.

To get र्श type R and then X and then Z.

Another example: आदर्श :  Shift+Alt Gr+Aand then D and then R and then X and then Z.

The full Bolnagri kekboard layout is:

Also see Sanskrit fonts and half letters

For Ubuntu 16.04 and 17.04 you must install the right language support

Go to System Settings...> Language Support > Install Languages and  install Hindi (or any other Indian language).

For older and newer versions of Ubuntu you can skip the above

Hope this helps.


TestDisk / PhotoRec

Yes, use the tool photorec; you'll be able to recover pretty much any file.

You should make sure that the SD card is read only as writing to it can corrupt any possibility of recovering data.

In Ubuntu, open a terminal and run:

$ sudo apt install testdisk
$ sudo photorec


acpi_listen is not working the way it should

According to Linux man page, acpid is the system-wide ACPI event catcher. acpi_listen is a simple shell-friendly tool which connects to acpid and listens for events. When an event occurs, acpi_listen will print it on stdout.

As far as i understand, the keys ctrl, shift are not event creating keys. fn keys coupled with up or down (for toggling brightness/volume for example) might give desired outputs.


Inconsistent copy and paste behaviour. Is there a fix?

That is a known limitation of X, please refer to this article of the official wiki:

https://wiki.ubuntu.com/ClipboardPersistence

The main issue remains the inconsistency between applications that may use different approach to clipboard handling.

In the wiki article there are listed working and not working application ( also the only workaround proposed is to install parcelite as clipboard manager )


How to choose custom programs to open specific file types?

What happens when you click "Show other applications"? That should show all installed apps and you should be able to select gpicview from there.


Jmeter not starting up while excuting command as non-root user

Note that this is not the result of testing, just research. Constructive criticism to this answer is welcome as are tested solutions.

Generally Speaking:

This error appears to occur due to a mismatch between the version of Java (JDK) used a compile time and the version of Java available at runtime or when several versions are installed simultaneously (as appears to be the case here).

You can check and compare the versions with for the compiler

javac -version

and the runtime with

java -version

To fix the actual problem you should try to either run the Java code with a newer version of Java JRE or specify the target parameter to the Java compiler to instruct the compiler to create code compatible with earlier Java versions.

There are several ways to resolve this it seems to boil down to whether you want to approach it by insuring that code will be run by the right JRE or insuring that the code is compatible with currently used JRE.

For the former, one example solution is to change the symbolic link (/etc/alternatives/java -> /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java) to the version used for compilation.

For the latter, a solution is to generate new class files compatible with an earlier runtime version of Java you are attempting to use by Utilizing Cross-compilation options. For example to generate class files compatible with  Java 1.4, use the following command line:

javac -target 1.4 HelloWorld.java

Specifically speaking:

Whether you are rolling your own or using a pre-built binary of Jmeter downloaded from here it's important to verify the integrity.]

Note that Jmeter 3.1 Requires Java 7 or later so it should be working with your Java 8 but since you aren't running MAC OSX there's no reason not to try it with Java 7

Another possible solution is to correct the JAVA_HOME environment variable.

With

export JAVA_HOME=jdk-install-dir

export PATH=$JAVA_HOME/bin:$PATH

Sources:

https://stackoverflow.com/questions/10382929/how-to-fix-java-lang-unsupportedclassversionerror-unsupported-major-minor-versi

http://docs.oracle.com/javase/7/docs/technotes/tools/windows/javac.html

http://www.manpagez.com/man/1/javac/

http://jmeter.apache.org/usermanual/get-started.html#classpath

https://jmeter.apache.org/download_jmeter.cgi

https://jmeter.apache.org/changes.html

https://docs.oracle.com/cd/E19182-01/820-7851/inst_cli_jdk_javahome_t/


How to change path of syslog file from /var/log to /opt/log?

Thanks for your help.

I found the solution for this question.
It is as follows :

In 50-default.conf file. I added following lines at the end so that most of the messages get logged in the mylog.log file.

daemon.*;mail.*;\
    news.err;\
    *.=debug;*.=info;\
    *.=notice;*.=warn   -/opt/log/mylog.log

After this in opt folder I created a log folder and changed the permission as  below:

sudo mkdir /opt/log

sudo chmod -c 777 /opt/log

Then in /opt/log folder I created a mylog.log file and here also I changed the permission as below:

sudo touch mylog.log

sudo chmod -c 777 mylog.log

And then I restarted the rsyslog service as follows :

sudo service rsyslog restart

Hope this will be helpful for some people.

Thank You.


Broadcom Wireless Issues in Lubuntu 14.04

Your 4306 hardware, according to http://wireless.kernel.org/en/users/Drivers/b43 takes the b43legacy driver, NOT the b43 driver.  Try the firmware-b43legacy-installer package to see if that gets you the correct firmware (ucode4.fw) and puts it into /lib/firmware/b43legacy.  It looks like you are pulling in the correct driver, it just doesn't have the correct firmware.


How do I select Wireless radio portions in Ubuntu?

All N-radios also support G. The difference is that N is faster; you may be having problems staying connected because your wireless card radio keeps trying to use a weaker N-signal instead of the stronger G-signal in some places.

Let's make this an answer in progress. Please pastebin the commands dmesg, lshw -c network and lsmod, and edit your question with the links. We'll go from there.


I was able to fix the problem by reinstalling binutils.


How do I enable silent updates for my system?

The package unattended-upgrades is used by Ubuntu to silently install important security updates to your system. It is enabled by default and runs on every current Ubuntu release.

You can use the same utility to upgrade your system by enabling unattended-upgrades to upgrade non security related updates. For that use your favourite text editor to edit the necessary config file located on /etc/apt/apt.conf.d/50unattended-upgrades, ie:

sudo nano /etc/apt/apt.conf.d/50unattended-upgrades

and remove the // marks on the start of the line "${distro_id}:${distro_codename}-updates"; so it looks like this

Dont forget to save the file.

You can change the configuration of the unattended updates by editing the file /etc/apt/apt.conf.d/10periodic, options for the configuration are in the /etc/cron.daily/apt script header. Read them to configure the frequency of the unattended updates.

That is it! Your system will be updating itself, user independent and without interaction needed.


Lock screen does not unlock with correct password Gnome and Ubuntu 14.04

Neither of the other two answers solved the problem for me, but some additional searching led to this bug report:

sudo chown root:shadow /sbin/unix_chkpwd
sudo chmod 2755 /sbin/unix_chkpwd

which solved the issue for me.


Run Cronjob every night between 3-6 o clock but only once

You can place you cronjob in /etc/cron.daily/ and it will automatically run in that timeframe.

Edit:
Sorry, I was referencing an old Debian installation where anacron wasn't installed by default. In that case /etc/cron.daily/ was executed by /etc/crontab on 6:25. But newer Debian installations (and so does Ubuntu) install anacron by default and so /etc/cron.daily/ will be executed by /etc/anacrontab five minutes after anacron was started or every new day.

To achieve your schedule (from the comments) you can set up a cronjob that will e.g. every 10 min between 3-6 start either anacron that will take care that the backup job only run once or you can write a custom controll script.
1. Alternative: anacron
mkdir ~/.local/share/anacron_spool
echo "1 0 backup.daily /path/to/backup.sh" > ~/.config/anacrontab
(crontab -l; echo "*/10 3-6 * * * /usr/sbin/anacron -s -t $HOME/.config/anacrontab -S $HOME/.local/share/anacron_spool") | crontab -

This will make anacron to serialize (-s) run all jobs defined in ~/.config/anacrontab. Because by default only root has write permission to write to /var/spool/anacron/ where the timestamps are stored we use a custom spool-dir (-S). If all jobs are done for today anacron will exit.
2. Alternative: custom controll script
Open an editor (e.g. sudo nano /usr/local/bin/run_once_a_day.sh) and paste this:
#!/bin/bash
SPOOL="$HOME/.local/share/run_once_spool/"
if [ $# != 2 ]; then
    echo "Usage: $(basename $0) <job-identifier> <command>"
    exit 1
fi

if [ ! -d $SPOOL ]; then
    mkdir $SPOOL
fi

if [ -e ${SPOOL}${1} ]; then
    last_run=$(cat ${SPOOL}${1})
else
    last_run=0
fi

today=$(date +%Y%m%d)
if [ $last_run != $today ]; then
    $2
    echo $today > ${SPOOL}${1}
fi

Press CTRL+O to save and CTRL+X to exit. Make it executeable and add a cronjob that will start it periodicaly with:
sudo chmod 755 !$
(crontab -l; echo "*/10 3-6 * * * /usr/local/bin/run_once_a_day.sh backup.daily /path/to/backup.sh") | crontab -


Ubuntu Phone - detect system type Desktop or Mobile

I know about detecting the system using simple ping command:

TTL
64   Linux/BSD
128  Windows
255  UNIX

You can change the default TTL, but it is usually the default one.
Or try the nmap:

nmap -O

But you have to study these command (sources) to find the answer you need.


Glitches after closing/opening laptop lid. T410p, NVIDIA

I have the same problem with NVIDIA 740M, from what I have read so far its seems to be related to the NVIDIA prime tecnology that allows to switch between the INTEL and NVIDA GPUs on the fly. The only work around for the hard power off is Ctrl + ALt + f1 follow by a Ctrl + Alt + F7 that will show you the login dialog box. Some of the apps like browser it will show like crap so you will need to restart.

Please let me know if you find a solution. I think I have read about someone that made it to fully disable the Prime feature.

Julian


Booting Ubuntu from a bootable USB-Stick

When you boot to the Live media, any changes you do will only be on the live media.  Writing would only go to any drive outside the live media if you specify by actually mounting it and specifically choosing that mount for output.

When you say you won't be installing on, I'm assuming you mean you won't be installing Ubuntu on the Windows machine's hard drive.  You might consider installing Ubuntu on a stick and booting to a fuller environment for programming.


How to know what program needs which group to be executed without sudo

First run the command (I wish you'd told us which) without sudo. Take note of the device(s) mentioned in the error message.

Use ls -l, followed by the device(s), e.g.

walt@bat:~(0)$ ls -l /dev/ttyS1
crw-rw---- 1 root dialout 4, 65 Dec 13 08:34 /dev/ttyS1

This device allows rw access for the owner (root) and members of the dialout group.

To add yourself to the dialout group,

sudo adduser $USER dialout

To make use of your new dialout group membership, either log out and log in, or newgrp dialout to start a shell with that group membership.


In LXQt

Edit the file /etc/sddm.conf

sudo nano /etc/sddm.conf

Look for a section marked [Autologin]

It should appear as

[Autologin]
User=<Some username>
Session=<usually blank>
Relogin=False

Remove the username from the User key, and any session name from the Session key

Save the changes to the file, and reboot!

Source of information: man sddm.conf

In Ubuntu using GDM

Using a GUI, Click the settings icon -> Details -> Users -> User in question

Then uncheck the 'autologin' box


New install of Ubuntu 20.04, Mouse through KM switch not fully working

I see you found the solution here: https://answers.launchpad.net/ubuntu/+question/686826

The Rosewill USB-3 KM switch must, on certain hardware configurations,
be hooked up to a USB-2 port in order to make full functionality!

And there was an issue with the USB Hub and USB port combination you were using.
Apparently according to your messages there, it seems the mouse works, with macros included, while plugged directly without a hub:

In the instance where everything is connected without the switch,
everything works fine. The mouse runs as a mouse and the extra macro
keys work, too.

ps. I'm posting this answer for future reference in case someone else gets to this post looking for information on the Viper V570 compatibility with Linux.


How to use dpkg to finish configuring extracted packages

You can use dpkg-source in order to pack and unpack the source files of a Debian package.

More info:

Wikipedia dpkg
dpkg-dev contains a series of development tools required to unpack, build and upload Debian source packages.[10] These include:

dpkg-source packs and unpacks the source files of a Debian package.

As written in Wikipedia Deb File Format

Since Debian 0.93, a deb package is implemented as an ar archive.[7] This archive contains three files in a specific order:

debian-binary - Contains a single line giving the package format version number. (2.0 for current versions of Debian).
control archive - A tar archive named control.tar contains the maintainer scripts and the package meta-information (package name, version, dependencies and maintainer). Compressing the archive with gzip or xz is supported. The file extension changes to indicate the compression method.
data archive - A tar archive named data.tar contains the actual installable files. Compressing the archive with gzip, bzip2, lzma or xz is supported. The file extension changes to indicate the compression method.


Windows 7 user can't successfully download or install ubuntu

Use UnetBootin (http://unetbootin.sourceforge.net/)

choose ubuntu on the list , the usb drive at the bottom and click ok , he will do everything for you (downloading and copying on usb)


On my PC ls mnt/test\ and ls mnt/test\ / (no quotes) work well.

:~$ mkdir -p "mnt/test "
:~$ cd mnt/test\ /
:~/mnt/test $ touch 1 2 3 4 5
:~/mnt/test $ cd
:~$ ls mnt/test\
1  2  3  4  5
:~$ ls mnt/test\ /
1  2  3  4  5


Why am getting this error when I try to install Emma?

Finally i got it working now, all i did was to enable enable the following Ticked the first and fourth box


When you encounter the above error, simply hit tab, then you will be shown certain options like live, install etc.

Type live and press Enter.Hopefully this should solve your problem.

Let me know if it worked !!  :)


How to create a user who can only access one directory?

sudo adduser brad
sudo chown brad:brad /var/www/brad

man adduser and man chown for more information and advanced options. Notice the chown above will only give ownership of the directory, use -R flag to do it recursively. Also notice no other user except brad will have ownership of said directory. You might need to change permissions for other users with chmod. Read about file permissions here.

You can also do:

sudo chown me:brad /var/www/brad

So you are the owner and brad is the group which has access to it (brad is the only member of said group). Or the other way around:

sudo chown brad:my_group /var/www/brad

Notice www-data might need access to said folder (and sub-directories and files) for the webserver to function properly.

  Also how could I give him access to phpmyadmin to create db's?

You should configure that in your webserver / through phpmyadmin. If permission is denied for some reason, just adjust it with chown or chmod.


How to show the menus for a window in the window's title bar in KDE Plasma 5

Here: https://launchpad.net/appmenu-qt5
Maybe you need this: "To enable the support, set QT_QPA_PLATFORMTHEME=appmenu-qt5 in your environment."

You can do this be editing the file ~/.profile and adding the line export QT_QPA_PLATFORMTHEME=qt5ct at the tail end of the file, as in the following example:

# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.

# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022

# if running bash
if [ -n "$BASH_VERSION" ]; then
    # include .bashrc if it exists
    if [ -f "$HOME/.bashrc" ]; then
    . "$HOME/.bashrc"
    fi
fi

# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
    PATH="$HOME/bin:$PATH"
fi

export QT_QPA_PLATFORMTHEME=qt5ct


How can I get a directory name by a window dialog called in shell script?

One fairly straightforward way would be to use zenity e.g.

# basic syntax
zenity --file-selection --directory --filename="$PWD/"

A simple code (source: gnome zenity help)

#!/bin/bash

DIR=`zenity --file-selection --directory --title="Select a File"`
case $? in
         0)
                echo "\"$DIR\" selected.";;
         1)
                echo "No file selected.";;
        -1)
                echo "An unexpected error has occurred.";;
esac

See zenity --help-file-selection for additional options.


How can I tell whether the bad sectors are physical or logical?

Bad sectors are not logical. It will always be physical and possibly symptoms of a slowly failing hard drive. There is no question of differentiating between physical or logical because it's always physical. Hope this answers your question and I'd soon get a new hard drive if I were you.


How do I install and manage GNOME Shell extensions?

In order to install an extension you are required to have the gnome-tweak-tool installed, this should be installed by default on most modern Ubuntu GNOME versions, however if it is not you can install it by running the following:

sudo apt-get install gnome-tweak-tool

With the gnome-tweak-tool come some pre-installed but not pre-enabled extensions, you can view these by opening the gnome-tweak-tool (you can either run this in Terminal (CTRL + ALT + T) or you can search for Tweak Tool in the Activities Overview) and going to the Extensions section.

Browser preparations (installing and updating)

Firefox

Version 52+

Since Firefox version 52 NPAPI plugin support has been removed so plugins like the GNOME Shell Integration plugin and Java etc won't work. So if you wish to install a new extension which isn't already installed then you will need a two-part solution:

Native host messaging application:

sudo apt-get install chrome-gnome-shell

The GNOME Shell Integration Firefox plugin.

After you have installed both of these you will need to restart your browser for the changes to take effect. Then you will be able to browse and install GNOME extensions from here.

Below version 52

If you wish to install a new extension which is not already pre-installed go here in Firefox and make sure that the GNOME Shell Integration plugin is enabled. So either go here about:addons (enter this into the URL bar and press ENTER), go to the Plugins section, and make sure that the GNOME Shell Integration plugin is set to Always Activate, or do the same but instead set it to Ask to Activate and then when you visit the GNOME extensions website make sure you either click Allow Now every time, or press Allow and Remember (you will need to click the little lego brick to get this dialog - the brick shown in the screenshot below):

Enabling this plugin allows the website to detect your GNOME version as well as to install and manage your extensions. The plugin should be installed by default in Firefox 52 and below on Ubuntu GNOME.

Chrome and Chromium

(and some other Chromium-based browsers including Vivaldi)

Since NPAPI plugin support is not available in these browsers either you will need a two-part solution:

Native host messaging application:

sudo apt-get install chrome-gnome-shell

The GNOME Shell Integration Chrome plugin.

After you have installed both of these you will need to restart your browser for the changes to take effect. Then you will be able to browse and install GNOME extensions from here.

Partial source: How To Install GNOME Extensions Using Google Chrome or Vivaldi

Epiphany (GNOME Web)

The native GNOME "Web" browser Epiphany still supports NPAPI plugins and has the necessary GNOME extensions plugin pre-installed and thus there is no need to do any setting up with it.

If it is not already installed then it can be installed with:

sudo apt-get install epiphany-browser

Installing a new extension

The most popular extensions will be displayed on the initial page you get to, you may however choose to sort page contents and search results using the Name, Recent, and Downloads filters. You can also choose to display results for All versions as opposed to just the Current version you are running (attempting to install extensions not compatible with your version of GNOME will result in a silent failure - the operation will not be successful but you will not be notified of this in any way - though extensions which are not compatible will be slightly greyed out in the results list so you will still be able to tell even with the All versions filter selected).
The different filters I mentioned above are accessibly through the relevant pull-down menus (I have put a red box around the settings in question):

You can also use the search box to find extensions, once you have found an extension you wish to install (if you are concerned about the safety of the extensions then you should read this information on the review process - go to the Are GNOME Shell extensions safe? section - extensions have to go through before they are accepted onto the website), click on its name in the search results, then once you are on its page click the ON/OFF slider next to its name (as done above in the gnome-tweak-tool), you will get a dialog prompting you if you wish to install the said extension, if you do, press Install, if you have changed your mind, press Cancel.

If you do not get such a dialog, you have just stumbled across one of your pre-installed extensions and activated it!

Once making changes to your installed/activated extensions from the website you will need to restart the gnome-tweak-tool in order for it to register the changes.

Managing extensions

In order to activate an extension click on the ON/OFF slider next to its name and description so that its status changes from OFF to ON, (and visa-versa to deactivate it).
You will see that the pre-installed extensions have a greyed out Remove button next to each of them, this is greyed out because they are pre-installed, if you install a new one however you will be able to use this button to permanently remove it.

You will also see that some of the extensions have a button next to their Remove button that looks like this:

Clicking this button will enable you to alter the configuration for the extension in question (it should launch a settings window).

The online view enables you to also do similar (though it also allows you to remove/uninstall pre-installed extensions, so tread carefully - though of course you will be able to re-install them again).

Updating extensions

The gnome-tweak-tool does not support the upgrading of extensions through its interface (though in future it is planned for the whole web interface to be scrapped and for it all to be done through gnome-software), if a new version of an extension comes out and you wish to upgrade to it you may do so by going here and clicking upgrade button next to the ON/OFF slider (if there is no upgrade button then the extension is already up-to-date):

You will then be prompted if you would like to Upgrade the said extension, pressing Upgrade will upgrade it, however pressing the Cancel button will disable or possibly even uninstall it so that you will need to reinstall or reactivate it again.

Tips and Tricks:

Right-clicking on the Activities Overview button (or Activities as it is normally called on the button) will bring up a window specifically dedicated to your GNOME Shell extensions:

This process should work for all those using GNOME 3.4+.


use mkfs to format partitions
use fdisk or parted to create partition table and partitions


wget downloads an html instead of my file

wget actually downloads your file...

The link you provided opened a webpage at picofile.com, mostly in arabic I presume, the direct download link to the "mmm" file was http://s8.picofile.com/d/8293527218/b9e0df57-217a-43bb-9e09-43ac5092b85a/mmm. Passing this URL to wget actually downloaded the file. That's common situation with most of these file hosting sites - the "sharing" url points to their website and the actual download link is hidden behind some javascript there. Often, the only way how to extract this link is starting a download via a browser and copying the download link from its download manager.


What all do I need with my Apache Server

Yes. Apache can serve files, and that is all that is necessary for javascript, css and jquery. All that technology works on the client side, i.e. in the browser. Cgi-bin is server-side technology, but that will work out-of-the-box as well.


Making an app for Ubuntu Software Centre

The Ubuntu SDK is called Quickly.  It does run on the command line, but it's still easy to use.  Here is a good video tutorial to get started.


Can the cat command edit a text file as well as read it?

If you want to edit interactively, use for example nano, otherwise you can use the stream editor sed.

You can find several good tutorials via the internet (with examples how to use them). When you have more experience you will find the man pages useful:

man nano

and

man sed

but in the beginning the tutorials are better.

I find several good tutorials with the following search strings

nano tutorial
sed tutorial

I suggest that you start working with a tutorial that fits what you need.


Ubuntu Heating Up, Continuos Fan, Hadoop Installation Worries on AMD 64

Power management in general is not as good as Linux as it is on Windows in my experience. However, here are some things you can try:

Install TLP: http://www.webupd8.org/2013/04/improve-power-usage-battery-life-in.html
Incorporate appropriate changes from vodik powersave: https://github.com/vodik/powersave
Use sudo powertop and make sure all the tunables are "Good"
Try searching on net for power optimisations for your specific laptop model
If you have hybrid graphics, enable power saving by disabling the discrete card when not required: https://wiki.archlinux.org/index.php/hybrid_graphics#ATI_Dynamic_Switchable_Graphics

Even after all this, my laptop runs slightly warmer than on Windows, and battery life is not as good. However, it's not that bad, certainly usable. Your mileage may vary.


How do I configure this interface for a static address?

Please adjust your file to:

auto lo
iface lo inet loopback

auto enp2s0
iface enp2s0 inet static
address 192.168.1.10
netmask 255.255.255.0
gateway 192.168.1.1
dns-nameservers 192.168.1.1 8.8.8.8

Restart the interface:

sudo ifdown enp2s0 && sudo ifup -v enp2s0

Did you connect?

ifconfig
ping -c3 www.ubuntu.com


Problem with panel of configuration can't see more icons for settings dialogs?

It turned out that running this command was necessary for making the icons appear in System Settings:

sudo apt-get install ubuntu-desktop


Your package list is obsolete and the old package is removed from the repositories. Refreshyour packages list and try it again.

The command for refreshig the packages list is:

sudo apt-get update


How to get rid of right-click menu scrolling in Firefox under XUbuntu?

Solved: I got rid of the arrow boxes by downloading the firefox add-on menu editor 1.2.7
this link is for a mac machine but for ubuntu it works the same way: http://www.simplehelp.net/2007/07/29/how-to-edit-the-right-click-context-menus-in-firefox/


Cannot change width of "Dash to Panel" vertical view

You choose to use traditional taskbar buttons with text. Why, then, you would you want a vertical layout to be smaller? That would prevent the text to be displayed.

To use the panel in a vertical layout, revert to the default icon-only buttons. Then you will have more flexibility in changing the width.
You could consider autohiding the taskbar, so that it pops over the existing window with legible labels each time you need to access it.
Else, you may need to file an issue to the developer of the Gnome Extension as to support a smaller display when using taskbar buttons with text.


Is the .iso file the one I need to download?

Yes, use the .iso file.

I'll assume you've installed Oracle VM VirtualBox. You then need to create a new VirtualBox - follow the wizard checking each step carefully. Give it at least 10GB of HDD space.

When it's created, click Settings and then Storage, click the "Empty" with the CD icon and click the CD with a down arrow next to it. Browse to your ISO file.

Then start the VM and follow the install process.


Amadeusz Sławiński, GNU Screen’s new primary upstream maintainer uploaded 2 versions this year:

the status quo of Screen development as version 4.2.0
the 4.2.1 that you can find in the Ubuntu repositories

From the 4.2.0 announcement:

  With this I also plan to put v.4 into maintenance mode and start
  developing v.5 with cleaned up source code, new features

Clearly the project is not unmaintained, but as many other projects it requires contributors to fix bugs and work on new features.

Sources:

GNU Screen 4.2.0 in Debian Experimental
http://savannah.gnu.org/projects/screen


You can try this:

Go to the dash and type "Terminal". Run it and type:

sudo apt-get install ntfs-config

This will prompt you to enter your administrator password. Enter it.

This will install a program, that as the name goes, configures you ntfs partitions
in you drive.

In the following screenshot, configure your drive as I put it there

Tick dev/sda2 and rename it to "/media/286452716452422C"

finally click auto configure.

Let me know if it works


Mongod service is on systemd list but failed to get properties

Depending on when you installed MongoDB and where you installed it from, the package might have been named 'mongod' or 'mongodb'. Apparently, you've installed it under both names. I suspect your problem stems from the duplicate packages.

First, check which MongoDB packages you have actually installed:

dpkg -l '*mongod*' | grep ii

Then, for each 'server' package installed, check which /etc/ "init" or "service" files belong to the package actually have installed. In my case, I have mongodb-org-server installed on 16.04, and my result looks like this:

$ dpkg -L   mongodb-org-server  | grep systemd
/lib/systemd
/lib/systemd/system
/lib/systemd/system/mongod.service

If you have another file in "/etc/init" for "/etc/systemd" that is not related to the version of MongoDB you actually have installed, remove it. You probably used "apt-get remove" on an old package, which doesn't automatically purge files in /etc.

If you've added or removed systemd .service files, use sudo systemctl daemon-reload to make sure your changes are reflected.


What Ubuntu can I run on my PowerEdge 840?

It was a hardware issue.
I got my hands on this machine just a couple of hours ago and the previous owner said that one of the DVD's arent working as they should, naturally I assumed it was the one that didnt have a broken front side but however that was not the case.
I got a pxe e61 media test failure which made me think "This is hardware related" so against all hope I plugged in the other DVD thinking "I've literally tried everything else, why not do this last thing?" and there we go, Ubuntu 16.4 started like a charm.
Take it from me, been dealing with computers for well over 14 years and I always check the hardware to begin with, dont do the same mistake as me. Good luck solving your issues!


Postfix Send-Only SMTP Server domain name configuration

I am not completely sure if I correctly understood what you are trying to achieve and what exactly the problem is but for now I'm assuming you want to use Postfix on server2.backup to deliver mail to a mailserver running on putty-server.
You don't need a lot of configuration to achieve this:
# myorigin = <sending domain>
myhostname = server2.backup
relayhost = <putty-server's IP>

Set myorigin to whatever domain you want as default in your 'from' email address, e.g. my-personal-domain.com or whitehouse.gov. You can omit it if you want to send from server2.backup.
You need to set relayhost to the IP of putty-server if there is no matching MX record for the domain you are sending mail to. If you want to send mail to multiple servers, check postfix' transport map setting.
That's it. Make sure putty-server accepts mails from server2.backup's ip(-range), e.g. by adding it to mynetworks on putty-server.
If this does not help you, update your question with

the output of lsb_release -a or cat /etc/os-release,
the output of postconf mail_version,
the output of comm -23 <(postconf -n) <(postconf -d),
relevant log lines from server2.backup (`/var/log/mail.log) and
relevant log lines from putty-server.


I assume you're trying to log in through SSH.  Did you also register your SSH key(s) with MAAS?  You need to do that, before you allocate the node to yourself (in the UI that's the Start Node button).

I believe the default username is ubuntu — so if you've gone through these steps, you should be able to ssh into the node with username ubuntu and no password.


Is there a Fraps-like recording application for Ubuntu with microphone support?

Simple Screen Recorder has all the features that you are looking for.

To install -

sudo add-apt-repository ppa:maarten-baert/simplescreenrecorder
sudo apt-get update
sudo apt-get install simplescreenrecorder


Cannot install openvas9 on Bionic for ARM

Hello and welcome to AskUbuntu!

According to the official ubuntu package documentation, openvas is available (version 9.0.2) for 18.04 in the universe repository.

You should check (and eventually enable) if the universe repository is enable (sudo add-apt-repository universe) and then:

sudo apt-get update
sudo apt-get install openvas


Package dependencies cannot be resolved when installing codeblocks

Install codeblocks-common first, then install codeblocks.


Try this;
go to

  preferences > Customize Look and Feel > Font

then change Sub-pixel geometry to None

For extra Drivers go to:

  preferences > Software Sources > Additional Drivers


Failed to download repository information Check your Internet connection. 12.04

Options:

1) Reorient the wireless adaptor antenna. If it's USB try using a USB extension cable and placing it higher.

2) Try connecting via wire (Ethernet cable) if possible

If #1 solves the problem it was caused by RF interference.

If #2 solves the problem it could still be either RF interference or a malfunctioning wireless adaptor.


Some other people have found this to be caused by the CUPS software (related to remote printers) here: Slow shutdown on Ubuntu 16.04 LTS (Stopping thermal daemon/running fit make remote CUPS printers)

If that's what the problem is for you too, the short answer is:

sudo systemctl disable cups-browsed.service


How can I figure out if my hardware specs are adequate for Ubuntu 13.10?

When it comes to graphic card management, you may want to install your card's proprietary drivers. On Ubuntu, this can be done in Systems settings > Additional drivers.

Then, remember that your laptop has only 2GB of RAM, which was extraordinary a few years ago, but not today anymore. Ubuntu is basically running Unity, Compiz and GNOME, three components that are quite heavy, and for some, experimental.

Linux is very light by nature, however, some distributions such as Ubuntu make it quite heavier...


Terminal is, in Ubuntu default software, the gnome-terminal. XTerm is... https://en.wikipedia.org/wiki/Xterm. UXTerm is XTerm with support to Unicode characters.
The main difference between XTerm and Terminal is that the gnome-terminal has more features, while XTerm is minimalistic (though it has features that are't in gnome-terminal, but they are more advanced).


What do I need to do to connect to public wifi in a local shop?

I had a similar problem, and found that I could make a curl request just fine:
$ curl -vL "https://www.google.com"
* Rebuilt URL to: https://www.google.com/
*   Trying 172.217.19.196...

When I connected directly to that IP in chrome(ium), I got shown the guard page, and could tick the necessary box. YMMV.


Set your desktop client to listen on a specific port using the Remmina client.  It has an option to do that.

When you go to create a new connection with the little document/plus symbol. Then in the drop down "Protocol" select "VNC Incoming Connection"

Then you can more tightly control the VNC server.

VNC works better on Linux then RDP.


My suggestion is to configure docker apache to use 8080 port, and configure system apache to proxy request on some particular virtual host to proxy requests to docker 8080

In frontend apache virtualhost config:

<VirtualHost *:80>
    ServerName mysite.com
    ProxyPass / http://127.0.0.1:8080/
    ProxyPassReverse / http://127.0.0.1:8080/
</VirtualHost>

Config is located at /ect/apache/sites-availabe/ and enabled by a2ensite configname


Is there a way I can rename Trash to Crap?

Yeah, you can abuse the translations system to do this.

Make a temporary text file using gedit

gedit /tmp/foo.po

and enter this text into it:

  msgid "Trash"

  msgstr "Crap"

Change to /usr/share/locale/en/LC_MESSAGES

cd /usr/share/locale/en/LC_MESSAGES

And then apply changes

sudo msgfmt -o unity.mo /tmp/foo.po

Now restart unity to make the changes take effect.

unity --replace

Source: https://askubuntu.com/a/225023/17722


Make sure that you have both Firefox windows open side by side, and click on the Tab that you want moved, and drag it to the new windows.

or

Click on the little icon to the left of a URL, and drag it to the new window.

or

Right click on the Tab that you want moved, and click on Move to a New Window.


It looks like problem was made by

Autosuspend for USB device BCM20702A0 [Broadcom Corp]

listed in Tunables tab in powertop. Disabling that fixed the problem.


image viewer in ubuntu that can show the pixel coordinates and pixel value as well for current mouse location in the image

edisplay will do it. Moreover, it gives RGB values and can focus, it is in the standard Ubuntu repository. Just install it via terminal:

$ sudo apt-get install edisplay

And for opening your images on it use this command:

$ edisplay --gl /path/to/image


How can I assign another static IP address to another LAN Card?

I would like to highlight couple of things here.

Your configuration is not for static IP , its for dynamic IP in the given network range.

# The primary network interface
auto eth0
iface eth0 inet dhcp

auto eth1
iface eth1 inet dhcp

If you want static IP really then instead of dhcp you have to use static along with IP Address and other required information.

For example:

auto eth1
iface eth1 inet static
        address 192.168.56.102
        netmask 255.255.255.0

type ifconfig -a then you will come to know what IP's actually assigned to your two interfaces. And for these two IP's if you cant ping then its an Issue.


How to remove the time stamp on the right side of the fish shell?

Put this in your config.fish (or eg. .config/fish/functions/fish_right_prompt.fish):

 function fish_right_prompt
  #intentionally left blank
 end

By putting stuff in this function you can also customize that part of the prompt however you want to. Whatever is returned by this function becomes the prompt.


Dropbox litters my folders with unhidden backup files

I've used Dropbox for years and never seen this behavior. On the other hand, this is typical behavior for some text editors. If you are creating files with your editor, check its Settings for a switch to turn this behavior off.


How to set resolutions with xrandr using multiple monitors

First list your monitors and resolutions:

xrandr -q

Take note of your monitors names, example (I truncated the output so as to not list all the resolutions)

bodhi@zenix:~$ xrandr -q
Screen 0: minimum 320 x 200, current 1920 x 1200, maximum 4096 x 4096
DVI-I-1 connected 1920x1200+0+0 (normal left inverted right x axis y axis) 520mm x 320mm
1920×1200 60.0*+

DVI-I-2 connected 1920x1200+0+0 (normal left inverted right x axis y axis) 520mm x 320mm
1920×1200 60.0*+

Here my monitors are "DVI-I-1" and "DVI-I-2"

With that information you can then set a resolution. Use "--output" and "--mode" to set each monitor's resolution.

xrandr --auto --output DVI-I-2 --mode 1920x1200 --left-of DVI-I-1

See my blog post and/or man xrandr for additional options (setting a resolution or dpi or frequency).

Post back, with the output of xrandr -q if you require specific help with your monitors.

Note: xrandr does not work with proprietary drivers.


How to Revamp my hard-drive and then do a dual-boot windows xp and ubuntu 12.04 LTS Ubuntu currently installed

Sounds like you're on the right track. Install windows before Ubuntu works best.

One way to format the drive is to use a Linux distro with gparted on it that runs form a CD. This way the drive is not mounted. I don't think you can safely format a mounted root partition.

What you want to do in GParted is delete all the partition then apply, that should be fine. Windows should be able to then format the drive in the windows installation process. Have windows only create a partition for itself leaving space for ubunut.

If you have issues you could drop to the windows console in the installation process and run 'fixboot' and 'fixmbr'. When you install ubunut grub will take over the Master boot record process.

Your on the right track.


A clipboard by definition contains only text. What it sounds like you want is a screenshot tool. Any Ubuntu distro should have one pre-installed. In Ubuntu Studio 20.04 it's called "Screenshot" under Accessories.


Formatting Disk? Clean new Ubuntu Setup on a messed up one

The installer for ubuntu will offer you various options (install alongside current OS, overwrite current OS, other,...)

If you want to be sure, I would recommend picking 'other' and formatting any partitions you feel unsure about.


How to rename a batch of files with an incrementing number in the file name?

The rename command in terminal is a useful script that will take care of this for you using the simple VIM-style search and replace command.  Assuming you have nothing else of the form Example*.java in your directory:

$ rename 's/Example/Q/' Example*.java


Switching from Mint to Ubuntu will i be able to access other HDDs in my PC?

Yes.

/media/ contains external disks. All you need to do is not format them. After installing you will find them at the launcher and clicking them will mount them or plug them in to make them show up.


How to change from German to English in the File Manager in Ubuntu 15.10?

If you want various formats in English, and not only the language, open Language Support, go to "Regional Formats", and select some English formats option of your choice. Then relogin.

https://help.ubuntu.com/stable/ubuntu-help/session-formats.html


How to find what program woke the computer up?

Nothing is automatically waking your computer up from hibernate. If your computer is in the hibernate state, it is actually powered off. The only way to turn it back on, is to push the power button.

If you mean from suspend, then most likely it is a configuration in your BIOS. There are no active programs running while the computer is in suspend mode. It's possible though, that your BIOS is configured to wake on LAN activity as well as keyboard or other events, and possibly something is making a network request to your computer, dialing the modem, or your cat is jumping onto the keyboard.


Is it possible to run a script on keyboard input language change?

If you are using Unity, and use indicator-keyboard to change the keyboard input, then in 14.04 at least we can exploit the fact that this changes the GSettings key org.gnome.desktop.input-sources.current. Here is a Python script that listens for changes to that key and then calls a function that prints some information and execs a subprocess.

from __future__ import print_function

from gi.repository import Gio, GObject

import subprocess

def on_changed(settings, key):
  print("Key changed", key, "to", settings.get_uint(key))
  subprocess.call(["touch", "/tmp/last-input-change"])

def main():
  settings = Gio.Settings("org.gnome.desktop.input-sources")
  settings.connect("changed::current", on_changed)
  loop = GObject.MainLoop()
  loop.run()

if __name__ == "__main__":
  main()


After using GParted to give my virtual disk more space, the Ubuntu VM will not boot

Your disk uses old format from 80's: https://en.wikipedia.org/wiki/Master_boot_record

  The organization of the partition table in the MBR limits the maximum
  addressable storage space of a disk to 2 TB (2^32 × 512 bytes).

You need to switch to gpt.


Unable to boot Windows after installing Ubuntu 14.04

Is is not possible to load your different OS in your configuration. Either all UEFI or all LAGACY installed OS will be selectable in one way.
You need to install Ubuntu in UEFI or install Windows in LEGACY.
Please look for solutions for running Ubuntu in UEFI.


How to develop for Android with Xamarin?

Short answer

Yes, you can develop with Xamarin.Android on Ubuntu! However, since Linux, sadly, isn't oficially supported by Xamarin, it's not as straightforward as it would be on Windows. In short, first of all you have to install Java, Mono and Android Studio, then you have to compile Xamarin.Android yourself and finally you have to setup your favorite IDE to work with Xamarin.

.

Prerequisites

Installing Android Studio

(Note: In theory you could just download the Android SDK and NDK, I haven't tried it though.)

Installation of Android Studio on Ubuntu has been covered thoroughly in a different SO answer, but I'll go over it quickly: first you need to install Java 8 JDK. While it's officially recommended to use Oracle Java, OpenJDK will do just fine:

sudo apt install openjdk-8-jdk

You'll also need to set the JAVA_HOME variable to match the installation directory of your Java 8 JDK. To do so, add this line to your ~/.bashrc:

export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64

Then you have to download Android Studio and unzip it somewhere you like, for example your home folder, or /opt/androidstudio.

Once you have it, you can start it up and open SDK Manager in the top right corner:

Now download the SDK versions you want to target. Be sure to also install NDK, though, as that's what we will need to deploy Xamarin applications. Then you can try building an sample app and deploying it to your phone (or to a running emulator) just to make sure everything works all right.

You also need to set the AndroidSdkDirectory environment variable, so that Xamarin knows where to look for the installed SDKs. You can do this by adding this line to your .bashrc, .zshrc or whatever shell you use:

export AndroidSdkDirectory=~/Android/Sdk

You can also create aliases for useful commands:

alias sdkmanager=~/Android/Sdk/tools/bin/sdkmanager
alias avdmanager=~/Android/Sdk/tools/bin/avdmanager
alias adb=~/Android/Sdk/platform-tools/adb
alias android-emulator=~/Android/Sdk/emulator/emulator

Installing Mono

As of October 2019, Ubuntu still doesn't have Mono 5 in its repositories. Therefore we'll have to add the official Mono repositories (it's a good idea anyway):

sudo apt install gnupg ca-certificates
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb https://download.mono-project.com/repo/ubuntu stable-bionic main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list
sudo apt update

Next step we install the Mono development packages. Maybe you won't need everything, but I was lazy and went with mono-complete. You'll also need nuget, so let's install that too:

sudo apt install mono-complete nuget

You can check whether the correct version was installed by trying the msbuild command. The old versions of Mono didn't have it, so if the command was found, you're probably ready to go.

.

Compiling Xamarin.Android

Dependencies

There are some dependencies needed to successfully compile Xamarin.Android. Most of those packages will be already installed on your machine, so you can try skipping this step and only installing those that are missing. However, it takes some significant time to retry the build, so you'll save it by installing them right away:

sudo apt install autoconf autotools-dev automake cmake build-essential curl gcc g++ g++-mingw-w64 gcc-mingw-w64 git libncurses5-dev libtool libz-mingw-w64-dev libzip-dev linux-libc-dev make ninja-build p7zip-full sqlite3 vim-common zlib1g-dev linux-libc-dev:i386 zlib1g-dev:i386 libx32tinfo-dev

Cloning

Fetch the latest Xamarin.Android source code from GitHub:

git clone https://github.com/xamarin/xamarin-android.git
cd xamarin-android

You probably don't want to build from master, so choose a stable release in the GitHub repo and check it out with git checkout [chosen commit hash]. Make sure to also reset the submodules to the correct version.

System detection

If you're using a distribution derived from Ubuntu, you'll have to add an extra line to the system detection code to make it work:

nano build-tools/xaprepare/xaprepare/OperatingSystems/Linux.cs

and under the line

{"Ubuntu",    (ctx) => new LinuxUbuntu (ctx)},

you have to add a line for your system, eg. for Elementary OS it's:

{"elementary",(ctx) => new LinuxUbuntu (ctx)},

If you're on pure Ubuntu, you can skip this step.

Build

First you have to build all the dependencies:

make prepare

And then you can build Xamarin.Android itself. If you only want to target the latest Android, run:

make

(The targeted version is the latest Android version supported by your application. So if you want to write apps for Android versions from 7 to 10, you want to target v10.0. If you want to be able to target any version of Android, you'll have to run make jenkins instead.)

Both of those steps require a significant amount of patience and Internet connection.

Installation

Finally you can install Xamarin.Android to your system:

sudo make install prefix=/usr

.

Using Xamarin

Set up a project

To test that our build actually works, we want to build and deploy an actual Xamarin project. Ideal for this purpose are the demo projects in xamarin/monodroid repository. So let's clone it:

git clone https://github.com/xamarin/monodroid-samples.git
cd monodroid-samples/Button

Add supported ABIs

For some reason, we need to add the list of supported ABIs to the project file. Open it in an editor:

nano DroidButton.csproj

And to the first PropertyGroup add this line:

<AndroidSupportedAbis>armeabi-v7a;arm64-v8a;x86</AndroidSupportedAbis>

If you didn't build with make jenkins, you'll also want to change the TargetFrameworkVersion to v10.0.

Build

msbuild

Deploy

Either start up a virtual device in AVD Manager (accessible eg. through Android Studio), or connect a phone in debug mode and then run:

msbuild /t:Install

This should install the app to your phone. If you want to build and deploy with one command, you can use /t:Build,Install. If you want to pass extra parameters to ADB (for example to identify the device where to deploy), use /p:AdbTarget=[adb options], for example: msbuild /t:Install /p:AdbTarget=-s1080c487.

.

Summary

So we've got Xamarin set up! This was a long journey, wasn't it? Full of surprises, letdowns and often pure misery. Was it worth it? You are to decide, but for me it definitely was. Now, take a break (only a short one though!) and then start building your dream application!


Mounting Flashdrive - mounted to home directory

A mount on a non-empty directory hides the files contained within it, which is often called shadowing. This doesn't cause the files themselves to be in jeopardy. There are several easy steps you can take to troubleshoot, fix, or (when necessary) work around this problem.

Make sure your own shell isn't what's keeping the filesystem from unmounting.

For a filesystem mounted at sudo fuser -km /home/my_name, running sudo fuser -km /home/my_name to kill all processes accessing the filesystem, as you have done, is usually sufficient to let you unmount it. You reported that when you did this your terminal was closed as a result.

This will happen if your current directory, in the shell, is the mount point you're trying to unmount or one of its subdirectories. (Your shell is killed, and then the terminal program running it sees that the shell has closed and, under most setups, quits automatically as well, much as it does when you run the exit command.)

To fix this, simply navigate outside the mount and attempt to unmount it again. For example, you could change directory to / first:

cd /
sudo umount /home/my_name

Find and close or kill whatever processes are accessing files in the mount.

If you are ever in a situation where don't want to kill processes with fuser, or if you are unable to do so and need to find out what those processes are, you have several options for finding them, including some graphical utilities. I'll briefly illustrate one option here.

You can run lsof on a directory to see what processes are accessing files inside it:

lsof /home/my_name

This works well for mount points. Sometimes lsof is able to obtain better information if you run it as root, though this is often not necessary:

sudo lsof /home/my_name

Output from lsof usually looks something like this:

ek@Io:~$ sudo lsof ~/mnt/old
lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1000/gvfs
      Output information may be incomplete.
COMMAND   PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
flock   15529   ek  cwd    DIR    7,0     2048 1280 /home/ek/mnt/old
flock   15529   ek    3rW  REG    7,0    21114 1311 /home/ek/mnt/old/md5sum.txt
less    15530   ek  cwd    DIR    7,0     2048 1280 /home/ek/mnt/old
less    15530   ek    3r   REG    7,0    21114 1311 /home/ek/mnt/old/md5sum.txt
less    15530   ek    5r   REG    7,0      231 1325 /home/ek/mnt/old/README.diskdefines
bash    27465   ek  cwd    DIR    7,0     2048 1280 /home/ek/mnt/old

This tells you the files and processes that are being used. In particular, if you have a situation where your shell is what's keeping it from unmounting, and you haven't noticed that this is the case, then lsof will make it plain with output like:

ek@Io:~$ lsof ~/mnt/old
lsof: WARNING: can't stat() tracefs file system /sys/kernel/debug/tracing
      Output information may be incomplete.
COMMAND   PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
bash    27465   ek  cwd    DIR    7,0     2048 1472 /home/ek/mnt/old/boot

In the above example, the only thing keeping the filesystem from being unmounted is that I had navigated into a subdirectory of the mount point with my shell (bash), and was still there.

If you need more information on a process, one way is to run ps with its process ID, which given in the second column of lsof's output:

ek@Io:~$ ps 27465
  PID TTY      STAT   TIME COMMAND
27465 pts/3    Ss+    0:04 -bash

You can also kill the process by its PID (kill 27465, but with whatever the appropriate number is in your situation). It's usually best to try this before moving on to the stronger kill -KILL 27465. (The -9 flag works in place if -KILL, too.)

Of course, before using the kill command or similar facilities at all, it's usually better to try closing programs the normal way, especially if there might be important data at stake. For example, it's better to save a document and close a word processor than to quit the word processor with the kill command.

Access the shadowed files through a nonrecursive bind mount.

As Paul says in Is it possible to access files “shadowed” by a mount? on SuperUser, you can access files shadowed by mounts by creating a bind mount and navigating to them there:

sudo mkdir /mnt/root
sudo mount --bind / /mnt/root

Those commands are adapted slightly from Paul's excellent answer to that question. (I encourage you to consult that page for additional details.) You don't have to use /mnt/root, but it's as good a choice as any.

If you do it that way, your entire root filesystem is accessible through /mnt/root.

If you have a separate /home partition then you'll want to make the bind mount bind to that instead:

sudo mkdir /mnt/home
sudo mount --bind /home /mnt/home

This is the same as for /, just with /home.

Reboot.

oldfred's suggestion to reboot the system is a reasonable solution to this problem. You should be able to shut down and reboot the system, if you want. Your data are shadowed by a mount, but should not be at risk of being lost.

Rebooting should be safe but you shouldn't need to reboot to solve this, if you don't want to. If you have trouble with the methods given above and want to get them to work, please comment or (better) edit your post. (Other people reading this with similar problems should consider posting a new question.)


The above did not work for me. Got an error doing the pip3 install that I could not resolve, presumably because I don't know  python that well.

I fixed the problem by downloading the latest build from SourceForge. The link is on lirc.org. You have to unpack the tar, run config, then make install.

Also, you may need to install the package lirc-compat-remotes which defines lots of remote controls, such as for mce.


ubuntu integrated graphics suspend + hybrid graphics

I had a similar problem. Updating the BIOS fixed it.


ntfsfix error: Volume is corrupt. You should run chkdsk. After ntfsresize

You need to boot into Windows, or use a different computer with Windows if it's an external drive. Windows should automatically detect that there's an issue and have a pop-up asking if you would like to check the disk for errors, so just press yes and you should be good.

If you're planning on using the drive on Linux more than Windows, I strongly suggest that you use ext4, as it works much better than NTFS in Linux, as I have learned the hard way.

BTW, according to the manpages:

  ntfsfix is NOT a Linux version of chkdsk. It only repairs some fundamental NTFS inconsistencies, resets the NTFS journal file and schedules an NTFS consistency check for the first boot into Windows.


Welcome to the forums! Here are some commands that I found others have said have worked for them:

In terminal, run export LANG=C; steam

or

In terminal, run export LC_NUMERIC=C
Start Steam

You might also want to check out your drivers - try changing to other drivers (Settings Manager -> Software Sources -> Additional Drivers), and see if that works.  If you change to a different driver, and it doesn't work, I would try running either of the above commands before switching to a different driver again.

Probably the best place to post bug reports and get support for anything related to Steam for Linux is at Valve's Steam-for-Linux Github. Not trying to shove you off the Askubuntu forums, just suggesting a better place for this specific issue.

Sources: Issue Report: Black screen on TF2 startup

Issue Report: Shader generation/compilation fails in TF2 - temporary fix - proper fix WIP


Can not upgrade Ubuntu server 19.04 to 19.10 ('ubuntu-minimal' could not be located)

You're using unsupported Ubuntu interim release.
Edit your /etc/apt/sources.list file and add the following lines:
deb http://old-releases.ubuntu.com/ubuntu disco main restricted
deb http://old-releases.ubuntu.com/ubuntu disco-updates main restricted
deb http://old-releases.ubuntu.com/ubuntu disco-security main restricted

and remove the lines which doesn't work.
Then run: sudo apt-get update again.
And try to do distribution upgrade again: sudo do-release-upgrade.
Source: How To: Fix apt update in Ubuntu 19.04.


Blank screen after Switch User or Resume

This reminds me of a fixed Lucid bug (LP #546578) when x-server gamma was not restored properly from resuming gnome-screensaver. The solution there was to disable gnome-screensaver until the bug was fixed, which is probably not a good idea on your laptop. The underlying bug in X-Server may not yet have been fixed - I haven't followed that. You could check if it's related to this by typing

xgamma -gamma 1.0

in a terminal to see if the display gets bright again.


GTX 970, nvidia-settings stuck at performance Level 2 of 3 under load

Folowing this guide helped me force the card to it's maximum clock speeds. Whatever Nvidia, whatever ...


Take a look at these answers mentioned on my previous post at: How make my Logitech Quickcam e3500 work? which I reproduce here for you and that may not help you to fix this issue but will allow you to use your webcam in web based video-chat services (such as www.ubiqq.com).

  This seems to be such a common issue when attempting to use the
  webcam, usb based, for a video conference through a flash player based
  system, such as Fonomo, Ubiqq, or Skype, etc.

  I suggest you to take a look at the answers provided in these
  questions, which may lead to help you to fix this issue.

  https://askubuntu.com/questions/53495/flash-crashes-on-enabling-webcam/53615#53615
  Webcam not detected by Flash
  logitec webcam for notebooks deluxe
  QuickCam E 3500 working from Cheese, but not Skype

  In my case I fixed that issue by using the Flashcam Project, mentioned
  on these answers and whose instructions for a correct usage can be
  reached right here: http://www.swift-tools.net/Flashcam/

  Another good trick that makes my days when attempting to use the
  webcam through web browsers is the usage of Webcam Studio, which can
  be reached here: http://www.ws4gl.org/. After running the Webcam
  Studio you will have a virtual "bridge" between your physical webcam
  and what the Flash Player is expecting to find.

  I hope this gives you a clue on where to begin.

  Good luck!


You can do this without editing configuration files: go to System Settings > User accounts, click "Unlock" and enter your password, then click the button next to "Automatic login":

'

Got this from here by Alin Andrei


Drop the "/home/prj/myfolder/*" and use "cd /home/prj/myfolder/" to navigate to that location.

cd /home/prj/myfolder/
find . -mtime 1 -type f |
    while read file;
    do
        tar -Pcvzf archive.tar.gz --remove-files "$file"
    done

The files will then be stored with a relative path.


How to find the lp-name and ppa-name on launchpad to add with add-apt-repository?

The package libraw5 was for Ubuntu 12.04 (Precise).

For 14.04 (Trusty) you need

sudo apt-get install libraw9

for 15.04 (Vivid)

sudo apt-get install libraw10

And as you said in another comment, to install lightzone use the PPA ppa:otto-kesselgulasch/lightzone

sudo apt-add-repository ppa:otto-kesselgulasch/lightzone
sudo apt-get update
sudo apt-get install --reinstall lightzone


KATE keeps forgetting I have the shell plug-in enabled

This is a bug with Kate. But if you disable the session auto save, it loads the plugins. You can do this by changing the Application Startup Behavior to Start new session. Application Startup Behaviors can be changed from Settings > Configure Kate > Sessions. This is not a fix, just a walk-around.


Why I'm unable to install Eclipse using ubuntu-make on Ubuntu 16.04 LTS?

The error output indicated that currently installed 18.05 version of Ubuntu Make is outdated, so we need to upgrade it.

By visiting the https://github.com/ubuntu/ubuntu-make we can determine two possible solutions:

use Ubuntu Make from Snappy

In my current case this means the following process:

sudo add-apt-repository -r ppa:ubuntu-desktop/ubuntu-make
sudo apt-get purge ubuntu-make
sudo apt-get install snapd

snap install ubuntu-make --classic

use other new official PPA as indicated in Ubuntu wiki page

In my current case this means the following process:

sudo add-apt-repository -r ppa:ubuntu-desktop/ubuntu-make

sudo add-apt-repository ppa:lyzardking/ubuntu-make
sudo apt-get update
sudo apt-get upgrade

Personally I want to avoid Snappy, so I have added new PPA to the system.
As the result Eclipse 20.03 got installed.


The package pamdepth is in the packge netpbm, however, the version in the repository does not seem to contain pamdepth, here is how I got it to work

The two versions conflict so

sudo apt purge netpbm

Download

wget downloads.sourceforge.net/project/netpbm/super_stable/10.47.62/netpbm-sf-10.47.62_amd64.deb?r=https%3A%2F%2Fsourceforge.net%2Fprojects%2Fnetpbm%2F%3Fsource%3Dtyp_redirect&ts=1472465698&use_mirror=freefr

or download here, now it had dependencies I could not resolve via apt (IDK why), so I installed it via software or double click the deb.

That was it, it is working, here is proof