When is Birth Date for a file actually used?

Birth time is the time when the file was created on the filesystem, also known as the file creation time (crtime on EXTFS). Note that, this is not defined by POSIX; only last access time (atime), last modification time (mtime) and the inode change time (ctime) are mandated by POSIX.

IIRC, Linux yet does not provide any interface for getting the birth time, there is a proposal for xstat() and fxstat(), yet to be implemented.

As @muru noted, the newer approach is statx(), which is merged in the mainline kernel recently. So, any (modified) userspace tool can leverage that (the statx structure now, see below) on any such recent kernel.

struct statx {
    __u32   stx_mask;
    __u32   stx_blksize;
    __u64   stx_attributes;
    __u32   stx_nlink;
    __u32   stx_uid;
    __u32   stx_gid;
    __u16   stx_mode;
    __u16   __spare0[1];
    __u64   stx_ino;
    __u64   stx_size;
    __u64   stx_blocks;
    __u64   __spare1[1];
    struct statx_timestamp  stx_atime;
    struct statx_timestamp  stx_btime;
    struct statx_timestamp  stx_ctime;
    struct statx_timestamp  stx_mtime;
    __u32   stx_rdev_major;
    __u32   stx_rdev_minor;
    __u32   stx_dev_major;
    __u32   stx_dev_minor;
    __u64   __spare2[14];
};

Here stx_btime is the file creation time.

In the meantime, stat is showing absence of the fields (or the empty values) st_birthtime/st_birthtimesec returned by the stat() call, in the stat structure:

struct stat {
   dev_t     st_dev;     /* ID of device containing file */
   ino_t     st_ino;     /* inode number */
   mode_t    st_mode;    /* protection *
   nlink_t   st_nlink;   /* number of hard links */
   uid_t     st_uid;     /* user ID of owner */
   gid_t     st_gid;     /* group ID of owner */
   dev_t     st_rdev;    /* device ID (if special file) */
   off_t     st_size;    /* total size, in bytes */
   blksize_t st_blksize; /* blocksize for filesystem I/O */
   blkcnt_t  st_blocks;  /* number of 512B blocks allocated */
   time_t    st_atime;   /* time of last access */
   time_t    st_mtime;   /* time of last modification */
   time_t    st_ctime;   /* time of last status change */
   };

There are some tricks with filesystem level debugging request to get the creation info from FS metadata e.g. for EXTFS:

debugfs -R 'stat /path/to/file' /dev/sda1

assuming the FS of the file in question is on partition /dev/sda1. You can extract the value of crtime to get the creation time of the file.


How can I configure the buttons of my wacom tablet?

You can use the xsetwacom command line utility.

Should be installed by default.

Example: use xsetwacom --list devices to get the list of devices.

xsetwacom --set <device here> button1 2
Would set button 1 on whatever device to button 2, or right click.

Explore the other flags for xsetwacom with man xsetwacom.
Try xsetwacom --get <option here> to see what options or key-mappings are available.


Files saved with Ubuntu is not visible in Windows 8

Well, under Windows 8, have you made all files visible? Hidden files?

It may also be due bad handling on the Linux side or bad interpretation of Win 8, so safer would be to use FAT32, like on USB-sticks as Linux is handling that perfectly and more easy than the different versions of NTFS.

Hope my limited software knowledge of Linux, but a bit better under Windows is worth something for you...
;3)


First of all: make a full back-up of both systems before continuing!

Just insert the SD-card into the SD-card reader of your laptop, download Lubuntu 32-bit if less then 1GB of RAM or an old processor or 64 bit if less then 2GB of RAM or Xubuntu 64-bit if less then 4GB of RAM or the 64-bit plain vanilla Ubuntu if your netbook has 4GB of RAM.

Then find out from gparted what disk the SD-card on your laptop is.  (sdc on mine, but yours might differ)

Then just go to a terminal by pressing Ctrl+Alt+T and use the following command to copy the iso file to the SD card:

sudo dd bs=4M if=/home/YourUser/Downloads/NameOfIso.iso of=/dev/XdY

where: YourUser is the name of your user name, NameOfIso is the name of the iso file you decided to download, X and Y are the letters of your SD-Card. (You should have downloaded to iso to the Downloads folder!  :P)

Warning dd is the abbreviation of Disk Destroyer!  Ensure twice that the command above is correct before pressing Enter!

When you get your prompt back, type sync and wait some more.  Then shut down the laptop (no hibernate nor suspend) and only then remove the SD Card!  (I only remember "newbie" and forget all about "semi"  ;-) )

Now insert the SD-card in the netbook, turn it on and boot from the SD-card and follow the official installation instructions for the Ubuntu version you decided to install...


postmaster.pid should be absent if the server isn't running. That's correct. It's the process ID of the running PostgreSQL server, and if there isn't one, there's not going to be a postmaster.pid unless the server stopped abruptly, in which case it'll contain the pid of the old postmaster from before the crash until PostgreSQL is restarted, at which point PostgreSQL will replace it with the pid of the new postmaster.

You never need to mess with postmaster.pid. Above all else, never delete it.

Whatever the cause for the service not starting is, a missing postmaster.pid is not it.

You haven't shown what command you used to start PostgreSQL, what the error was, or anything else, so it's hard to help you beyond that. General tips:

you must start and stop services with sudo;
Check /var/log/syslog and the PostgreSQL logs for details on startup problems


How to show window switch bar at the bottom like Microsoft Windows?

AFAIK, Unity can only show its bar on the left-hand side of the screen at the moment. If this worries you a lot, you can:

try installing some dock, such as Docky, AWN or CairoDock. See http://www.omgubuntu.co.uk/2010/04/you-choose-the-best-dock-for-ubuntu-poll/ for an overview.
Use "Gnome classic" session, which does have a panel at the bottom though it's not quite similar to Windows.
Install "kubuntu-desktop" and use a KDE session, which may be closer to Windows experience.

Though I admit the last two options feel like a bit on an overkill for just moving the panel to the bottom :)


Automatic Adding of Filesystems to /etc/fstab

That's normal, because there is no way for tools or operating system to know where do you want to mount the partitions, logical volumes or etc that you have just created.

The ones you create while installing system are detected by your choices (When you select your root, home, etc) and are added to fstab because they are necessary for booting your system.

you have to manually edit the fstab.

BUT, there is other ways to automatically mount partitions, tools like udisks.

https://help.ubuntu.com/community/AutomaticallyMountPartitions


update manager not detecting upgrade to 12.04

There are two things that you can do:

The first is to ALT-F2 and start update manager with the command

update-manager -d

the -d should show the upgrade option (you might have to check for updates first)

The second thing you can do is to upgrade from the command line with the command:

sudo do-release-upgrade


If you have broken packages try apt-get -f to fix it and try add some repository that will help apt to find your packages.
And also check apt-cache command ,It will helps you.


Try ntfsfix.

sudo ntfsfix dev/sda1

and I think you should give the partition number in your mount command,
dev/sda is the disk and dev/sda1 is normally the first partition.


VirtualBox seems to disable printing in Ubuntu to USB Printer

If both the virtualbox guest and ubuntu are sharing the same USB connection then you will need to define either the guest or ubuntu to be the "master" printer server.

For example, you can have two printer connections in ubuntu - one for the local USB printer and the second set to print to the windows guest print server.

Thus, when you want to print from ubuntu when the windows guest is running, select the printer connected to the windows guest.


How to add "share dropbox link" to nemo on ubuntu 18.04

You need to install the package nemo-dropbox, which is not installed by default with the nemo package. That package is needed to ensure integration of Dropbox with the nemo file manager.

To install the package, open a terminal and issue the command

sudo apt install nemo-dropbox

You will probably need to log out and long back in before it takes effect.


You can specify port forwarding for incoming ports to forward to port 22 on each of the computers.

Say you have 4 computers on this network. We will call them A, B, C, and D. You have a laptop on a different network and you want to connect to computer A, B, C, or D.

Set incoming port forward on port 55555, for example, to forward to computer A on port 22.

To connect to computer A on port 22, you would connect to the external IP on port 55555 which will forward to computer A on port 22. The command to connect would read like so:

ssh username@externalIP:55555

example:

ssh holymoses@123.456.78:55555

Set up to forward all incoming connections on port 55556 to computer B, port 22 and so on and so forth.


I screwed up my system no commands work at all

You need to include the folders where commands can be found in the PATH environment variable. So it sounds like your PATH environment variable is missing the /usr/bin entry. What is the output of echo $PATH for your system?

The default for Ubuntu 14.04 is  /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games and you can restore this by simply running

export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

Then you should be able run the command you tried in the first place to add the paths, or to add them all at once you can simply run...

export PATH=/usr/lib/gcc/x86_64-linux-gnu/4.6/cc1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

I hope this helps!


Ubuntu won't boot when first booting with dual boot windows 10

Looks like I figured it out :

I have found the way to disable the secure boot (it was disguised as "attempt secure boot"). This settled the problem with the safe mode being "zoomed in" but not the other one.
I have found another post where they talk about black screen when first booting. It was because of the graphic card drivers (Nvidia) who were not installed because Ubuntu. Here is the detailed solution to fix these drivers problems : How do I install additional drivers?

Reboot and, problem solved! I post it so, if other people have these problems, they know how to solve them!


How do I subscribe to a tag in launchpad?

It appears this was a 'bug' and has been implemented in the latest build (source), and should be available to you now.

is this what you are looking for?


How to fully remove mysql from Ubuntu 18.04?

From the output it is clear that the MySQL was completely removed and systemctl is unable to load and start that service. Whenever a service is modified or removed, systemctl has to be refreshed. To refresh, run:

sudo systemctl daemon-reload

But here for some reason, it wasn't refreshed. In such cases, rebooting helps. Rebooting the system refreshes systemctl thoroughly.


Why can't I change my icon theme in gnome-classic?

OP Fixed it by himself:

  It seems that after uninstalling Unity that I have full control over everything. Any explanation (since Unity or some part of it seemed to be the cause) would be really nice.

Any answers on how it happened will be voted  up


Cannot remove Nexus 5 Network from network list

Is your Nexus 5 plugged in with tethering turned on? Ubuntu is seeing it as another network device. There are two obvious remedies here:

Unplug it
Turn off tethering

But it's probably not responsible for your wider networking issues.


You can use a shell extension called Appfolders Management to do this - it lets you simply right-click the icon and you see the options available, which allow you to add to a new or existing folder.

See: How to install and manage Gnome shell extensions to help you :).


Crawls-Mail fails to enter e-mail address when associated nickname is typed in address field

In the address field, after typing nickname, press Tab and there will be list of emails matching nickname from your address book.


I was getting the following error when the email was trying to send 'Cannot start "/usr/sbin/sendmail": executable not found (adjust sendmail variable)'. The fix for this is to install SSMTP and edit /etc/ssmtp/ssmtp.conf to point to your smtp relay.

This is a good guide on how to set this up http://forums.debian.net/viewtopic.php?f=16&t=56312 .


Ubuntu GNOME 16.04.3 - customize button does not work when I click on it

It seems GNOME Control Center is somehow not installed. You may try installing it by running the following command in Terminal:

sudo apt install gnome-control-center

If it says it's already installed, you may try purging the package first and the reinstalling it.


Unfortunately, the only thing to do now is to:

Restore the system backup you took before you started the upgrade.

If you have none:

Boot an Ubuntu 18.04 Live DVD/USB
Use that one to back up your Documents, Videos, ...
Reinstall
Reboot

If all data is gone:

Restore the backup you just made.


Device lookup failed cryptswap1. Can't boot after upgrade from 16.04 to 18.04

Ok, what I did was commenting out the line contained in /etc/crypttab after that the system started working. What I don't know now is if I still have a swap drive or not. Actually, I'm not sure if this was the correct solution. But, at least, I can login now and all works.


UBUNTU 14.04 LTS tearing and black screen

Go to the ubuntu software center.

Click "edit" and select "software sources".

Now, click on the "additional drivers" tab.

Here, you will be given the option for which driver to use. You can choose to install the nvidia proprietary driver or use nouveau.

If you are using the nvidia proprietary driver and are unhappy with the resolution of Grub2, your splash screen, and the tty terminals, see here https://askubuntu.com/a/594946/167115


Compiling library from source code, how to overwrite current package?

Set LD_LIBRARY_PATH to "/usr/local/lib"

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:"/usr/local/lib" in Bashexport LD_LIBRARY_PATH=$LD_LIBRARY_PATH:"/usr/local/lib"


I can't make Ubuntu ask for a password anymore!

To stop Google Chrome asking for password do as follows:
I think the simplest way is to set the password for the keyring to an empty password -- you will not be prompted for a password then:

Open Applications -> Accessories -> Password and Encryption Keys
Right-click on the "login" keyring. Select "Change password"
Enter your old password and leave the new password blank
Press ok, read the security warning, think about it and if you still
want    to get rid of this dialog, choose "use unsafe
storage/continue".

Again, as the message says: This will expose all your passwords (e.g. email passwords) that you chose to save in the default keyring to anyone using your computer or having access to your files and is therefore not recommended.

To solve autologin problem. Open System Settings. click on User Accounts. click on Unlock(on top-right corner). Then toggle auto-login option. Then log-out and login again. See whether this is working according to auto-login option you set.


Can a script starting with a bad shebang line work?

Likely that different shells/interpreters aren't overly strict, and either don't pay attention to the shebang, or don't fault when the interpreter in the shebang doesn't exist. I would imagine the second is more likely.

What shell were you using in case?


Run

glxinfo |grep string

If you get this

OpenGL vendor string: VMware, Inc.

Then, it looks like I had exactly the same problem: the intel cpu-integrated graphics didn't use intel drivers. I fixed it with the following:

Be sure you have installed intel proprietary drivers. In case you have the drivers installed - jump to step 2, in case you don't, go to https://01.org/linuxgraphics/downloads and download "Graphics Installer 1.0.8 for Ubuntu* 14.10" (they currently don't have the version for 15.04, but this version also works fine), install it with

dpkg -i name_of_the_downloaded_file.deb

The installer of the driver itself won't work, because it checks for Ubuntu version in /etc/lsb-release, so save your original /etc/lsb-release somewhere and change the file to this:

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=14.10
DISTRIB_CODENAME=utopic
DISTRIB_DESCRIPTION="Ubuntu 14.10"

Then run the installer:

intel-linux-graphics-installer

And install the driver (next, next...)

Now, don't forget to replace back the /etc/lsb-release with your saved copy.
Edit the grub config

vim /etc/default/grub

Find

GRUB_CMDLINE_LINUX_DEFAULT="..."

And remove "nomodeset" from this line, because if it's set - it will prevent the driver from loading. Save the file and run

update-grub
reboot

That's all. It should work fine now.


Manually download packages on other operating systems

To find out what packages you need (and the URLs for them), you can use the --print-uris argument to apt-get. For example:

apt-get install -y -d --print-uris ca-certificates

That will list everything you need to download manually on the Windows system. If you want to make it really easy, you could even generate an HTML file with the links that you could load on the Windows machines:

echo "
" > /tmp/debs.html
apt-get install -y -d --print-uris ca-certificates | grep ^"'" | cut -d"'" -f2 | awk '{print "
" $0 "
"}' >> /tmp/debs.html
echo "
" >> /tmp/debs.html

Just access file:///path/to/debs.html once it is on the Windows machine, and you can download all the required packages.


Webapps don't open correctly when using Chromium

Do you have the 'Unity WebApp extension for the chromium browser' installed? If not, go to the Software Center -> Technical Items (or just search in Synaptic). I had to install it to get Chromium working correctly.


Looking into the repository, it appears that there is no conky-manager package available for any version of Ubuntu over 16.04.

Thus, as a workaround, you can simply edit the file
/etc/apt/sources.list.d/teejee2008-ubuntu-ppa-$YOUR_DISTRO_NAME.list and change it to look like this:

deb http://ppa.launchpad.net/teejee2008/ppa/ubuntu xenial main
# deb-src http://ppa.launchpad.net/teejee2008/ppa/ubuntu xenial main

After that, just run sudo apt update one more time and you should be able to install it no problem after that.

Mind you, $YOUR_DISTRO_NAME in the file name above depends on the version you are currently running. You can find out what that is by running: lsb_release -c | awk '{print $2}'


When you open Printing by searching through the dash. You'll get printing dialogue box. And once you click Add, then you should see something like below;

Expand Network Printer by selecting that little arrow, then type the IP on the Host.

Once again, if you do not see such option, please post a screen of what you see.

Useful Link: Network Printing with Ubuntu


Open dconf Editor.
If dconf Editor is not on your system, do:
sudo apt update

sudo apt install dconf-editor

Adjust the following setting...


Most users install programs via command (sudo apt install firefox) or via software.center|ubuntu.software which automatically installs the program to wherever the .deb file dicated.  It's sort of similar with snaps (though they stay as squashfs & aren't installed to your actual filesystem [fs])

Most people's programs aren't that huge; its the data that takes all the space. User data on an ubuntu will generally go to /home/

The /usr is commonly where apt-get|apt|etc will install a program; and its the unix (*nix) default place (ie. historically been put there since '80s if not 1970s)

You can install programs wherever you want!  But when you upgrade; remember where you installed it so it can be backed up & restored.  I install many things in /usr/local/bin out of habit; but others go inside /home as I find it easier to recover if I have problems (/home is on different drives for many of my systems, at least different partition, thus allows me to replace system drive & clean-install but keep).  Also you can choose to use a filesystem that allows growing|shrinking during operation which is more used by servers or mission critical systems.

Note:  don't mix up /root & the / directories.
/root/ refers to the 'root' user directory (equivalent is /home/root/ if it wasn't a special user),
and '/' which is the top or root directory.
my "/" directory is on a small 160gb drive; but i've mounted many tb of directories onto it so the partition & drive sizes mean little.


Boot initialization problem, boot unknown partition, dual boot pc

I solved the problem following the steps:

1- I tried to install Ubuntu again a few more times, then the installation proceeded and created the grub again.
2- I ran the Boot-repair again, and using gparted I could see the boot partition.(as required by Boot-repair).
3- So, I uninstalled the Ubuntu using the OS-Uninstaller from Boot-repair.
4- I ran Windows installer, deleted all partitions preservating my data partitions;
5- Finally, Windows could be installed.

Observation:
If you have problems installing Windows run Boot-repair again, and try install Windows again.

I didn't install Ubuntu again, I will put it in other computer exchanging Windows by Ubuntu.(Only one operating system avoid this type of problems)


Can you try these steps?

Execute this command in a terminal:

sudo apt-get install libgl1-mesa-glx

Retry, if that doesn't fix it continue with the next steps.

Execute this command in a Terminal:

sudo -H gedit /etc/X11/xorg.conf

Add the following to the bottom of that file:

Section "Screen"
Identifier      "Default Screen"
DefaultDepth    24
EndSection

Section "Module"
Load    "glx"
EndSection

Section "Device"
Identifier      "Default Device"
Driver  "nvidia"
Option  "NoLogo"        "True"
EndSection

Save the file
Reboot and retry

Reference:

http://ubuntuforums.org/archive/index.php/t-1810956.html


Can't run Java applications (like logisim) due to "Assistive Technology not found" error

I can confirm your issue on clean Ubuntu 18.04 LTS.
So I reported bug 1788267  to the LaunchPad (currently it is marked as duplicate of bug 1788250 and exists in Debian too as bug 900912).

It is unbelievable - many Java applications are broken and show the same error involving java.awt.AWTError: Assistive Technology not found: org.GNOME.Accessibility.AtkWrapper.

Update 20180913 - bug is fixed. Steps below are not needed (they are included in the updated package).

But we can fix this problem by disabling Assistive Techonologies inside /etc/java-11-openjdk/accessibility.properties:

sudo sed -i "s/^assistive_technologies=/#&/" \
/etc/java-11-openjdk/accessibility.properties

and/or inside /etc/java-8-openjdk/accessibility.properties

sudo sed -i "s/^assistive_technologies=/#&/" \
/etc/java-8-openjdk/accessibility.properties


In case you have a running Ubuntu system ... You can add the Ubuntu install ISO file to the GRUB boot menu and install Ubuntu without having to create an installation media (DVD or USB drive).

Open a terminal and execute :

sudo apt-get install gksu

gksudo gedit /etc/grub.d/40_custom

Insert the following into the file :

menuentry "ubuntu install media" {
set isofile="/…/XXX.iso"
loopback loop (hdX,XX)$isofile
linux (loop)/casper/vmlinuz.efi boot=casper iso-scan/filename=$isofile noprompt noeject toram
initrd (loop)/casper/initrd.lz
}

Note : ... =  ISO file path | X = disk | XX = partition | XXX = ISO file name )

Save the file and execute :

sudo update-grub

Now reboot - choose the new entry from the GRUB boot menu and proceed installation as usual.

You will find some alternatives here -> Is it possible to install Ubuntu without a CD or USB drive ?


Screen brightness changes when moving mouse to certain areas (XPS13 9379 - Ubuntu)

I found out it is actually an XPS13 issue or "feature". On the 9370 it is possible to deactivate it in the BIOS:

Settings --> Video --> Dynamic Backlight Control --> Disable!


Upgrade to 16.04 breaks Wifi on Dell XPS 13 (9343)

Disabling secure boot in the BIOS solved the problem for me. (found answer on dell forums: http://en.community.dell.com/support-forums/laptop/f/3518/t/19683197)


IRQ Conflict between Ethernet Port and USB 2 controller with Linux 5.4.0-56-lowlatency kernel

I found that installing version 5.4.0-57 fixed this issue for me.
Steps I took were:

Edit /etc/apt/sources.list and add the line deb http://archive.ubuntu.com/ubuntu/ focal-proposed main  (I added it at the end, which appeared to work)

Reboot with version 5.4.0-54 to get internet access, then run the Software Updater

This installed version 5.4.0-57 and my internet access is now OK.
I guess 5.4.0-57 is not officially released yet, so up to you if you think it's worth it.  I should now remove the extra line I added to /etc/apt/sources.list to avoid the Software Updater retrieving proposed versions all the time.


Ubuntu 18.04 - Dell XPS15 9570 - Impossible to reliably suspend/hibernate

Edit /etc/default/grub with

  sudo vim /etc/default/grub

make sure that the GRUB_CMDLINE_LINUX line has the following items:

  GRUB_CMDLINE_LINUX="nouveau.blacklist=1 acpi_osi=! acpi_osi=\"Windows 2015\" acpi_backlight=vendor mem_sleep_default=deep"

or

  GRUB_CMDLINE_LINUX="nouveau.blacklist=1 mem_sleep_default=deep"

Insert acpi_osi=! acpi_osi=\"Windows 2015\ will not change screen brightness.

update grub:

  sudo update-grub

reboot
after computer has restarted, try suspending to see if the laptop wakes up normally


I've seen this happen a few times.  When it happened to me, it looked like Unity's compositing manager just stopped drawing the screen for some reason.

As an alternative to restarting my session, I switched to a terminal like you did, and then ran the following:

DISPLAY=:0.0 unity --replace

That got everything drawing again.  It is possible that you could just blindly run unity --replace from the Alt+F2 prompt in this case too, but I haven't tried that.

I haven't done any investigation myself about the underlying cause though.


inserting lines after specific line with loop

I would use awk:

read ids
# some validation here...

awk -v input="$ids" '
    BEGIN {
        n = split(toupper(input), user)
        fmt = "%-4s %-8s     NNN    0.050 0.050  0.05\n"
    }
    {print}
    /<< IGS core stations >>/ {
        for (i=1; i<=n; i++)
            printf fmt, user[i], user[i]"_GPS"
        exit
    }
' ./text.data

outputs

   SITE              FIX    --COORD.CONSTR.--
      << default for regional stations >>
ALL               NNN    100.  100.   100.
      << IGS core stations >>
BRMU BRMU_GPS     NNN    0.050 0.050  0.05
ISTA ISTA_GPS     NNN    0.050 0.050  0.05
ANKR ANKR_GPS     NNN    0.050 0.050  0.05


How can I switch monitors with a shortcut?

I finally found a solution.

After trying everything I could think of, I decided to take a completely different approach. I completely disassembled my computer, and found the problem with my computer screen (The screen was unplugged from the main board). So I fixed it, reassembled my computer and started it back up. Everything worked perfectly, I was able to log in and use it normally.


Not seeing Plymouth graphical boot-up screen until end of boot process

After a tiresome internet-searching session, I finally managed to find my answer here: https://askubuntu.com/a/79959/289337
Thanks for the replies though. (By the way, JohnnyEnglish's method didn't work for me).


The problem isn't for the most time a local IP, it's a global IP. The global IP must be specified in your DNS host so that your domain name is linked to the global IP of your host. IF this link is broken the router wont get any data and the site will be unavailable.

Things to check.

Is the website accesable via the global IP?
is the global ip the same as the IP of the domain name?
is the router configured to send all website request to your server?
does the server work on the local IP?

apache doesn't need a domain name it just needs a working link to the real world, like a global IP, then link your domain name to that global IP.


How to use awk to edit a specifc line set by a variable (awk NR, -i inplace and -v var)

You just need to apply a default {print} rule to other records ex.
awk -i inplace -v line_number=$line_number 'NR == line_number {print $1; next} {print}' file

or perhaps more idiomatically
awk -i inplace -v line_number=$line_number 'NR == line_number {print $1; next} 1' file

Alternatively, you could do something like
awk -i inplace -v line_number=$line_number 'NR == line_number {$0 = $1} 1' file


Which command should I use to open an MP3 file?

If you want to use the App set as preferred, from the directory containing the MP3 file, use xdg-open:

xdg-open abcd.mp3

From man xdg-open:

xdg-open - opens a file or URL in the user's preferred application

If you know the application you want the MP3 file to be opened with, for example, rhythmbox:

rhythmbox abcd.mp3

or VLC media player:

vlc abcd.mp3


How can I kickstart a group advocating digital literacy with Ubuntu?

If you can provide transportation for the shipment FOB Portland, Oregon, you could apply for a grant from a 501(c)(3) not-for-profit organization, FreeGeek.Org. See http://www.freegeek.org/about/grants for details.


Fail to install Realtek Wi-Fi driver rtl8821AU

It looks like you don't have the "make" executable.  Install the build-essential package:

sudo apt-get install build-essential

then try again.


File missing after copying to file system partition

The tmp folder in the 'file system' partition of Ubuntu is a temporary folder, and it will be flushed, the content will be removed at shutdown and reboot.

So I am sorry, but the files are gone. Maybe, if you are lucky, some of the file data are still there and can be recovered with PhotoRec, but it can be a lot of work to identify them among all other file data, that PhotoRec can find.

To avoid overwriting more data, please stop using this system, boot from another drive (and try to recover files). Do not mount this 'file system' partition of Ubuntu.


Installing Ubuntu, Windows 10 not in grub now

I used a windows 10 instilation disk to enter windows 10 and the entering the command prompt (shift f10) used the commands

bootrec.exe /fixboot
bootrec.exe /fixmbr

to reinstall the windows bootloader. A program titled easyBDC was than used to add Ubuntu back as an option. Its not a perfect solution as Windows 10 does still not appear in grub, but it works.


Why doesn't MATE respect `x-terminal-emulator`?

The list of default MATE applications is customized by special applet of MATE Control Center.
It is named Preffered Applications.

You have to start it with mate-default-applications-properties and then set needed Terminal Emulator on the System tab:

and it will open when you press Ctrl+Alt+T.

Note: if we read source code of this component, then we can see that terminal alternatives are enumerated by their desktop-files and not by update-alternatives functionality - see this code fragment about desktop file.


Getting Windows games to play on PlayOnLinux

Try to install Visual C++ runtime libraries:

2010 = http://download.microsoft.com/download/5/B/C/5BC5DBB3-652D-4DCE-B14A-475AB85EEF6E/vcredist_x86.exe
2008 = http://download.microsoft.com/download/5/D/8/5D8C65CB-C849-4025-8E95-C3966CAFD8AE/vcredist_x86.exe
2005 = http://download.microsoft.com/download/5/B/C/5BC5DBB3-652D-4DCE-B14A-475AB85EEF6E/vcredist_x86.exe

Check this link for StarCraft II on Ubuntu


Where are gnome extensions preferences stored?

Schema Files
The default extension settings are located in an *.xml file in the following directory if you installed the extension globally:
/usr/share/gnome-shell/extensions/<extension directory>/schemas

The default extension settings are located in an *.xml file in the following directory if you installed the extension locally (which seems to be your case):
~/.local/share/gnome-shell/extensions/<extension directory>/schemas

In the *.xml file, the <key> tags will list the keys. The <default> tags will contain the default values. You could manually edit these files. In order to transfer settings across systems, you will need to update the extension's *.xml "gschema" file.
In the example extension you referenced above, the settings are located at Screenshot configurations.
If you edit these files on your installed system, you will need to recompile the "gschema" by running one of the following commands.
If you had installed the extension globally, execute:
sudo glib-compile-schemas /usr/share/gnome-shell/extensions/<extension directory>/schemas

If you had installed the extension locally, execute:
glib-compile-schemas ~/.local/share/gnome-shell/extensions/<extension directory>/schemas

This will create an updated gschemas.compiled file in the extension's schema directory.
Gsettings
When you change a setting using a GUI (the extension's settings dialog), the change is actually stored in gsettings.
You can use Dconf Editor to locate the key and value for a particular "gsetting".
Install Dconf Editor using:
sudo apt install dconf-editor

(You can also use the gsettings commandline tool instead of the Dconf Editor GUI tool).
The <schema> or <path> tags in *.xml file (as described above) will tell you which schema to navigate to in Dconf Editor. (Hint, it will be under /org/gnome/shell/extensions/). The *.xml file will also list which keys can be configured.
You can search for the schema and key in Dconf Editor, and make changes.
In my experience, most extension settings are stored in "relocatable" schemas. Effectively, this means you can search for them and change them using Dconf Editor only after they have been set at least once. Otherwise the key simply will not be available in Dconf Editor, and you will consequently not be able to change its value. This is because the default values from the *.xml files (as described above) are used when there are no gsettings to override them.
Because you want to transfer these settings across installations, try exporting your gsettings, and loading them onto your new machine. See this answer to another question for instructions. (This approach may be actually easier then editing the *.xml files, described above).
Watch for Changes
A good way to watch for gsettings changes, as you make them, is to run the following command:
dconf watch /

This will show you which schema and key you just changed.
Install the the dconf commandline tool using:
sudo apt install dconf-cli


Wifi with Asus R510JK on ubuntu 15.04 and kernel 4.0

This might work sudo apt-get purge bcmwl-kernel-source

sudo apt-get install bcmwl-kernel-source in the 3.19 kernel

bcmwl with kernel 4.0 bug report

Also check lsmod | grep acer and see if acer_wmi is listed, then

echo "blacklist acer_wmi" | sudo tee -a /etc/modprobe.d/blacklist.conf


How to find installed Oracle SQL Developer?

You can use:

  which sqldeveloper

to see where the executable script is installed.

To make it easier to use, you can create a desktop icon. So create a file sqldeveloper.desktop anywhere you wish:

cd /path/to/your/desktop/
nano sqldeveloper.desktop

and populate it with:

[Desktop Entry]
Exec=/path/to/sqldeveloper/script
Terminal=false
StartupNotify=true
Categories=GNOME;Oracle;
Type=Application
Icon=path/so/some/image
Name=Oracle SQL Developer

and update:

  sudo update-desktop-database


Broadcom BCM4312 Wireless Modem UNCLAIMED After Installing Updates

According to your wireless script output, the b43 driver is blacklisted by bcmwl-kernel-source.

[/etc/modprobe.d/blacklist-bcm43.conf]
blacklist b43
blacklist b43legacy
blacklist ssb
blacklist bcm43xx
blacklist brcm80211
blacklist brcmfmac
blacklist brcmsmac
blacklist bcma

You need to remove it by running

sudo apt-get remove bcmwl-kernel-source

That package was wrongly installed. Then you can start b43 by

sudo modprobe b43

or reboot.


Ubuntu touch: changing standard reminder time (possibly feature request)

I looked onto the sources of the current developer version. There it is 15 minutes by default. So, it'll be fixed.

Maybe someone can explain or link to guides about installing developer versions.


Openvpn connection problem using network manager

if it works with sudo..

try running

ll /home/pookyfox/Documents/tw-proxmox-ovh_vpn/

or

ls -o /home/pookyfox/Documents/tw-proxmox-ovh_vpn/

and check if your user/group has read/execute rights to those files.
If you see something like these

drwx------   8 root root  ...
-rw-r--r--   1 root root  ...

but not like these

drwxr-xr-x   2 root root ...
drwxrwxrwt  17 root root ...
drwxr-xr-x  10 root root ...
-rwxrwxrwx   1 pookyfox pookyfox ...

just do a sudo chmod -R 777 /home/pookyfox/Documents/tw-proxmox-ovh_vpn/ and try to re-run them again.

Just throwing the first idea off the top of my head, hope it helps.


UPDATED ANSWER:

The hard drive you want to use as a backup device must have one of the following filesystems:

ext2/3/4
reiserfs
reiser4
xfs
jfs
btrfs
luks

If that's the case, it will show up in the backup devices list in the GUI of timeshift and/or it's possible to add it via --backup-device on the cmdline.

OLD ANSWER:

You need your filesystem to be compatible to the backed up system. So let's say you have an ext2/3/4 formatted Ubuntu filesystem. You need to format the backup filesystem (e.g. your external HD) to ext2/3/4.

I am not sure which are all the working combinations in the end, but this will definitely do always:

Ubuntu (extX) -> External Drive (extX) - Where X is {2,3,4}

After you formatted your external drive with the correct filesystem (e.g. with exactly the same filesystem as your Ubuntu partition), the new backup drive will show up as one of the options in the GUI of timeshift.

EDIT (Background information):

The true answer lies in these lines (Main.vala):

public Device? get_device_from_name(Gee.ArrayList<Device> device_list, string device_name){
    foreach(Device pi in device_list) {
        if (!pi.has_linux_filesystem()) { continue; }
....

Here you can see a function from Timeshift sources. -> While iterating through the possible devices, those that have not a Linux filesystem will be excluded from possible backup devices.

Another source file provides us with what is defined as Linux_filesystem in Timeshift (Utility.vala:633ff):

public bool has_linux_filesystem(){
        switch(type){
            case "ext2":
            case "ext3":
            case "ext4":
            case "reiserfs":
            case "reiser4":
            case "xfs":
            case "jfs":
            case "btrfs":
            case "luks":
                return true;
            default:
                return false;
        }
    }


If you are not absolutely sure that you need this package, you can remove it:

sudo apt remove dleyna-renderer
sudo apt autoremove

Otherwise, there is not much that you can do about this: it is a known bug.

You could create a launchpad account and add yourself to the number of "people who are affected by this bug" on that page.


i am unable to log into ubuntu via the gui

try to chown the .Xauthority file in your home folder

sudo chown $(id -u):$(id -g) $HOME/.Xauthority

Let the system fill in the UID, GID and home directory.

This problem happens when you sudo instead of kdesudo/gksu/gksudo the file manager. hope this helps you.


There are a number of tools, but first you should ensure you have the MP4 codecs installed. See here for instructions.

Once that is done, there are a number of tools available to you:

RecordMyDesktop

sudo apt-get install recordmydesktop

Other tools referenced here - Istanbul, Kazam. There is also xvidcap.


Now that I have Firefox 49 or higher, how do I watch Netflix?

As wisely mentioned in comments: if you have this problem, contact Netflix support about it. It's a problem to be fixed on their side, and the more complains they'd get, the faster it get fixed.

A solution by GizmoChicken:

    Is anyone able to play Netflix?
    With the original user agent it requests to install silverlight
    With chrome user agent it plays, but with tearing and high cpu load.

  Netflix plays for me on Firefox 49 when using the following User-Agent entry:

Linux / Chrome 53: Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/53.0.2785.34 Safari/537.36

  Sometimes I have to hit "refresh" to start a video. I don't recall ever having to do that with Chrome. So it's still not perfect.

=====================================
(edit by OP)

Before using the user agent string above (which worked) I had to do two other things.

Get Firefox to install the Widevine plugin by ticking the box on
Preferences/Content labeled Play DRM Content.
Install User Agent Overrider extension.  Then go to the extension's preferences and add the user agent string above.

Then just select the Linux / Chrome 53 user agent, go to Netflix.com, and Bob's yer uncle.

Edit 2: This also works on 32 bit Ubuntu! Woo hoo!

Edit 3: At least as of April 2017, 32 bit no longer works, but the user agent workaround is no longer required.

Edit 4: One of the many awesome enhancements in Firefox Quantum is that Netflix works again in 32 bit! (Dec 2017)


First create a mount-point:

sudo mkdir /media/data

Change the ownership of the mount-point:

sudo chown johanna: /media/data

Set the permissions:

sudo chmod 755 /media/data

Now open the fstab-file:

sudo nano /etc/fstab

Add the following line at the end of the file:

/dev/sda3  /media/data  ext4 defaults  0  2

Press Ctrl+o and then hit Enter

Press Ctrl+x

Close the terminal and reboot. You will be able to write to your mounted partition now without root-privileges.

Note

On german keyboards the Ctrl-key should be the left Strg-key.

Explanation

It looks like you mounted the partition via the desktop-icon or opening the partition in the file-manager. Doing so will automatically create the directory /media/<username>/<partition-name>, the partition-name might be the label of the partition (if one exists) or the UUID of the partition.

This automatically created folder should be owned by  and you should have read- and write-permissions, but mysteriously this doesn't seems to be the case. Also, this folder will be removed as soon as the partition is unmounted, if you don't unmount the partition yourself, the partition will be unmounted whenever the system shuts down. This explains that any changes (ownership, permissions) will not survive a reboot.

To ship around this we create a directory which we use as mount-point, adjust ownership and permissions of the directory and at last we add an entry to the fstab-file, so the partition will be auto-mounted at start-up. This directory is not going to be removed when the partition is unmounted.

Addition

I also have the impression that you wanted to set up your installation with a separate /home-partition. It seems you created the partition, but you didn't specify the mount-point (which would be /home) during installation. As the result you got a system with your system-partition and a big, but empty partition. Don't worry, you still can achieve this by copying the contents of the /home-folder to the partition and after doing so changing the mount-point of the partition to /home, here is a nice "How to do that":

https://help.ubuntu.com/community/Partitioning/Home/Moving


You can see here how to tell the IDE to scale for a hidpi display:

http://tools.android.com/tech-docs/high-density-display-with-android-studio

However, I found this to work most of the times but not always. What always works is to run the following command in the terminal before launching Android Studio:

xrandr --dpi 192


I'll go a different route... Use ufraw-batch not ufraw.

sudo apt-get install ufraw-batch

## This will output (not replace) the file with a new extension.
## foo.CR2 exported to foo.png
ufraw-batch --out-type png *.CR2

See ufraw-batch --help and man ufraw-batch for more info.


If I don't use KDE why does updating download lots of kde packages?

Found it from your package history!

You installed Kile - LaTeX front end for KDE, that integrates many tools needed to develop documents with LaTeX, in just one application.

Kile pulls all the packages below. BTW, this answer has a command-line way of getting a chronological list of the packages you have installed, in case you want to find something like this in the future.

 docbook-xml docbook-xsl dvipng icoutils imagemagick imagemagick-common
  kate-data katepart kde-runtime kde-runtime-data kdelibs-bin kdelibs5-data
  kdelibs5-plugins kdoctools konsole kubuntu-debug-installer lacheck
  latex-beamer latex-xcolor libattica0.3 libcdt4 libclucene0ldbl
  libdlrestrictions1 libgif4 libgraph4 libgvc5 libilmbase6
  libkatepartinterfaces4 libkcmutils4 libkde3support4 libkdeclarative5
  libkdecore5 libkdesu5 libkdeui5 libkdewebkit5 libkdnssd4 libkemoticons4
  libkfile4 libkhtml5 libkidletime4 libkio5 libkjsapi4 libkjsembed4
  libkmediaplayer4 libknewstuff3-4 libknotifyconfig4 libkntlm4 libkonq-common
  libkonq5-templates libkonq5abi1 libkparts4 libkpty4 libkrosscore4
  libktexteditor4 liblqr-1-0 libmagickcore4 libmagickcore4-extra
  libmagickwand4 libnepomuk4 libnepomukdatamanagement4 libnepomukquery4a
  libnepomuksync4 libnepomukutils4 libnetpbm10 libntrack-qt4-1 libntrack0
  libopenexr6 libpathplan4 libphonon4 libplasma3 libpolkit-qt-1-1
  libqapt-runtime libqapt1 libqca2 libqt4-designer libqt4-qt3support
  libqtwebkit4 libsolid4 libsoprano4 libstreamanalyzer0 libstreams0
  libthreadweaver4 libvirtodbc0 libxml2-utils libxss1 lmodern luatex netpbm
  ntrack-module-libnl-0 odbcinst odbcinst1debian2 oxygen-icon-theme pgf phonon
  phonon-backend-gstreamer plasma-scriptengine-javascript prosper ps2eps
  psutils qapt-batch sgml-data shared-desktop-ontologies soprano-daemon
  tex-common texlive texlive-base texlive-binaries texlive-common
  texlive-doc-base texlive-extra-utils texlive-font-utils
  texlive-fonts-recommended texlive-fonts-recommended-doc
  texlive-generic-recommended texlive-latex-base texlive-latex-base-doc
  texlive-latex-recommended texlive-latex-recommended-doc texlive-luatex
  texlive-pstricks texlive-pstricks-doc tipa virtuoso-minimal
  virtuoso-opensource-6.1-bin virtuoso-opensource-6.1-common

That's why I stick to editor for writing TeX ;)


What worked for me was using the nomodeset option in the grub bootloader. There are two methods to set nomodeset:

Temporary:

While booting press and hold shift in order to see the grub menu
Choose the entry you want to change (in a normal installation the first entry) and press e to edit it
Look for quiet splash and add nomodeset before it
Finally press F10 to boot.

If this worked for you, you can use the permanent way for all bootups.

Permanent:

edit /etc/default/grub (for example: sudo nano /etc/default/grub)
change the line GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" to GRUB_CMDLINE_LINUX_DEFAULT="nomodeset quiet splash"
Finally update the grub config: sudo update-grub

The next time rebooting, you don't have to specify the boot option.

I run Ubuntu 16.04 LTS with 4.4 kernel on Lenovo i310 laptop.

The output for sudo lshw | grep -A9 VGA is the following:

  description: VGA compatible controller
  product: Sky Lake Integrated Graphics
  vendor: Intel Corporation
  physical id: 2
  bus info: pci@0000:00:02.0
  version: 07
  width: 64 bits
  clock: 33MHz
  capabilities: pciexpress msi pm vga_controller bus_master cap_list
  configuration: latency=0

This answer is partially copied from last answer at When I start my camera in video call on Skype 4.1. incoming video is flashing blue?


Is there a skype "engine", not GUI, for 32bit, so that one can use pidgin or alike for video-calls?

The SkypeWeb plugin for Pidgin does not - at this stage - support voice/video.  It is on my TODO list to add support for it via gstreamer-webrtc

A workaround for now is to use your browser to connect to web.skype.com and change your user agent to one that supports voice/video.  This used to be limited to Google Chrome on Linux


Reinstalled 15.10 and now steam controller unusable in game

I fixed it myself with help from a reddit post and some additional googling that came from said post.

There is a typo in /lib/udev/rules.d/99-steam-perms.rules that needs to be edited from *********=="***", ATTRS{idVendor}=="****", ATTRS{idVendor}=="****", ****="****" to *********=="***", ATTRS{idVendor}=="****", ATTRS{idProduct}=="****", ****="****" on both lines this appears.

I replaced information that I did not need to edit with * in the unlikly event that those are specific to my machine and could cause issues for others if pasted directly as is.

Plugging in the steam controller and starting Big Picture after doing this allowed for a firmware update from November 3rd 2015 to install that allowed the controller to function with default layout in game but would not allow for button customization.

The December firmware update, one that brings a gui with additional customizations for lights, feedback and such, still does not seem to want to download on linux, but if you can get the firmware.bin file you can manually install it by holding right trigger while starting the controller bringing up a usb storage device allowing you to update. I have not tried this myself yet, but I provided a link to instructions below and will update this post when I try the fix myself.

Ask Ubuntu thread: How do I get a Steam Controller working?

Associated bug report: https://bugs.launchpad.net/ubuntu/+source/steam/+bug/1498655

Updating firmware manually: https://unix.stackexchange.com/questions/248647/unbrick-a-steam-controller


How do I install Ubuntu on my Mac PowerPC G5

Still attempting the install on your G5? I've got mine working--except for wireless.

Here's my experience.

When my screen went blank it was because I had two monitor cards installed. I got rid of the inactive one, and text appeared instead of going blank--as if to suggest that the installer was trying to write to the non-existent monitor. I don't know your setup, so I don't know if that's going to be a help or not. Think carefully about any virtual monitors that you may have created, or mirrored screens that you may have needed to set up for some reason. Maybe that'll jog your memory. HTH.

I had OS X 10.5.8 installed on a 2 TB drive. I used Disc Tools to adjust the partition to 1 TB (which you can do starting in 10.5.8 and up), and installed the Ubuntu PowerPC 12.04.01 version along side OS X in the remaining 1 TB partition.

I tried PowerPC Lubuntu (note the 'L' in Lubuntu) 12.10 with miserable results.

BTW, I also tried PowerPC 10.04 LTS and everything worked--everything.

However, upgrading from PowerPC 10.04 to 12.10 was a train wreck.

As I said, I've got both working--OS X 10.5.8 and PowerPC 12.04.01--although I'm still trying to track down the resolution of the wireless / Broadcom / B43 networking issue. I'm hoping that that won't take too long--we'll see.

The bootloader in use--yaboot--works great for Ubuntu, but not for OS X. If I want to boot OS X, I hold down the option key to get Apple's option page and choose OS X from there. Apparently, yaboot is passing incorrect or incomplete boot parameters to the OS and after about 30 seconds, yaboot --> OS X freezes. yaboot --> Linux works fine.

Doug Parker
Orlando, FL


You are running a graphical program (gedit) with sudo which usually is for command line use. There is a problem defining a graphical environment for root in this case. It is preferably to use gksudo for running graphical programs.


My graphic card overloads when i use flash player

I more or less ran into the same issues on an old (outdated) PC*: CPU started to work really hard and Youtube videos became choppy when played at fullscreen - HD videos even in a small screen. I eventually discovered that copy-pasting the URL from a Youtube video into VLC Player (use CTRL-N, then paste), virtually eliminated all choppiness and gave me smooth fullscreen videos. Not a perfect solution, but might be an acceptable work-around for some.. Btw DVD-video is also normal when I play it in VLC-player.

As a side-note, I also noticed that most videos played smoother on the Youtube site when I was using a Ubuntu live-USB (although I did get pop-ups about flash not being installed just before the video started playing).

*Pentium IV 2,8 GHz, about 1,7 Gb of ram, HP Compaq D330, Graphics card: Ati radeon 9200PRO - so I suppose it could be a mix of old hardware, bad drivers and imperfect browser-plugins. Btw I experienced the same issue in a whole bunch of Ubuntu flavours and Mint, but Lubuntu still performed best (because of the low system load).


It sounds like it would be possible, but it will take some time. Now I have never done exactly what your trying to do, but what I would do is use the GParted live CD and shrink down the partitions on both hard drives so that both or all the partions would fit on one drive. Then on the drives check which one has the boot label most likely the one with Ubuntu is my guess since your using grub. Then you would want to use a cloning tool(Like CloneZilla) and copy the other hard disk onto the one that has a partition marked with the boot flag. make sure and copy all the partitions as it will most likely mess up if you don't. After that you'll need to boot into Ubuntu and do a grub update(You can look up on google how to do it is really easy. You should be ready after that.


Accented characters not displayed in ssh session

I already solved the problem thank's to this article
The steps followed:
$ export LC_ALL="ca_ES.UTF-8"
$ export LC_CTYPE="ca_ES.UTF-8"
$ sudo dpkg-reconfigure locales

Then I selected ca_ES.UTF-8 and en_US.UTF-8 on Locales to be generated page and ca_ES.UTF-8 on Default locale for the system environment (I tried selecting en_US.UTF-8 and works too).


What is the current state of the Ubuntu Professional certification?

I just received a response from Canonical, and it stated that in October 2010 they discontinued the Ubuntu Professional course and it was  replaced it with a course that isn't tied to any certification.

They also let me know that while they are not offering any sort of certification at the moment, that they are working towards producing their own certification process that will be ready sometime after Summer 2012.


Is there an equivalent of virtual env but for the whole of ubuntu?

I would suggest you to use vagrant.
Using vagrant you can easily create/destroy/re-create development and testing environments.

You use with docker,lxd,virtualbox as providers to build,test packages without making any change in your host system. It is very helpful to create identical development environments.

Vagrant provides functionality to take/restore snapshots of your virtual environment. Using  docker as vagrant provisioner, you can build/test your virtual environment in no time. For example you need to test some new package, you just need to build docker image once with preinstalled libraries. Vagrant will provision docker image and test/run your built package. This way it saves lots of time to build virtual environment. You can use same image multiple times.

To install Vagrant, Download latest vagrant linux zip file,unzip it and copy vagrant binary to /usr/bin.

unzip vagrant*_linux_amd64.zip
sudo cp vagrant /usr/bin/

or You can install vagrant via apt.

sudo apt install vagrant

Verify vaagrant installation.

vagrant --version


Some steps you can take to fix the login loop:

Go to terminal from login screen:
Ctl Alt F1

login with user-name and password.

Run updates "sudo apt-get update"

Check all applications "sudo apt-get upgrade"

Check all packages "sudo apt-get -f install"

Update grub "sudo update-grub"

Remove all old applications and packages "sudo apt-get autoremove"

Reboot "sudo reboot"


php-mcrypt package missing in Ubuntu Server 18.04 LTS

Mcrypt has been deprecated in PHP 7.2, so it's not available by default.

You can still install the mcrypt extension using pecl. These instructions are for the apache web server.

# Install prerequisites
sudo apt-get install php-dev libmcrypt-dev gcc make autoconf libc-dev pkg-config

# Compile mcrypt extension
sudo pecl install mcrypt-1.0.1
# Just press enter when it asks about libmcrypt prefix

# Enable extension for apache
echo "extension=mcrypt.so" | sudo tee -a /etc/php/7.2/apache2/conf.d/mcrypt.ini

# Restart apache
sudo service apache2 restart

That should get you going.

In the long term you might want to replace mcrypt, it's deprecated for a reason.


Can't switch to gdm3 using sudo dpkg-reconfigure gdm3

re: sudo dpkg-reconfigure gdm3 error message.

Just reboot and you should be running gdm3.

The error that you're receiving just means that gdm3 wasn't already running, so it couldn't reload it.


split a text file to what's before and after a given pattern

Use csplit for things like this.

CSPLIT(1)                        User Commands                       CSPLIT(1)

NAME
       csplit - split a file into sections determined by context lines

-f, --prefix=PREFIX
          use PREFIX instead of 'xx'
--suppress-matched
          suppress the lines matching PATTERN

Regarding the regex part of the command:

Each PATTERN may be:

   INTEGER
          copy up to but not including specified line number

   /REGEXP/[OFFSET]
          copy up to but not including a matching line

   %REGEXP%[OFFSET]
          skip to, but not including a matching line

   {INTEGER}
          repeat the previous pattern specified number of times

   {*}    repeat the previous pattern as many times as possible

   A line OFFSET is a required '+' or '-' followed by a positive integer.

The command

csplit <file.txt> /<string>/ '{*}'

will split <file.txt> into parts based on how often it finds <string>. The '{*}' will repeat the search and creates multiple files for each occurrence. By default the files will be named xx{number}; use the --prefix option to change that. Adding --suppress-matched will omit the search string from the files.


Reinstall Ubuntu Operating System
You can install programs/applications via Terminal, but in neither case an operating system. The Terminal is good and you can do a lot of things with it, but this time you will need more than only the Terminal to reinstall Ubuntu.
Please read the following community wiki to find out what you need:

How To Reinstall Ubuntu

Reinstall Ubuntu desktop system
If you are referring only to the Ubuntu desktop system package, then you can use the following command to reinstall it:
sudo apt-get install --reinstall ubuntu-desktop


Ubuntu 16.04 won't boot after power outage (EFI)

Solution by OP:

So I was installing some texlive-* packages when the outage hit, I tried booting from a previous kernel and it worked, after rebooting everything is normal again


How to get a working mtp connection for Galaxy S2 in 12.04?

Android 2.x

On phone, go to: Settings ➔ Wireless and network ➔ USB utilities.
Connect your phone to your PC using a USB cable.
Tap Connect storage to PC.
Scroll down from the phone notification bar. Click USB Mass Storage and tap "Connect storage from PC". The android robot will turn from green to orange. (Important step!)
From your PC, open the folder to view your files.
Copy files between your PC and the memory card.


If you use 12.04 64bit through WUBI, it should pick up the touch screen. Mine did without me having to install any drivers. However, 12.10 is a different story so I went back to 12.04. I have a ProLite Monitor.


How to check for any activity on a physical disk?

If you were using dd there is a command that would tell us if still doing its job

 sudo pkill -USR1 -n -x dd

Dont sound like that what you're doing.

I think the reason the activity light is still going after sync is because writing to SD Card tends to be slower...... Or did I totally miss the point

Sorry, couldn't find answer to question about checking if /dev/sdb is in use.

edit

Check out iotop

 sudo apt-get install iotop

Then run it with this command

 sudo iotop --only

This way it will show you only what in use.

Is this what your looking for?  If not there are some other suggestions HERE


How to use win explorer to create folders for Bash on Ubuntu on Windows?

We STRONGLY recommend against modifying any Linux files/folders from Windows in the manner described above: Doing so will likely result in data loss and/or corruption:

There's a reason we made the lxss folder hidden and system ;)

It's fine to access Windows from Bash/Linux, but we've not yet done the work to persist and manage Linux file permissions & metadata when accessing files under .../lxss/ using Windows tools & apps.

[2016-11-17: Update]
To expand on this question and its answer, I wrote-up a more thorough explanation here: https://blogs.msdn.microsoft.com/commandline/2016/11/17/do-not-change-linux-files-using-windows-apps-and-tools/


How can I run emacs in gnome terminal without popup interface?

To run emacs in the Terminal without a GUI (i.e., without it creating a graphical window for itself), use:

emacs -nw

The -nw flag stands for "no window."


At first: yes there is a way. The Problem is that your "Ubuntu partition" is using another filesystem than windows. Its probably ext4, and Windows is not able to handle these filesystems. So even if Windows could show you your Ubuntu partition, you could not use it.

Now you could ask "but why is Ubuntu able to recognize and handle the Windows FAT and NTFS partitions?", well Ubuntu is smarter ;)

For handling some linux partitions on windows, you need some extra software on your system. Maybe you could try this:

http://www.webupd8.org/2011/08/access-ext4-ext3-or-ext2-partitions-in.html
http://www.howtogeek.com/112888/3-ways-to-access-your-linux-partitions-from-windows/

Or you could resize your ubuntu partiton with gparted

https://help.ubuntu.com/community/HowtoPartition/ResizingPartition
http://www.howtogeek.com/114503/how-to-resize-your-ubuntu-partitions/


Script to generate a list of urls from a list of authors

After testing your command, I got this result :

"site.com/Osho
"site.com/Hartmann
"site.com/Nicolai
"site.com/Bird
"site.com/Robert
"site.com/Montgomery
"site.com/Coates
"site.com/Ta-Nehisi

As I can see, you want to replace each space with a +, so you can use the sed command like that :

< list.txt xargs -l | sed "s/\ /+/g" | xargs printf 'site.com/%s\n' > url.txt

Here is the result :

site.com/Osho
site.com/Hartmann+Nicolai
site.com/Bird+Robert+Montgomery
site.com/Coates+Ta-Nehisi

This command is really effective and dynamic, you can have a really long composed name (with 6, 10 or more parts), only space would disappear, each - character won't even be modify

NB : I just removed the " character inside your printf command because it's not need in your expected output


How can I try Ubuntu without changing anything on my computer?

Download the ISO from Ubuntu.com and follow the directions on the site.

Put the disc in your drive and boot up the computer. It will boot into the live environment. Live meaning it is running off the CD/DVD disk and RAM but not off your hard drive. It will not touch the hard drive at all.

You have to boot from the CD if it does not do this automatically. You may have to press a certain key to get to the boot menu while starting up. This depends on your computer but is usually F12 to bring up the boot menu and F1,F10, or Delete, to bring up the BIOS menu. You need to change the boot order of your computer to boot from the CD/DVD device first.  It should say what key to press on the boot screen. :) Have fun!

Alternatively WUBI installs along side your main operating system and can then be accessed as an option from the start menu. It then runs in side windows, and can be uninstalled at any time later.


It was indeed an enlightenment wallpaper. In the Bodhi forums, someone found it in /usr/share/enlightenment/data/backgrounds/Brown_Rock_Hi.edj


Unable to connect to freenode because of open proxy

At the moment, squid is listening on all of your network interfaces. If you change it to only listen on your internal network, then nobody on the internet will be able to connect. If you are only using it on a single machine, this is easy. Change the line

http_port 3128

to

http_port 127.0.0.1:3128

This means squid will only listen on your localhost interface.

If you have other machines accessing the proxy with one network card for the internet and one for the internal network, you'd repeat the above change but substitute your internal network IP address for 127.0.0.1.

This is documented at http://www.squid-cache.org/Doc/config/http_port/ - see the bottom paragraph.

It'd probably be worth checking that your firewall is running and configured as well - 3128 doesn't need to be visible to the outside world.


You can maybe use "dconf" to do that:

  How to disable automount in nautilus's preferences


Unable to find the .lit file reader app clit

Download Calibre - this will read your LIT format files, and also be able to convert them to other formats.

OR

you can install the clit program by sudo apt-get install convlit


nvidia-settings does not work since upgrade to 14.04

I was able to solve this problem by installing the more recent version of the nvidia driver from the repository.

sudo apt-get purge nvidia-304
sudo apt-get install nvidia-331


install Ubuntu 12.04 system requirements

These are the minimum requirements taken directly from the ubuntu system requirements page

700 MHz processor (about Intel Celeron or better)
512 MiB RAM (system memory)
5 GB of hard-drive space (or USB stick, memory card or external drive but see LiveCD for an alternative approach)
VGA capable of 1024x768 screen resolution
Either a CD/DVD drive or a USB port for the installer media
Internet access is helpful

Your machine should definitely be able to run ubuntu.

You can also always use an ubuntu live cd to try out ubuntu and see if it suits you. =)


How to mount sd-card image created with dd?

To avoid the need to create separate images for each partition or installing a utility like kpartx, you can mount each partition individually by specifying an offset in the mount command.

First examine the partitions in the image file and determine the offset by using fdisk:

$ fdisk -u -l rpi_image280914

Disk rpi_image280914: 16.0 GB, 16012804096 bytes
255 heads, 63 sectors/track, 1946 cylinders, total 31275008 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000cdac7

           Device Boot      Start         End      Blocks   Id  System
rpi_image280914p1   *        2048      514047      256000    c  W95 FAT32 (LBA)
rpi_image280914p2          540672    31242239    15350784   83  Linux

Take the Start sector of the partition you want and multiply that value by the Units size. So if you want the second partition you'll get 540672 * 512 = 276824064.

Now create a folder and mount the partition:

mkdir rpi_partition2
sudo mount -o loop,offset=276824064 rpi_image280914 rpi_partition2/

Once you are done doing what you want with the partition data:

sudo umount rpi_partition2/
rm -r rpi_partition2/


Ubuntu 18.04: How to customize the font face and size in Dash to panel extension?

The Dash to Panel Gnome Shell extension simply adheres to the style defined in the Gnome Shell theme in use. Therefore, the extension does not offer options to customize appearance. To change the appearance, you can try finding another Gnome Shell theme that suits your taste. If however you want fine control over just the font settings, then the only way would be to edit the style sheet of your Gnome Shell theme directly. These style sheets use the same syntax as these used for web pages. See this Ubuntu answer to learn how you could find and edit the appropriate style files.


How to copy symbolic links while preserving the validity of the link?

It seems the symbolic link links to file with relative directory. I would recommend to create a symbolic link with ln -s /usr/local/boost_1_52_0/stage/lib/libboost_timer.so /usr/local/lib/ instead of copying it.


Why is the kernel module cfg80211 also listed as a kernel process [cfg80211]?

It is the standard behavior of ps to list kernel threads, as these too are processes--just a different kind of process, because they run in supervisor mode (which some people call "kernel mode").

If you run ps ax (or ps aux) without piping its output to grep, you'll see a whole bunch of kernel modules listed first (and then probably some others interspersed with user processes, if they were started later).

For example, here's the first 10 lines of the current output of ps ax on my system:

  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     0:03 /sbin/init
    2 ?        S      0:01 [kthreadd]
    3 ?        S     97:17 [ksoftirqd/0]
    6 ?        S      0:00 [migration/0]
    7 ?        S      0:24 [watchdog/0]
    8 ?        S      0:00 [migration/1]
   10 ?        S      6:06 [ksoftirqd/1]
   12 ?        S      0:18 [watchdog/1]
   13 ?        S<     0:00 [cpuset]

lsmod will list loaded modules. ps aux will list current processes, including kernel processes associated with modules. These are different things, however. For example, a loaded kernel module might have any number of kernel processes associated with it (zero or more).


Can sudo be reinstalled after being removed?

I can install applications using:

pkexec apt-get install <appname>

From man pkexec:

  pkexec allows an authorized user to execute PROGRAM as another user. If
  username is not specified, then the program will be executed as the
  administrative super user, root.

So, I suppose that pkexec apt-get install sudo should work as well.

Edit: now I can confirm: yes, sudo can be installed using using pkexec  apt-get install sudo:

(click to enlarge)


What is the best way to make my desktop look like a mac?

I found this amazing tutorial on 5 steps to transform your Ubuntu to Mac
OMGUbuntu - 5 Tips To transform Ubuntu To MAC

Then , I found a nice splash screen/boot screen to make Ubuntu feels more like Mac . Its a splash screen theme from plymouth . Enjoy =) UbuntuRoot - Plymouth Mac OS X Splash Screen


How to add custom scripts while making a LiveCD customization

My stock answer for this question is this article over on Turnkeylinux's blog.  It's an Ubuntu derived distro and they have a physical to live set of scripts in their repo that works pretty well.  Bonus, you can install their scripts on Ubuntu mainline.

There's also remastersys and a couple others, but I found the turnkey scripts to be really straightforward for my needs.

The article:
Converting a virtual disk image: VDI or VMDK to an ISO you can distribute
By Alon Swartz - 58 comments | Latest by unit

Why would anyone in their right mind want to convert a VM into an ISO?

Good question, the answer for Conor Fox (who was the inspiration for this post - thanks Conor!) was to distribute his customized TurnKey PostgreSQL image so others could use it.

Distributing an ISO as opposed to a VM image allows it to be installed on any virtualization platform, as well as on bare metal, with the added bonus of running live.

I suppose that's a good enough reason, so lets get to it.

Convert VM disk to raw image and mount it

First we need to get qemu-img, a tool bundled with qemu (KVM's virtualization backend) to convert the VM disk to a raw image, and TKLPatch, the TurnKey customization mechanism to package the ISO.

If you are not using a TurnKey installation, see the TKLPatch installation notes.

apt-get install qemu
apt-get install tklpatch

I'll show how to convert a VMWare VMDK image into raw disk format. If you are using a different virtualization platform such as Virtualbox, see this post on converting a VDI to a raw image.

qemu-img convert -f vmdk turnkey-core.vmdk -O raw turnkey-core.raw

Next, mount the raw disk as a loopback device.

mkdir turnkey-core.mount
mount -o loop turnkey-core.raw turnkey-core.mount

GOTCHA 1: If your VM has partitions, it's a little tricker. You'll need to setup the loop device, partition mappings and finally mount the rootfs partition. You will need kpartx to setup the mappings.

loopdev=$(losetup -s -f turnkey-core.raw)

apt-get install kpartx
kpartx -a $loopdev

# p1 refers to the first partition (rootfs)
mkdir turnkey-core.mount
mount /dev/mapper/$(basename $loopdev)p1 turnkey-core.mount

Extract root filesystem and tweak for ISO configuration

Now, make a copy of the root filesystem and unmount the loopback.

mkdir turnkey-core.rootfs
rsync -a -t -r -S -I turnkey-core.mount/ turnkey-core.rootfs

umount -d turnkey-core.mount

If your VM had partitions (GOTCHA 1):

kpartx -d $loopdev
losetup -d $loopdev

Because the VM is an installed system as opposed to the ISO, the file system table needs to be updated.

cat&gtturnkey-core.rootfs/etc/fstab&lt&ltEOF
aufs / aufs rw 0 0
tmpfs /tmp tmpfs nosuid,nodev 0 0
EOF

GOTCHA 2: If your VM uses a kernel optimized for virtualization (like the one included in the TurnKey VM builds), you need to replace it with a generic kernel, and also remove vmware-tools if installed.

tklpatch-chroot turnkey-core.rootfs

# inside the chroot
apt-get update
apt-get install linux-image-generic
dpkg --purge $(dpkg-query --showformat='${Package}\n' -W 'vmware-tools*')
dpkg --purge $(dpkg-query --showformat='${Package}\n' -W '*-virtual')

exit

Generate the ISO

Finally, prepare the cdroot and generate the ISO.

tklpatch-prepare-cdroot turnkey-core.rootfs/
tklpatch-geniso turnkey-core.cdroot/

Thats it!

Bonus: By default the ISO will boot automatically. If you want to include the TurnKey bootsplash and bootmenu, extract the cdroot from a TurnKey ISO and tell tklpatch-prepare-cdroot to use it as a template.

tklpatch-extractiso turnkey-core.iso
tklpatch-prepare-cdroot turnkey-core.rootfs/ turnkey-core.cdroot/
tklpatch-geniso turnkey-core.cdroot/


Deleted all three 'Files' .desktop files in /usr/share/applications/ - how do I get them back?

All these files came from nautilus package. See search results on https://packages.ubuntu.com :

nautilus-folder-handler.desktop
org.gnome.Nautilus.desktop
nautilus.desktop

So you need to reinstall the Nautilus package with:

sudo apt-get install --reinstall nautilus


Could not resolve host: content.dropboxapi.com when to upload file at shutdown

method 1:  /etc/systemd/system/upload.service
1.1  /etc/systemd/system/upload.service

sudo vim  /etc/systemd/system/upload.service
[Unit]
Description=upload files into dropbox
Before=shutdown.target  reboot.target
Requires=network-online.target
After=network.target

[Service]
ExecStop=/bin/true
ExecStart=/bin/bash  /home/upload.sh
StandardOutput=journal
StandardError=journal

[Install]
WantedBy=multi-user.target

1.2  vim  /home/upload.sh

cd  /home
curl -X POST https://content.dropboxapi.com/2/files/upload \
            --header "Authorization: Bearer xxxx" \
            --header "Dropbox-API-Arg:  {\"path\":\"/test.txt\",\"mode\":{\".tag\":\"overwrite\"}}" \
            --header "Content-Type: application/octet-stream" \
            --data-binary @"test.txt"

1.3    sudo systemctl enable upload service

method 2:  /lib/systemd/system-shutdown/upload.service
2.1  /lib/systemd/system-shutdown/upload.service

sudo vim  /lib/systemd/system-shutdown/upload.service
[Unit]
Description=upload files into dropbox
Before=shutdown.target  reboot.target
Requires=network-online.target
After=network.target

[Service]
ExecStop=/bin/true
ExecStart=/bin/bash  /home/upload.sh
StandardOutput=journal
StandardError=journal

[Install]
WantedBy=multi-user.target

2.2  vim  /home/upload.sh

cd  /home
curl -X POST https://content.dropboxapi.com/2/files/upload \
            --header "Authorization: Bearer xxxx" \
            --header "Dropbox-API-Arg:  {\"path\":\"/test.txt\",\"mode\":{\".tag\":\"overwrite\"}}" \
            --header "Content-Type: application/octet-stream" \
            --data-binary @"test.txt"

2.3    sudo systemctl enable /lib/systemd/system-shutdown/upload.service


2nd instance of Firefox does not obey GTK2 customizations

Something very strange is going on. First of all, the problem was solved by syncing both profiles. A simple rsync -avz <old_profile_dir> <new_profile_dir> does the trick.

But it still doesn't explain why this was happening. As far as I know, I haven't installed any extensions or themes to tweak Firefox. Now for something much more interesting:

Check this screenshot of Gmail before syncing the profiles. Notice that the scrollbar is on the right. At the top right, it displays "xxx@gmail.com" and the labs icon, settings, etc. On the top left, the menu is black and underlined.

Now see this screenshot of Gmail after syncing the profiles. Not only is the vertical scrollbar on the left, but more interestingly, the Gmail UI is totally different. On the top right it displays the name "XXX XXX" rather than "xxx@gmail.com", and everything else goes under the "wheel". Clicking on the wheel opens up mail settings, account settings, etc. On the top left, the menu is bigger and bolder blue, with no underlines. Overall font size is 1-2 points larger.

So what is this mystery? Why does the Gmail UI change? Why are the scrollbars on the left?


It seems like its a theme issue, try:

sudo apt-get install lxappearance

I don't use KDE but I've seen a lot of problems with the KDE themes on 11.10


Ubuntu 16.04 Persistent - Installing Nvidia Proprietary drivers(Post Login Loop)

What finally fixed the problem for me was disabling the UEFI secure boot option for my OS:

Enter your UEFI Bios utility on boot and navigate to advanced mode.
Disable fast boot
Go to boot/secure boot and change OS type to "Other OS"
Save and restart

http://www.rodsbooks.com/efi-bootloaders/secureboot.html#disable


Most probably Your card vendor doesn't support newer kernels. You can contact the vendor and ask him for a driver.

You can also insert the card and

try to force its reading:

sudo sh -c "echo 1 > /sys/bus/pci/rescan"

or just leave it there and restart computer -- the card will probably detected during the boot.


Cant run shell in Ubuntu server 18.04.2 LTS but it does run in Ubuntu Desktop 18.04 LTS

It looks to me like the sed command has too many or too few /, see the comment by @steeldriver for a better sed command.

Alternatively, you can open the script in vim and view non-printable characters with [esc] :set list to see if you have any carriage returns. If that isn't the issue we'll need more context in order to solve the bash error.


Cannot boot into Windows after installing server 9.04

Yes, looks like you've installed over Windows.
If your laptop has an HDD instead of SSD than the data is still there on one of the layers of the HDD. I would recommend not to put any more data on it and preferably to use a special service to recover data.
You can try to recover data yourself but you need an external HDD(USB External HDD) on which you would recover the data and also you would have to install recovery tools or use a data recovery CD.


Cron job shut down the system ignoring the specified time

Between the two issues, you may need to:

For 1) edit the sudoers file (use 'visudo') if some part of your script requires root access. Lots of info on the web on how to do this.

For 2) this sounds like a script debugging issue. Do you get the same behavior if you run the script from the terminal rather than waiting for cron to kick it off? Is the behavior different if you run it as root (sudo)?

You might also consider adding [[ and ]] to your if statement. +1 to @Elder Geek for case.


Why is the compose key (AltGr) disabled by default?

The compose key is the key you define for the purpuse and not necessarily AltGr (Right Alt).
Many keyboard layouts use AltGr by default as a modifier to access 3rd and 4th level symbols included in the layout, and in those cases it's not suitable to define AltGr as a compose key.

I assume it's not enabled by default because there is no obvious key which would be suitable in all use cases. The key you define as a compose key stops working in its original way.


What are the design guidelines for appindicator icons?

To use custom icon located in python script folder, use this way (PyGI code snippet)

appindicator.Indicator.new_with_path (
   "indicator-name",
   "icon-name",
   appindicator.IndicatorCategory.APPLICATION_STATUS,
   os.path.dirname(os.path.realpath(__file__))


Right click the desktop and create an empty file (or use gedit) named easytether.desktop. Paste this into this file:
[Desktop Entry]
Name=Easytether
Exec=easytether connect
Terminal=true
Type=Application

and save! You will then need to make the file executable, by editing the properties of the file, or running: chmod +x easytether.desktop.

The Name=Easytether line specifies the name of the shortcut that will appear to the user.

The Exec=easytether connect line specifies the command to be run, in this case, easytether connect.

The Terminal=true line specifies that the command should be run in GNOME Terminal, so that the user can inspect its output. You can later set this to false if you don't want the shortcut to open a Terminal window. For instance, if you made a shortcut to the "sound" panel of the "settings" and want it to only open that (the command would be "gnome-control-center sound").

You can even add a line Icon=path/to/png/ (or Icon=iconname and put your iconname.png in ~.local/share/icons) in order to add a custom icon to your launcher.

Also, you can put the easytether.desktop file into ~/.local/share/applications and start it from Dash or other app-launcher (Synapse, Kickoff, Slingshot etc).


Do 'Tunables' in 'PowerTop' help on battery life?

The Good/Bad settings may or may not help, it really depends on the hardware. Some settings are marginal, others save a fraction of a Watt, others may actually not help at all.  Here is some analysis I did late 2011. I used a high precision digital multi-meter and an Atom 450 "HPMini 210-1000" and a Sandy Bridge "Lenovo ThinkPad 220i" machine to sanity check all the powertop settings for the candidate machines.
Powertop tunables that resulted in gains

Autosuspend for USB device HP Webcam-50: 2.6%
Wireless power saving for interface wlan0: 8.5%
Wireless power saving for interface wlan0: 0.5%
Autosuspend for USB device Broadcom Bluetooth device: 6.4%
Enable SATA link power management for /dev/sda: 0.4%
Enable Audio codec power management: 0.5%
Runtime PM for PCI device Intel 2nd gen Core proc. DRAM controller: 1.0%
Runtime PM for PCI device Intel 6 series/C200 HD audio controller: 1.2%
Runtime PM for PCI device Intel 82579LM gigabit network connection: 0.4%
Runtime PM for PCI device Realtek RTL8188CE 802.11b/g/n WiFi adapter: 0.4%
Runtime PM for PCI device Ricoh e823: 0.4%

Powertop tunables that resulted in losses

Runtime PM for PCI device Intel N10/ICH 7, PCI Express port 1: 0.2%
Runtime PM for PCI device Intel N10/ICH 7, PCI Express port 2: 0.3%
Runtime PM for PCI device Intel N10/ICH 7, USB UHCI controller #2: 0.2%
Runtime PM for PCI device Intel N10/ICH 7, USB UHCI controller #3: 0.3%
Runtime PM for PCI device Intel N10/ICH 7, USB UHCI controller #4: 0.1%
Runtime PM for PCI device Intel 2nd gen Core proc. graphics controller: 1.5%
Runtime PM for PCI device Intel 6 series/C200 MEI controller #1: 0.7%
Runtime PM for PCI device Intel 6 series/C200 PCIe root port 1: 0.7%
Runtime PM for PCI device Intel 6 series/C200 PCIe root port 2: 0.6%
Runtime PM for PCI device Intel 6 series/C200 PCIe root port 4: 0.6%
Runtime PM for PCI device Intel 6 series/C200 PCIe root port 5: 0.5%
Runtime PM for PCI device Intel 6 series/C200 USB EHCI #1: 0.3%

source: http://kernel.ubuntu.com/~cking/power-benchmarking/powertop-good-bad-recommendations/results.txt
raw sample data: http://kernel.ubuntu.com/~cking/power-benchmarking/powertop-good-bad-recommendations/powertop-good-bad-recommendations.ods
Fluctuations in battery reading
Note that powertop tries to figure out the power consumed from the battery ACPI status. Some batteries are not that accurate since they sometimes re-calibrate their capacity settings. So one can get some wild fluctuations in battery readings. With the kind of settings you are looking at powertop may not be able to measure the savings because we could be talking about a few mW in savings on each setting.
For big savings, see https://wiki.ubuntu.com/Kernel/PowerManagement


Postfix is a mail transfer agent, it's used to send email from within your computer system (email is inherently built into every unix-like operating system). This is sometimes used to record notifications for system administrators (i.e. an email to the 'root' user account) and things like that.

In short, you can safely select No Configuration. You absolutely don't need to worry about it.

The reason why postfix was configured was that bsd-mailx depends on it, which in turn is a dependency of devscripts, which is installed as part of the debian build system.


Unable to install VMware Player 6.0.3 on Ubuntu 14.04 due to missing modules

Try

vmware-modconfig --console --install-all

to force the recompilation of the modules.

Assuming you have the build-essentials package installed so you can actually compile kernels for the system.


Delete directory by referencing symbolic link

You can use the following command:

rm -rf $(ls -l ~/temporary | awk '{print $NF}')

If you don't want to parse ls, then you can use:

rm -rf $(file ~/temporary | awk '{print $NF}' | tr -d "\`\',")

or simple:

rm -rf $(readlink ~/temporary)

To take care of spaces both in the name of the directory that in the name of the link, you can modify the last command as follows

rm -rf "$(readlink ~/"temporary with spaces")"


Error upgrading to 13.04, "'ascii' codec can't encode character "

To paraphrase the OP's comment, the problem was that the regional configuration was mis-configured. For some reason, the system was using a Chinese-like language. It wasn't installed manually, and couldn't be uninstalled either.  To fix this error, the system locale was changed.

See:
Some menus are in Chinese/Japanese!


Consider using Damien Cassou's PPA:

To add this PPA:

sudo add-apt-repository ppa:cassou/emacs
sudo apt-get update

For emacs-snapshot:

sudo apt-get install emacs-snapshot-el emacs-snapshot-gtk emacs-snapshot

Or, for emacs24 (i.e. 24.3, stable):

sudo apt-get install emacs24 emacs24-el emacs24-common-non-dfsg

Update

As mentioned in Damien Cassou's PPA, the repository will not be maintained further (currently features Emacs 24.3) and it is recommended to use the Ubuntu Elisp PPA.

Hence, use this to add the PPA:

sudo add-apt-repository ppa:ubuntu-elisp/ppa
sudo apt-get update
sudo apt-get install emacs-snapshot emacs-snapshot-el

Ref: Emacs guide


Ubuntu 18 LTS , Stuck on "Updates and other software" during installation

with Nvidia cards you need to add nomodeset to the grub boot parameter.
here is how to do that.


What does it do?

The DLNA spec allows devices on a network to receive and send media (say, videos or music). You can play media on your system on other devices on your network, like an XBox, or a TV, or your Pi running Kodi or Plex, etc.

The spec is pretty widely supported. Several industry players back it, meaning it's more likely to be available on an average consumer device as time goes by.

A Digital Media Renderer is something that can play media received using DLNA. So, "discovering and manipulating Digital Media Renderers" essentially means that apps can use this library to see if there are DLNA-capable devices on the network, and send media to them (and then control playing that media, hence "manipulate"). Essentially, this library implements the DLNA spec's sending media part. (The dleyna-server library, OTOH, implements the receiving part - it's used to work with a DLNA server.)

  How can I use it?

I'm not sure why it's installed on your system, but aptitude suggests one reason on 16.04:

$ aptitude why dleyna-renderer
i   plymouth     Suggests   desktop-base
p   desktop-base Suggests   gnome | kde-standard | xfce4 | wmaker
p   gnome        Depends    gnome-photos (>= 3.14)
p   gnome-photos Recommends dleyna-renderer

And, yes, GNOME Photos does support it (as of 3.14):

  Status: Completed

  With this, we want to turn GNOME Photos into a Digital Media Player
  (or DMP) that can browse DMSes (DLNA Media Server) on a local network.
  It will also extend existing DMC (DLNA Media Controller) capabilities.
  Currently it can push the local/cloud content to DMRs (DLNA Media
  Renderer). With it acting like a DMP now, content can be pushed from
  DMSes to DMRs.

In the hamburger menu (☰) should be an option saying "Display on"... I don't have any DLNA devices, so the popup that shows is empty for me.

Kodi and Plex also support it. I'm not sure what else on Ubuntu supports DLNA.

  Why do I want it?

Unless you have something on the network to play to, or receive from ... you don't need it.

  What are the security ramifications to it running?

Not sure, need to research more on that. The dleyna project is supported by Intel, though, so I'd expect good security support.

  Is it safe to remove?

It should be. Even on 17.10, it's only a recommended dependency of gnome-photos. At any rate, it's nothing mission critical even on the desktop.


After my laptop is suspended, I can't log in

You don't have the numlock key on, do you?  No warnings like the caps lock, and on some keyboards, the numbers will replace the letters which produces an invalid password.


Ruby on Rails

  sudo apt-get install rails

For details, see the Ubuntu Help here.

MySQL

  sudo apt-get install mysql-server

For details, see the Ubuntu Help here.


Monitor sleep on MacBook with Ubuntu Server w/o X

Old Ubuntu versions. This may still work with 17.xx
Seek for this line in /etc/default/grub

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

You may add the option consoleblank=1

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash consoleblank=1"

OR
Try setterm --help | grep power to find the powersave and powerdown options. You'll find a way to set a 'suspend' delay.

OR
You may also have a look to TLP laptop mode tools


How do I use two different versions of wine on the same installation?

PlayOnLinux

You can use PlayOnLinux to install applications which run on different versions of wine. PlayOnLinux provides an option of installing some libraries as well along with installation of a program.

To mange different versions of wine, go to Tools > Manage Wine Versions

If you want to add your custom compiled version of Wine to this list, create new wine "version" in ~/.PlayOnLinux/wine/linux-amd64 or linux-x86 and copy your custom installation there.

While installing an application you have an option of installing it a new virtual drive, in which you can install a different version of wine.


Why is the grub menu appearing when there is no dual-boot option?

Change the two lines

GRUB_TIMEOUT_STYLE=hidden
GRUB_TIMEOUT=10

to

GRUB_TIMEOUT_STYLE=menu
GRUB_TIMEOUT=0

and run sudo update-grub again.

Please take a look at the GNU Grub Manual, here the relevant points:

‘GRUB_TIMEOUT’

    Boot the default entry this many seconds after the menu is displayed,
    unless a key is pressed. The default is ‘5’. Set to ‘0’ to boot
    immediately without displaying the menu, or to ‘-1’ to wait
    indefinitely.

    If ‘GRUB_TIMEOUT_STYLE’ is set to ‘countdown’ or ‘hidden’, the timeout
    is instead counted before the menu is displayed.

‘GRUB_TIMEOUT_STYLE’

    If this option is unset or set to ‘menu’, then GRUB will display the
    menu and then wait for the timeout set by ‘GRUB_TIMEOUT’ to expire
    before booting the default entry. Pressing a key interrupts the timeout.

    If this option is set to ‘countdown’ or ‘hidden’, then, before
    displaying the menu, GRUB will wait for the timeout set by
    ‘GRUB_TIMEOUT’ to expire. If ESC is pressed during that time, it will
    display the menu and wait for input. If a hotkey associated with a
    menu entry is pressed, it will boot the associated menu entry
    immediately. If the timeout expires before either of these happens, it
    will boot the default entry. In the ‘countdown’ case, it will show a
    one-line indication of the remaining time.

Grub also has some functions which might override the timeout set in /etc/default/grub:

The filesystem which holds Grub's Environment Block is not writable (due to filesystem corruption or lack of support)
Boot failure (will override your settings only for next boot)
Multiple Operating Systems (Dual boot)


Upgrading a system with /home on a different physical drive

Your /home directory as long as data is concerned will not be affected by system upgrades.

So you can unmount it from one system and mount it on another system and still be able to access your data as it was before.

However applications configuration files which reside in your /home directory (eg. Firefox, LibreOffice ...etc) can be affected during system upgrades.

Fortunately these configuration files can be backed up and restored when needed.

So, short answer is your configuration will work as you intend it to be and you can do system upgrades later.

Piece of advice:
system is almost always fixable, but data is not. So please keep data backups always.


How create a keyboard shortcout to launch an .jar file with Oracle Java 7 Runtine?

I've done this before with a shell script.  I haven't tested it from a custom keyboard shortcut, but give it a shot once.  This is what worked for me, and allows me to fire-up cassandra-gui by clicking on a shell script icon.

java -jar ~/cassandra-gui-0.8.0-beta1/cassandra-gui.jar

Basically, you invoke Java with the -jar option and give it the path of the jar file.

java -jar [path]/[filename].jar


Mount share in fstab for multiuser access

mount without any specific UID.

  //[url/share] /media/mountpoint cifs credentials=[credentialfile],iocharset=utf8,sec=ntlm,nobootwait 0 0

According to samba manual:

  uid=arg sets the uid that will own all files or directories on the mounted filesystem when the server does not provide ownership information. It may be specified as either a username or a numeric uid. When not specified, the default is uid 0.

As an alternative you can create a new group (sambausergroup), and both users (alfa an beta) to the group, then use that group in fstab.

  //[url/share] /media/mountpoint cifs credentials=[credentialfile],iocharset=utf8,sec=ntlm,file_mode=0777,dir_mode=0777,uid=alpha,gid=sambausergroup,nobootwait 0 0


Desktop can't delete file because thunar was replaced by nautilus (Xubuntu 12.04)

Research indicates that there are issues between Thunar and Nautilus.

Replacing Thunar with Nautilus?:

  The desktop component doesn't play well yet with the filemanager because it is using the dbus interface of thunar directly.

Thunar File Manager:

  It does not play nice (at all) when copying out of it's own Thunar window and into the Nautilus window.

My own experience is that I cannot cut/copy/drag files directly from the desktop to a Nautilus window.  I get the following 2 errors:

Error while moving "New Folder ".
There was an error moving the file into /home/****/From Desktop.
Error moving file: No such file or directory

Error while moving.
There was an error getting information about "".
Operation not supported

I get exactly the same errors when attempting to copy/cut/drag from a Thunar window to a Nautilus window.

Workarounds:

Use the Thunar file manager when working directly with the desktop (cut/copy/drag)
Do all of your file operations from within Nautilus itself

So even if Thunar has been completely removed from the system, you should still be able use workaround #2.

Applies to:

Xubuntu 12.04
Nautilus 3.4.2
Thunar 1.2.3


Dual monitor screens are reversed only in login screen

The issue arises because the login screen configuration file is located elsewhere, and your home folder holds your personalised configuration for use after login.

I had the same gripe with Zorin.

All you need to do is either copy or symlink from your personal config file to the default lightdm config file...

To copy... (ie make an orphan copy of your config)

sudo cp ~/.config/monitors.xml /var/lib/lightdm/.config/

To symlink... (ie a LIVE link to your config, which is then used every time!)

sudo ln ~/.config/monitors.xml /var/lib/lightdm/.config/

Both solutions are referenced in THIS POST

HTH :D

Edit: I am now using Mint 19. The monitors.xml file now appears to be in ~/.config/xfce4/xfconf/xfce-perchannel-xml/displays.xml


Removing Guest Session at login in Ubuntu 14.04

Just press Ctrl+Alt+T on your keyboard to open Terminal. When it opens, run the command(s) below:

sudo nano /usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf

Add the following line, save and then close.

allow-guest=false

Reboot, and you're set.

Edit

Thanks to Gunnar Hjalmarsson

Based on Gunnar Hjalmarsson comment "ubuntu-session was last updated in the middle of March. Try sudo apt-get install --reinstall ubuntu-session" when that is done, the Guest session returns.

After some research, this can be done a different way as well.

Open /etc/lightdm/lightdm.conf file from your terminal using the following command:

sudo -H gedit /etc/lightdm/lightdm.conf

If the file exists, then just add the following line:

allow-guest=false

Otherwise copy and paste the following into it:

[SeatDefaults]
user-session=ubuntu
greeter-session=unity-greeter
allow-guest=false

Save the file and exit the editor.  Reboot your system, and the changes will remain even after an update to ubuntu-session as mentioned by Gunnar Hjalmarsson's comment.


Bluetooth can no longer discover devices. 16.04.3

So i basically purged every package that had to do with bluetooth, reinstalled them, rebooted. I could now connect to my headphones, but it still disconnects from my headphones after 5mins.

So more googling revealed that tlp was the culprit, so i followed the steps in this article

Basically add my bluetooth adapter to tlp's USB_BLACKLIST

sudo nano /etc/default/tlp

...
USB_BLACKLIST=”<Your usb adapter ID gotten from lsusb>”
...


Also had some problems with Compiz following an upgrade from 11.04 to 11.10.

Just finished performing a clean install of 11.10 Desktop (32bit), now CompizConfig works fine. Hope this helps.


squidGuard: error while loading shared libraries

You have more than one option:

Remove your self-compiled version and install the official Ubuntu version with apt-get
Compile your version again with

sudo apt-get install checkinstall
make clean
./configure --prefix=/usr
make
sudo checkinstall