I want shotwell to open all .cr2 files in a folder and all its subfolders, what command line do I use?

Usually, you will want to just open Shotwell and drag in the folder.

If you need to, you can make the shell build a list of CR2 files and tell Shotwell to open just those files. Occasionally that may be what you want, but in this case that did not do quite what you needed due to Shotwell's behavior -- in some other circumstances, a feature -- of automatically showing you other image files (of all types) residing in the same folders as the images you opened.

To ensure Shotwell only knows about the images you are interested in, you could clone the directory tree somewhere else, copying only .cr2 files and the folders that contain them, but nothing else. That may take up substantial additional space, though. So another approach is to construct a hierarchy of symbolic links -- where instead of having having a new directory tree of copies of your original .cr2 files, you have a new directory tree of syminks to them. This takes up far less space.

This answer covers all those approaches.

Opening a Folder of Images (Including Subfolders) in Shotwell

Shotwell itself gives you two ways to open a whole directory tree of photos. If these will work for you, then you won't need to do anything clever in the command line or even use it at all. If not, you might end up doing this in connection with another technique.  (For example, if you end up creating a new directory of symlinks or copies of your .cr2 files, you can use one of these ways to open it.)

Way 1: Just open the whole folder in Shotwell.

In Shotwell, in the File menu, click Import from Folder. Then select the folder you want to import images from. This won't be limited to .cr2 files, but if you're opening files from multiple subfolders containing .cr2 images created from a digital camera, then most likely those will be the only files present.

See Jakob's answer to Show all pictures recursively (include any subfolders) for more information.

Way 2: Drag the folder into Shotwell.

With most desktop environments and file browsers, you can also open Shotwell and drag the folder that contains your images into the Shotwell window. Like Import from Folder, this is another way Shotwell recommends to open photos.

When you drag from a file browser window or your desktop into Shotwell, you can drag to a specific library. Or if you don't have multiple libraries set up, you can just drag basically anywhere and it works. (You don't even have to drag into the left pane.)

This method is very convenient, and it is as powerful as manually selecting the folder (with File > Import from Folder, as described above). When you open files or folders using either of these methods, Shotwell gives you the option to open the photos without copying them into its library.

To import without copying, click Import in Place instead of Copy Photos.

Launching Shotwell with a List of Image Filenames

If for some reason you want or need to do this by running a command in the Terminal, you can run the shotwell command and pass each image's filename to it as an argument. Globstar makes it easy:

shopt -s globstar
shotwell **/*.cr2

That opens the .cr2 files located anywhere in the current directory. It differs from running Shotwell and then dragging the folder in, in that Shotwell will only try to import the the files whose names you give it. However, since Shotwell often shows other image files from the same folders as the files you've told it to open, this may not be adequate for your needs. (And further information you've given about your problem suggests that it is not. See below for an alternative.)

This does not include files or subfolders whose names start with .. However, if you have CR2 files whose names start with a dot, then most of the time you probably don't want to open them in Shotwell anyway. Unless you've deliberately named your files or folders in this way, a dotfile with an image or document filename extension is more likely to be a metadata file rather than an actual image or document. For example, macOS often adds such files (e.g., ._kittens.cr2 for an actual picture kittens.cr2) when accessing external media (including flash drives and digital cameras).

If you do want to also find files whose names start with . or that are in folders whose names start with ., then enable dotglob as well. You can do this with shopt -s dotglob or by passing both globstar and dotglob to the shopt builtin:

shopt -s globstar dotglob

By default, globs are case-sensitive. But you might want to match filenames case-insensitively, so as to open files ending in .cr2, .Cr2, .cR2, and .CR2. To do that, either:

Enable nocaseglob by running shopt -s with nocaseglob, either by itself or with other shell options. For example, to run shotwell on all .cr2 files, searching case-insensitively and including .-files and files in .-directories:

shopt -s globstar dotglob nocaseglob
shotwell **/*.cr2

Or, use .[cC][rR]2 instead of .cr2 in your glob pattern itself. For example, this accomplishes the same as above:

shopt -s globstar dotglob
shotwell **/*.[cC][rR]2

Note that case sensitivity is entirely separate from whether or not . files and folders are matched. You can remove dotglob from the examples above and they can still be case-insensitive.

To specify a directory rather than just using the current directory, put its name and a / before the **/*.cr2 glob. For example, replacing the shotwell command above with this one will open all the .cr2 files inside the Pictures subdirectory of your home directory:

shotwell ~/Pictures/**/*.cr2

Unlike with the first command that uses your current directory, no matter where you run that command you will be telling Shotwell to open the same files.

Testing

If you really have to use the terminal for this, then I'm guessing it may be part of something more complex. If you like, you can test such commands before actually running them by replacing shotwell with printf '%s\n'. Instead of passing the filenames to Shotwell, that lists them one per line. For example, on my machine:

ek@Io:~$ printf '%s\n' ~/tmp/**/*.cr2
/home/ek/tmp/another image.cr2
/home/ek/tmp/image.cr2
/home/ek/tmp/some folder/image3.cr2

Turning Off Globstar and Other Shell Options

The globstar shell option has be enabled to work, which is what the shopt -s globstar command (above) did. If it's already enabled, then you don't need multiple commands. And you only need to set globstar once per shell instance.

You can turn globstar back off by running:

shopt -u globstar

And you can check whether globstar is on or off by running:

shopt globstar

If you're using globstar in a script, you should consider turning it back off if there might be code that comes afterwards in the same script that is not written with globstar in mind. For example, writing ** when you mean * is usually no problem when globstar is disabled, but with globstar turned on, it can cause serious problems by making a command affect far more files than someone intended.

Similarly, if you used dotglob or nocaseglob and you want too turn them off, you can do so with shopt -u dotglob and shopt -u nocaseglob, respectively. You can also pass multiple shell options to shopt -u to unset them at the same time. For example, to turn off globstar, dotglob, and nocaseglob:

shopt -u globstar dotglob nocaseglob

Compared to globstar, there are fewer serious mistakes you might make because you forgot you left dotglob or nocaseglob on. But other people (including people you consult on sites like Ask Ubuntu) usually assume dotglob and nocaseglob are disabled when they suggest commands for you to use, unless you tell them otherwise.

For more information on these glob-related shell options (and also on globs in general), see the bash reference manual. They are all covered primarily in 4.3.2 The Shopt Builtin. For globstar, see also 3.5.8.1 Pattern Matching. For dotglob, see also 3.5.8 Filename Expansion.

Building a New Directory Tree

Since in your case you seem to really need Shotwell to show only .cr2 files, you have non-.cr2 files in the same folders with .cr2 files, and image browsing in Shotwell is automatically offering those files too, it looks like you will need to have a folder that contains no other image files than the .cr2 files you're trying to open.

Moving the files, as you've suggested, is one approach, but I recommend instead either copying the files or, better, making symbolic links to the files (see also FOLDOC), because:

If you're moving the files across devices, that requires copying anyway, so in that case moving is no faster.
If you have the space, it's often a good idea to keep an unmodified folder of everything you started with until you're satisfied that what you've done is correct according to your needs. Obviously this is not always applicable or practical. But in your case, these files are the result of a data recovery operation. It may be useful to keep an easily perused record of precisely what was recovered and from where.
If you choose to create symbolic links, the amount of additional space consumed is extremely small. (If the target disk is completely full, though, then you will still need to free up space on it -- or use a different target disk -- to create symlinks.)

There is another decision for you to make, too. Do you create all the new entries (whether they be copies or symlinks) in the same directory, flattening the file hierarchy? Or do you create directories at the destination corresponding to each of the directories at the source that contain at least one .cr2 file?

Flattening the file hierarchy lets you see all the files at once, easily. In particular, it is easy to see the files' names and sizes all at once, as well as to select any combination of the files in a graphical file browser.
But it also loses information about what folders they were in, which may be valuable (though you can return to the original folder and look for them there if you don't move the files).
The bigger problem with flattening the file hierarchy, though, is what happens if you have two or more files of the same name in different places. If you flatten the file hierarchy, then depending on how you do it, either all but the first will fail to be copied (or linked) and you'll get an error or warning, or all but the last copy (or link) will be overwritten.

This is another reason I recommend copying or making symlinks rather than moving files. If you "successfully" move multiple files into the same file, you've lost all but the last one!

Because of the disadvantages of flattening everything into a single directory without subdirectories, the approaches I take here build a new directory tree at the destination.

Way 1: Copying

I show this first because it's a little simpler, but I suggest you instead create symbolic links ("Way 2"), especially if the destination drive might not have enough space to hold all the files. "Way 2," which is a bit more complicated, is much more detailed because there seem to be fewer resources on how to use that technique, it's the way I expect most people in this situation will prefer, and information that applies to both methods -- basic advice about escaping spaces in paths -- is given there rather than here.

When you need to copy a directory tree and you need to customize the copy operation, you should usually use rsync instead of cp. This is one of those cases.

Replacing src with the path to the top-level directory containing all your CR2 files, and replacing dest with the name of the directory you want to create that will contain a hierarchy of symbolic links to the CR2 files, run:

rsync -rl --prune-empty-dirs --include='*/' --include='*.cr2' --exclude='*' src/ dest

Don't forget the / after the name of the source directory, unless you want an additional top-level directory to be created inside dest. That is, if you omit the trailing /, then rsync will make the destination directory for you, inside dest. For example, suppose src is a relative path containing no /. Then:

With src/ in your rsync command, you get a symlink dest/foo/bar.cr2 for the file src/foo/bar.cr2.
With src in your rsync command, you get a symlink dest/src/foo/bar.cr2 for the file src/foo/bar.cr2.

Since it could be confusing for the top-level directory where symlinks will be placed to have the same name as that of the top-level directory containing the .cr2 files that the symlinks will point to, I recommend you include the / at the end of the destination directory name in your rsync command. (And, for the source directory, give it a directory that is empty, doesn't exist, or is otherwise dedicated to this purpose. Otherwise, you'll be cluttering up some other folder.)

As is generally the case when you pass the name of a file or directory to a command-line program or script, if your destination or source directory paths contain any blank spaces (or characters treated specially by the shell, like \, $, ', and various other punctuation), then you will have to quote them. I've detailed how to do this, for the most common case of spaces, in "Way 2"--the advice about quoting in that section applies here as well. However, if you're not sure how to quote the name of a folder, you can have Ubuntu do it for you by simply dragging the folder into the Temrminal; its full path will be pasted in with correct quotation.

After copying just the .cr2 files and the folders that contain them, you can open the destination folder up in Shotwell. (See "Opening a Folder of Images (Including Subfolders) in Shotwell" above.) However, before running rsync, I recommend you decide if want to skip entries that start with . and if you want to include entries with case-variant suffixes. If so, you'll have to run some slightly different rsync command.

Customizing the Handling of Dotted Entries and Case Sensitivity

You may want to use a different rsync command to change whether or not files and directories that start with a dot are skipped and whether or not you want case-sensitivity in matching the suffix .cr2.

The command above does include directories and files whose names start with .. To exclude such files and directories, put --exclude='.*/' --exclude='.*' before all other --includes  and --excludes. That is, use this rsync command instead (with the appropriate substitutions for src and dest, of course):

rsync -rl --prune-empty-dirs --exclude='.*/' --exclude='.*' --include='*/' --include='*.cr2' --exclude='*' src/ dest

The rsync commands shown thus far have been case-sensitive and will not copy files that end in .CR2, .Cr2, or .cR2 rather than .cr2. If you want such files to be copied, then you'll need to account for that by using the --include pattern *.[cC][rR]2 in place of *.cr2.

This third command is case-insensitive and (like the first command) does not skip files and directories whose names start with .:

rsync -rl --prune-empty-dirs --include='*/' --include='*.[cC][rR]2' --exclude='*' src/ dest

If you take the approach of copying files with rsync, and you're not sure which of these commands you want, I suggest using that one if you want to make sure not to miss anything. However, you should be aware that dotfiles may contain metadata, and dotfiles named like images may not really be images. See the discussions on dotfiles in the "Launching Shotwell with a List of Image Filenames" section above, and on dotfiles and case sensitivity in "Way 2" below.

This fourth command is case-insensitive and (like the second command) does skip files and directories whose names start with .:

rsync -rl --prune-empty-dirs --exclude='.*/' --exclude='.*' --include='*/' --include='*.[cC][rR]2' --exclude='*' src/ dest

Way 2: Creating Symbolic Links

This is what I recommend you do, though Way 1 is okay if you have enough space on the destination drive. You don't have to read Way 1 to use this.

The method presented here makes a list of .cr2 files and loops through the list, creating target directories as needed and populating them with symbolic links to each .cr2 file.

This is just complicated enough that I suggest putting it in a script rather than just typing it in interactively. You can put the script wherever you like, but for convenience, I'll show how to do it with the script placed directly in your home folder.

Write (or paste in) the script.

Create a text file, make-symlinks, in your home folder. No file extension is needed.

You can do this with any text editor, like Vim, Nano, Gedit, or Leafpad. Don't use a word processor like LibreOffice Writer, though. (You could even do it by running cat > ~/make-symlinks, pasting in the contents of the file, and pressing Ctrl+D on a new line, if you wanted.)

If you name the script something other than make-symlinks, make sure to use that name when you run commands that use the script later.

#!/bin/bash

shopt -s globstar dotglob nocaseglob

for f in **/*.cr2; do
    mkdir -p "$1/$(dirname "$f")"
    ln -s "$PWD/$f" "$1/$f"
done

Put that in the file, and save the file. This script uses globstar, a Bash feature explained above in "Launching Shotwell with a List of Image Filenames".

You can change how it handles dotted entries and case sensitivity.

Depending on your needs, you may want to make some changes:

If you don't want to include .cr2 files whose names start with . or that reside in directories whose names start with ., remove dotglob from the shopt line.

Files and directories whose name start with . are often used for metadata (see the "Launching Shotwell with a List of Image Filenames" section above). On the other hand, if you want to make sure you have everything, or if there's something inexplicably missing that you are pretty sure is there, then should keep dotglob.
If you want to include only files that end in exactly .cr2 but not case variants (.CR2, .Cr2, and .cR2), then you should remove nocaseglob. Since your situation involves data recovery and Shotwell will not show you any of the files you missed when you open up the directory of symbolic links -- that's the point of this method, after all -- you will likely want to keep nocaseglob.

Make it executable.

Run this command to mark your script executable:

chmod +x ~/make-symlinks

Run it at the source and pass the destination as an argument.

Then change directory to the source directory, i.e., the top-level folder that contains the pictures. For example, if they are in the Pictures subdirectory of your home directory, you would run:

cd ~/Pictures

This is where you'll run the script. Pass the destination directory to the script as a command-line argument.

For example, if you want a directory called cr2s to be created on your Desktop to contain the symbolic links, run:

~/make-symlinks ~/Desktop/cr2s

Or if you just want that directory directly in your home folder:

~/make-symlinks ~/cr2s

Or if you have a drive mounted at /media/you/MyDrive and you want to create a folder on it called links to contain the symbolic links:

~/make-symlinks /media/you/MyDrive/links

But if the drive is /media/you/My Drive (with a space) then you must use quotation. Any of these works (use just one, don't run them all):

~/make-symlinks '/media/you/My Drive/links'
~/make-symlinks /media/you/'My Drive'/links
~/make-symlinks /media/you/My\ Drive/links

But if you use ~ for your home directory, don't quote that:

~/make-symlinks ~/'Two Words'   # good
~/make-symlinks ~/Two\ Words    # good
~/make-symlinks '~/Two Words'   # BAD, because ~ doesn't get expanded

make-symlinks creates the destination directory for you if it doesn't already exist, just as it creates subdirectories within it. However, it still works if the destination already exists.

You can even run it multiple times and pass the same destination directory (for example, if you interrupted it with Ctrl+C), though you'll get failed to create symbolic link errors for the symlinks that already exist, and that could be confusing.

You probably don't want to pass the name of a directory that already exists and contains unrelated files (like your home directory) to make-symlinks. If you do, you can expect a whole bunch of symlinks and subfolders to be created in it. You probably want to use a new directory -- or one that doesn't exist yet -- for make-symlinks.

Import the newly created symlink tree into Shotwell.

After you run make-symlinks, just import the directory you passed to it into Shotwell, using either of the methods given in the first part of this answer ("Opening a Folder of Images (Including Subfolders) in Shotwell"). For example, you could open Shotwell and drag the folder in.

Since all the the entries in folder are either symbolic links to .cr2 files or directories that contain them, with no other file types, Shotwell should not see any of the other files.


Try to select at the loginscreen Unity 2D (this is done via the little 'radar-icon' nearby your login name (the one were you type in your name and password)

If this loads correct, you can adjust some things so Unity 3D loads properly. I suspect the Steam-program got a little bit in the way with something. (This you have to test over and over again)

If Unity 2D doesn't load:

Can you start up in recovery mode ?

To achieve this simply open up Grub (after Bios-screen press and hold SHIFT) and select the recovery modus. From there on you can try to initialise Unity again.

We need a bit more information, I see you've installed Steam is that program shut down correctly before you quited Ubuntu ?

Apparently it's clear that Unity doesn't load fully; so if tweaks were made (e.g. CCSM used) it could be they are in the way of things.


Deleted Ubuntu partition and now I get grub rescue

That once happened to me. You need to put Windows 8 installation disc in your computer and start it. Then you go to repair system and to more options and select command prompt. Then, type the following commands: bootrec /WriteMbr, bootrec /Fixboot, bootrec /Fixmbr.

It will probably say that it couldn't find any windows systems but that's normal - it will be fixed. THIS WILL DELETE GRUB AND INSTALL WINDOWS BOOTLOADER!


Command line BitTorrent client with UDP trackers support


Setting system environment variable via bash script?

The error you are getting is likely because EDITOR is not set - so your command becomes

~/.profile

which tries to execute the .profile of the invoking user (clearly root in this case).

Even if set $EDITOR usually points to an interactive text editor - it's not going to magically take the following line and insert it in the file. In any case /root/.profile is the personal .profile file for user root - no help if you want to modify the system-wide environment.

To make a system-wide change, you should modify either /etc/profile or /etc/environment1 - or (better) create a custom file in the /etc/profile.d/ directory e.g.

echo 'export MY_VAR="123"' >> /etc/profile.d/myvars

Your script will of course need to be run as root e.g. using sudo

[1] note that if you use /etc/environment, remove the export (variables in this file are just defined as simple name=value pairs)


After Insalling Ubuntu 16.04 Grub couldn't boot

It looks like your BIOS is trying to boot from the USB alone ; did you update the boot options of your BIOS so it can boot on your HDD you installed Ubuntu on ?
If not, go to BIOS setup on computer startup, then boot options, and bring your HDD up the list so it can be booted from.


Segmentation Fault and other issues after switching to XFCE

converted comment to answer

There is a bug-report that included the error message you reported - it was logged against this launchpad bug

Given that Minitube and Clementine are both QT multimedia apps, the resolution below would be a good candidate to try.

The resolution was to remove the package qt-at-spi

i.e.

sudo apt-get remove qt-at-spi


I finally found a solution, it's a Mesa bug.
http://gitlab.freedesktop.org/mesa/mesa/-/issues/2814
Starting the problematic apps with AMD_DEBUG=nodmacopyimage solves the problem.
And it also doubles my fps in everything else...


How to boot to terminal (ubuntu 12.04/gtx660Ti)?

Not sure of the overall issue, but to boot into terminal if CTRL+ALT +F1 does not work, you could try this:

Open Terminal and type:

sudo gedit /etc/default/grub

look for this line:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

change it to:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash text"

then update your grub

sudo update-grub

then restart:

sudo reboot now

if you want to use the desktop just type:

startx

Try at your own risk... backup ALL of your system first... :)


How can I connect to mysql database which is on the server locally?

With problems ERROR 2003 (HY000): Can't connect to MySQL server on '88.198.86.120' (10061 "Unknown error"). You can grant permission for user root with IP 88.198.86.120(IP locally) as command:

mysql> GRANT ALL PRIVILEGES ON *.* TO root@'88.198.86.120' IDENTIFIED BY 'NbYe&er9gTdbEzVkcHJbZ$r' with grant option;

mysql> flush privileges;

If you running firewall, you should allow IP 88.198.86.120 connect to port 3306 with:

ufw allow from 88.198.86.120 to any port 3306


To check the file system on your Ubuntu partition...

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

If for some reason you can't do the above...

boot to a Ubuntu Live DVD/USB
start gparted and determine which /dev/sdaX is your Ubuntu EXT4 partition
quit gparted
open a terminal window
type sudo fsck -f /dev/sdaX # replacing X with the number you found earlier
repeat the fsck command if there were errors
type reboot

Update #1:

Now, to check the SMART information in your hard drive...

boot to a Ubuntu Live DVD/USB
start Disks application
select the correct disk in the left pane
go to the "hamburger" icon and select SMART Data & Tests
review the data, note if it indicates that your drive is good/bad
run the tests


How to change the default monospaced font?

Install gnome-tweak-tool.
Then you will find it as "Advanced Settings" (Impostazioni Avanzate)


How to convert an .xcf file/image to JPEG or PNG?

You have to export the image, not save it.

To convert:

Open the XCF file using GIMP
Click on File
Click on Export
Enter a filename

It'll be saved as PNG by default. You can use any other format by simply adding the extension to your filename (like image.jpg, image.bmp) or selecting another file format in the bottom right of the export window.
Click on Export

The downside of exporting is that you'll only save what you see. So all your layers will be merged, and all editable components you may have added (like text) are not editable anymore.

So, if you would like to easily edit your images in the future, also save it as a XCF file as this will preserve all layers, components and other things as they are when you close GIMP.


"Warning! No such command: linux" at GRUB prompt

Have you tried booting from a livecd, chrooting into your ubuntu partition(s), and manually running '# grub-mkconfig -o /boot/grub/grub.cfg'?


How to configure Network Interfaces on ubuntu in virtual Boxes?

There are two things to know

As already mentioned above there is no need for a second gateway with a dhcp server in your network because the gateway entry is generated from there.
After you've added a host-onely adapter you have to copy the ip-adress from your windows host.

So far.

Here is an example configuration for a host only connection with one additional adapter:

auto eth1

iface eth1 inet static
address 192.168.253.128
netmask 255.255.255.0
network 192.168.253.1
broadcast 192.168.253.255

The Third block of the network line depends on your ip.
the broadcast line is needed for network communication between the host and the guest. This is a networking protocol related thing.


Disabling ipv6 worked for me.

Solution from here :

echo 1 | sudo tee /proc/sys/net/ipv6/conf/all/disable_ipv6


Unable to install files with apt-get: "unable to locate package"

Try running sudo apt-get update before trying to install the package. After installation the system doesn't have an up-to-date package list so you won't be able to find the package.

Once you've done this you should be able to install as normal.


Environment variables of current process

In the terminal session transcript,

seed@ubuntu:~/test$ strings /proc/$$/environ | grep LOGNAME

the seed@ubuntu:~/test$ part is just the user's prompt string - the actual command is

strings /proc/$$/environ | grep LOGNAME

Here, $$ (without backslashes) is the PID of the shell, as described in the Special parameters section of man bash:

 $      Expands  to  the  process ID of the shell.  In a () subshell, it
          expands to the process ID of the current  shell,  not  the  sub‐
          shell.

So this command returns the value of LOGNAME in the shell's environment - it's not really meant for examining the environment of a process invoked from the shell (although in general, the process will inherit the shell's environment).

Inside a C program, you can obtain the values of environment variables much more directly, using the getenv function:

GETENV(3)                  Linux Programmer's Manual                 GETENV(3)

NAME
       getenv, secure_getenv - get an environment variable

SYNOPSIS
       #include <stdlib.h>

       char *getenv(const char *name);

So for example

#include <stdlib.h>
#include <stdio.h>

int main(void)
{
  char *envval;

  if((envval = getenv("LOGNAME")) != NULL) {
    printf("Value of LOGNAME is: %s\n", envval);
  }
  else {
    printf("LOGNAME not found in environment\n");
  }

  return 0;
}

such that

$ gcc -o getenv_test getenv_test.c

$ LOGNAME=foo ./getenv_test
Value of LOGNAME is: foo


As stated, it would would probably be better to run a lighter version on an older laptop. I just installed Lubuntu on an older dell. Much more just for the basics. Ubuntu 32bit may also run depending on specs.
   There are plenty of tutorials online on how to download and install. But simply, you choose one you would like. Download the file. Obtain a 4 gig flash drive. Use a LiveUSB program to load the linux file to the flash drive, also making it bootable. Then run on pc you want to change, and mainly follow directions. Any problems, leave a question :)


Stability of Connecting to a Server Over the Internet with a Public IP Address?

Depending on your ISP you can have either dynamic or static IP. It's hard to tell which one you have right now - just ask your Internet provider.

But in case it's dynamic you need to set up DDNS service (dynamic DNS), with a domain name, that will be resolved to your current public IP.

And yes, if you're not sure you better use something like freeDNS to set dynamic DNS.

Also make sure that your SSH Server ir properly secured if you want it to be open to the public Internet.

Read these tutorials about SSH hardening:

https://linux-audit.com/audit-and-harden-your-ssh-configuration/
https://www.cyberciti.biz/tips/linux-unix-bsd-openssh-server-best-practices.html


After Backing Up the Whole Drive

Boot Live Ubuntu USB or DVD.
Open GParted.
Right click on sda7 and select Resize/Move.
Stretch the partition to fill all the space in the drop down.
Click on the little check mark to Apply All Operations.

If you had needed to increase the Windows partition size, you would do it in Windows Disk Manager.


The "problem" is with your video card, it does not do 3d graphics. To compensate it uses llvm which uses your CPU rather then your video card to do 3d rendering. The result is your display is slow. Previous versions of unity and gnome did had a 2d fall back mode, but they have been phased out.

"gnome" - both gnome shell and unity - use llvm (llvmpipe) and both will be slow.

Personally, I use KDE which is a balance of eye candy and speed. Other options are xfce or lxde.

kde (kubuntu) is a great spin, xubuntu, and lubuntu will all perform more reasonable for you and none use llvm (llvmpipe).

See http://www.mesa3d.org/llvmpipe.html


Windows 10 wont boot can i remove and install Linux from command prompt?

I was in this same position that you are in. The easiest thing to do is download the latest Ubuntu LTS ISO and burn it onto a DVD. Boot from the DVD then install. I would stick with the LTS. They are more stable for the most part. Avoid the latest versions until you know what you are doing.
There are some documented installation bugs in the latest LTS. There are also work-arounds for these bugs. You will have Internet access to search online during the install. This was what I did when I encountered errors during install. As an example, choosing third-party drivers during installation resulted in an install error. The work-around was to disconnect your Internet connection/cable during install. After installation completes, reconnect Internet, reboot, and finally update your new install.


Is there any danger in booting an existing Windows 10 in a VM on separate SSD and accessing a shared data partition?

I use multiple OS on the same data every day. Dual-boot vs. virtualization will make no difference. Your workflow is what keeps your data integrity.
If your data is in a database, then it's easy: Responding to read/write queries from multiple sources is what database applications do. One application on one OS owns the database - all other applications on all OS communicate with that application (not the data directly).
If your data is in non-database tables and files, then you must create your own rules for which applications are allowed to read/write (and when). Keeping different applications from trying to read/write the same file at the same time is mostly an exercise in scheduling.


Why does the unity top panel not show the Chrome icon?

In Unity the "top panel" is a menu bar only, when an application is running in Unity you get an arrow on the left side of the icon (and an additional arrow on the right when the application is focused)


Will Ubuntu work out on my mother's computer?

Yes, Ubuntu is certainly the way to go. And not just because your in a situation. I believe it would probably be better in a number of ways.

All the hardware except the mouse should work perfectly, even the printer and scanner.
Ubuntu should work fine on 512MB of ram, the processor is sufficient too. But not for VirtualBox, that needs a much more powerful machine. But it doesn't look like you need it anyway.
4 & 5 - Card games is something there are a lot of in the Software Center. Especially poker, solitaire and bridge. The windows game will probably work, but it'd be best to try the native games first.
Yes, large font themes are available by default. Check the System > Preferences > Appearance program to set the computer to high visibility and increasing font sizes.
There is a way, but get a usb mouse as soon as possible. serial mice are a almost impossible to get working without serious work.
Install the package ubuntu-netbook-launcher this is a UI which displays nice large icons on the desktop which my mum really likes. You may have to make a start up item so it launches on login and you should pre-fill the favourites with useful things like firefox.
Set your mum up on gtalk with empathy and make sure you two are friends. That way she can ask you for help, but more importantly she can share her desktop with you and you can fix issues even if the any ssh/router configuration gets toasted.


Why doesn't sudo need password when used in rc.local?

As Javier pointed out in comments, the scripts included in rc.local (and init.d) are run by root and then some of them drops privileges or change users, since running services with the root account is normally a security hole. If you want your script run by root even when calling them manually, you can use the SETUID:

sudo chown root /home/victor/startupAP.sh
sudo chmod +s /home/victor/startupAP.sh

But remember that the setuid is ignored if you use a shebang.


How do I use the Malayalam language in LibreOffice Writer?

You need to add the Malayalam keyboard layout.  To do that just follow the images below.

Click on Keyboard Layout

Click the + sign to add a layout

Choose that correct layout that you want, and then click add

To switch languages, you can either use that key combination shown in the image below

Or


Data partition not listed when I want to open a file

Opening an unmounted partition in a file manager like Dolphin mounts it automatically in Ubuntu. In the context menu of the partition in Dolphin, you should be able to see the Mount or Unmount option based on its current status.

If your data partition resides on the internal hard disk and should be available always, you can automount it at startup.
In your specific case, you can simply add the following line to the /etc/fstab file (edit it as superuser, e.g. sudo nano /etc/fstab):

UUID=08CDB5494B990AD2   /media/data   ntfs    defaults    0   0

Add this line below the line where / is defined. It doesn’t matter whether it will go above or below the /swapfile line. The number of spaces between columns doesn’t matter, too.

The second column (/media/data) says where the partition will be mounted. This must be an existing folder which is not used for anything else. If it has not been created yet, create it using the command:

sudo mkdir /media/data

Then reboot Ubuntu and your data partition should be mounted automatically.

See also:

How to make partitions mount at startup?
Howto auto-mount windows-partitions using /etc/fstab


This is definitely a problem I've noticed as well. I have a very fast computer with an SSD and no CPU was being used by the process giving the cursor. An empty gedit window would show the dang thing.

In fact this problem drove me so crazy, I decided to go with the "hackish" solution - get rid of the "thinking" cursor.  I never needed it anyways.

The way to get rid of the "thinking" cursor without breaking anything is to simply replace it with the normal cursor image.

If you're using the default cursor theme DMZ-White, simply open a terminal (Ctrl-Alt-T) and run these commands:

cd /usr/share/icons/DMZ-White/cursors
sudo mv watch watch.old
sudo ln -s left_ptr watch
nohup unity --replace &
exit

Restart if the problem still occurs.

Now, this doesn't technically fix the problem, but it definitely hides it out of annoyance.


How to update composer 1.6.3 to latest version 2.0.4?

Remove the old composer (the one in the repros):
sudo apt remove composer

There will remain a directory with preferences in your home folder. Move that out of the way:
mv ~/.composer ~/was-composer

Then, execute the four commands at the top of this page: https://getcomposer.org/download/
You now have a local version that you can run with php composer.phar. To make it global, first make it executable, then copy it to a directory that lies on your $PATH:
chmod +x composer.phar
sudo mv composer.phar /usr/local/bin/composer

Now you can do composer require... etc., from any directory.


Why LibreOffice keeps saying the document is locked for editing?

There should be a hidden "lock" file created by LibreOffice and, for some reason, not automatically removed when the document was closed.

Open the folder where the document is located and press Ctrl+H to show the hidden files, then search for a file with a name similar to your document file name, but starting with ".~lock.". Remove that lock file and you're done.


With the last openssh upgrade, I had to reauthorize all of my connections before forwarding them to sshpass.


What event failed? As far as I can tell everything is mounted as expected and the system boots fine

I would start with /var/log/boot.log and /var/log/dmesg.


Wine won't run any .exe programs that are installed on other Drives

install ntfs-config

then tick the "Enable write support for internal devices" chekbox

if your windows drive not mounted automatically, type in terminal

sudo mountall

or reboot


The Search Firefox Bookmarks extension seems to be exactly what you're looking for (github link). Take a look at the screenshot from their webpage:


Failed to get properties: No such interface '' in Ubuntu 16.04.3 LTS

The error is in start-tdk-api.sh.  I'm guessing either an environment variable is not set (like PATH) or you're not executing in the directory you think you're in.

You can set environment variables in the service file or update the PATH variable in the script (probably the easiest).

You can also set the working directory for the script in the service file:

[Service]
WorkingDirectory=/directory/to/run/from


How to Solve Wirelesss router issues vs. ISP issues

The easiest way to tell if it's your wireless network\your laptop wireless interface or if it's your Internet connection is going to be the ping utility.

Here's what you need to do

Find the IP of the default gateway on your network:

-Open up a terminal and type:

ip route show

Here you're looking for an entry that looks like this:

default via 192.168.1.1 dev wlan0  proto static

The "192.168.1.1" part is the IP of your default gateway (AKA your router).  Obviously your IP may differ.
Ping the IP of your gateway:

-Back in the terminal type:

"ping" then the IP of your gateway.  For instance if your gateway IP was 192.168.1.1 you would type:

ping 192.168.1.1

The ping command simply sends an echo request and if everything is working right you should begin to see responses from the gateway that look like this:

64 bytes from 192.168.1.1: icmp_req=3 ttl=64 time=1.35 ms

Or you might see something like this which indicates dropped packets:

From 192.168.1.113 icmp_seq=1 Destination Host Unreachable

Let that run for a minute or so to get a good sample size. You should see replies continue to scroll down the terminal until you hit CTRL + C to stop the ping.
Now we ping a random host on the Internet for comparison:

-Open up a second terminal (File->Open Terminal) and follow the same procedure, this time using the command:

ping www.google.com

Now you have two samples that we need to compare:

-Scroll through the replies in the first sample and look for dropped packets (see above) or very high latency (over 100ms in the "time" field).

If if you see a lot either of these issues in the first (default gateway) sample, you can reasonably assume that there's an issue either with your wireless network (or router) or with your laptop/wifi harware.

If the first sample looks fine but you see a bunch of issues with the second (Internet sample) then it reasonable to assume that the issue is with your connection to the Internet.

Take several samples for longer lengths of time if you need to, that will only give you a better idea of what's going on.

If you think the issue might be with your laptop you should try from another computer and see if you get the same or different results.

Good Luck!


How to add an image icon to default executable applications ?

What you need to do is create a .desktop file somewhere like your home folder.  Next, add these lines:

[Desktop Entry]
Type=Application
Name=<Name of your Application>
Exec=/path/to/executable
Icon=/path/to/icon/file
Comment[en_US]=<What you want the mouse over text to be>


The new webapps feature only work with Firefox and Chromium. Google Chrome is not supported because it doesn't allow adding new extensions outside of the Chrome web store while Firefox and Chromium are both open source browsers and adding a new extension isn't as difficult.

That said, if someone does the necessary work to get it integrated into Google Chrome, it might work as well. I just don't see it happening for the 12.10 release.

Do Unity webapps work in Google Chrome?


Screen resolution Issues, Intel HD graphics, Samsung Syncmaster SA10

Replaced the cable.
Faulty VGA cable; there was a pin missing on the one end.

The screen displays perfectly now.


Try choosing a different kernel from Advanced Options in the GRUB menu.


HP-Pavilion-Laptop-14-ce3xxx - RTL8821CE - network not working

Ensure Secure Boot is disabled and then put in the command
sudo apt install rtl8821ce-dkms

Once it is done with the install restart your computer and you should have wifi.
if it is truly already installed, replace the install with reinstall.


Suspend broken on Ubuntu 16.04 LTS, Dell XPS 9350

I had this same problem on an XPS 15 9550. The only thing that worked for me was going into the bios and turning on "Block Sleep" under power options. This apparently turns off Intel Rapid Start and sleep (state 3). So technically the machine doesn't hibernate / suspend (state 3), but it does go to a higher sleep state when closing the lid / opening / power button and comes back fine. Seems like until the issue is addressed in the kernel, or driver this may be the only option and is the only thing that worked in my case.

EDIT: This script worked for me and I was able to turn off Block Sleep in bios! Sleep / suspend now works on my ubuntu 16.04:
https://ubuntuforums.org/showthread.php?t=2317843&page=11


It does not work out of the box.
Apparently magic jack itself was developing linux drivers but they terminated the project.
there are some ways to get it to work though.

If you connect your magic jack with your router you can use it with the guide at the bottom of this page

If you connect your magic jack with your pc you will need to run it with a virtual machine
You can use this guide

I hope this helps


Try to create the directory /lib/firmware first (at least I guess that's why it fails; I might be wrong):

sudo mkdir -p /lib/firmware


Single click to open items issue in budgie

You cannot change the behavior where just hovering on the file/folder would also select the file (unless, of course, if you can edit the source code). To select a file with a click, hold down Ctrl or Shift.

Apart from the requirement to press a key for selecting one file, you can employ these keys as usual to select multiple files: Ctrl allows you to select additional files, preserving the selection. Shift allows you to select a range.

So the only difference compared to the default behaviour of "Double click" is that you should be holding down Ctrl or Shift before clicking the file you wish to select.


There is no public key available for the following key IDs 1397BC53640DB551

I resolved running:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 1397BC53640DB551

The command above download the missing key using the hexadecimal numbers given in the error (1397BC53640DB551) with apt-key. After running apt-key to download the missing PUBKEY, any packages from that repositories will be considered trusted.

It seems to be a known problem in chromium that is being worked on (check here). They are working to remove SHA1 encryption (link).

Another possible workarounds that have been posted on reddit

wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | sudo apt-key add -

Looking at this, seems that Google now has two keys, and the old one will probably be discontinued along with SHA1.


This problem has nothing to do with Thuderbird.  In an effort to fight spam servers are tightening up their requirements.  One of the common requirements for relaying is that the IP address have a PTR record, often with the addition requirement that it passes rDNS validation.  Some servers will freely forward for servers from IP addresses they consider local.  It appears your relay (SMTP) server does not relay for your IP address.

If you are using your ISP's relay, you should configure Thuderbird to connect to the Submission (587) port and authenticate with your credentials.   It is rare that a server will relay email received on the Submission port without authentications.  If they do, it should only be from IP addresses which are local to the server.  You can configure the credentials when you define the SMTP server used for sending email.  You can also add or modify them from the Account Settings menu in Thuderbird.

See the Outgoing section of my Email Policy for more details on restrictions that may be in place.


That is Nautilus Terminal.
Nautilus Terminal is a terminal embedded in Nautilus, the GNOME's file browser. It is always open in the current folder, and follows the navigation (the cd command is automatically executed when you move to an other folder).
Nautilus Terminal has a lot of functionalities:

It always follows your navigation in your folders.
It supports Copy/Paste (CtrlShiftC / CtrlShiftV).
It supports drag & drop of files and folders.
It can be hidden/shown when you want (with the F4 key).
It is resize-able.

Installation
sudo add-apt-repository ppa:flozz/flozz
sudo apt-get update
sudo apt-get install nautilus-terminal

Then run this command to restart nautilus:
nautilus -q

Website: http://projects.flogisoft.com/nautilus-terminal/


How to make locale "de_DE.CP1252" available for "dpkg-reconfigure locales"?

Actually, my questions consists of two parts: The ultimate goal is to not need to apply localedef more often than necessary and I thought that making my locale recognized by dpkg-reconfigure locales solves that. Sadly, that doesn't seem to be the case.

dpkg-reconfigure locales

The following description is ONLY to make some locale available to dpkg-reconfigure locales, it doesn't solve my problem entirely, which I address in another question. The directory created by localedef /usr/share/i18n/locales/de_DE /usr/lib/locale/de_DE.CP1252 still gets deleted whenever dpkg-reconfigure locales is executed after I did the following described steps.

Another answer brought the file /etc/locale.gen to my attention, which contains the following docs:

# This file lists locales that you wish to have built. You can find a list
# of valid supported locales at /usr/share/i18n/SUPPORTED, and you can add
# user defined locales to /usr/local/share/i18n/SUPPORTED. If you change
# this file, you need to rerun locale-gen.

So I created /usr/local/share/i18n/SUPPORTED with the following entry and dpkg-reconfigure locales contained the locale I'm interested in:

de_DE.CP1252 CP1252

The file /etc/locale.gen afterwards contained my locale as the last line as well:

# zu_ZA.UTF-8 UTF-8
de_DE.CP1252 CP1252

And with all other lines in that file, disabling my locale using dpkg-reconfigure locales changes the line to become a comment as well:

# zu_ZA.UTF-8 UTF-8
# de_DE.CP1252 CP1252

So, the important thing seems to be making the locale available in the file /usr/local/share/i18n/SUPPORTED instead of the package default at /usr/share/i18n/SUPPORTED.


Deleting folders from directory which does not contain .txt files within it

Read man find, man xargs, man sed, man uniq. I'd solve your problem like this:

Produce a list of ALL the directories. The ones you want to delete are on this list.
Produce a list of all directories containing '*.txt' files. For simplicity, I'll assume the '*.txt' filenames do NOT contain blanks.
Subtract the two lists, giving the list of directories not containing '*.txt' files.
Pass this list to echo rm -rfv. (Remove the echo when you're happy)

Here's one way:
WARNING I have executed parts of this as Proof-of-Concept, but have NOT done an End-to-End test.

# --depth imposes a bottom-up order
find /dir/groupd --depth -type d --print >/tmp/alldir.tmp

# 'sed ...' changes '/dir/groupd/file1/foo.txt' to
#                    '/dir/groupd/file1'.
# and `uniq` keeps only one, no matter how often '/dir/groupd/file1'
# is generated.
find /dir/groupd --depth --type f -name '*.txt' --print | \
    sed -e 's%/[^/]*$%%' | \
    uniq >/tmp/txtdir.tmp
#
grep -E -v -f /tmp/txtdir.tmp /tmp/alldir.tmp >/tmp/nontxtdir.tmp
# inspect /tmp/nontxtdir.tmp, or
xargs </tmp/nontxtdir.tmp echo rm -rfv


Where is the bleachbit configuration file for root

The config file for "root" user lives at:

/root/.config/bleachbit/bleachbit.ini

If it's not there the run the program using sudo, it should get created.


Completely removing the libs sudo apt-get remove libqt4* and installing again sudo apt-get install libqt4* worked.

There seems to be a different between that and sudo apt-get install --reinstall. I still don't know the cause of the problem.


Dual boot Ubuntu / Ubuntu installation, non-UEFI PC. How do I delete one of the GRUBs?

First decide which of the both systems should control the grub instance in the MBR.
Boot this system and run

 sudo grub-install /dev/sdX

to make sure this system now controls grub. In the second step boot the other system and run

sudo dpkg-reconfigure grub-pc

During reconfiguration of the package you will have the choice to install an instance of grub to the PBR of the system-partition or not to install an instance of grub at all.

That's all, you're done, only one OS will reinstall an instance of grub to the MBR from now on when a system-upgrade ships with a new version of grub.


What is OpenVPN, What does it do on ubuntu?

OpenVPN is a server and client application for providing a secure encrypted connection from one machine to another. The configuration is not entirely simple and you would need to control both the client and server. Usually this is to provide secure, encrypted and authenticated access to a server or network that you control. Often used for remote workers to safely access private resources within a business domain. There are other VPN services which do this, some of which are application built on top of OpenVPN.

What most people want when they're looking for a VPN is a VPN service, which provides the ability to use a VPN to connect to a server somewhere else in the world. Normally this is used to forward internet traffic from that server to your machine, you appear on the internet as if you are the remote server. Most VPN services come with their own dedicated client to connect to them and select the remote server, although it may be possible to connect to some services using the OpenVPN client. Some of these dedicated VPN applications are also built on top of OpenVPN.

This is usually done in order to browse the internet somewhat anonymously, or avoid to avoid some location specific restrictions. I say somewhat anonymously as most VPN service providers keep some sort of usage logs, and may be compelled by their local governments to turn over such information.

If you want a VPN service, you probably don't want to use OpenVPN.


`dnscrypt-proxy' package freeze at update, remove or reinstall

I had same issue which resolved by following:

sudo lsof -i which returned me opened ports like below:

COMMAND    PID       USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
smbd       643       root   30u  IPv6  10183      0t0  TCP *:microsoft-ds (LISTEN)
smbd       643       root   31u  IPv6  10184      0t0  TCP *:netbios-ssn (LISTEN)
smbd       643       root   32u  IPv4  10185      0t0  TCP *:microsoft-ds (LISTEN)
smbd       643       root   33u  IPv4  10186      0t0  TCP *:netbios-ssn (LISTEN)
dnscrypt-  816   dnscrypt    8u  IPv4  10712      0t0  UDP localhost:mdns
dnscrypt-  816   dnscrypt   10u  IPv4  10714      0t0  TCP localhost:mdns (LISTEN)
.
.
.

Last two lines say dnscrypt is alive by PID#816

sudo kill 816 killed it.
sudo apt-get remove dnscrypt-proxy is now free to remove package with no frezze!


in my Ubuntu 14.04 LTS ,when turned on the machine there is no desktop icon ,no menu bars only wall paper

I had the same problem and I solved it by this:
bring up virtual console by pressing Ctrl + Alt + F1, then type

 sudo apt-get update
 sudo apt-get install ubuntu-desktop

it will take some time after finishing reboot the system

sudo reboot


Same issue as this one: Ubuntu 18.04 openGL/GLSL problem no textures

Basically, Ubuntu 18.04 LTS ships with a new version of GLM.
The new version of GLM has changed the default constructor for matrices.

e.g.

model = glm::mat4();

must be changed to:

model = glm::mat4(1.0f);

for the same behavior as earlier version of GLM.


First of all: To use boinc, I'd recommend installing it through the software repositories, not from a script. (Simply search for boinc in the Ubuntu Software Centre. You can get boinc manager there, too).

There are many advantages in using the software sources instead of downloaded scripts. It's more secure and you'll get automatic updates through the update manager, for instance.

I never used this script and don't know if it's meant to open any windows or just print to the console its run in. To run it and see what's printed, open a terminal (Ctrl+Alt+T or search Terminal in the Dash). You'll need the path the script is located in. Let's say its /home/fossaw/Downloads. You'd type /home/fossaw/Downloads/boinc_7.4.42_x86_64-pc-linux-gnu.sh in the terminal and hit enter, which runs the script.

If something is printed to the terminal that sound like there is a permission problem, run sudo /home/fossaw/Downloads/boinc_7.4.42_x86_64-pc-linux-gnu.sh. It will ask you for your password and hence run the script with root privileges.


You need to install the gstreamer0.10-plugins-bad package to get LADSPA support within GStreamer.

Cheers,
 Mike.


Ssh allows you to start a new (separate) text login, but that's not the only thing you can do with it. It also allows you to do things like tunnel internet, tunnel a port, and start a graphical program in that new text login and have that program show up on the local computer but run on the remote one. All of this is encrypted, so it it safe to send confidential things like passwords over it.

Also, do realize that on a Linux machine, it is possible for a user to be logged in multiple times. (This seemed so cool when I first came from Windows).

VNC sends passwords unsafely, which means that it is possible that someone could listen in on your connection and then use the password they hear to login themselves!

So, the general idea is to use ssh to securely connect and start a new text login that you basically don't use. Then you tell ssh to also tunnel the port for VNC, which means that the VNC is wrapped in the ssh encryption so no one will hear your password. When you connect to the remote VNC server, it show the graphical login, not the text one.

How to do this:

you run something like

ssh <monitoredusername>@<monitoredcomputeripaddress> -L <randomportabove1024>:localhost:<monitoredcomputer'svncserverport>

This will magically make the monitored computer's VNC server "appear" on your local computer at . Then you can do

vncviewer localhost:<randomportabove1024>

to login.


Why am I getting this undefined reference error while trying to build a c++ project?

looks like to need to install the stdc++ dev files

sudo apt-get install libstdc++-4.8-dev

then to compile the code

g++ -o execname ./sourcefile.cpp -std=c++11


I think that the issue is with the pulseaudio configuration files. They are somehow messed up.

I had the same problem with my linux Ubuntu 18 and I searched online for a long time until I found the answer.

The easiest and most effective solution is that you delete all the configuration files for pulse (pulseaudio) and then restart pulseaudio.

type the following code in the terminal:

rm -r ~/.config/pulse*
pulseaudio -k

Hope it helps!


Download one of the available Eclipse bundles from the official site. I got eclipse-SDK-3.7-linux-gtk-x86_64.tar.gz
Extract it

tar xzf eclipse-SDK-3.7-linux-gtk-x86_64.tar.gz

Or just be lazy and Right Click > Extract Here
Move to /opt/ folder

mv eclipse /opt/
sudo chown -R root:root eclipse
sudo chmod -R +r eclipse

Create an eclipse executable in your path

sudo touch /usr/bin/eclipse
sudo chmod 755 /usr/bin/eclipse
sudo nano /usr/bin/eclipse

copy the following into /usr/bin/eclipse

#!/bin/sh
#export MOZILLA_FIVE_HOME="/usr/lib/mozilla/"
export ECLIPSE_HOME="/opt/eclipse"

$ECLIPSE_HOME/eclipse $*

save the file (^O = Ctrl+o) and exit nano (^X = Ctrl+x)
Create a gnome menu item

sudo nano /usr/share/applications/eclipse.desktop

copy the following into /usr/share/applications/eclipse.desktop

[Desktop Entry]
Encoding=UTF-8
Name=Eclipse
Comment=Eclipse IDE
Exec=eclipse
Icon=/opt/eclipse/icon.xpm
Terminal=false
Type=Application
Categories=GNOME;Application;Development;
StartupNotify=true

save and exit nano
Launch Eclipse for the first time

/opt/eclipse/eclipse -clean &


wifi connected but no internet access in ubuntu 16.04

Type this in your terminal : ping www.google.com

When you will press enter, it will start pinging Google and a long stream of text will be visible in the terminal. If after pressing enter this message is displayed "Host not found". Then maybe your WiFi driver isn't compatible with Ubuntu 16.04. Either move to 14.04 or run 16.04 using a live USB and then try to connect and browse the Internet. If it connects and Internet works fine in Live USB, then reinstall Ubuntu.

I also faced this problem but when I booted using Live USB, the problem was solved.

Let me know if this works. :)


Can't drag/drop applications to a different desktop

I'm going to take a guess and suppose you were using metacity on the older system, and are now using compiz.

Compiz works a bit differently with the GNOME-panel, and you can't drag the applications on the panel to a new workspace. You can however, drag the application by the title bar and move it to the edge of the screen. This will cause the window to change to the next workspace (so long as you have the advanced effects enabled in appearance properties).

Leave me a comment if you need more detail.

EDIT:
You will also need compiz config to enable dragging windows across desktops.
Desktop wall (or cube if you like) provide the option. In desktop wall for example:

The option is edge_flip_move. You can also you edge_flip_dnd for drag and drop :)


Problem installing kubuntu from iso in hard disk drive

You use the wrong path to your .iso-file in the linux-command:

linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=${isofile}

should be

linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/home/jorge/Torrents/$isofile

You should also add the parameters noprompt and noeject to this line:

linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/home/jorge/Torrents/$isofile noprompt noeject

to prevent being prompted to remove the installation media when the installation is finished and the machine is going to be rebooted.


Repair the package management by running

sudo apt-get -f install

This will complete the installation of packages that are not installed or configured completely.


AMD Radeon HD 3000 Series (I installed but where is aticonfig)

Check this article. It gives the most comprehensive explanation on ways to install ATI Drivers. The link will answer most of your questions. I presume that you want to install the drivers manually, you might want to read section 3 in the link.

aticonfig --initial configures X to use ATI drivers provided they are installed properly. Make sure you run this command as soon as your drivers are installed completely and before rebooting.


Laptop vendors install different Wifi+BT modules to the same laptop models.

Hence there is no guarantee that BT will work, since not all BT adapers are supported by Linux kernel. If you could find out which adapter is installed, it will be possible to tell if it is supported.

Atheros, Intel and Broadcom chips are supported.


Español/English - Trouble downloading / Problema descargando adobe-flashplugin_11.2.202.236

In my opinion You should go to Adobe get Flash www and install it using apturl (choose Linux OS and apturl). Installation should proceed automatically. (Here I assumed x64 Ubuntu).

Regards


How to extend Ubuntu disk space without using Live CD?

use easus partition master (or any other that you prefer) on windows to resize the partition of ubuntu...


Will 13.10 format a usb stick native via "Files"?

There's nothing broken.

To format a partition, you need to have write access to the partition file in /dev. This can only be done as superuser (root). You should've noticed that GParted asked you for your password. At this moment you granted the program root permissions.

Nautilus, or any other file browser/manager, is run with user permissions by default, so it can read and write to the mounted stick directory, but not to the device file itself, which it would have to do in order to format the partition. To run Nautilus with superuser permissions, open a terminal and enter gksudo nautilus.


I found a great tool to install pentest tools on Ubuntu. It's name is Pentesters Framework (ptf).

You can install It from this link , and see this link for a  description.


Can I create a Custom "Taskbar" in Ubuntu Unity

I found a way, using the latest version of Wine, I can install Rainmeter, a better Windows Conky Alternative, and do everything I wish to do. Its easier to program (since I'm used to the program on my other PCs). Unfortunately if you wish to copy my work, at the current time you can only install Rainmeter 1.3 or lower, anything higher will crash as you attempt to open the program (may work differently on your installation). Also transparency's do not work, they appear black. Not much of a problem for me.


the 'djmount' package will let you mount dlna/upnp servers to a local directory and the contents will appear as local files  you can then play.  This should let any video player access the files as if they were on the local machine.

Ive only toyed with it a little bit but it does seem to work for my anime.

djmount (source: djmount): file system client for mounting network media servers. In component universe, is optional. Version 0.71-6 (raring), package size 66 kB, installed size 163 kB

its homepage with guides and docs   http://djmount.sourceforge.net/


Android SDK Manager failed to create directory

It was a permission related issue only. Got it installing the packages by using sudo and providing the full path to android as /path/to/sdk/rootfolder/tools/android.


IMHO The latest phablet-flash tool update creates way too many zero length lock files.

For each build directory in Downloads/phablet-flash/ubuntu-touch/, type the following:

touch Downloads/phablet-flash/ubuntu-touch/<build-date>.lock

eg. (for your example)

touch Downloads/phablet-flash/ubuntu-touch/20130808.lock

Note: This should not reoccur for any future downloads.


X299 ACPI Error: UEFI or Driver/Kernel bug?

There was a new Beta-Bios yesterday (1.42). This solves the problem.
I can now boot a standard Ubuntu 17.04 normally and with ACPI turned on.
So far it also looks stable.


The uptime command lists load average for the last 1, 5 and 15 minutes:

$ uptime
 05:49:47 up  8:40,  1 user,  load average: 3.38, 2.16, 1.87

The load needs to be divided by number of CPUs. For example my system is a quad core (4 CPUs) Hyper threading (2 threads per CPU) so I need to divide by 8. The 5 minute load average of 2.16 is really .27 or about 27%.

You can learn more here and here.


Problem installing Ubuntu 11.10 on new laptop

Here are the instructions:

In grup menu, press e.
Then find the "quiet splash" words and change it with "nomodeset" (if your graphics card is nvidia) or "radeon.modeset=0" (if radeon).
Then press Ctrl+x button conbination to continue with the changes you have just made.

It would help you maybe.


Is there any way I can get a package name from terminal?

apt-cache search searches the local package database of enabled repositories, in relevant files within /var/lib/apt/lists/ directory, as presumably the package is not available in any of your enabled repositories, you are not getting anything expectedly.

There are different techniques to install packages from any user (compressed) archived file like the one you have (PCL_TLKBGL.tar.gz) by (usually) extract, create, copy cycle. The installation and uninstallation instructions should be written inside some file within the archive, possibly a README.

Now, as you have used a install.sh script to install the package, there might be a uninstall.sh or there could be some method mentioned, you never know. So extract that compressed archive (PCL_TLKBGL.tar.gz) you have and check inside for any hint.

As a side note, if you use sudo make install as the last stage of installation (this will copy relevant files to mentioned directories), you should look at checkinstall instead to create a .deb archive out of the files and easily maintain/remove using package managers.


Resuming an upgrade to 12.04 which got stuck on reconfiguring dropbox

I know this is not quite the question you asked however here is a short discussion about the dropbox problem:

http://ubuntuforums.org/showthread.php?p=11891423

In fact to update dropbox it must be stopped (killed via sudo gnome-system-monitor)


apt-get hangs, waiting for suitable packages

First, get the process id (pid) of the apt-get that is running:

ps ax | grep apt-get

Then kill the process by its pid:

sudo kill -9 [pid]

Or use htop, it lists your processes and enables you to send a variety of signals.


usbip - Why is linux version different in linux-source package and uname -r?

To install USBIP 2.0 on 4.2.0-42-generic I had to find the source code to USBIP. It is not /usr/lib/linux-tools/. The source was to be found in the folder: linux-lts-wily-4.2.0
I found the source in this folder: linux-lts-wily-4.2.0/tools/usb/usbip

Following the instructions in this link I was able to compile, install and run USBIP.

Installing linux-tools-generic did not work. I had to compile from source.

I can now connect to my Arduino on my Raspberry Py's USB port from my Ubuntu computer. Much faster than using XRDP and running Arduino IDE directly on the Raspberry Pi.


How can I fix stability problems with Unity 3d on 12.04 with Nvidia drivers?

I had the same problem in that after 2-3 hours with Unity 3D the console would become unresponsive (display freeze), and the screen became corrupted (applications straddling across workspaces). This was compounded since I run VMware Player with Windows7.

Solution 1: Run in unity 2D mode which had no problems, so obviously the issue with Unity 3D is the graphics driver. Standard Ubuntu 12.04 comes with Nvidia driver 295.40 so the next solution was to upgrade.

Solution 2: Upgrade to the latest proprietary Nvidia driver. This may solve the issue since the release notes on the Nvidia site indicates there are issues with the recent Nvidia drivers which have only just been resolved (read: there may still be some problems!). I have had no problems (up for more than 24 hours, no freezes) except occasional pixel corruption in my VMWare player window.

The easiest upgrade route is via the PPA mechanism since this will properly upgrade the current driver.
Just do (from https://launchpad.net/~ubuntu-x-swat/+archive/x-updates):

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

The only caveat, is to remember to uninstall this PPA when you do the next distribution release upgrade:

sudo ppa-purge ppa:ubuntu-x-swat/x-updates

Real Solution: Ubuntu 12.04 should upgrade the standard Nvidia driver as part of the normal upgrade/update process rather than have users use a PPA.


dumplicated entry in fstab:
UUID=51a0d1be-d9d7-4d08-aebc-bddc25cdc4e5 none            swap    sw              0       0

you should remove one of them, even though the comment has some difference.


LightDM login Background Sync with Nitrogen

This worked for my computer (Ubuntu 14.10)
Run it when you change the nitrogen background.
Note: Do NOT run this code as root; it will ask for root when nessarary!

#! /bin/bash

# backgroundsync.sh -- Sync background between nitrogen and lightdm

IMAGE=`cat ~/.config/nitrogen/* | grep "file" | cut -d "=" -f2 | head -n 1`

sudo xhost +SI:localuser:lightdm
sudo su lightdm -s /bin/bash << END
gsettings set com.canonical.unity-greeter draw-user-backgrounds 'false'
gsettings set com.canonical.unity-greeter background '$IMAGE'
END


Mouse lag while running Ubuntu 16.04 LTS in 4K with this monitor: LU28E590DS

For anybody reading this with an Nvidia card, after my initial tests using the following hardware:

CPU: Intel 6700K
RAM: 64GB DDR4
VID: Nvidia 1080 GTX
SSD: 2x Samsung SSD 850 PRO 1TB (Raid 0)
TV:  Samsung KS8500 4K
OS:  Ubuntu 17.04 & 17.10

I had the same choppy lagging mouse movement. The solution was raising the refresh rate of the resolution. In my case it was in the Nvidia Settings. The video card had the Refresh Rate in AUTO (Which was setting it up as 30Hz). I changed it to 60Hz and that solved the issue.

The mouse now moves correctly and smooth.


How to completely clean disk previously used in Windows?

" I want to completely delete all files."
You can use bootable Ubuntu installation media to use a live session.  This is the "Try Ubuntu" option.
Once you are in a live session, you can use the "Disks" application to format your local hard drive(s).  If you have anything on or connected to the device that you want to keep, make sure you choose the correct disk, because formatting a disk will effectively erase everything.


I want to create a video of same resolution as of image

Omit the scale filter if you want the video to be the same resolution as the input:
ffmpeg -loop 1 -framerate 30 -i image.jpeg -i audio.mp3 -vf format=yuv420p -shortest output.mp4


you'll need an ubuntu machine to develop for ubuntu touch

getting started:
http://developer.ubuntu.com/get-started/

apidocs:
http://developer.ubuntu.com/api/ubuntu-12.10/qml/mobile/overview-ubuntu-sdk.htmlhttp://qt-project.org/doc/qt-5.0/qtquick/qtquick-qmltypereference.html


Rotating screen with Nvidia driver impossible. Why?

Timo Aaltonen has fixed this issue! Thank you.


Whenever I put apt update && apt upgrade -y and this will happen

The error message clearly says that the process is trying to create the file /data/data/com.termux/files/usr/include/proc/version.h.dpkg-new but it exists already.

.dpkg-new files are generally created by dpkg (which is run by apt) to unpack the updated files near the old files. When everything has been successfully unpacked, they are renamed over the old files.
Quoted and adapted from https://raphaelhertzog.com/2011/07/18/deciphering-one-of-dpkg-weirdest-errors-unable-to-open-pathtofoo-dpkg-new/.

However, in your case, another version of that file exists – most likely it’s been kept from a previous dpkg run. This can happen due to an interrupted dpkg run or the file is kept to manually solve conflicts.

If you don’t need the file anymore, delete (or rename) it and run dpkg (or apt in your case) again.


User authenication for Ubuntu Virtual machine using Ubuntu Server

If you want login information to be the same on multiple servers you should look at LDAP.
https://help.ubuntu.com/community/OpenLDAPServer


Perf sched_stat_sleep issues after reboot

Turns out just adding additional fstab options helped fix the permission issue:
debugfs /sys/kernel/debug    debugfs defaults,mode=755 0 0
tracefs /sys/kernel/tracing  tracefs defaults,mode=755 0 0


SSH using putty : Network error connection timeout

ssh service for Ubuntu is sshd, you can check if it's actually running by typing sudo systemctl status sshd, if sshd it's up then try modifying your firewall rules, as long as I remember Ubuntu comes with ufw by default so I will make some assumptions here:
let's  say sshd isn't installed, then sudo apt-get install sshd.
Try this for testing firewall:
iptables -A INPUT -p tcp --dport 22 -j ACCEPT
Now try to ssh into your server, if it works then remove the iptables entry.
Personally I prefer firewalld because that's the firewall I use daily if you want to use it install it with sudo apt-get remove ufw && sudo apt-get install firewalld
After installing firewalld assuming your nic (ethernet interface) is eth0 move it to public, considering that this is a server and security matters:
sudo firewall-cmd --permanent --zone=public --add-interface=eth0
Not recommended add ssh service for this interface: sudo firewall-cmd --permanent --zone=public --add-service=ssh (if you do this you will receive a lot of traffic coming from people trying to enter your server)
Now let's say you have an static ip if you use an static ip on your personal computer then you can add that ip to a whitelist, there are many ways to do this but I will tell you my favorite
sudo firewall-cmd --permanent --direct --add-rule ipv4 filter INPUT 0 -p tcp --dport 22 --src MY-STATIC-IP -j ACCEPT
If you have any problem let me know and I hope this help you!!!


Cannot auto-start LXC containers created with LXD

It's a few months later now, and autostart is (for some time now) supported in lxd itself.  You can just

lxc init ubuntu u1
lxc config set u1 boot.autostart true

Now u1 will autostart on each reboot.


Fan is on at a fairly low temperature, but working as intended. How can I adjust this on a thinkpad to save battery?

A utility called fancontrol might help. Install:
sudo apt install -y fancontrol

Page on arch wiki:
Fan Speed Control - ArchWiki
This might only work if your laptop is relatively new. It needs to have PWM(pulse-width modulation) for being able to adjust it.
Edit: Found a good answer: power management - How to control fan speed?


How do I install gedit without Zeitgeist?

First, uninstall the zeitgeist package and allow gedit to be automatically uninstalled. Then:

sudo su
apt-get download gedit
apt-get download gedit-plugins

dpkg --force-all -i gedit_3.6.0-0ubuntu1_amd64.deb gedit-plugins_3.6.0-0ubuntu1_amd64.deb

Just did this on Xubuntu 12.10 and it seems to be work fine on my system. Note that the exact name of the deb files will differ. You should disable the zeitgiest plugin which will still be installed in gedit, since presumably it won't work anyways.

(note: dpkg command borrowed from this question):

How can I install a package without installing some dependencies?


Pulseaudio using WSL E: [(null)] pulsecore/pid.c: Daemon already running

Short answer: delete the file

  %USERPROFILE%\.pulse\%USERDOMAIN%-runtime\pid

(replace USERDOMAIN with USERDOMAIN_ROAMINGPROFILE if you are using a roaming profile)

Explanation:
I recently ran into this and using Sysinternals PROCMON I was able to track down the cause:

Usually GNU applications designed to run as a service adhere to a practice to setup a runtime PID file in order to avoid duplicate launch. On crash, the start/stop script of the service handles removing the stale PID file in most cases.

On this case however there is no script handling the start and stop of pulseaudio.exe so on crash the PID file remains then at next startup the app refuses to start, seeing the PID file and wrongly concludes 'oops we are already running'

(WSL IS NOT LINUX, by the way; pulseaudio.exe is a GNU application compiled to run in windows independent of WSL)


Optimization: RAM cleaning and monitoring

Memory management in Ubuntu and Linux in general is fairly optimal.  Any applications that cause memory problems (eg "memory leaks") would be considered buggy. Unused RAM is utilised by the system for read-ahead cache and other optimisations.  These optimisations are removed from memory if it required by the system, so there's no need to clean it either manually or by some kind of watchdog daemon.

If you run out of normal memory, then the system will start to use the swap partition, so it's important to at least have one set up.  This will cause performance to degrade but will prevent the system from crashing if you do run out of normal memory.

If you are consistently using a large amount of swap in normal operations it would be a good indication that your system is underspec'd for the kinds of things that you are trying to do.  If you hardly every use any swap, or only use a tiny amount after extended run times then you don't have an issue.  To get an overview of memory usage open a terminal window and type

free


New Acer Nitro 5 with Ubuntu 16.04 show No space available 0.0KB

Storage Scheme got to change from SATA RSI to AHCI and for Acer you could achieve such a by reference
https://ubuntuforums.org/showthread.php?t=2439670


Researching on forums, it looks like your card is not supported properly. Try(in a terminal) sudo apt-get install linux-wlan-ng-firmware linux-wlan-ng hostap-utils

If you don't know what to do with the commands you above, you may press CTRL+ALT+T and then type the command(Or paste with right-click>PASTE as Terminal uses Ctrl+V for something else.)

Source: http://ubuntuforums.org/showthread.php?t=1848327


What is the difference between graphics drivers in the kernel, and graphics drivers for Xorg?

Difference between two files

Differences can be found on many levels. For this limited answer the size differences and application differences are described.

Size differences

$ ll /usr/lib/xorg/modules/drivers/nouveau_drv.so
-rw-r--r-- 1 root root 221200 Jul  6  2017 /usr/lib/xorg/modules/drivers/nouveau_drv.so
$ ll /lib/modules/4.14.20-041420-generic/kernel/drivers/gpu/drm/nouveau/nouveau.ko
-rw-r--r-- 1 root root 3646510 Feb 16 15:53 /lib/modules/4.14.20-041420-generic/kernel/drivers/gpu/drm/nouveau/nouveau.ko

The kernel Nouveau module is 16 times larger than the Xorg driver. This implies the kernel module does a lot more.

There are additional Xorg drivers some systems (especially laptops) will have:

  In Debian the 2D graphics drivers for the X.Org Server are packaged
  individually and called xserver-xorg-video-*.[7] After installation
  the 2D graphics driver-file is found under
  /usr/lib/xorg/modules/drivers/. The package xserver-xorg-video-nouveau
  installs nouveau_drv.so with a size of 215 KiB, the proprietary Nvidia
  GeForce driver installs a 8 MiB-sized file called nvidia_drv.so ...

The nvidia_drv.so is 37 times larger than nouveau_drv.so.

Application differences

The kernel Nouveau module is a .ko file and the Xorg driver is a .drv.so file type. This question asks what the difference is between the two file types. The best answer (IMO) states:

  In laymen terms:

  Kernel modules (ko) run in kernel space, user modules (so) run in user
  space.

  Kernel spaces facilitate (or not) access to a variety of functions
  that user space does not.

  Kernel modules are always executed in kernel space and if buggy or
  erroneous, can freeze the system.

  User space is "protected" and a buggy module or app is less likely to
  crash the system.


It seems my pulseaudio server hangs and running these two commands fixes the issue:

killall pulseaudio; rm -r ~/.config/pulse/*
pulseaudio -k

I have not encountered the issue in a while now, it may just have been some bad config. I suspect the initial killall is redundant but since I have not encountered the issue I cannot test it. Hope this helps someone else!


What's the best way to install Unity and KDE together?

Either way will work fine. KDE is just another skin for Ubuntu, and the same goes for Unity. Both ISOs are the same size, so there's no short-term advantage to downloading one or the other.

I recommend you install the one you like the most. That way, if you decide not to install a second DE, or you prefer having a slightly cleaner install, you don't have to worry about installing one DE and uninstalling the other.


Is it resource consuming if I use multiple work-spaces?

If I remember correctly, a workspace is just a "container" for programs. Anything running inside a workspace is still active and using processing power, even if it's not the "active" desktop.

Some programs may treat themselves as minimized or hidden when their workspace is not available, but there should be little to no performance gain or loss.

Meaning, there should be little to no difference between running one Firefox process on each of four workspaces versus running four Firefox processes on one workspace. If anything, there will be a (very) slight performance loss because the system needs to keep track of four workspaces.

As to why, programs in a non-active workspace are still active themselves. A download in Firefox on one workspace will still continue if you're in another. A YouTube video playing in one workspace should[citation-needed] be audible from another workspace.


Ubuntu 14.04 will not show network manager icon

This question is a duplicate here:
My Network Notification icon not showing Ubuntu Kylin 14.04
I would suggest one of the answers that were given to me, try to enter Ubuntu's recovery mode and follow the other steps suggested.

Or you could download your package iso to a USB stick and take update the Network Manager from the USB stick.

The only thing that worked for me though was to update Ubuntu from the USB stick, from 14.04 to 16.04.


My guess is you used sudo to unpack a tarball, or something to that effect, which made the  created directory be owned by root. Fire up a terminal and try this:

sudo chown -R snotbox:snotbox ~/Downloads/Codeigniter

Replace snotbox with your username, and remember that the file path is case sensitive. i.e. ~/Downloads/Codeigniter is not the same as ~/Downloads/codeigniter.


Sounds  like the 5% reservation for the root user. You can change that with

sudo tune2fs -m 1 /dev/sdc5

to 1% like in this example. If it is just a storage partition 0% should be OK too.


Enable the 'table of contents'-sidepane in Document Viewer

As described by '@guillermo chamorro' in the comments: when I press F9 the sidepanel pops up. It can show different things, that are selectable in the dropdown menue on top. To view the table of contents of a document that drop down needs to be set to the 'Outline' setting.


Passwordless ssh to vagrant to load another user after vagrant ssh

config.ssh.private_key_path should point to your private key file (usually ~/.ssh/id_rsa — the name of the file is displayed when you run ssh-keygen), not ~/.ssh/authorized_keys.


Can't boot my Ubuntu 12.04 machine; displays error on start

Fixed it.  The problem was the hard drive was full, and XServer couldn't start.  I freed up some free space and the problem went away.


How to install a dual-boot Ubuntu in BIOS mode and Mac OS X?

I was able to get Ubuntu booting in BIOS mode following experimentation with manual GRUB installation. Subsequent to that, my NVIDIA drivers worked.

The key factor is that grub-install will either install a BIOS or EFI version based on factors I don't understand. More importantly, I was not able to find an option that forces the BIOS version to be installed from an EFI machine. (The --target=i386-pc option was not working for me.) I found a special case: when running the Ubuntu Live CD on a Mac, grub-install installs a BIOS version not EFI, even though the Live CD is booted in EFI mode.

Sketch of the procedure:

Partition hard drive in Mac Disk Utility, making at least two partitions for Ubuntu. 1) a very small GRUB boot partition, and a partition for the root file system.  Format for the partitions can be anything, they will be changed later.
Boot the Live CD.  Start the installer from a terminal using ubiquity -b.
Run the custom installation "Something Else". When given the partition options, select the root partition and format it for linux, setting the / mount point.  Edit the the GRUB boot partition, changing the partition type to BIOS Boot -- and mark it System Partition and Legacy BIOS Bootable.
Complete the Ubuntu installation.  Do not reboot.
We'll install GRUB from Terminal in the Live CD session.  For whatever reason, this installs the BIOS GRUB. Terminal Commands: (sdX is the drive to install GRUB and the Ubuntu installation)

$ sudo mount /dev/sdX /mnt
$ grub-install --root-directory=/mnt /dev/sdX
  Installation finished. No error reported.
$ grub-install --root-directory=/mnt --recheck /dev/sdX
  Installation finished. No error reported.
$ ls /mnt/boot/grub
  #the presence of the director i386-pc is a great sign.

Configuring the GRUB installation is a bit tricky.  We run it as though /mnt is the root filesystem.

$ sudo mount --bind /dev /mnt/dev && sudo mount --bind /dev/pts /mnt/dev/pts && sudo mount --bind /proc /mnt/proc && sudo mount --bind /sys /mnt/sys
$ sudo chroot /mnt
$ update-grub
$ exit

Running grub-install from the above context would install the EFI GRUB.  This explains the two steps.

Note: If the above update-grub command fails due to executable not found then this procedure needs an adjustment. That indicates the initial condition for Step 5 is that the application package GRUB2 be installed on the target installation already. This procedure has not been tested straight through.
If all went well, you should be able to restart.  Hold down the option key, and you should a boot option presented by the Mac called Windows.  That should boot you into GRUB, which will be set up to boot the new Ubuntu installation.


How to set static IP address on Ubuntu 16.04 LTS?

First, verify that the address and other details are valid; that is, that you haven't specified 192.168.15.xx when the network is actually 192.168.0.xx.

Second, verify that the selected address is not in the pool used in the router for DHCP addresses. You can either look in the administrative pages of the router or, if this is not feasible, by guesswork. What do other computers, phones, iPads, etc. get for addresses. For example, if devices on the network get addresses like 192.168.15.4, 192.168.15.5, 192.168.15.7, etc. then I'd suggest a static IP address of 192.168.15.100.

Set you details in Network Manager similar to this:

Be sure to specify DNS nameservers. Usually, the gateway address is sufficient but I would also include a fallback, such as 8.8.8.8 or 8.8.4.4.

Click Apply and restart NM from the terminal:

sudo service network-manager restart

Check:

ip addr show
ping -c3 www.ubuntu.com


smbclient shows me my share, smbnetfs does not

OK, problem solved.

I changed the auth file to :

auth "HOME" "mderouss" "password"

This did not solve the problem.

Then I also corrected a problem I noticed in the nmbd log ( /var/log/samba/log.nmbd ) :

[2015/11/08 14:27:01,  0] ../source3    /nmbd/nmbd_nameregister.c:492(register_name)
register_name: NetBIOS name MARK-HP-PRO-3120 is too long. Truncating to
[2015/11/08 14:27:01,  0] ../source3/nmbd/nmbd_nameregister.c:492(register_name)
register_name: NetBIOS name MARK-HP-PRO-3120 is too long. Truncating to
[2015/11/08 14:27:01,  0] ../source3/nmbd/nmbd_nameregister.c:492(register_name)
register_name: NetBIOS name MARK-HP-PRO-3120 is too long. Truncating to
[2015/11/08 14:27:24,  0] ../source3/nmbd/nmbd_become_lmb.c:397(become_local_master_stage2)

I changed the hostname to 'mark-lab1', and whoopee, smbnetfs now works and I have my smb network mounted where I want it :).

I think what was going on was that my hostname was ( for reasons unknown ) being truncated to nothing, although exactly how that would lead to this problem I don't know.

Cheers,
Mark


Usually, when the display server is not responding you can still obtain a non-graphical login screen by typing Ctrl+Alt+F1.

Then you should be able to login, and you should look at the log file /var/log/Xorg.0.log. Please paste here any error appearing in this file.


Perhaps you've gone about it the wrong way - by default, apport doesn't have to be disabled to handle unpackaged binaries, it will just log a few lines in its log file (/var/log/apport.log) and fall through to the default kernel behavior - write the core file to the current directory.

If this did not work for you, it probably wasn't about apport, it's more likely you didn't have some other prerequisite, such as the directory of foo not being writable to the user running the binary.


Are there download limits for Ubuntu-One published files?

You should have no problem doing what you describe.


So the answer is, 16.04 does not have Polaris (RX 480 470 460) firmware, so it can't run.

You need to install .deb package from future release, e.g. http://packages.ubuntu.com/yakkety/all/linux-firmware/download

You also need at least kernel 4.7 http://kernel.ubuntu.com/~kernel-ppa/mainline/ and

updated Mesa; e.g. Oibaf PPA: https://launchpad.net/~oibaf/+archive/ubuntu/graphics-drivers


Flash 9.0.115.0 brought 3D hardware acceleration to Linux. Due to a series of problems using 3D acceleration, the feature is not enabled by default.

To enable 3D acceleration you have to set OverrideGPUValidation to true.

You can either do this in:

/etc/adobe/mms.cfg (you might need to create the folder) for a system wide change
~/.adobe/mms.cfg for a user change

See here: http://blogs.adobe.com/penguinswf/2008/08/secrets_of_the_mmscfg_file_1.html


Go to the Cannon Asia website (or any other Cannon website) and download the driver CAPT Printer Driver for Linux Version 2.60. Then execute the following steps:

Extract it to get a folder containing directory 64-bit_Driver/Debian, enter inside.
Install the deb file cndrvcups-common_2.60-1_amd64.deb through terminal:

sudo dpkg -i cndrvcups-common_2.60-1_amd64.deb
sudo dpkg -i cndrvcups-capt_2.60-1_amd64.deb

Install portreserve:

sudo apt-get install portreserve

Restart the printer

service cups restart

Add printer and start the Cannon Printer daemon.

sudo /usr/sbin/lpadmin -p LBP2900 -m CNCUPSLBP2900CAPTK.ppd -v ccp://localhost:59787 -E
sudo /usr/sbin/ccpdadmin -p LBP2900 -o /dev/usb/lp0
sudo service ccpd start
sudo service ccpd status

Check the printer status

captstatusui -P LBP2900

If you are seeing the message “Ready to print”, you are done...


Invalid partitions table! after deleting fully encrypted ubuntu disk and install ubuntu over it

It was that BIOS was set in legacy mode.
Setting it to EUFI - non secure boot fixed it.

I really don't know what changed it or why ubuntu hasn't detected it.


how can i import photos from a canon digital camera?

Usually one can simply connect a USB device to Ubuntu and the device will automatically recognise it as a camera, or if this doesn't happen you could try inserting the SD card directly into the computer.
Then one can open Shotwell and follow the instructions here

Connect the camera to your computer and switch it on. Shotwell will
detect it and list it in the sidebar.
Select the camera in the sidebar. Previews of each photo on the camera will be displayed.
If you like, you can choose a set of specific photos to import. To do this, hold down the Ctrl key and click to select individual
photos. You can hold down Shift and click to select a range of
photos too.
Click either Import Selected or Import All. The photos will be copied from the camera and saved on your computer.


Is Chromium GTK+ theme lighter than the others?

I tested out my chromium install (Version 24.0.1311.0 (164559)), and it turns out that the GTK Version has a slightly higher memory footprint.

I tested it by enabling and disabling GTK Theme, while checking the memory footprint (Shift+Esc). I had killed all extensions to make sure they didn't affect the results. I also kept only the settings page open so as not to have webkit rendering affect it either.

My results were:

GTK Version - 157,676K
Classic Theme - 157,456K

So, there is a difference, but its too little to be of any relevance.


Aspire One 722 frequently starts with illuminated black screen (64 Bit)

I had a problem similar to yours. After an upgrate to 12.10 I couldn't see the login screen. The screen was only in purple color (like the unity theme) but I heared the login sound. There was no chance to do anything. After googleing today I got the tip the reset the boot options in the bios. There the first entry was the network boot option depending on the freezing bug of 11.10. Now the netbook boots from the ssd first and surprise, surprise, I could see the login screen and could login to the 12.10. Maybe you should check your boot options and move down the network boot option. I hope this will help you.


How to access a different Hard Drive through Ubuntu Shell?

First Mount Your HDD partitions
Let us assume that sdb is your external hard drive and sdb1 is the partition, you want to copy your data to.
Run sudo mount /dev/sdb1 /mnt to mount sdb1 to /mnt. To copy anything to external HDD run cp <required_file> /mnt/<some_folder>


Single-Boot Linux Acer Chromebook 15 CB5 "YUNA"

I run Gallium on my Chromebook (CB5-571). There is a screw you need to remove on the back of the machine to disable write protection. I previously used crouton to run Ubuntu through a Chrome OS tab but I wanted to do away with Chrome OS completely so I opted for Gallium as it's optimized for Chromebooks. I'm running upgraded firmware as well.

First check that your HW is supported.
https://wiki.galliumos.org/Hardware_Compatibility

They have detailed instructions on how to install here:
https://wiki.galliumos.org/Installing/Preparing


You can start Chrome with a key

google-chrome --allow-outdated-plugins

But it is a bug, that will be fixed soon, I hope


How to collect all the "txt" and "log" files using find?

This is almost the same as Raphael B.'s answer, but one that will also handle exceeding the maximum argument length. We do this by simply telling tar to read the filenames to archive from stdin (where there is no limit) instead of expecting them as arguments:

find . \( -iname "*.log" -o -iname "*.txt" \) -print0 | tar --null --files-from=- -zcf "$file"

Note that this is GNU specific. tar on other UNIX or UNIX-like systems does not understand --null, but the tar in Ubuntu is GNU tar, so it'll work fine there.


How do I disable the "CD as package" source from the command line for ubuntu 12.04 LTS server?

You can edit the source list by editing the following file:

/etc/apt/sources.list

This link may be able to help you more.


You probably still need to install the thesaurus as follows:

sudo apt-get install mythes-en-us

And don't forget to enable it under:

Tools > Options > Language Settings > Writing Aids


The system drops to a grub prompt on boot after an update. How do I fix this?

This occurs when GRUB stage1 runs and is followed eventually by stage2 which also runs but halts without displaying the GRUB menu. It is not a system hang but is a working GRUB shell prompt that is preceded by simple editing instructions.

What I think is happening...

The text "grub> " (including the trailing space) and the text of the GRUB shell editing instructions can be seen with a binary file editor in the messages section of the binary file /boot/grub/stage2. Those particular pieces of text do not appear in the binary file /boot/grub/stage1 nor any of the stage1.5 image files. So having the boot process abort to this grub> prompt is good circumstantial evidence that stage2 is at least successfully starting. For example, one of the first tasks of stage2 is to read the file /boot/grub/grub.conf to create the GRUB menu. If grub.conf is not found or is corrupted or is badly misconfigured, booting is suspended ending at this GRUB shell command prompt where commands may be entered manually.

This situation requires correction of the problem with grub.conf. Re-installing GRUB does nothing for a missing or busted grub.conf file. Nevertheless, other reasons for this event apparently happen and are amenable to simply re-installing GRUB as the first example below demonstrates. Therefore, re-installing GRUB should always be tried for this situation if no obvious problem with the grub.conf file can be found.

http://fedoraforum.org/forum/showthread.php?t=214548
http://fedoraforum.org/forum/showthread.php?t=29835
http://fedoraforum.org/forum/showthread.php?t=150590
http://fedoraforum.org/forum/showthread.php?t=2195
http://fedoraforum.org/forum/showthread.php?t=155361
http://fedoraforum.org/forum/showthread.php?t=195339