Is it safe to have permission to create files in var/www/html?

I think there are a couple of things you should check out first which will serve you as an introduction.

What you have in /var/www/html is what is called a "Directory" for a Virtual Host in Apache.

What does this mean? It means this directory has been created and defined by default for you. It also means you can create a directory anywhere in your filesystem and assign it as the directory for this Virtual Host.

Where does this Virtual Host definition live? In LAMP, you have this called Virtual Hosts. This means you can host many websites and resources in your same server/machine. These virtual hosts are usually defined under /etc/apache2/sites-available/

If you check that folder you'll find this file: 000-default.conf

There's where /var/www/html is defined. You are actually free to modify this, and place it, let's say somewhere beneath your /home/{user} directory.

I recommend you as a next step for your introduction to LAMP (in Linux) to take a look at Virtual Hosts. How to create them, and how to make them work.

You will find some Apache commands like a2ensite a2dissite to make the new virtual host sites available or disable them and many other interesting things in the way.

Security Issues:

About your security concerns if you want to be sure no-one has access to your /var/www/html you should have an active firewall. The firewall would block any non-requested communication to port 80, which is the port wide open for /var/www/html

You should notice that the Virtual Host defined by default has the widest possible access. It's defined like this <VirtualHost *:80>. This definition makes anyone guesssing your IP in your LAN to have access to see your /var/www/html. That's actually the purpose of a server, to serve things to the outside world. So that's basically ok.

But if you want to protect that, you have to either created a new VirtualHost, aka a named Virtual host, and probably use a Firewall to protect your ports (port 80, and whatever other port you wanna use)


Linux Alias with multiple and depending commands possible?

Normally, failure of a command is signalled by its non-zero exit status. In such a case, using && solves your problem:

ls /nonexistent-file && echo This won\'t be printed

If you need to check the output, you can use grep and ||:

echo fail | grep 'fail\|error' || echo This won\'t be printed

Don't forget to quote the alias content:

alias safe-ls='ls /nonexistent-file && echo This won'\''t be printed'

If you need parameters for the commands, you'll have to use functions instead:

safe-ls () {
    ls "$1" && echo This won\'t be printed
}


connect to host localhost port 22: Connection refused

vagrant@vagrant-ubuntu-trusty-64:~$ ssh -vvvv localhost

  [...]

vagrant@vagrant-ubuntu-trusty-64:~$ sudo netstat -tulpn|grep 22
tcp        0      0 10.0.2.15:22            0.0.0.0:*

The line 10.0.2.15:22 tells ut that something is listening on port 22 on 10.0.2.15. However, you try to ssh localhost. Localhost is 127.0.0.1 (or ::1 for IPv6). From what information you provide, nothing listens to port 22 on the loopback interface.

Thus ssh localhost does not work. ssh 10.0.2.15 will probably work.

If a socket listens to a specific interface, it will only receive packets destined for that interface. A socket can listen to the wildcard 0.0.0.0, which means it will receive packets on that port on any interface. A process listening at 0.0.0.0 can be accessed both by the localhost and the network address of the host.


Setup Local Mail and get cron job output mails

When a cron job starts successfully or fails to execute for some reason cron daemon automatically sends an email to the user who set the cron job. That mail contains the description of a successful job or the detailed report why the particular cron job failed.

If your local mail system is not set you will not receive those mails. The cron job output emails will just die in a local mail spool folder. So you need to set up your mailer daemon to read those mails. See this answer on How read local email in thunderbird to get all your local mails.

If your cronjob fails you will receive a mail stating the reason of failure. This is one of the best way to detect the error in setting a cron job.

Alternate ways

According to this answer one can get errors of a cronjob in a log file using redirection. But you need to set the redirection with your cron job and specify the log file by yourself.

And the /var/log/syslog file is always there to check if your cron job is running as you expected or not.


dwm does not show any windows after login

Reinstalling dwm helped.

$ apt-get --reinstall install dwm


What are the major differences between Fluxbox and Blackbox?

The most important difference is probably that Fluxbox is still actively developed, while Blackbox's last cvs commit seems to have been in 2005.

Another important difference is that Fluxbox has various features that Blackbox does not - most notably:

You can use tabs to group multiple windows together
Fluxbox has a system tray/notification area
Fluxbox supports key bindings out of the box while blackbox requires a separate tool (taken from The Alpha Nerd's answer)


I suppose that your Magnet download into utorrent is triggered by clicking the magnet icon or whatever when you download it. You can do Right click -> copy link (or whatsoever), then you can paste it to a magnet to torrent tool, I found this on google, but i'm sure there are tons of them out there.


Removing PPAs to proceed with update manager seems risky

If you're doing an upgrade of Ubuntu from one major release to the next the update manager will deactivate all your system's PPAs before attempting an upgrade.

Your comment to Agmenor's question sort of answers your question. If the PPA is not being updated, then it's probably not useful to you and you can just remove it; or worse it's being unmaintained and can just be removed.


MySQL 5.6 dpkg install error, even after complete uninstall

first remove mysql-server completely using commands:

sudo apt-get remove --purge mysql-server mysql-client mysql-common
sudo apt-get autoremove
sudo apt-get autoclean

then try to install it again.

sudo apt-get install mysql-server

if you installing with dpkg command and if it show any dependency on other package then run command :

sudo apt-get install -f

then try again to install

EDIT: Here is bug with mysql-server-5.6 so try lower version of mysql-server. if you want to install mysql-server-5.6 then you can use this PPA.

create any file under /etc/apt/sources.list.d/

sudo vi /etc/apt/sources.list.d/mysql.list

and paste below lines and save it.

deb http://ppa.launchpad.net/ondrej/mysql-5.6/ubuntu trusty main
deb-src http://ppa.launchpad.net/ondrej/mysql-5.6/ubuntu trusty main

and update it

sudo apt-get update

then install it using command

sudo apt-get install mysql-server-5.6

it is tested on Ubuntu 14.04 .
 Here is PPA available for Ubuntu Version 12.04 ,14.04 ,14.10, 15.04 and 15.10.


Is there a mininal, command-line-only distribution of Ubuntu or similar that runs within MS Windows

You might find that something like coLinux or andLinux might be slightly lighter but personally, I'd choose a VirtualPC/VirtualBox/VMWare virtual machine every time.

The problem with the xming-style native builds of Linux distributions is they're very non-standard. They're hacks to serve a purpose. They might fit your purpose but I prefer to have standard things available. With a VM  you can port to a proper bare-metal install if the need ever arises.


Dropbox very high CPU usage without any actual data transfer

First run in a terminal:

sudo apt-get install cpulimit && sudo apt-get update

Then use a text editor like gedit or kate and put the following text in the file.

#!/bin/sh
dropbox start -i
cpulimit -e dropbox -l 15

save the file with a name like "cpulimit.sh." After saving go to the icon and right click, somewhere in the permissions section, there will be a box for "make executable" or something similar. Check that box. Go to the autostart program, which you can find by typing "startup" in unity ubuntu or autostart in kubuntu. Add a program, browse, find the .sh file you made and set ok. It should run every time you boot up. In the code above you'll notice there is a '15' that is the cpu useage max. You could probably set it even lower if you want (eg replace '15' with '8' or whatever). I don't know if there is a minimum or not.


How to save installer file while downloading from ubuntu software center?

Ubuntu uses deb archives and when you download to install from Software Center all the packages are cached on /var/cache/apt/archives. Basically what you need to do is to copy it somewhere else or in an external backup drive. So in your folder navigate to /var/cache/apt/archive. You can do this doing Ctrl+L and typing the location and just copy all the *.deb packages to somewhere else.

Other than that if you are cozy with command line you can just do:

cp -r /var/cache/apt/archives /your/destination

Your destination should be writable, i.e you should be able to make folder and files on the location where you copy the debs.

If you want to install softwares on another Ubuntu you can just do sudo cp -r /you/destination/*.deb /var/cache/apt/archives.


Themes mess up any time I install anything in wine

Wine should not do anything to the Ubuntu theme. I think you should file a bug report with Wine. http://bugs.winehq.org/


Well, I tried "update-grub" again and id didn't work, but I tried to do the same in my manjaro instalation and it now works well, seems like every grub-change must be donne in Manjaro I dont know why.


Look into configuring

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

You need a file normally called default.conf there defining virtualhosts like so...

<VirtualHost yourIPaddress:80 >

    ServerName www.yourdomainname.here
    ServerAlias yourdomainname.here
    ServerAdmin <yourmail address>
    DocumentRoot /var/www/{your webroot folder}

    <Directory />
    Options FollowSymLinks
    AllowOverride All
</Directory>
<Directory /var/www/{your webroot folder} >
    Options Indexes FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    allow from all
</Directory>

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
    AllowOverride All
    Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
    Order allow,deny
    Allow from all
</Directory>

     # set your own filename #
ErrorLog ${APACHE_LOG_DIR}/logging_filename_errorlog.log

# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel error

    # set your own filename #
CustomLog ${APACHE_LOG_DIR}/logging_filename.log combined

Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
    Options Indexes MultiViews FollowSymLinks
    AllowOverride All
    Order deny,allow
    Deny from all
    Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>


The default Java runtime environment (JRE) on Ubuntu is OpenJDK (instead of Oracle/Sun). Unlike the name OpenJDK this comes as two parts: a JRE (default-jre) and a JDK (default-jdk).

To also install the JDK (providing javac), install the metapackage default-jdk  and you should be all set.

In case you have more than one Java runtime or Java compiler installed, select the right one with update-alternatives:

sudo update-alternatives --config java   # runtime
sudo update-alternatives --config javaws # runtime Web Start (applets)
sudo update-alternatives --config javac  # compiler


When installing Ubuntu I didn't know the passwords wouldn't show so I just kept hitting random keys. Now I don't know the password

Had to do this:

I opened up Command Prompt.
Changed dir: cd C:\Users\username\AppData\Local\Microsoft\WindowsApps. If you open that folder (you can do Windows + R) and find ubuntu.exe, it should work.
Logged onto root user: ubuntu config --default-user root. Personally it didn't require a password or something.
Start Ubuntu in that same cmd: ubuntu
Change password: passwd username. It shouldn't require the current password if you logged in as the root user.
And I proceeded to uninstall Ubuntu before running into any other issue. I need to do research BEFORE installing it, not after. Should learn at least the basics before diving into this new "world".


Delete Fedora, install Ubuntu, keep Windows

The easiest way would be"

Insert Ubuntu LiveDVD/USB.
Begin with Ubuntu installation.
When the option comes to choose the partition on which to install, delete the one with Fedora using the '-' button on bottom-left of the window.
Now, select the free-space just created, click on '+' button to create a new 'ext4' partition.
Continue.

P.S. Make sure you've backed up anything important you had on the Fedora partition beforehand.


Repeat whole line matches with grep for multiple instances on the same line

Using the perl string repetition operator, obtaining the number of repeats by evaluating the result of the match in a scalar context:

$ perl -pe '$_ x= (() = /banana/g)' file
There is one banana here
There are two banana banana here
There are two banana banana here
There are three banana banana banana here
There are three banana banana banana here
There are three banana banana banana here
Basically there is no limit to how many banana banana banana banana banana banana banana we can have
Basically there is no limit to how many banana banana banana banana banana banana banana we can have
Basically there is no limit to how many banana banana banana banana banana banana banana we can have
Basically there is no limit to how many banana banana banana banana banana banana banana we can have
Basically there is no limit to how many banana banana banana banana banana banana banana we can have
Basically there is no limit to how many banana banana banana banana banana banana banana we can have
Basically there is no limit to how many banana banana banana banana banana banana banana we can have


Virtualbox is in the official repository.

Just open a terminal and enter:

sudo apt-get install virtualbox

After installing you should add the user, you want to use VirtualBox with to the vboxusers group by:

sudo adduser $USER vboxusers

If you prefer a more recent version, take a look at Download VirtualBox.


Backport Ubuntu 20 theme and icons to Ubuntu 16

Standart theme of Ubuntu 16.04 called Ambiance.
I have found similar theme here: https://www.gnome-look.org/p/1398295/

Download Ambiance.zip
Unpack it to /usr/share/themes/ folder.
Download and run gnome-tweaks tool
Select Appearance/Themes/Applications: Ambiance


get specific lines from File1, others from File2 and print them in File3

Quick answer (others can feel free to edit to add details):

(sed -n 19,40p File1; sed -n 9,18p File2) > File3

-n tells sed to not automatically print all input lines, then X,Yp tells it to print lines X to Y, inclusive. The (command1; command2) construct "joins" both commands into one for the purpose of output redirection.


How to get videos on Yahoo finance to play

Use Google Chrome.  It has Flash built in.  Not Chromium.  Until Firefox and other browsers start doing this it will always be a hassle and I personally prefer to get work done rather then messing with a browser plugin.  I love Firefox, but I also have an Nvidia video card and the current Ubuntu installed Flash plugin has lots of issues.  Also Google adds patches faster then Adobe at times.

https://www.google.com/intl/en/chrome/browser/


The easiest way in this case is to use Google Chrome. It has the latest Adobe Flash built-in.


HistTimeFormat error showing message when opening terminal

The command should've been written like this in order to be under quotes in bashrc file
echo 'HISTTIMEFORMAT="%d/%m/%y %T"' >> ~/.bashrc


Dualboot Windows 10 and Ubuntu with SSD + HDD

Installing / on the SSD including /home, then making symlinks to the HDD, is slightly easier than installing /home on the HDD. Moreover, most I/O will be to small files like browser cache files, which will remain on the SSD, so you will have the benefit of the higher speed of the SSD. It is very well possible to put the entire /home on the HDD, it is just slightly trickier.

As I see it, you have plenty of space on the HDD. Use a couple of 100's Gb for a separate partition which is going to contain your real Music, Pictures and Video folders. Make a mount point for it:

sudo mkdir /mnt/myhdd

and mount it:

sudo mount /dev/sdb1 /mnt/myhdd

(replace /dev/sdb1 with the actual partition). If that works, include a line in /etc/fstab to automatically mount the partition after a reboot.

After installation, you will have an empty folder /home/user/Music. Remove it:

rmdir ~/Music

and make a symbolic link instead:

ln -s /mnt/myhdd/Music ~/Music

Do the same for Videos, Pictures, etc.
You could even make it an NTFS partition so it can be accessed by Windows.  However, you should then disable fastboot on the Windows system, otherwise the NTFS partition may be left in a condition that prevents Ubuntu from accessing it.


Is there a CLI webcam image grabber that works with a video4linux2 device?

From here
Streamer

Streamer (http://linux.bytesex.org/xawtv/) is a versatile program that allows a
capture from a webcam or video device using only the command line. It may be offered
in your Linux distribution's Xawtv package. To install streamer try

# sudo apt-get install xawtv

To take a standard JPEG picture from the command line where the camera is accessed
through /dev/video0:

#streamer -c /dev/video0 -b 16 -o outfile.jpeg

Where > -b is the number of colors (in bpp,whether 15, 16, 24 or 32)
& -o is the output filename in the current directory

If you are going to capture multiple images be sure to append the output file name
with zeros, as streamer can name the capture files in sequence, i.e., -o
outfile000.jpeg becomes outfile001.jpeg, outfile002.jpeg, and so on.

From comments: streamer is not included in the xawtv package, sudo apt-get install streamer


I actually found it here and here, and works also on 15.04.

In your home directory type

sudo updatedb -U $HOME

the sudo seems necessary as it tries to create a temp file in /var/lib/mlocate/mlocate.db ⇒ odd


LXAppearance is the culprit after all. See https://bbs.archlinux.org/viewtopic.php?id=125540

I tried copying the configuration file created by it to .config/gtk-3.0. After restarting gnome-terminal, the menus disappeared completely (or to be precisely everything is nearly zero-sized, and there is text). After commenting the .config/gtk-3.0/settings.ini line-by-line the culprit is gtk-font-name. Anyhow, this proves that gnome-terminal is a GTK3 app which does read the settings.

Solution  was to install gnome-themes-standard and edit .config/gtk-3.0/settings.ini to  say "gtk-theme-name=Adwaita" (it is the only theme in the package, but it suits me fine).

Final remark: confusingly in the directory /usr/share/themes many themes have gtk-3.0 subfolder without being GTK3 themes. I hope it is of help to someone.


One of the pains in having a dual-boot set-up with Windows and Ubuntu is suddenly realising you need to access a file on the other OSs partition.

In Ubuntu this is easy as Windows partitions can be mounted, read and written to out of the box – no configuration needed.

But the other way round? Well that’s a bit more complicated..

Ext2Explore
One tool I’ve long made use of to nab the odd file from my Linux partition when Windows-bound is  ‘ext2explore’.

The open-source ‘Ext2explore’ utility allows you to browse a Linux partition – be it Ext2, ext3 or ext4 – from within Windows, giving you the options to ‘save’ any files needed to a location of your choosing within Windows.

It’s not perfect, but if you’re forgetful or unable to access your Linux partition for whatever reason it’s a darn-well handy thing to have around.

Where to get it
Ext2Explore can be downloaded, for free, at sourceforge.net/projects/ext2read/.

How to run it
Ext2Read doesn’t come with a typical Windows installer. Instead you just unzip the archive, enter the folder and run the ‘ext2explore’ programme inside.

In Windows Vista and Windows 7 you will need to right click on this launcher and choose ‘Run as Administrator’.


New to this, want to install Cairo Desktop

The easiest way to install Cairo Dock is to start the Software Centre and search for Cairo, this will install the software as it should be. Then you can set it up how you want it set up, this nearly bought me to tears :)

Once it is set up and running and as you want it to be, if you want to play with Terminal, take a look at some of the commands that are available to you here


How to stop bzr from using ssh (asking a password) for downloading?

You can use different branch URLs for push and pull. First check the current related branches with bzr info:

$ bzr info
Standalone tree (format: 2a)
Location:
  branch root: .

Related branches:
    push branch: bzr+ssh://somehost.example.org/home/user/foo/
  parent branch: bzr+ssh://somehost.example.org/home/user/foo/

To switch any of these, just issue the push or pull command with the --remember option, such as:

$ bzr pull --remember http://somehost.example.org/~user/foo/

After that, you can verify the new setting with bzr info again.


HP EliteBook 840 G6 Sound is not recognized only dummy device

Due to; https://bugs.launchpad.net/ubuntu/+source/linux-oem-osp1/+bug/1864061
echo "options snd-hda-intel dmic_detect=0" | sudo tee -a /etc/modprobe.d/alsa-base.conf

sudo reboot


How do I execute a file from a FAT USB drive?

Because of limitations of the FA32 file system, you can't.

Now, you can cheat:

either call sh etoys.sh instead of ./etoys.sh
if you want, you can even create another script (that would lie on your hard drive, for example) that simply calls your script on the USB drive:

#!/bin/bash
sh /media/USB/etoys.sh


There are several advantages to GPT:

Supports disks larger than 2TiB.
Supports partitions larger than 2TiB.
Supports more than four partitions, with no distinction between primary, extended, and logical partitions.
Uses GUIDs as type codes, which means there's less risk of conflicting/duplicate codes.
Uses LBA addressing exclusively, compared to MBR's dual use of LBA and CHS. (Even on MBR, CHS is useless on disks over about 8GB, though, so there's little risk of real conflict on modern hard disks, which are much bigger than this.)
Provides duplicate partition table structures at the start and end of the disk, which makes recovery from some types of user errors, bugs, and disk damage possible.
Provides checksums of important data structures, which enables detection of some types of partition table damage.
Provides a UTF partition description field, so you can give your partitions names. Note that this is independent of the name of the filesystem contained in the partition.
Is used natively by EFI/UEFI firmware.

Note the difference between a tebibyte (TiB; 1024^4 bytes) and a terabyte (TB; 1000^4 bytes). The former are IEEE-1541 units, whereas the latter are SI units. For most disk measurements, IEEE-1541 units are more natural. Some documentation and software (especially older stuff) mis-applies SI suffixes to IEEE-1541 measurements, which is confusing.

Most of these advantages are minor ones for most installations. The two most important advantages are the fact that GPT is the natural partitioning scheme for EFI and the lack of primary/extended/logical distinction. The other GPT advantages combined are worth noting, but are not overwhelming issues for most people.

Most computers introduced since mid-2011, including the vast majority of systems that shipped with Windows 8 and later, use EFI firmware. If you boot such a computer in EFI mode (rather than using the CSM, which enables BIOS-mode booting), using GPT is something of a default. If you boot (or dual-boot) Windows in EFI mode, using GPT is required (it's a Windows limitation). IIRC, Ubuntu won't install to an MBR disk in EFI mode, either, but you could probably convert partition table type and get it to boot after installing it. Booting from an MBR disk in EFI mode is poorly tested, though, and might fail on some EFIs.

The primary/extended/logical distinction of MBR is an awkward hack that was created in the 1980s to get around the four-partition limit of MBR. GPT defaults to supporting 128 partitions, but that limit can be raised if it's absolutely required. MBR logical partitions are no slower to access than primary partitions, but they are more prone to damage because of the fact that they rely on a linked-list data structure that spans multiple sectors scattered throughout the disk. The biggest problem is simply dealing with hassles like running out of primary partitions or handling partition resize operations that involve both primary and logical partitions (and that therefore also requires resizing an extended partition, which is an extra operation -- and an extra chance for something to go wrong).

If you're booting in BIOS mode on a sub-2TiB disk, it's probably best to stick with MBR, simply because there are some BIOSes that don't react well to booting from GPT disks. Such problems can usually be worked around, but it's easier not to run into the problems in the first place. Using GPT on a BIOS-based computer will also prevent you from installing Windows on that system. If you know what you're doing and want to use GPT, though, using GPT in BIOS mode for an Ubuntu installation is do-able, and I won't discourage you from doing so -- but if you run into problems you may need to troubleshoot it.

As most modern computers use EFI, though, GPT may be semi-required -- if you boot in EFI mode. If you use BIOS/CSM/legacy mode on such a computer, sticking to MBR is still preferable, for the reasons just noted. FWIW, my recommendation at this point, if you've got the choice, is to disable BIOS/CSM/legacy support and use EFI mode exclusively on EFI-based computers. This simplifies the boot path and makes it less likely that you'll run into problems. The trouble is that there's a lot of bad advice out there to do the contrary, which creates more problems than it solves, in my estimation. (A search on this site, for instance, reveals numerous problems caused by cross-mode OS installations and other issues related to using BIOS/CSM/legacy mode on an EFI-based computer.)

If you've got an over-2TiB disk, you pretty much must use GPT. The main exception to this is if the disk uses a 4096-byte logical sector size, which raises the 2TiB MBR limit to 16TiB. Some external disks do this, and I've heard of some high-end internal disks that do it, too. (Note that many disks have 4096-byte physical sectors and 512-byte logical sectors. They have the same 2TiB MBR limit as disks with 512-byte physical and logical sectors.)


ping to server located on the same machine

Using an ICMP ping would never be of much use when testing to see if an HTTP server is running correctly.  Instead you need to make an HTTP request and verify that it is correct.  A popular technique is to use curl or wget, and check for text that you know should be in the reply.


Is It Possible To Recover A Partial LVM Logical Volume?

[EDIT: If you are unfamiliar with LVM, please read this overview or at least the Wikipedia page about it.]

LVM splits its Physical Volumes in slices called "Physical Extents" (PE). You can check which Logical Volumes have PEs allocated in the PVs that you still have by issuing this command:

pvdisplay -m

Which outputs something like this (showing one PV here only):

--- Physical volume ---
  PV Name               /dev/sda3
  VG Name               htpcvg
  PV Size               929.27 GiB / not usable 18.71 MiB
  Allocatable           yes
  PE Size               32.00 MiB
  Total PE              29736
  Free PE               1190
  Allocated PE          28546
  PV UUID               7SfjbY-3dy4-UDeB-iSEL-3R9Y-vvnv-O7m9jr

  --- Physical Segments ---
  Physical extent 0 to 28545:
    Logical volume      /dev/htpcvg/home
    Logical extents     29430 to 57975
  Physical extent 28546 to 29735:
    FREE

With this info you can know how much of your LVs is stored in that PV.

Then, if that information shows that you have some extents of your LVs' available, you can activate the VG that contains them with this other command (edit VolGroupName):
[EDIT: Please read the manpage]

vgchange -a y --partial VolGroupName

That should make your LVs "available", but faulty anyway (you won't be able to read missing PEs, obviously). To be safe, you could also make your defunct LVs read-only with lvchange -p r --partial /path/to/logical/volume

Now, given that you probably won't be able to mount the filesystems that reside in your partial LVs, you should copy what's left of them with ddrescue:

ddrescue -n /dev/mapper/yourVG-yourLV /file/for/the/dump ddrescue.log

And then do some forensic analysis on that dump. Here you have many options. Photorec is just one.


A "does not have a release file" error in a PPA means that there are no packages for your release of Ubuntu. So stop trying to use it.

Disable or delete that PPA.


Yes you can use mono

For a nice IDE to work in try monodevelop:

sudo apt-get install monodevelop

This will also pull in all the necessary runtimes needed.


12.04.3 can start only after I press "resume" in rescue mode (every boot) - problem with Nvidia driver

The proprietary nvidia driver should be used without KMS. You have to edit the /etc/default/grub file, use your favourite text editor (vi, nano, gedit, etc.):

sudo vi /etc/default/grub

Change the GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" line to the following:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nomodeset"

Save the file, then run sudo update-grub Then reboot, and it should work.

If it still doesn't solve it, then remove also "quiet splash" from the previous line, and again sudo update-grub. (This will disable the graphical boot screen.)

The recovery booting did work, because the recovery menu entry had the nomodeset parameter.


bash: error in export command that bash: !st: event not found

Use ' instead of " and your variable export will work.

The '!' is interpreted as a history invocation, so your command history is searched for 'st' which causes an 'event not found' message.

You can verify this with the following sequence:

ls /etc
a="k!ls"
b='k!ls'

and then:

$ echo $a
kls /etc
$ echo $b
k!ls


Configuring Creative Sound Core 3D (CA0132) in Ubuntu 20.04LTS

In Alsamixer the HP Speaker setting was muted, preventing audio.


Resume from Suspend fails on Samsung X360 laptop

So today I finally had the idea to simply downgrade my kernel. I went back to 2.6.35-28-generic. This fixes the resume problem. Also it is only a work-around and brings other problems with it. For me the resume is more important. Maybe this helps other people with similar problems to narrow the causes.


How to add accents etc to letters using the "English (UK)" input source?

If you look at the UK keyboard layout chart:

you'll see a ton of tertiary and quaternary symbols per key.

These are used with the Right Alt for the tertiary and Right Alt+Shift for the quaternary ones, so Right Alt+Shift+M will give you °, so you can now write: -40°C = -40°F


Extremely slow graphical desktop startup process Ubuntu 18.10

I have completely reinstall the system, but this time I have chosen Lubuntu. The problem has been disappeared.

I am keeping this question opened because it seems the issue affects some users and there have been not any resolution yet.


networking.service raises or downs the network interfaces configured in /etc/network/interfaces, that is, those network interfaces which are not managed by NetworkManager. If you look into /lib/systemd/system/networking.service you will see that all it does is ifup or ifdown depending on whether it is to be started or stopped.

It is a oneshot unit, which means that it does its thing and exits, it does not remain running in the background.

By default all network interfaces are managed by NetworkManager and networking.service does nothing. On a server it is quite common to assign a static IP address to one or more interfaces by editing /etc/network/interfaces, and in this case those interfaces are no longer managed by NetworkManager and they are raised or downed by network.service.


There is a bug report at MathWorks for this specific bug. In the bug report, there are 2 workarounds proposed:

wmname workaround:

Install wmname by running sudo apt install suckless-tools
Run wmname LG3D in the terminal
Run matlab & to start MATLAB

_JAVA_AWT_WM_NONREPARENTING workaround:

Run export _JAVA_AWT_WM_NONREPARENTING=1 in the terminal
Run matlab & to start MATLAB


How do I get the sound working on a Dell Dimension 5000?

Have you run updates, to complete installation?

Have you checked for 'alternative drivers'?

IF SO, then start sound troubleshooting:

Wiki: DebuggingSoundProblems


How to hide dotted files when they reappear after closing file manager?

There are better ways to protect confidential files. Anyone with some basic knowledge of linux can find and read hidden files.

I suggest that you create an encrypted directory or encrypted partition, and store your confidential data there. You can do it manually.

Maybe the best alternative is to install a new version of Ubuntu and use 'LVM with encryption' alias 'encrypted disk', which is an automatic alternative at the installer's partitioning page.

The following link can help you with such an installation,

Install (entire disk with lvm and encryption) in Ubuntu Desktop amd64 in Xenial 16.04.4


Update /etc/crontab to quit a process as root every other minute during working hours

It's not possible to set this up in just one crontab line (at least I don't know a way right now) so you have to setup two jobs:

one for the hours 8-11 and 13-15 that runs every minute (i.e. 08:00-11:59 and 13:00-15:59)
and one for the minutes 31-59 in hour 12 (i.e. 12:31-12:59)

*     8-11,13-15 * * 1-6 /usr/bin/killall firefox
31-59    12      * * 1-6 /usr/bin/killall firefox

The 1-6 means monday to saturday

Add these to lines not to /etc/crontab but to root's crontab instead by issuing

sudo crontab -e

Change the command (killall …) to your needs.


@fossfreedom gave me a link to an answer, the answer is great, but didn't completely solve my problem. So I will put what I did to make my computer hibernate under ubuntu-budgie 17.04

Create Swap File (go to the next step if you already have a swapfile)

These commands create a formatted 4GiB swap file, mounted and added to /etc/fstab:

sudo fallocate -l 4g /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
echo '/swapfile swap swap defaults 0 0' | sudo tee -a /etc/fstab

Install Userspace Software Suspend (uswsusp)

sudo apt install uswsusp

Verify Swap File Partition

sudo findmnt -no SOURCE,UUID -T /swapfile
> /dev/sda1 11cc33ee-1234-abcd-1234-ddeeff112233

Configure uswsusp

This will create /etc/uswsusp.conf and recreate initramfs using those details:

sudo dpkg-reconfigure -pmedium uswsusp

Yes to 'Continue without a valid swap space?' (Wizard hasn't set swap file yet.)
Select the partition that the swap-file resides on, cross-reference with details from findmnt above. (Note: not the swap-file itself)

Create the file /etc/initramfs-tools/conf.d/resume if it doesn't exist, and put your swap_id in it like this :

sudo -s
swaplabel /swapfile
> UUID:  81bb07cd-d495-4733-be81-3447f9161f33
echo "RESUME=UUID=81bb07cd-d495-4733-be81-3447f9161f33" > /etc/initramfs-tools/conf.d/resume
update-initramfs -u

Test Hibernate

sudo s2disk

Use s2disk with systemd Hibernate

sudo cp /lib/systemd/system/systemd-hibernate.service /etc/systemd/system/

Edit the new file:

sudo gedit /etc/systemd/system/systemd-hibernate.service

Replace the last line of the file (starts ExecStart=...) with the following:

ExecStart=/usr/sbin/s2disk
ExceStart=run-parts -a post /lib/systemd/system-sleep

Update the systemd daemon and test hibernate:

sudo systemctl daemon-reload
sudo systemctl hibernate

Allow hibernation from top panel buttons

Open the file :

sudo gedit /var/lib/polkit-1/localauthority/10-vendor.d/com.ubuntu.desktop.pkla

and find both sections :

[Disable hibernate by default in upower]
[Disable hibernate by default in logind]

and change both values from no to yes :


Batch low quality compress +1TB of images and videos in multiple folders

With ImageMagick's convert command, something like:

convert input.jpg -quality nn output.jpg

You can also resize them to something smaller (here, 2000px in the margest dimension) with a little bit of sharpening to compensate the slight blurring introduced by the scaling down (unless the pictures are already heavilty processed (smartphone pictures):

convert input.jpg -geometry 2000 -sharpen 0x1.0 -quality 85 output.jpg

convert produces a new file (so you can use it as an evolved cp command). Otherwise from the same package the mogrify command does everything in place.

As an amateur photographer: just don't. Getting a low quality version of a high quality picture is easy. The revers is nearly impossible. What is 1TB nowadays? I'm not even sure it will take less time to recompress and backup tan to back them up directly (unless you back up to the cloud).


Probably the simplest thing is to start a new bash shell and source the setup file, then exit from the shell to get back to your previous environment. Ex.:
$ printenv grep '[bf]oo'

$ bash --rcfile setup_foo.sh
$ printenv | grep '[bf]oo'
MODE=foo
PATH=/opt/bin/tool_foo/:/home/steeldriver/bin:/home/steeldriver/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin

$ exit
exit
$ printenv grep '[bf]oo'

$ bash --rcfile setup_boo.sh
$ printenv | grep '[bf]oo'
MODE=boo
PATH=/opt/bin/tool_boo:/home/steeldriver/bin:/home/steeldriver/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin

$ exit
exit
$ printenv grep '[bf]oo'


Why can't I use an OpenSSL key pair with ecryptfs?

You're not missing anything. Ubuntu, and other distros, could not ship the OpenSSL key module due to licensing issues with the GPLv2-licensed libecryptfs.

The copyright holders to the OpenSSL key module recently added an exception that should allow distros to ship the OpenSSL key module.

You can probably expect the key module to show up in the Ubuntu release after the 12.04 release. Note that the time frame is still undecided.

In the meantime, you could compile ecryptfs-utils yourself and copy the libecryptfs_key_mod_openssl.so to the appropriate location (likely /usr/lib/ecryptfs/). If you decide to do that, please keep in mind that it is not tested and you will be unsupported.


Had the same problem. Fixed it by addgroup sudo as root, and then changing the Group ID to 201 in /etc/groups. (Pick an unused number < 1000)


If the hosts file does not exist, then start with a new one.

I would run ...

sudo su
gedit /etc/hosts

Then inside the new file, add the following:

127.0.0.1    localhost
127.0.0.1    {whatever name you have for your machine}

# The following lines are desirable for IPv6 capable hosts
::1          ip6-localhost ip6-loopback
fe00::0      ip6-localnet
ff00::0      ip6-mcastprefix
ff02::1      ip6-allnodes
ff02::2      ip6-allrouters

Save the file first and then you can go back to add to it.

If it gives errors trying to do the above, then it is not as straightforward.


Yes, you can do that. Boot you virtual server with clonezilla and create .img.
With colonezilla you can transfer .img directly to you host via ssh.
Only what can make problem is specific drivers on desktop when restore .img file.


Assigning sounds on startup and shutdown

If you want another sound during login you can do it this way from a terminal sesson:

cd /usr/share/sounds/ubuntu/stereo

replace the file desktop-login.ogg with the soundfile you want. You can do it like this (including backup):

$ sudo cp desktop-login.ogg desktop-login.ogg.old
$ sudo cp ~/Downloads/dekstop-login.ogg

If your new file is inside your home's Download directory. I have not seen a default application where you can do this.

And yes, you can create a custom sound from for instance a music clip with audacity. Just make sure you save it as ogg and do not make it too long.

You can also do it like this. From command line

$ gksu nautilus

This will open Nautilus as root. Now navigate to your new file, right click and copy it. Navigate to

/usr/share/sounds/ubuntu/stereo

and click on desktop-login.ogg, press F2, and add .old to the name. Then click on some free space, right click and choose paste.


Are you sure FTP is the solution you would like to use?  Have you heard of SCP?  SCP is just like FTP in that it is used to transfer files, but it is done over SSH, which can make it easier to administer and allows you to more securely transfer files.

If you decide to try SCP, you would want to add your user to the www-data group (as I imagine it has +RW access to /var/www/) and then execute the following command:

scp ~/Projects/site/index.html user@host:/var/www/

If you're 100% sure you want to use FTP, please let us know which FTP daemon/server you are using to better help you configure it to your purposes.


How do I change the default shell used in Byobu (tmux)?

Put the following in your $HOME/.byobu/.tmux.conf:

set -g default-shell /usr/bin/zsh
set -g default-command /usr/bin/zsh

Full disclosure: I'm the author and maintainer of Byobu.


The best solution for you is to install Ubuntu server which has no GUI and is used by connecting via SSH from a remote computer(this is the recommmended way)


Before you start the process below, I suggest you backup your user files to an external hard disk, a USB flash drive, or a cloud storage service like Dropbox.

Assuming you have your Ubuntu partition beside the Windows 10 NTFS partition, like in this picture
,
you first have to boot into Windows 10, and shrink the main Windows partition from there.

There are instructions on how to do that all over the internet, one here. You will see the new space as a black box in Disk Management marked as Unallocated Space.

Now boot into Ubuntu from a live USB, assuming you have one from which you installed your Ubuntu. If not, create one (again?) via pendrivelinux.com and use your existing Ubuntu disk image or download a new one.

You should have GParted installed on your live USB, if not you can get it in the Ubuntu Software Center, Synaptic Package Manager, or by running sudo apt-get install gparted from a terminal window.

Run GParted, find your hard disk Ubuntu main partition, and expand it. If you don't know how, you can find instructions on it here.

Hope that helps, if not just leave a comment.


I had this exact same issue. This forum post solved it for me.

It almost sounds like you have a package missing. Try installing it:

sudo apt install gvfs-backends

If it says it's already installed, try reinstalling with

sudo apt --reinstall install gvfs-backends


How to free up space taken by windows 7 virtual machine on ubuntu host?

Virtual Machines store their own data on disk as individual files outside of the VirtualBox (or VMware, depending on your setup) configuration files and folders.

As such, you need to find where you initially saved the virtual machines (probably somewhere inside your /home/$USER directory), and delete the actual folders and files that were created for the VM.  That will free up the space on disk.

That will free up your space.  It might be in a folder labeled "VirtualBox VMs" or "My VMs" or "Virtual Machines" or similar in your home folder, but there's no way for me to tell from this system.


I mangled my own logging configuration files to make this more compelling. It took me a bit to figure out that UCF purging piece. I kept getting:

  Not replacing deleted config file /etc/rsyslog.d/50-default.conf`

... even after export UCF_FORCE_CONFMISS=1... ucf -p did the trick, but I don't know why it came to that.

sudo mv -v /etc/rsyslog.conf ~
sudo mv -v /etc/rsyslog.d/50-default.conf ~
sudo ucf -p /etc/rsyslog.d/50-default.conf
sudo apt-get -o DPkg::Options::="--force-confmiss" --reinstall install rsyslog


Check the release directory for the ".manifest" files which list every package (eg. ubuntu-core-12.04.4-core-amd64.manifest). Ubuntu Core is just a minimal install of Ubuntu, you could make something very similar yourself by running:

mkdir chroot
debootstrap --arch=amd64 trusty chroot http://archive.ubuntu.com/ubuntu/

Ubuntu Core is just a minimal rootfs of around 60MB size whereas Ubuntu Mini Remix is a 200MB iso live image.


Do malicious web sites ever exploit vulnerabilities in Linux clients?

After adding my comment, I was very intrigued, and decided to do some research. Now all of this talk of malicious websites is a big "if." What I mean by this is that there are many factors that go into any malicious website. These include but are not limited to the following:

1) Ubuntu (Linux) Compatible - As unfortunate as it is, most PC users these days are running one version or another of Microsoft Windows, and because of that, most malicious programs in general are made to affect and attack the Windows operating system. As you can see here however, there are still people out there developing attacks against Linux users. Back to the point, because of this, over 95% of malicious websites that are made will not affect you! (You being an Ubuntu/Linux user)

2) User "stupidity" - First off, the user will have to either mis-click a link, visit an "unsafe page", or click on an advertisement of some sort to get to one of these pages. Once there, the website cannot do much on its own. On some level, the user will have to be prompted to either
A - Download a file or
B - (If the website is coded well enough to slip it into the background) The user will be prompted if any changes are attempted at changing the system.

So do your best not to visit said sites, and if you do, get some browser protection.

3) Intensity And Actual Function of Malicious Software - This is probably the one you will have to worry most about. Because Linux is a more in depth operating system, the system tends to be spread out more, which may make it hard to track down exactly where this Malicious Program infested (if at all). However, this is also a good thing. For example, in the link above, the program manifests as A Mozilla process. I Personally use Chrome, and have uninstalled Mozilla, so if I even so much as see a glimpse of the logo, I will start to worry. This can also make it easier to track and destroy the infest.

4) Protection On Computer - This one although looked past very often is probably the most important. If any of you reading this remember the crisis with MACs and their "great protection," skip ahead. If not, when the Mac-book laptop was first introduced, and the Apple Operating System was first being born, viral infestations were in their early stages, as little baby computer-bugs. When Apple announced that their laptops and computers would have (to paraphrase) "Next-To Perfect Antivirus," people were ecstatic. Because of this pre-installed anti-viral defense, the everyday user refrained from using any type of other software to protect their computer. As a result, once the Apple anti-viral software was cracked, millions of dollars of damage could be dealt from a remote source. Although that story may seem off topic from the question, it is exactly why Ubuntu and Linux in general in starting to get targeted by hackers. Because Ubuntu is famous for being safe and secure, people don't bother to get any antivirus software, leaving them open to attacks. So please, PLEASE, get some damn antivirus.

5) Elongated Periods of Time - Although Trojan viruses, and some minor bugs can manifest within a matter of minutes, some viruses may take hours, or even days to grow to their full size and take over your computer (sometimes literally.) To prevent this, you can schedule scans to happen on your computer. Depending on how time you spend browsing the web, you can adjust this accordingly. I personally have mine set to run every hour, and the best part is that I don't have to do anything! Just make sure to always play it safe. If you think you may contracted a virus, just do a scan immediately, and hey, you can always come to AskUbuntu for help solving it!

As to more thoroughly answer the question of "WIll people bother to go after Linux users?", yes. Unfortunately, every operating system is vulnerable to attack, and with a recent (past 1-2 years) surge of people using Linux, there have been more attacks on said people. Although many people do experience viruses on a daily basis, the "documented cases" that you are asking for do not really exist. If you were to see the official list, you would see that most viruses have been dealt with by now, but remember, more are made/updated every day.


(Little) problem with .desktop configuration file

question does the desktop entry execute correctly?  if it does then right click on the icon and select properties and try changing the icon there.
good luck.


How to eliminate or disable the GNOME3 top panel?

You can remove panel using gconf-editor
Run

 gconf-editor

And navigate to desktop>gnome>session>required_components>panel and remove gnome-panel

Close the gconf-editor window and Reboot.


GTK+ uses box-based sizing, just like CSS and other modern tools. Also, a VBox will have all its children oriented vertically. You won't be able to add anything to the right.

You can use the GtkLayout for absolute positioning, or a GtkGrid to create a grid-based layout (which is appropriate for calculator).


code --verbose not launching VS CODE Showing Error: ENOSPC: no space left on device, watch '/snap/code'

In my case I found the answer at a GitHub thread. As j-o-d-o commented:

  Increasing max user watches resolved the issue:

>> sudo sysctl fs.inotify.max_user_watches=16384

  Was at 8192 originally


Internet Proxy settings don't work in terminal. How to configure them?

Here is a link to a python program named UBPROXY . Given below are the steps to set proxy Authentication.

http://code.google.com/p/ubproxy/downloads/detail?name=ubproxy

Download this program. Then open your terminal and run these commands:

cd ~/Downloads

(Presuming that your download exist in this directory)

chmod +x ubproxy
sudo ./ubproxy


Upgrade Ubuntu 12.04 to 14.04 fails (stopped at the command screen root)

Try the below command,

sudo apt-get update

sudo apt-get dist-upgrade

sudo do-release-upgrade -d

Hope this helps !


Fix package post-installation script subprocess returned error exit status 10 for libpaper1:amd64

I just had the same issue and here's what I did to fix it...
sudo rm /var/lib/dpkg/info/libpaper1*
sudo dpkg --configure -D 777 libpaper1
sudo apt -f install

Hope it helps.


Changing Wallpaper on 12.04 Login Screen

Just change the background on the desktop, choose one of the pre-configured images, and that will do it.

If you want to use your own image then click on the + sign, add your image, and then change the permissions

on the image for group read and write and other to be read only.

And that will do it.  No need to use anything else.


VirtualBox Toolbar is hidden! How to show it?

To re-enable the Toolbar right-click on the bottom line, then select and tick the Show Toolbar entry on the pop-up menu:

  Do not disable both, the toolbar, and the statusbar.

When running Unity desktop the only way to restore them is to manually edit the VirtualBox.xml file located in ~/.config/VirtualBox or ~/.VirtualBox.

Search for the following lines

 <ExtraDataItem name="GUI/Statusbar" value="false"/>
 <ExtraDataItem name="GUI/Toolbar" value="false"/>

to replace "false" with "true".

Please make a backup of this file before you edit it, as all informations on your VMs are stored there as well. No instance of Virtual Box or VirtualBoxManager must run on editing this file because it will be overwritten otherwise.


The Medibuntu Project has come to an end - what do I do now?

By now almost all the medibuntu packages have been already superseded with packages from the main repos (restricted, universe, multiverse), so the task is to eliminate the traces of medibuntu.

You would probably be better off installing aptitude before hand (see below).

As root, do the following to forget medibuntu:

aptitude purge medibuntu-keyring
rm -f /etc/apt/sources.list.d/medibuntu.list
aptitude update

Now, to purge the packages which come from medibuntu, do this:

aptitude purge $(dpkg-query -W -f='${PackageSpec}\t${Maintainer}\n' '*' |\
  grep medibuntu-maintainers@lists.launchpad.net |\
  cut -f1)

You might have to select an alternative dependency problem resolution (e.g., aptitude might suggest that you remove a 100 packages if you purge a medibuntu library libavutil; say no and it will offer to install the same library from an alternative source).

This means that you will probably be better off using aptitude than apt-get for this task because the former offers the alternatives for dependency problem resolution.  See also

Aptitude vs. apt-get: Which is the recommended (aka the “right”) tool to use?
Is aptitude still considered superior to apt-get?


How to set version numbers and package file names via dpkg-buildpackge for automated builds on a build server?

Have a look at git-buildpackage:

  Customizing snapshot numbers

  If the auto incrementing of the snapshot number doesn't suite you needs you can give any python expression that evaluates to a positive integer to calculate the new snapshot number:

gbp dch -S -a --snapshot-number=1
gbp dch -S -a --snapshot-number='snapshot + 2'
gbp dch -S -a --snapshot-number='os.popen("git-log --pretty=oneline | wc -l").readlines()[0]'
gbp dch -S -a --snapshot-number=`git-log --pretty=oneline debian/0.3.3 | wc -l`

  You can also add the snapshot-number calculation to gbp.conf:

[DEFAULT]
snapshot-number = os.popen("git-log --pretty=oneline | wc -l").readlines()[0]


How to get a higher resolution with projector (unknown display)?

The VGA problem miraculously solved itself after I plugged in a DisplayPort connector.


Apt-get ignoring a repo even if I clear the cache

The "Ign" just means that there is nothing new from the repo that needs downloading and you're up to date.


How to install in EFI mode with Encrypted LVM?

First, it's not 100% clear that you booted the installer in EFI mode. If it booted in BIOS mode, it would try to install grub-pc (for BIOS-based systems), which wouldn't work if your firmware is set to boot the hard disk in EFI mode. I doubt if this is the problem, but I thought I'd toss it out as a possibility. You can check your boot mode by dropping to a shell and looking for the /sys/firmware/efi file; if it's present, you've booted in EFI mode. If not, you've probably booted in BIOS mode, although that's not 100% certain.

In any event, at this point your best bet is to do a manual installation of an EFI boot loader. IMHO, GRUB 2 (which is Ubuntu's default) is the worst possible choice; it's flaky and unreliable on EFI systems, in my experience. The easiest to get working is likely to be either ELILO or Fedora's patched GRUB Legacy. If you want to use a 3.3.0 or later kernel, it includes its own built-in EFI boot loader, which is quite reliable and can be very easy to use if paired with rEFInd. My Web page on EFI boot loaders describes all the options and includes installation instructions. Detailing them all here would be impractical.


Running an executable jar file when the system starts

You can do this by adding the command to the end of /etc/rc.local you'll have to use sudo access to edit this file.

So this command should work for you , replace your_executable.jar with your actual jar file.

sudo echo 'java -jar your_executable.jar' >> /etc/rc.local


getting list of installed programs and installing them again on another drive

Alternatively you can use Aptik to do this task using a GUI instead a CLI (personally I prefer the CLI method described above, but here you have another possible solution). Aptik allows you to Backup & Restore your favourite App's, PPA's and many more!

You can get Aptik from official PPA using this simple line:

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

Or:

sudo apt-add-repository -y ppa:teejee2008/ppa
sudo apt-get update
sudo apt-get install aptik

Here you have more info about Aptik:

I used several times in university computers (I'm the SysAdmin) after a fresh Ubuntu installation and this tool help me to save a lot of time.

Also I recommend you Timeshift to make an OS image backup from same author (Clonezilla randomly failed when restoring an HDD image disk into a SSD and really), but also I recommend you Ubuntu AfterInstall wich you can to install a lot of useful software (restricted extras, VLC, etc...) using only a few mouse clicks.


Resize plasma popups

Plasma popups ( calendar, kickoff, device notifier, ... ) can be resized by holding  Alt key pressed and dragging with the Right Mouse Button.

The size will reset when the plasmashell restarts (logout): https://bugs.kde.org/show_bug.cgi?id=332512


There is no "command" button on non-mac keyboards. So you can't use a key that doesn't exist ;)

However, the good news is that almost all of these shortcuts are essentially the same, you just need to use Ctrl instead of ⌘. So:

app exit is Ctrl+Shift+q (OK, this one is a little different)
copy is Ctrl+c
paste is Ctrl+v
select all text is Ctrl+A

It is also trivial to change these. Click on the settings icon on the top right, then System Settings -> Keyboard -> Shortcuts -> Windows. There you can assign whatever you like.


I'm surprised to hear that desktop effects have any impact on the functioning of your applications. I wouldn't be surprised to hear that wine flatly ignores your font size settings.

Anyway - Virtual Magnifying Glass and KMag look like they will do the job without requiring desktop effects. (the latter can be installed from Ubuntu Software Center)


Open a terminal and type sudo gedit /etc/default/grub

Modify the line: GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" to GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_backlight=vendor"

Then run sudo update-grub and reboot.

If it doesn't work try changing the same line to GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux acpi_backlight=vendor" and run sudo update-grub again.

This works for some backlight problems.


On each sudo command I get [sudo] password for root:

Use the instructions on this answer to access a recovery shell.

Once you have your file system mounted with write support just move the file /etc/sudoers to another place and restore the original configuration with apt-get install sudo.

Also, if you do not remember the password for your user you can take the chance and use the command passwd yourusername to change it on the recovery shell.


I am not sure why, but apparently the lockup corrupted something in the gnome-shell directory. To fix I renamed the file .local/share/gnome-shell to ./local/share/gnome-shell.old. I then rebooted the computer.


How do I setup tty autologin in Ubuntu which is running Upstart

There is no /etc/inittab in Ubuntu, because Ubuntu uses upstart to define startup services and runlevel. And this has not started from the last release of Ubuntu, but a long time ago.

Anyway, you can still use inittab, simply create one. I report a passage from /usr/share/doc/upstart/README.Debian.gz:

How do I change the default runlevel?
-------------------------------------

If you have an /etc/inittab file, edit it.  Locate the following line:

    id:N:initdefault:

Where N is the default runlevel, change this to match.

Most people won't have that file, you can edit /etc/init/rc-sysinit.conf
and change the following line:

    env DEFAULT_RUNLEVEL=2

but bear in mind that Ubuntu do not use standard runlevel meaning as other linux distros/unix os. Old standard was:

0 - shutdown
1 - single user mode
3 - multiuser text mode
5 - multiuser graphical mode
6 - reboot

but Ubuntu uses:

0 - shutdown
1 - single user mode
2 - multiuser graphical mode
6 - reboot

Finally, if you want to have a virtual terminal with automatic login, then modifying the exec line in tty1.conf seems the correct way, though I do not know mingetty, so cannot say if you used it correctly.


How can I get Apache SSL to work in 13.10 after upgrade?

Enable the module by copying the file:

cp /etc/apache2/mods-available/socache_shmcb.load /etc/apache2/mods-enabled/

That will handle the first error.

Then there is an error about SSLMutex, so replace that line of mods-enabled/ssl.load with
this instruction:

Mutex sysvsem default


I had the exact same problem, so I investigated.
The root cause is a JS error in /usr/share/gnome-shell/extensions/ubuntu-dock@ubuntu.com/dash.js: JS ERROR: TypeError: firstIcon is undefined (can be seen in journalctl /usr/bin/gnome-shell -f).
I edited the file in-place to make sure this was indeed the problem, and replaced:
        let firstIcon = firstButton.icon;

        // Enforce the current icon size during the size request
        firstIcon.setIconSize(this.iconSize);

with
        let firstIcon = firstButton.icon;

        // Enforce the current icon size during the size request
        if (firstIcon) {
            firstIcon.setIconSize(this.iconSize);
        }

ensuring that the execution is not stopped if firstIcon is undefined. Then I reloaded the gnome shell using Alt+F2 then r, and lo and behold, the issue was gone!
I haven't investigated the reason why firstIcon was null to begin with. Therefore, I don't know if I have corrected the issue or just one of its symptoms, so I'm not sure if this should be turned into a PR or just a documented bug-report.


Installing Ubuntu from USB - how to finish the installation

It's supposed to tell you explicitly when to remove the USB flash drive, but I think that, unfortunately, that message is not visible 100% of the time.
It's right when the live system shuts down. The best time to remove it is before rebooting. If you've rebooted already and you're in the live system again, then shut down, remove the USB flash drive, and boot your computer.
Assuming there were no problems during the installation, Ubuntu should be installed and working.
If It Still Doesn't Work
If the installation appeared to complete, but booting without the flash drive fails without detecting an operating system, this usually means the GRUB2 boot loader did not successfully install to the Master Boot Record. To fix this, boot from the USB flash drive, select Try Ubuntu (not Install Ubuntu), and reinstall GRUB to the MBR, using any of the techniques on either of these pages:

How can I repair grub? (How to get Ubuntu back after installing Windows?)
(This applies even though the cause of the problem is not a recent Windows installation.)

The Ubuntu help wiki section on repairing GRUB2.

If It Still Doesn't Work
Then it's necessary to collect more information to troubleshoot the problem. Boot from the USB flash drive, select Try Ubuntu, open a Terminal window by pressing Ctrl+Alt+T. Run:
sudo parted -l

Then select the text from the terminal, copy it to the clipboard, edit your question (or, for readers besides the creator of this question, ask a new question) and paste the text in. You can format it with the <$> tool in the Ask Ubuntu editing toolbar.


How do I uninstall paper theme from my computer?

To uninstall the 'paper' theme remove the following packages:

sudo apt-get remove paper-icon-theme paper-gtk-theme paper-cursor-theme

If you have used the provided PPA you can safely remove the PPA  with ppa-purge:

sudo apt-get install ppa-purge
sudo ppa-purge ppa:snwh/pulp

References:

Ask Ubuntu: How can PPAs be removed?


Fan Control with 13.10 and ASUS P8Z77-V deluxe motherboard

I tried steps which described on the following page, and those work with Ubuntu 15.04.

How to control fan speed?


Ubuntu Server 19.04 Not installing Ethernet firmware on Dell Poweredge R610

Your netplan file currently says:

# This file is generated from information provided by
# the datasource. Changes to it will not persist across an instance.
# To disable cloud-init's network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}

I suggest that you do exactly that. From the terminal:

sudo -i
echo "network: {config: disabled}"  >>  /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg

Next, let's amend the netplan file to add your configuration:

nano /etc/netplan/50-cloud-init.yaml

Edit the file to read as I suggest below to include your settings:

# This file is generated from information provided by
# the datasource. Changes to it will not persist across an instance.
# To disable cloud-init's network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}
network:
  version: 2
  renderer: networkd
  ethernets:
    eno1:
      dhcp4: true

Netplan is very specific about indentation and spacing. Please proofread carefully twice. Save (Ctrl+o followed by Enter) and exit (Ctrl+x) the text editor. Next:

netplan generate
netplan apply
exit

Reboot. You should be all set.

EDIT: If you prefer a statis IP address which is recommended for servers, I suggest that your /etc/netplan/50-cloud-init.yaml file be amended to:

network:
  version: 2
  renderer: networkd
  ethernets:
    enp3s0:
      addresses:
        - 10.10.10.2/24
      gateway4: 10.10.10.1
      nameservers:
          addresses: [10.10.10.1, 8.8.8.8]

Of course, substitute your details here. Follow with:

sudo netplan generate
sudo netplan apply

Reboot.

REFERENCE: Please see the many netplan templates at /usr/share/doc/netplan/examples.


I think it might be a false positive.  Try checking with rkhunter, because it gives fewer false positives.  To download  rkhunter, and for more detailed info on how to use it, See this site

If it come up clean, then you have reason for concern.

Try this as well:

rkhunter --check
update
sudo rkhunter --propupd
rkhunter --check

Source: The Rootkit Hunter project


You can now simply flip a switch in System Settings -> Accounts for any of your google accounts and it will take care of syncing your contacts (and calendar) for you.


Ubuntu 14.04.2 i386 boot hangs after installation but is fixed by using live USB's initrd.lz

Answering my own question here...

I am now able to boot into the system after including the radeon and radeonfb modules into the initramfs.

I followed this Ubuntu Forums thread, basically

find out the dependencies of radeon and radeonfb from
/lib/modules/$(uname -r)/modules.dep
create files named radeon under
/usr/share/initramfs-tools/modules.d/, and add radeon and the
dependent modules name as content. Do the same for radeonfb.
run update-initramfs -u -k all to update all existing initramfs/initrd on the system
make sure that the updated /boot/initrd.img-$(uname -r) has the
module by running zcat /boot/initrd.img-$(uname -r) | cpio -it |
grep -i radeon

Reboot

Now that I am able to boot, posting the lspci -v output of the APU video just for completeness sake

00:01.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Kabini [Radeon HD 8400] (prog-if 00 [VGA controller])
        Subsystem: Gigabyte Technology Co., Ltd Device d000
        Flags: bus master, fast devsel, latency 0, IRQ 48
        Memory at c0000000 (64-bit, prefetchable) [size=256M]
        Memory at d0000000 (64-bit, prefetchable) [size=8M]
        I/O ports at f000 [size=256]
        Memory at feb00000 (32-bit, non-prefetchable) [size=256K]
        Expansion ROM at feb40000 [disabled] [size=128K]
        Capabilities: <access denied>
        Kernel driver in use: radeon


this actually answered my question just fine, the most upvoted answer is perfect:
How to avoid using sudo when working in /var/www?


You should use sudo apt search gnutls or visit packages.ubuntu.com before trying to install it.

I guess what you want to install is:

sudo apt install gnutls-bin

Hope that helps!


Assuming your tablet is a CTL-4100WL, the linuxwacom device IDs list says that your tablet requires version 0.30 of the libwacom database in order to be recognized by the GNOME Control Center. Ubuntu 18.04 only ships version 0.29, however, which would explain why nothing appears. Ubuntu 18.10 has an updated version of libwacom but will still be affected by the stylus bug you've linked to. If I recall correctly, the upcoming Ubuntu 19.04 release should have that bug fixed as well.

Note: the previously-mentioned page also notes that version 4.17 of the Linux kernel is required to use the tablet over Bluetooth (only version 4.10 to use it over USB) but Ubuntu 18.04 only ships version 4.15. I assume you've installed the input-wacom driver to allow your device to work over Bluetooth.

Note 2: The GNOME Control Center currently has a known issue with button mapping on non-pro tablets. You may not be able to map all of the buttons and may notice that GNOME is confused about the physical location of the buttons that you can map.


How to combine multiple CSV files to one ods file on the command line. One sheet per original file

With perl:

#!/usr/bin/env perl
use strict;
use warnings;
use autodie;
# CPAN modules required:
use Spreadsheet::Write;
use Text::CSV;

my $xlsx_file = shift @ARGV;
$xlsx_file .= ".xlsx" unless $xlsx_file =~ /\.xlsx$/;
my $xlsx = Spreadsheet::Write->new(file => $xlsx_file);
my $csv = Text::CSV->new({binary => 1});

for my $csv_file (@ARGV) {
    my @rows = ();
    open my $fh, "<:encoding(utf8)", $csv_file;
    while (my $row = $csv->getline($fh)) {
        push @rows, $row;
    }
    $csv->eof or $csv->error_diag();
    close $fh;

    (my $sheet_name = $csv_file) =~ s/\.[^.]+$//;   # strip extension
    $xlsx->addsheet($sheet_name);
    $xlsx->addrows(@rows);
}
$xlsx->close();

And use it like:

/path/to/create_xlsx.pl file.xlsx *.csv

If perl is not your thing, a bit of googling reveals:

python: https://openpyxl.readthedocs.io/en/stable/
ruby: https://stackoverflow.com/questions/4644341/which-gem-support-import-export-to-xlsx-file-in-ruby


So - there's an oddity in Ardour:  If you have jackd running in an attempt to use realtime mode, Ardour will fail.  And if you start jack from Ardour, Ardour will always try to start with realtime mode enabled...

The solution to this is to force jackd to start without realime enabled.  The easy way to do this, is to use qjackctl and in it's setup, un-check the realtime mode checkbox:


How to PERMANENTLY disable mouse accelleration in 17.04?

Solved by adding the line at the end of ~/.profile

Open a terminal (ctrl+alt+t)

Use your text editor of choice to edit '~/.profile'

$ nano ~/.profile

Add the following line at the bottom of the text file.

xinput --set-prop 8 'libinput Accel Profile Enabled' 0, 1

8 is the id of the mouse I want the settings applied to. In your case, this number can be something else. You can list your devices with xinput -list to figure out what yours is.

Save the changes, and the command should be executed every time you log on to your desktop.


How to patch kernel to get some hardware working

In my experience, applying a patch to a kernel x versions newer, is unlikely to succeed. You might be able to hack in the changes by hand, but that is a lot of work and is not future proof.

Since you are on 12.04, an alternative might be to upgrade your kernel. Looking at the last year a lot of improvements have been made for Sony laptops: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/log/?qt=grep&q=sony-laptop

Maybe you can first try to download and install a Live Linux distro (for example on CD or USB) with a fairly new kernel, to see if the problem is already fixed. From here you can make the choice to upgrade your current distribution/kernel or go for the manual method.


while updating its throwing error like as follows :

This error is caused by the CD-ROM APT repository. This repo can be used if you have an Ubuntu Live CD to install software offline. You will probably want to disable this feature, otherwise some APT operations will throw you errors like these.

To do it, search for "software sources" in the Dash. Open Software Sources, go to System Admin tab and uncheck the option that says something like "CD-ROM for Ubuntu". Reload the sources and close. Now if you run sudo apt-get update or check for software upgrades with the update manager the problems should not appear anymore.


You need to install the driver. Connect to internet some other way and run in terminal

sudo apt-get install git dkms
git clone https://github.com/lwfinger/rtl8188eu.git
sudo dkms add ./rtl8188eu
sudo dkms install 8188eu/1.0


Default sound device different when run as service

We don't have any experience with squeezelite emulator but it appears that it makes direct use of ALSA.

To control ALSA with media keys we can define keyboard shortcuts for the user running sqeezelite (in your case root):

amixer set Master 10%+ ## for Volume UP 10%
amixer set Master 10%- ## for Volume DOWN 10%
amixer set Master toggle ## for Mute

Desktop user keyboard settings, or other per-user audio settings (e.g. default audio devices) will only work after we run squeezlite from a user session (e.g. on login).


Nautilus trash doesn't show deleted files on other partitions

I had similar issues, even going so far as to place a shortcut to the trash bin in my file manager so that I could get the space back. In the end the best solution for me was to:

Use the trash-cli package which can be installed with sudo apt-get install trash-cli and empties all of a users trash with the command trash-empty


Error while opening Software Center and Update Manager in Xubuntu

cd /usr/share/software-center/

ls | grep ^software-center$ does this yield any output? if yes then only the symbolic link is deleted from /usr/bin/.

to create symbolic link again,

sudo ln -s '/usr/share/software-center/software-center' '/usr/bin'

if this doesn't help

try reinstalling sofware-center. It seems like python script of software center has been deleted or moved.

edit >

try sudo apt-get install software-center


Have I Installed Lubuntu 21.04 LTS, or need I do something to have LTS?

You don't make a choice during installation.
You choose by selecting the correct release to download.
If you download 20.04, that IS an LTS release.
If you download 21.04, that's NOT an LTS release.
LTS releases occur every two years in April: 10.04, 12.04, 14.04, 16.04, 18.04, 20.04. See the pattern?
Both LTS releases and non-LTS releases are solid, stable releases of Ubuntu. You can run either and be quite happy.


Windows hibernation: why lubuntu is prevented to mount a partition on which the hiberfil.sys is not present?

I found a solution to my question on my own.

  SOLUTION

  Wrote in terminal:

sudo ntfsfix /dev/sdXY

where sdXY is the partition I needed to mount, in my case - DATA partition.
With this I can hibernate windows and still be able to use the DATA partition on lubuntu without losing the hibernated data on windows, which is on windows system partition.


Launcher going all black. What is wrong with it?

Have you tried to restart unity? Adding from the second answer found here:

Hold down ctr+alt and press t. This will bring up the terminal. Then type unity. This will restart unity and hopefully fix the issue.


edit :

sudo -H gedit /etc/NetworkManager/system-connections/HP-LASERJET

and find the section that says

[802-11-wireless-security]
key-mgmt=wpa-psk

and place the following on the next line.

psk=yourPassword

As a prevention for rewriteing it by system use:

chmod 400 /etc/NetworkManager/system-connections/HP-LASERJET


How can I install Ubuntu 10.04 to replace 12.04?

A quick Google search gave me the the following site:

http://releases.ubuntu.com/lucid/


How to get Ubuntu installer to sense Windows 8.1 as an OS

First, try disabling Fast Startup in Windows. This feature is incompatible with dual-boot configurations, and it's conceivable that it's causing the problem you're seeing, although I'm far from positive of that. If this works, I'd appreciate seeing a comment to that effect so that I know it's a possible solution.

Second, if that doesn't work, you'll just have to use the "Something Else" installation option. (That referenced question/answer refers to Windows 7 and may have some Windows 7-specific elements, but the basic principles still apply.) Unfortunately, a lot of people have been seeing this problem with Windows 8 and 8.1 installations, and doing the partitioning manually is what works for most people.


Brother DCP-J140W does not scan (brscan4, USB connected)

My ADS-2000 stopped working upgrading to Debian jessie.  Installing brscan0.4.3 fixed my invalid argument issue.

I entered the site here:
http://support.brother.com/g/b/productsearch.aspx?c=us&lang=en&content=dl

When I searched for brscan4, the top result appears to be out of date with the 0.4.2-4 image (http://support.brother.com/g/s/id/linux/en/download_scn.html).


OK.  Finally figured this out.  For some reason, I had the MAAS Cluster Controller API URL set to my LAN network address, not my MAAS internal network address.

I fixed this by running

sudo dpkg-reconfigure maas-cluster-controller

Then I set the API URL to:

http://192.168.xxx.xxx/MAAS

And now my PXE nodes enlist properly!

Hope that helps someone out.


How to delete all files that contains " (2)" wildcards dont work

You need to escape (or quote) the parentheses - but not the glob wildcards * e.g.

ls *\(2\)*

or

ls *"(2)"*

or even

ls *'('2')'*

If you want to match the leading space explicitly, you will need to escape or quote that as well e.g.

ls *\ \(2\)*

or

ls *' (2)'*


To flesh out the answer a bit, you may want to look at chown's man file before you do anything, but to change the owner of all files in /home/user, you'd do:

chown -hvR user /home/user

where "user" is the name of the owner you want to change it to.


Dropbox install fails in 12.04 TLS (32 bit)

Try run it from terminal using the command:

dropbox

Download and install it from here https://www.dropbox.com/install?os=lnx if something wrong occur it's probably because you are using Ubuntu via CD

Don't forget to choose the 32 bit version for Ubuntu, it's the first option. :)


I researched this further and I believe this is what you need to do. Type this command in the terminal.

To change the password for oracle:

passwd oracle

Then try:

sudo /etc/init.d/oracle-xe configure

Originally, I thought it had something to do with changing the filetype. Boy, was I wrong. :)


Untrusted Source .jar file will not open

You need to give it the executable bit.

Run this command in terminal (ctrl+alt+t):

sudo chmod +x yourfle.jar

Then you can run it normally with:

java -jar yourfile.jar


Mounting with Nautilus works but fstab gives "Host is down" error?

fstab is run at boot, before VPN connections get a chance to actually connect.

Run nmcli con list to get your connection's UUID. Note that or copy it to a text file.

Now, make another shell script in your home folder:

#!/bin/bash
sleep 25
nmcli up uuid <your uuid here>
sleep 5
mount //139.___.___.140/home /media/___

replacing VPNNAME with the name of your VPN, and <your uuid here> with the UUID you noted earlier when getting the list of network connections.

Add that script to startup applications.

Replace the line in fstab with:

//139.___.___.140/home /media/___ cifs domain=CS,username==___,password=___,uid=sai,gid=sai,user  0 0

so it can be mounted by user.

You'll notice that you need to fill in the data you redacted from your post. The command will take 30 seconds to get intalized, allowing for connectivity. You can make the sleep times shorter if you wish.


Is it possible to search for a keylogger using netstat / nmap?

By default, Ubuntu ships with no open ports on public interfaces.

Not entirely true. Technically speaking, Ubuntu ships with minimum open ports, particularly 631, which is for network printing. But such services as mail transfer, ssh, ftp - they all require a server software installed on your machine. For instance , ssh port 22 is open on my machine only after I installed openssh-server.

That doesn't mean you're 100% safe, only 89% safe. The other 10%  can be added by enabling the default firewall or installing your own.

  Does that mean that if I got infected by a keylogger my computer would not send information to the hacker's computer?

I am no information security professional, but I wouldn't be surprised if there were keyloggers that send information through port 80, which is the standard port for internet stuff. Browsers do that, for instance. So the answer is , information could still escape your computer

  Is it possible to download an application (virus/malware) that would open a port on public interface if it had root access?

Yes. As I described a little earlier if you install ftp or ssh servers, you get ports 25 and 22 open, and you install them as root; So what stops malware doing the same if it has root access ? Exactly nothing.

  How do I check for open ports on public interfaces? I know netstat -a, netstat, nmap -v localhost, nmap -v -p1-65535 localhost, but they all show different information so I am not sure.

netstat and nmap are two of the basic and best command-line utilities that are used by system administrators across the world. They're already good, but require learning a bit about the flags.

netstat -tulpan is what I personally use in my checks. This shows all TCP and UDP connections, including listening ones and prints out the connections in ip address (numeric ) format. If there's an IP address that is suspicious , it can be checked with nslookup or dig or whois. In addition the -pflag will tell you what program is using which port or has connection established. That is pretty useful, you can later lookup that process as well as process id, eventually locating the executable file.

nmap is good for scanning local network as well as your own machine. Personally I use sudo nmap -sT -T4 -n 192.168.0.1/24 on my local network to check pretty quickly all the devices on my network, including my own machine. I can see what computers are on the network.

  Using nmap -v -p1-65535 localhost my computer finds two ports: Discovered open port 631/tcp on 127.0.0.1 Discovered open port 51072/tcp on 127.0.0.1 Does the IP at the end mean that it's not being sent to another computer?

When you scan with localhost , that means you're scanning your own computer. Localhost,or the address that computer refers to itself, is set to 127.0.0.1. It's like asking yourself Who am I ? Well, I am me would be the response.

That means you have ports 51072  and 631 open. 631 is open by default, but 51072 is a little trickier. Ports from 1024 to 65534 are used to establish temporary connections, for example by internet browsers. Typically they're opened and then closed, but if it's persistent you may already have some form of malware installed, not necessarily a keylogger.

I'd suggest you disconnect the computer from the network immediately. Examine your Autostart entries, change password with sudo passwd $USER, enable Ubuntu's default firewall with sudo sed -i 's;ENABLED=no;ENABLED=yes;g' /etc/ufw/ufw.conf. Make sure you change/enable the router admin password (not the wifi password, the actual password that allows you make settings changes to your router), preferably from another computer.

After that you should be able to return to your internet browsing, but you may want to observe your connections, ports, behavior of the machine. Avoid doing anything that could compromise important passwords and logins. If you still have an issue, consider asking information security professionals for help.


Wi-Fi network does not connect right after system started, but it works after restart

If it was not consistent with all devices, I would say that this is might be a driver issue. The RTL8192CU does have a history of issues with a few linux kernel versions.
However, you might want to take a look at this.
I would suggest to change the TKIP encryption into AES and switch to WPA2 instead of WPA.

* Update *
Sorry I missed that you're using CCMP.
However, I have noticed that there are two other networks in the area that use the same channel(11) that you are using. Try to change it to 8 or 6 and see how it goes.


Running a graphical application through ssh and keeping it alive

I solved the problem by updating xpra, following the instructions here. I was using the Ubuntu 12.04 default xpra.


Bit Rate issues on ubuntu 12.04 Centrino Advanced-N 6205 wireless card

It seems from the output of the wireless debugging script that your WiFi is sharing channel 11 with 6 other WiFi networks close to you.

Please go to your router and change the channel to 2 (currently unused by any of the WiFi networks around you).  That will improve your throughput.


Disappearing and reappearing ethernet connection

I solved this already by changing kernel driver version from r8169 to r8168.
http://www.foxhop.net/realtek-dropping-packets-on-linux-ubuntu-and-fedora


How can I find the database directory of Thunderbird?

All personal files are stored under /home/$USER/ inside hidden directories.

For Thunderbird that could be 2 locations...

/home/$USER/.thunderbird/
/home/$USER/.mozilla-thunderbird/

Ubuntu uses the 1st nowadays.

There will be a subdirectory named after your profile.
All of the messages for an account are stored in a subdirectory named after the mail server.


Read contents of a previous Fedora hard drive

By default, Fedora uses LVM. By default, the Ubuntu live (desktop) does not have have lvm support, but you can install it and then mount the Fedora partition.

sudo apt-get update && sudo apt-get install lvm2

Now list and mount your lvm partition / data

List your physical volumes

sudo pvscan

List your volume groups
    sudo vgscan

Activate all volume groups available.
    suod vgchange -a y

Again run lvscan to show your active volumes.

sudo lvscan

Mount the partition to /mnt ( get this information from the above commands )

sudo mount /dev/VolGroupXXX/LogVolXXX /mnt

You should now be able to access your data in the /mnt directory


can't find bin folder in my minecraft folder!

I can access my Minecraft bin directory by going to ~/.minecraft/bin/

Although this isn't Ubuntu specific, may I recommend that you try out MagicLauncher.  This allows you to install and enable/disable Minecraft mods really easily.

Once you run it click on Setup. You will be presented with this dialog:

Then to add a mod click Add and select the zip of the mod you want to install. Really simple!


How many and how should I set up my partitions?

The partitioning scheme can be anyway you like it.Just be sure you do not delete your Windows partitions when creating or modifying ones for Ubuntu. Paying attention will help with this.

Please take a look at: Partitioning Schemes - Ubuntu Help for some additional info regarding how to partition your machine. The following set up is how I have three of my machines running.

I have seven partitions while dual booting Windows 8.1, they are as follows:

/dev/sda1 - 2GiB (boot partition /EFI that windows created automatically during it's installation)

/dev/sda2 - 350GiB - (Windows partitions with install)

/dev/sda3 - 100GiB "Extended Partition" (since you can only have four primary partitions on a system)

/dev/sda5 - 4GiB "Linux-Swap" (usually you only need to have half the amount of your ram for swap. Since I have 8GiB of Ram I used 4GiB for Swap)

/dev/sda6 - 20GiB "/" (root partition)

/dev/sda7 - 70GiB "/home" (I have a separate partition for my home folder)

For my root "/" and "/home" partitions I have formatted them to the Btrfs (Betree), file system as this runs best for me. Ext4 will work just fine as well.

Then you can install Ubuntu along side of Windows.

For your question regarding if Windows 10 will corrupt Ubuntu - It should not. I had upgraded to Windows 10 preview while I have Ubuntu installed and nothing was harmed. I always recommend reading over the official help documentation at Ubuntu.com for installation and partitioning.

To answer your question on whether or not you can create a partition that both Windows and Ubuntu can use, I am not sure. You could always create one then try to mount it on both Windows as well as Ubuntu, but I am unsure how this would work due to the way Windows and Ubuntu handles files systems. I guess it would be similar to having a network drive that you could see on both OS's. Just not 100% sure.


cannot launch inkscape in windows subsystem for ubuntu

This does not seem to be due to stack size as some other solutions from the past state. There are multiple open issues for this when it comes to Ubuntu > 18.04:

https://gitlab.com/inkscape/inkscape/-/issues/1420
https://gitlab.com/inkscape/inkscape/-/issues/1458

The beauty of WSL is it's easy to set up another distro. I installed 18.04 and was up and running with working inkscape very quickly.

As of Windows version 2004, you can also switch to WSL2. I have Ubuntu 20.04 and inkscape is working in WSL2.

https://docs.microsoft.com/en-us/windows/wsl/wsl2-kernel


How can I restore the executable bit of /bin/chmod?

There are several methods. The easiest will probably be:

install -m a+x /bin/chmod .
./chmod

You can use perl. see man 2 chmod.

perl -e 'chmod 0755, "/bin/chmod"'


Duplicating Ubuntu from external hard drive to internal SSD?

It sounds like your SSD is not working correctly so you should sort out those issues first.  If you want to, you can just copy everything from the hd to the ssd.  Boot Ubuntu into rescue mode and go to a root shell.  Format the ssd, then mount it somewhere, and simply copy all of the files over, then update grub.  Replace sda1 with the correct drive:

mke2fs -t ext4 /dev/sda1
mount -t ext4 /dev/sda1 /mnt
cp -ax / /mnt
blkid -p /dev/sda1
nano /mnt/etc/fstab

Write down the UUID that blkid reports, and change the UUID for / in fstab to match.  Then update grub and reboot:

mount -o remount,rw /
update-grub
reboot

When you reboot, grub should have an entry to boot from the ssd.  Make sure it boots correctly, and check mount to make sure that / is actually mounted on the ssd.  If it is, run sudo dpkg-reconfigure grub-pc and check the box to install grub on the ssd, then you can reboot, configure your BIOS to boot from the SSD, and recycle the Ubuntu partition on the HD.


By reverting to old interface, I'm pretty sure you refer to Unity, as it was default desktop environment for Ubuntu 16.04.

First, bring up your terminal window, then type following command:

sudo apt install ubuntu-unity-desktop

In middle of installation process, you will be asked to choose a display manager, as for Ubuntu 16.04 it is LightDM, meanwhile 18.04 uses GDM.

To put it up:

If you want the login screen to look like the one from 16.04, pick LightDM.
If you prefer current look, pick GDM.

Source from linuxbabe.com

Once the installation is complete, restart your system. At the login screen, click on Ubuntu icon (in LightDM), then click Unity (default)


Simply copy the commands to terminal, if you got a folder .wine which is your current installation will be renamed to .wine_BACKUP:

    mv ~/.wine ~/.wine_BACKUP
    wget -nc https://dl.winehq.org/wine-builds/Release.key
    sudo apt-key add Release.key
    rm ./Release.key
    sudo apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/ -y
    sudo apt-get update
    sudo dpkg --add-architecture i386
    sudo apt-get install --install-recommends winehq-staging -y
    sudo apt-get install winetricks -y
    winecfg

enjoy


I cannot print with HP Laser107a whilst I cannot make hplip to detect it

In order to work follow these steps:

Remove the existing device from the gnome device manager (ommit this step if you setup the printer for first time):

Download the driver from hp website
Unzip the zipped file.
Run the following commands:

cd uld
sudo ./install-printer.sh

On the questions that the install script asks just press y and enter.
Then click upon the button shown in the following screen (assume no printer as added).

Then click add:

Then select the printer from an existing database and press forward:

And select the Laser 10x driver:

Please check whether you can ommit steps 2-4 because a propriatery driver is being installed. With the steps above you will be able to print, though hplip-gui won't be able to detect the printer.


You have already a default route for this gateway

Example:

No default route

% route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
link-local      *               255.255.0.0     U     1000   0        0 eth0
192.168.2.0     *               255.255.255.0   U     0      0        0 eth0

Add a route

% sudo ip route add default via 192.168.2.1

% route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         fritz.box       0.0.0.0         UG    0      0        0 eth0
link-local      *               255.255.0.0     U     1000   0        0 eth0
192.168.2.0     *               255.255.255.0   U     0      0        0 eth0

Add the route again

% sudo ip route add default via 192.168.2.1
RTNETLINK answers: File exists

As you can see, here is your error message.


Ubuntu is not like Windows, where each piece of hardware has a separate installable driver with its version.

Most of hardware is supported directly by the Linux kernel, that contains drivers almost for everything including AMD GPUs.

So there is no amdgpu version that comes with Ubuntu.


WARNING: This worked some releases ago and I didn't test it with the current one!

Close Banshee.
Backup your ~/.config/banshee-1/banshee.db (copy it, do not move or rename it).
Execute the following command: sqlite3 ~/.config/banshee-1/banshee.db "update coretracks set LastSyncedStamp = 0 where PrimarySourceID=1"
Start Banshee. It should now update your folder and file names. It takes quite a long time, depending on how many files you have. You can see how it's working in the bottom left corner.

Oh, and big thanks to gabaug in the Banshee IRC channel for this solution :P


Boot Ubuntu ISO pure From RAMDISK/MEMDISK

Experience with Booting ISO file toram
I booted a Ubuntu ISO file using GRUB2 with the following menuentry.
menuentry "Ubuntu 20.04 ISO" {
    rmmod tpm
    set root=(hd0,3)
    set isofile="/isos/ubuntu-20.04-desktop-amd64.iso"
        loopback loop $isofile
        linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile persistent persistent-path=/ub2004-1/ fsck.mode=skip quiet splash toram --
        initrd (loop)/casper/initrd
}

Opened Nautilus and entered sudo umount -lrf /dev/sdxy
Where sdxy is the partition containing the running ISO file.
Then opened Nautilus and clicked the little triangle on the left next to a partition on the ISO's USB.
Received a message that it was safe to remove the drive. I did so.
Then plugged the USB drive back in and proceeded to modify the unlocked partition.
When work was complete shut down the computer as normal.


Windows has gone missing from the grub menu

Your are missing two essential Windows boot files, bootmgr & /boot/BCD.Those are what grub2's os-prober looks for. Normally Windows has those in a separate 100MB (hidden) boot partition, but you do not show that partition or missing space for it.

You will have to move boot flag back to sda1 as Windows only repairs the partition with the boot flag. You can use gparted or with your Windows repairCD or flash drive the set active command. And then run Windows repairs to recreate the bootmgr & BCD. If you run auto repairs 3 times, it will also put the Windows boot loader back in and you have to use Boot-Repair or manual install to readd grub to MBR.

Then the sudo update-grub will find Windows. Or Boot-Repair will run it also.


How do I deploy a local charm from the Juju GUI?

The latest version of the Juju GUI (cs:precise/juju-gui-85 at the time of writing) supports working with local charms.

It requires Juju version 1.17.3 or higher.

In order to work with local charms in the GUI you simply drag and drop a .zip archive of your charm onto the canvas portion of the GUI. You can even use this same procedure to upgrade already deployed charms with a local charm.

To deploy a local charm via the command line you would use the following command:

juju deploy --repository=/path/to/charm local:precise/charm-name

https://jujucharms.com/docs/stable/controllers-gui


No sound from any playback devices Ubuntu 14.04 fresh install

Did you installed gstreamer plugin ?
To install it launch software centre and install ubuntu restricted extras.


Canon MG5320 not recognized by Simple Scan (prints fine)

Located deb files from Canon Asia, installed via software center and scangearmp runs from terminal.


After installing python3-distutils, it should launch. I had the same issue.

sudo apt-get install python3-distutils


GIMP: I mistakenly clicked "don't ask again" when asked to rotate picture. How to undo this?

Make sure Gimp is not running
Locate your "Gimp profile" (normally ~/.gimp-2.8 if on 2.8, otherwise see here for ways to locate it.
Edit the parasiterc file with a text editor
Find a line that starts with (parasite "exif-orientation-rotate" ...)
Delete the line and save the file.


Keyboard mappings on laptop seem irreversible

go to settings/keyboard/behavior and uncheck : Restore num lock state on startup.


How to have a AZERTY layout AND numbers without push shift?

You'll have to modify the fr file in /usr/share/X11/xkb/symbols.

Make a copy of the file somewhere.
Modify it as necessary.
Make a backup of the original file in the original folder.
Overwrite the file with the modified version (you'll need administrator rights: gksu nautilus in terminal). BE CAREFUL. YOU COULD BREAK THINGS!
Restart X server or reboot.

P.S. If you're using Ubuntu 12.04, you'll have problems with the modified layout (I do) but there is a temporary workaround. In a terminal type:

sudo setxkbmap fr

I'm not using the standard french layout but the one called french alternative and french alternative latin 9 only. I have to use:

sudo setxkbmap "fr(oss)","fr(oss_latin9)"

Modify the command accordingly.