xdotool author here.

What you are seeing is very likely that there are two window ids. You could try and figure out exactly which window id was the one you wanted, but in most cases can just use the 'command chaining' and 'window stack' features - see "WINDOW STACK" and "COMMAND CHAINING" in the xdotool manpage.

The simplest solution to your question is to have xdotool search and pass the window ids directly to the windowactivate command, like so:

xdotool search --onlyvisible --class nautilus windowactivate

The above does a search, saves the results on the window stack, then calls windowactivate, which with no arguments applies to the first window on the window stack (aka '%1'). Think of it as a way to pipe search results into other xdotool commands within the same command line.

Here's another example to get the titles of all google chrome windows, using the '%@' window stack thing that means 'all windows on the stack' (unlike %1, %2, etc which are specific windows in the stack)

% xdotool search --onlyvisible --class chrome getwindowname %@
asdf - Google Search - Google Chrome
CNN.com - Breaking News, U.S., World, Weather, Entertainment & Video News - Google Chrome
Ask Ubuntu - Google Chrome
Google Chrome

In general, any command that emits a window id (search, selectwindow, getactivewindow, etc) will populate the window stack for use with chained commands. Another example, killing a window (usually quits an application) by clicking on it:

% xdotool selectwindow windowkill


Shouldn't dconf-editor and gsettings access the same database?

dconf-editor uses schema path to show settings data tree. Same structure used to store data in GVariant database.
gsettings (from glib-2.0) uses schema id to show/get settings data. Same way as any other application should do which uses GSetttings API.
It's up to the application developer to set both as he/she would like. (with some restriction for canonical naming). So path could be different than id but most application developers prefer to use identical word series/combination. Some don't preserve same capitalization. Example Tracker project from Gnome

<schema id="org.freedesktop.Tracker.Miner" path="/org/freedesktop/tracker/miner/" />

In addition to that, some alternative applications share same settings which belong to the Gnome desktop. Example: input-sources

First, Apps should not mess with dconf

Introduction from dconf project page:

dconf is a low-level configuration system. Its main purpose is to provide a backend to GSettings on platforms that don't already have configuration storage systems.
Where's the data stored? (Ref: https://wiki.gnome.org/Projects/dconf/SystemAdministrators)

A profile is a list of configuration databases. What it seems that Gnome & Unity use same profile.

$ cat /etc/dconf/profile/gdm
user-db:user
system-db:gdm

user-db:user: First database in the profile is read-write rw and it is created in the user's home directory.

$ file ~/.config/dconf/user
/home/sneetsher/.config/dconf/user: GVariant Database file, version 0

system-db:gdm: read-only

$ file /etc/dconf/db/gdm
/etc/dconf/db/gdm: GVariant Database file, version 0

dconf could bind a text style store in addition to GVariant Database from db.d/* folder. Example (Notice file path, so it is a part of system-db:gdm):

 $ cat /etc/dconf/db/gdm.d/00-upstream-settings

 # This file is part of the GDM packaging and should not be changed.
 #
 # Instead create your own file next to it with a higher numbered prefix,
 # and run
 #
 #       dconf update
 #

 [org/gnome/desktop/a11y/keyboard]
 enable=true

 [org/gnome/desktop/background]
 show-desktop-icons=false
 ...

Schema Files: Relation between schema id & schema path  (*.gschema.xml)

What is the schema XML file in the data/glib-2.0 folder of my Quickly application? by trent shows a nice example of using GSettings API in a Quickly application, and his conclusion based on his experience.

Back to Vino. Each application that uses GSsettings should define its schema's and should store/install them in /usr/share/glib-2.0/schemas/ (It's a glib directory):

$ dpkg -L vino | grep -i glib-2.0
/usr/share/glib-2.0
/usr/share/glib-2.0/schemas
/usr/share/glib-2.0/schemas/org.gnome.Vino.enums.xml
/usr/share/glib-2.0/schemas/org.gnome.Vino.gschema.xml

$ more /usr/share/glib-2.0/schemas/org.gnome.Vino.gschema.xml
<schemalist>
  <schema id='org.gnome.Vino' path='/org/gnome/desktop/remote-access/'>
    <key name='enabled' type='b'>
      Enable remote access to the desktop
      <description>
        If true, allows remote access to the desktop via the RFB
        protocol. Users on remote machines may then connect to the
        desktop using a VNC viewer.
      </description>
      <default>false</default>
    </key>

    <key name='prompt-enabled' type='b'>
      Prompt the user before completing a connection
      <description>
        If true, remote users accessing the desktop are not allowed
        access until the user on the host machine approves the
        connection. Recommended especially when access is not password
        protected.
      </description>
      <default>true</default>
    </key>
...

If you noticed, The schema is defined with an id and a path. The schema file name follows the id value.

<schema id='org.gnome.Vino' path='/org/gnome/desktop/remote-access/'>

*.enums.xml files are for custom enumeration declaration, to be used as new data types in *.gschema.xml with same schema id.

$ cat /usr/share/glib-2.0/schemas/org.gnome.Vino.enums.xml

<schemalist>
  <enum id='org.gnome.Vino.VinoIconVisibility'>
    <value nick='never' value='0'/>
    <value nick='always' value='1'/>
    <value nick='client' value='2'/>
  </enum>
</schemalist>

$ gsettings range org.gnome.Vino icon-visibility
enum
'never'
'always'
'client'

$ gsettings get org.gnome.Vino icon-visibility
'client'

Compiling Schema's (Ref: Playing with dconf and gnome-tweak-tool)

As part of the installation process (it has a dpkg trigger), schema's are compiled with glib-compile-schemas tool (from glib)

sudo glib-compile-schemas /usr/share/glib-2.0/schemas

*.gschema.xml will be compiled to a binary file /usr/share/glib-2.0/schemas/gschemas.compiled
Vendor Override Files (*.gschema.override)

In addition to schema files, glib-compile-schemas reads vendor override files, which are key files that can override default values for keys in the schemas (Ref: man glib-compile-schemas). They contain the changes done by Ubuntu distribution to override upstream schema defaults.

$ ls /usr/share/glib-2.0/schemas/*.gschema.override
/usr/share/glib-2.0/schemas/10_compiz-gnome.gschema.override
/usr/share/glib-2.0/schemas/10_desktop-base.gschema.override
/usr/share/glib-2.0/schemas/10_evolution-common.gschema.override
/usr/share/glib-2.0/schemas/10_gnome-settings-daemon.gschema.override
/usr/share/glib-2.0/schemas/10_gnome-shell.gschema.override
/usr/share/glib-2.0/schemas/10_gnome-system-log.gschema.override
/usr/share/glib-2.0/schemas/10_gsettings-desktop-schemas.gschema.override
/usr/share/glib-2.0/schemas/10_libgtk-3-common.gschema.override
/usr/share/glib-2.0/schemas/10_ubuntu-settings.gschema.override
/usr/share/glib-2.0/schemas/20_ubuntu-gnome-default-settings.gschema.override

$ cat /usr/share/glib-2.0/schemas/10_gnome-settings-daemon.gschema.override
[org.gnome.desktop.wm.keybindings]
switch-input-source=['<Super>space']
switch-input-source-backward=['<Shift><Super>space']

Example of override files use, See How to customize the Ubuntu Live CD? (5. Customization 2: Backgrounds and Themes).
Lock files

Currently, dconf supports only per-key locking, no sub-path lock. User defined values will still be stored in user-db but will have no effect on applications. dconf/gsettings returns default values instead for those locked keys. Lock files are stored in db.d/locks/. Example:

$ cat /etc/dconf/db/gdm.d/locks/00-upstream-settings-locks
/org/gnome/desktop/a11y/keyboard/enable
/org/gnome/desktop/background/show-desktop-icons
/org/gnome/desktop/lockdown/disable-application-handlers
/org/gnome/desktop/lockdown/disable-command-line
/org/gnome/desktop/lockdown/disable-lock-screen
/org/gnome/desktop/lockdown/disable-log-out
/org/gnome/desktop/lockdown/disable-printing
/org/gnome/desktop/lockdown/disable-print-setup
/org/gnome/desktop/lockdown/disable-save-to-disk
/org/gnome/desktop/lockdown/disable-user-switching
...

After locks modification, to be effective run:

sudo dconf update

A good showcase: dconf Settings: defaults and locks
Changing Global Settings

The default for gsettings/dconf-editor is to edit the user-db. To change system-db, write a new override file and recompile schema's.

I couldn't get this to work:

sudo su gdm -c 'gsettings ...'

neither the other answers here Set Default/Global Gnome Preferences (Gnome 3), may be that was for an old release.


How do I make gmusicbrowser select the USB headphones as the default output?

This was fixed in 16.04 at least on my box.

The catch is, pavucontrol now remembers which app has which default sound sink and which fallback sound sink.  So, I can choose to set my USB headphones as an out and the on-board as a fallback, so they get used if the headphones get disconnected (I think it's the other way around actually - USB specified as a fallback, but they kick in when plugged in), but it's app specific.


How to reset Krusader configuration to defaults / remove corrupted config file?

apt-get purge krusader

and removing ~/.config/krusaderrc for each user

and then reinstalling

apt-get install krusader

reverts Krusader to "factory default", showing the initial config dialog where you can set all the paths to the tools that Krusaders uses. That should erase all the config that exists.


how to install wireless driver broadcom STA (wl) for asus x201e with kernel 3.8.1

Was one of the fixes you tried linux-backports-modules? If so, I'd remove it:

sudo apt-get remove --purge linux-backports-modules-cw*

Next, I'd reinstall the Broadcom driver:

sudo apt-get install --reinstall linux-headers-generic
sudo apt-get install --reinstall bcmwl-kernel-source
sudo modprobe wl

You should be all set.


How to copy or move a file from a folder to desktop?

Desktop is a directory in your user's home directory.

If your language is English it is called Desktop.

To copy some file there, you can run

cp file ~/Desktop

~ stands for /home/<username>

If your UI language is not English, it is called differently.

You can do a copy without finding the correct name by

cp file "$(xdg-user-dir DESKTOP)"

You can get the name of the Desktop directory by

xdg-user-dir DESKTOP

You can use mv instead of cp if you want to move a file instead of copying.


What is "failed to create symbolic link" error?

The /usr/lib/firefox/firefox file only exists if the default Firefox from the Ubuntu repositories is installed. Reinstalling it with sudo apt install firefox would remove this error message. It would also be appropriate to check if installing packages with Kali Linux tools uninstalled any other applications which are installed by default in Xubuntu.


GNOME settings are generally stored via the GSettings API, which is an implementation of the DConf specification. This stores the settings in a binary database, which should not be replaced while logged in.

Instead, the settings need to be exported and then loaded in again.

You can use dconf dump / > dconf-settings.ini to dump the settings to an INI file, and then use cat dconf-settings.ini | dconf load / to load those settings back in. You can replace the / with a specific path to limit what settings are dumped and loaded. See man dconf for more details there.

If you want to simply set a single key, rather than whole paths, it would be better to use gsettings for this, with gsettings get and gsettings set in a script.


Microsoft Sculpt Ergonomic Desktop virtual joystick: how to remove it?

The temporary brute force solution is to just rename/delete the device files, i.e.:

rm /dev/input/js0
mv /dev/input/js1 /dev/input/js0

Note however most modern games do not use the /dev/input/js0 interface at all, so you will need to take care of the /dev/input/eventX files as well. You can use evtest to find out which device is your keyboard and joystick. On the next reboot the devices will be back in their old order.

Another slightly less brute force method is via the environment variable:

SDL_JOYSTICK_DEVICE="/dev/input/js1"
export SDL_JOYSTICK_DEVICE

This forces SDL based games to use js1 instead of js0. I don't think this will work with modern SDL2 based games and it will only work for a single joystick/gamepad, so it's of limited use.

SDL2 does provide an option to configure a joystick and remap buttons, but I don't think it has a facility to reorder devices at the moment.

And finally there is also the "clean" method by writing an udev rule, this will essentially do the same as the rm/mv hack, but permanently. These rules go to /etc/udev/rules.d/ and tutorials for writing them can be found scattered around the net, maybe this will help, not sure if it's up to date:

http://www.reactivated.net/writing_udev_rules.html


I'm running ubuntu 16.04, How do I make a hotspot from the same wifi interface?

Any single-band wireless device can only either receive or transmit a wireless signal.

Even my dual-band (5Ghz and 2.4Ghz) can only receive or transmit at any time. Even if I am connected to a 2.4Ghz wifi, I cannot create a 5Ghz hotspot from that same device.

The only possible way to create a wireless hotspot is if you have an internet connection via another wireless card or through a wired connection.

TL;DR - It's not possible.


How to add microphone audio into avconv's video in x11grab mode?

Make sure microphone is properly plugged in. You may also test your recording settings using "sound recorder" on your Ubuntu.

Now, execute the following command on terminal by replacing 1366x786 by your screen resolution.

avconv -f alsa -i pulse -f x11grab -r 30 -s 1366x768 -i :0.0 -vcodec libx264 -preset ultrafast -threads 4 -y myscreencast.mp4

If you use avconv regularly of making screencast you would like to avoid typing above command each time (in that case, do the following) :

Save the script given below in ~/Videos/ with filename screencast

#!/bin/sh
echo "Enter the output file name: "; read name

fullscreen=$(xwininfo -root | grep 'geometry' | awk '{print $2;}')

avconv -f alsa -i pulse -f x11grab -r 30 -s $fullscreen -i :0.0 -vcodec libx264 -preset ultrafast -threads 4 -y $name

Do, chmod +x screencast

Now, double-click on screencast file and "Run in Terminal"
Enter the name of video you want to make(filename and extension eg:myvideo.mkv or myvideo.mp4).

Finally, on completing your screencast, do ^C (contol+c) in terminal.

Your video will be saved in ~/Videos/
Bingo!!!


It appears something may be amiss with your keys and authentication agent.  In your Unity terminal session, try:

SSH_AUTH_SOCK=0 ssh -vT github

One clue is that you're using a different authentication agent if you're running in an X session versus a text (vty) console.

Source: https://help.github.com/articles/error-agent-admitted-failure-to-sign


Can't move/resize windows with Logitech wireless mouse connected (Precise)

I fixed this problem by disabling then re-enabling Smart Move in the Logitech mouse settings


14.04: Can't install fglrx on Dell with AMD graphic card

I have the same problem and I haven't solved it yet. But I found out what's wrong.

I'd like some expert advice to, but it looks like FGLRX does NOT work on Ubuntu 16.04 and the latest 14.04 (5) because it is not compatible with a recent version of XORG.

Here's an explanation:

Ubuntu 14.04.5/16.04/16.10 and AMD graphics

Please Note: 14.04.5 brought with it Xorg 1.18, which is what causes the problem in 16.04 to begin with. Luckily, it is completely possible to downgrade Xorg to 1.16 (on 14.04), so you can still use fglrx. Read here.

I actually needed the AMD APK to code in OpenCL 2.0, so I guess I just have to avoid AMD drivers and find another way to install OpenCL.

One suggested solution in the linked page is:

Try out Oibaf's drivers.

They work for AMD, NVIDIA and Intel, so you can even try them out if you dislike NVIDIA's proprietary drivers or are hoping for more performance from your Intel card.
They support newer OpenGL and OpenCL versions, so stuff that depends on those will work.
They claim to be optimized, so you could see an real boost in performance.

Oibaf's driver seems like a great replacement to fglrx, and it probably is. However, if you have a really recent AMD card, you may want to try out AMD's own offering.


The first screenshot shows no sound card. It looks like you connect to an external monitor, could be the headphone and you did not exit the device properly. Redo what you did and make sure you select the PC sound card (Output Device) before exiting the external device.

Could be a dead sound card also or corrupt driver.

What do you read there:

inxi --extra -A

See the given solution there by Mr.reaysawa

Headphones not detected if plugged in before boot Ubuntu 18.04


What package creates /usr/lib/jvm/default-java?

You can search for this information using apt-file. You may need to setup apt-file before you can use it.

sudo apt-get install apt-file            #Installs
sudo apt-file update                     #Updates local file list
apt-file search <path to file/directory> #Does the searching

It reports that default-jre-headless is the package you should be looking for.

You may find this question on Super User useful


Wired Network (eth0) disappears on a Lenovo Z570

sudo dpkg --configure -a

This solved the problem for me. All configuration files were rewritten including the ones for network-manager. I must add that I have a Intel Corporation PRO/Wireless 4965 AG on a Dell XPS M1530.


How do I create an bootable win 7 usb in ubuntu?

First, download WINusb by running these commands in the terminal

sudo add-apt-repository ppa:colingille/freshlight
sudo apt-get update
sudo apt-get install winusb

after the installation, run winUSB and specify the .iso image you want to use in creating your bootable flash drive


Rooted Nexus One doesn't show up in Banshee

The instructions you followed should no longer be necessary for getting Banshee to recognize your Nexus One.  Support for the Nexus One was added in the Banshee 1.6 stable release.  However, there was a recent bug in the Ubuntu packages for Banshee 1.9.5 that caused Banshee to build without a hardware manager.

The good news is, this has been fixed in the 1.9.6 release, which is available in the Banshee Unstable PPA.  I'm not sure if the release has been pushed out in the Natty updates yet, but if it hasn't, it should be soon.  (If updating to Banshee 1.9.6 doesn't fix the problem, be sure to report back here, and we'll see if we can figure out what's going on.)


Ubuntu 18.4 LTS With NVMe SSD On board Work slower than Normal SSD

You can try with this:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nvme_core.default_ps_max_latency_us=200"

And then update the GRUB.


Unmet dependencies error while installing uuid-dev

Update did not help on Ubuntu 10.04 32bit.

I had to manually download the required package here and install it:

cd
wget http://launchpadlibrarian.net/41632055/libuuid1_2.17.2-0ubuntu1_i386.deb
sudo dpkg -i libuuid1_2.17.2-0ubuntu1_i386.deb


Use the unallocated space to expand Windows (Ntfs Partition)

To expand the NTFS partition, the free space must follow it.  Right now it is in the middle of your extended partition.  To fix this, you will need to move the ext4 partition to the right, then resize the start of the extended partition to the right, then you can expand the NTFS partition.

Note that moving partitions takes a very, very long time, and if something goes wrong ( power goes out ), you will trash your data, so make a backup first.


Linux is still in control of the MBR or master boot record (so-to-speak) which isn't installed on the linux partition.

All you need to do is repair it using Windows install media or windows repair disc. You don't say which Windows version your using so here's a google search for all, just check it out:

https://www.google.com/search?client=ubuntu&channel=fs&q=repair+wiindows+boot+record&ie=utf-8&oe=utf-8

The MBR needs to be replaced by the Windows one. Its very unlikely to do it without a cd/usb. Messing with it in other ways could cause you more grief. Don't do that to yourself.


Remotely log into multiple computers and run a python script

Another option is Ansible. Like SaltStack, Ansible is a configuration management solution. Ansible was literally built to execute commands on multiple remote machines.

Ansible is nice because you don't have to install anything on the "target machines". You simply install it on the host machine (i.e. your computer), and it uses SSH to log into target machines and run shell commands on them.

Here are instructions to install Ansible on Ubuntu.

Let's say you want to run your script on 2 target machines, at ip1 and ip2. You could create an Ansible playbook, playbook.yml, as follows:

---
- hosts: "ip1:ip2"
  user: "my_login_user"

  tasks:
    - name: "execute my script"
      script: my_script.sh

Then, create your script, my_script.sh or my_script.py or whatever, in the same directory as playbook.yml.

Finally, run the following from the command line:

ansible-playbook -u my_login_user -i "ip1,ip2" --private-key=<path_to_my_private_ssh_key> playbook.yml

If you have SSH access to the target machines via that user and SSH key, Ansible will SSH into them and will run your script. You can extend this to as many machines as you want.


I just upgraded from 18.04 to 20.04.1 LTS & now cannot connect to my vpn

As I understand it, you're using the Proton VPN app to connect. It is likely that during your upgrade to 20.04 some parts of that app got removed. Reinstall the app as follows:

First uninstall the Proton VPN app from your system. If you've been using the Python-based community version, type: protonvpn configure and select 7) Purge Configuration. and then type sudo pip3 uninstall protonvpn-cli or pip3 uninstall protonvpn-cli. If you've been using the official client, remove it with sudo apt purge protonvpn. Depending on which version you have been using, not every command is going to work. No worries, just run dem all to be sure.
Then run sudo apt autoremove to clean up any leftover packages.
Follow the step by step guide on the Proton VPN website in order to install the VPN client.
Connect to the VPN as described in the link above.


Anaconda Navigator only shows Visual Studio Code

It's likely that you installed anaconda as root with something like

sudo sh ~/Downloads/Anaconda...

Then launched navigator without sudo

anaconda-navigator

That's what I did to cause the same issue on my install anyway

To fix this either allways run  in sudo anaconda-navigator, or remove the anaconda install with

sudo rm -rf ~/anaconda3

and re-install without sudo.


The command gconftool-2 --recursive-unset /apps/gnome-terminal will unset all settings you added to the gnome-terminal.

You can also unset only one key with the --unset option.

You might need to log off and back on for the settings to take effect.


Install the 32-bit libraries: sudo apt-get install ia32-libs


Not if you haven't done something to preserve the session beforehand, like using screen to keep the shell alive, or used script to save the output. You could, of course, browse your command history to see which commands you had used:

history | less


What does outputting to /dev/null accomplish in bash scripts?

>/dev/null redirects the command standard output to the null device, which is a special device which discards the information written to it

2>&1 redirects the standard error stream to the standard output stream (stderr = 2, stdout = 1). Note that this takes the standard error stream and points it to same location as standard output at that moment. This is the reason for the order >/some/where 2>&1 because one needs to first point stdout to somewhere and then point stderr to the same location if one wants to combine both streams in the end.

In practice it prevents any output from the command (both stdout and stderr) from being displayed. It's used when you don't care about the command output.


How to fix invisible Unity panel, launcher and dash in a VM?

OK, this time I have an answer, at least for my Virtualbox installation:-
The problem was with the version of "VirtualBox Guest Additions".
I was running version 4.2.12.
After updating my VB installation I then fired up my guest and pressed HOST+D
(HOST in my case is the right CTRL key)
This popped up a message asking if it was ok to install the Guest Additions.
After OK'ing this the old version was replaced.
On restarting the guest now displays the Panel and Launcher correctly


How can I change or shut off a screensaver setting without using Gnome

Using the graphical tool GConf Editor:

Run the command gconf-editor from a terminal or  the Alt+F2 dialog.
Navigate to apps ➜ gnome-screensaver.
Uncheck the idle_activation_enabled setting to stop the screensaver from activating automatically.
If you want to set the screensaver theme to Blank screen, right click on the themes item and click Unset Key.

From the command line:

Disable the screensaver from automatically running when the computer is idle:

gconftool --set --type=bool /apps/gnome-screensaver/idle_activation_enabled False

Set the screensaver theme to Blank screen:

gconftool --unset /apps/gnome-screensaver/themes


Unable to boot Windows 7 after installing Ubuntu to MacBook with OS X & Windows 7 (bootcamp)

It would help to have more detailed information about how your GRUB and Windows boot configuration are currently setup on your MacBook. I suggest you try this:

Boot into the Ubuntu you installed on your MacBook.
Create a Bootinfo Summary using the boot_info_script.
Copy the summary into a pastebin (For example, http://paste.ubuntu.com).
Edit your question to include the link to the pastebin containing the summary.

An alternative way to accomplish the same thing would be to install and run a utility named Boot-Repair tool. It will create a bootinfo summary and post it to a pastebin for you "automatically" in one step.

I have another answer which describes how to do this. Here is a link to that answer:
How to use boot-repair to provide a "Bootinfo Summary"

Note:
The Boot-Repair tool also has a button to perform a Recommended repair. Since this is a Mac with a hybrid MBR, I would caution against doing that until you have a better understanding of just what the problem is.
My advice is to first get the bootinfo summary and wait until you have looked at it before attempting to fix this with Boot-Repair.


One way is to simply run vino-server yourself.  First, kill the old server.

sudo killall vino-server

Then launch the server yourself.  You may wish to set the display, particularly if you're doing this over SSH.

/usr/lib/vino/vino-server --display=:0

Once you have it working, wrap it in nohup...& and it will keep working until your next reboot:

nohup /usr/lib/vino/vino-server --display=:0 &


Packages not showing up in created APT repository

Yes, you do need to build 2 sets of packages - you cannot install i386 packages on an amd64 system without forcing the installation, which generally should not be done.


If the last character must be either B or N, then the condition in your code is wrong.
Instead of

(!ref.toUpperCase().endsWith("B")) || (!ref.toUpperCase().endsWith("N"))

it should be

(!ref.toUpperCase().endsWith("B")) && (!ref.toUpperCase().endsWith("N"))

You need and instead of or.
Read it like this: "If last letter is not B and last letter is not N, then error".


First, might be a 12.04 installer bug...which is off topic.

Second, you should be able to install grub from live like this.


Terminal says 'Broken package' when using apt-get to install phpMyAdmin

Only with that app, or with everything you try to install?

You can try:

sudo apt-get -f install


You should use the Terminal app.
Navigate to your files, then type nano filename. This opens your file in the text editor nano and you can make your changes.


gkbd-keyboard-display failed: Command not found

In Oneiric and Precise, gkbd-keyboard-display is available in the package gkbd-capplet.

To install it, run the following command in a terminal:

sudo apt-get install gkbd-capplet


I am sudo but cannot edit file or save it

$ gedit /etc/bumblebee/bumblebee.conf

You claim you are sudo here? I claim you are not... you need to do...

sudo gedit /etc/bumblebee/bumblebee.conf


Qjackctl alsa connections, what connects to what?

Connect the output of the USB MIDI cable to the input of whatever it is that you want the guitar connect to.
In this case, I'd guess the cable calls itself "mio", and you want to make sounds with rakarrack.


"service kdm stop" yields "stop: Unknown instance:" and I'm unable to log out

If you are having this kind of issue, you can reboot the computer from the command line:

sudo reboot

Make sure to save any work you may have open.  This command will not prompt you at all, and programs which want to block shutdown will most likely be unable to do so.  This will bypass X.  If for some reason this does not work, try adding the "--force" option:

sudo reboot --force

If you are unable to launch a terminal, you may be able to get to run a command with Alt+F2, but be sure to use "gksu" or "kdesu" instead of "sudo".  If this doesn't work, press Ctrl+Alt+F5 (you can use any F key from F1 through F6), login, and proceed as above (using "sudo", not "gksu").  If you still cannot reboot the machine, use the magic sysrq key

If you don't want to reboot the whole computer, you may be able to fix it by sending a SIGHUP to kdm (or gdm or lightdm), but it sounds as if you already tried that.  But in case you haven't:

pgrep dm -l

Look at the PID's printed for

12345 kdm

(or gdm or lightdm), and then send it a signal:

sudo kill -SIGHUP 12345

(replace 12345 with whatever number it output)


Advice on setting up parental controls/times for my son

I am new to Linux too, I briefly used Ubuntu for a year before I replaced my laptop with a smartphone a over a decade ago, but haven't touched it since until 2020, when I bought a Pinephone and installed Debian on it, followed shortly afterwards by my wife buying an ancient secondhand Dell desktop for our then 8 and 12 year old daughters' schooling from home.
Now this PC wouldn't even boot up it's Windows XP operating system and even if it did, the Microsoft Teams software the school used wasn't compatible with it. I fought on a little and got it booting up, only to find myself in a Windows absent driver nightmare, still it was a little nostalgic.
Soon afterwards I installed Debian and it just worked, bliss! During bootups it'd mention two failing hard drive sectors (which has since grown to five over the last several months), but it has worked brilliantly, there is even a .deb Teams package for download from Microsoft's website. I assume it'd work on Ubuntu too.
So far I've just been using StephenBlack's hosts file, specifically the unified hosts plus social networks, pornography and gambling, I can't remember if I just copied it over /etc/hosts with KDE's Krusader file manager, or copied and pasted the text from the downloaded file into the existing file using KDE's Kate text editor, either way it made the computer quite safe for the children. Another possibility is the administrator addon for Nautilus (Gnome Files).
I've read Apparmor might be useful for restricting applications by user, although it has no GUI yet and it's purpose is securing the OS from applications to protect against things like unpatched vulnerabilities, so it'll be interesting to see what happens there.
Last but not least, my answer. Squidguard, check the squidguard documentation on imposing time constraints.  I think it can do everything you want, if not a combination of Squidguard and using your hosts file as mentioned above should work. I only discovered it myself a moment ago after not seeing an answer I liked in the replies yet. Another advantage of this is if you use the computer as an internet access point and router (as I do my Pinephone), you should be able to use iptables to transparently route the connection through the squid proxy (I'm assuming that's what it's using) to protect every connected device too.
Edit: Don't forget to backup, you'll be annoyed to lose your configuration and your children their schoolwork and game data. I use Deja Dup to a network drive and Timeshift to a second hard drive at the moment. If you're using Wayland, KDE's Muon Package Manager works almost as well as the great Synaptic Package Manager on X display servers.


Command line volume control amixer has problems with muting

Looks like a bug, you should report it.

Meanwhile, you could instead use

amixer set Master playback 3+
amixer set Master playback 3-


Set up apt-get remove commands in deb file (dh_make)

You will need to use maintainer scripts to do things during the removal of your app (specifically prerm and postrm).

You may want to take a look at Debian packaging policy http://www.debian.org/doc/debian-policy/ch-maintainerscripts.html

Below is an example prerm script that I had previously used when removing the mythbuntu-repos package, in order to remove the added repository and key information as well.

#!/bin/sh

case "$1" in
    remove|purge)
    if [ -x /usr/bin/apt-key ]; then
        /usr/bin/apt-key del EEED06D0 2>/dev/null || true
        /usr/bin/apt-key del 1504888C 2>/dev/null || true
    fi
    rm /etc/apt/sources.list.d/mythbuntu-repos.list 2>/dev/null || true
    ;;
esac


problems with update manager after changing ubuntu version

Go to Software Centre and install Synaptics Package Manager. After installing open it and select Custom Filters from the bottom left and from the left toolbar select Broken. Right Click on the broken packages and select reinstallation or complete removal option. This should solve it.


Here is how I just build it on Ubuntu 20.04:

Clone source code
 git clone https://gitlab.gnome.org/World/deja-dup.git

and cd ./deja-dup into the folder.

Switch to older branch with gtk3 support for Ubuntu 20.04
git checkout --track origin/40`

Update whatever you want to change, eg. Improve full backup speed with Déjà Dup / Duplicity

Make and install (including installing missing packages):
meson . _build
ninja -C _build
ninja -C _build install

Voilà:


Can you provide us with the output of ulimit -a ran in a session where this happens?

/etc/pam.d/sshd should involve pam_limits.so when you open a session. This module will use /etc/security/limits.conf to apply various restrictions to your session, including regarding memory usage.


Tomcat Installation startup.sh not working

Your problem is that you cannot mix guides. Just revert the modifications to the ~/.bashrc file. With the first command you already have tomcat installed but without starting the webserver. Just run sudo service tomcat7 start then go to your web browser and type http://localhost:8080 and done.

sudo lsof -i:8080
COMMAND   PID    USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
java    11399 tomcat7   44u  IPv6 632616      0t0  TCP *:http-alt (LISTEN)


Either disable system sound effects or, I am assuming you want to disable only the screen shot sound, move or rename /usr/share/sounds/freedesktop/stereo/camera-shutter.oga

sudo mv /usr/share/sounds/freedesktop/stereo/camera-shutter.oga /usr/share/sounds/freedesktop/stereo/camera-shutter-disabled.oga


How to take screenshot of shutter's menu?

Just use the default screenshot tool, (gnome-screenshot in Gnome, no idea in Unity)  and give it a delay of say, 5 seconds. Then navigate to your desired menu and wait, the screenshot will show the chosen menu.

That then allows you to take pictures like:

It's the same idea as a regular camera. To take a picture of your camera, you need to use another camera.


Two different SSD drives, which one to mount for home?

I'd use the slower ssd too. Ubuntu boots fast anyway so it really doesn't matter which you choose. You would not notice the difference anyway (unless you do some benchmarks).


Yeah I just bought the same laptop.  I found that until I had everything "working" I had to remove "quiet splash" and add in "nomodeset" to get through installation.  After installed ubuntu... I ran sudo X -configure then mv ~/xorg.conf.new /etc/X11/xorg.conf

Once that was done I edited /etc/grub/Default and added "nomodeset" after "quiet splash" and then sudo update-grub

I tried to install bumblebee and the Nvidia PPAs but as far as my ubuntu install knows it seems to only be aware of the intel card....


Cannot install Ubuntu 20.04 on Mac mini 2020

OK so this is what worked for me.From the 20.04 iso on a USB let the installer do it's thing.It will create a small partition with /boot/efi and take up the rest of the drive with / as you know there is no need for a swap partition as Ubuntu now uses a swap file.The installer will appear to fail as per my question above.Executing 'grub-install /dev/nvme0n1' failed. This is a fatal error.When you reboot you will get a limited grub terminal.Full notes are here but below are the basics from rohiths answer;
At the grub console;
grub> ls

(memdisk) (hd0) (hd0,msdos) (hd1) (hd2) (hd2,gpt3) (hd2,gpt2) (hd2,gpt1)

You may not get exactly the same results as this, but you’ll have some similar options.
Now, find the partition which contains your user's home directory.
grub> ls (hd2,gpt2)/home

rohith/

Keep trying until you find it.
The result from the last step has two parts: (hdX,gptY). You need to keep the hdX part, but go through all the gptY options looking for a /boot/grub directory.
grub> ls (hd2,gpt2)/boot/grub

unicode.pf2 [...] grub.cfg

Now you want to set this as your root for further commands.
grub> set root=(hd2,gpt2)

The only way to boot properly was to use the UUID of the drive. To get it -
grub> ls -l (hd2,gpt2)

Note down the UUID. You'll have to type it manually in the next step.
grub> linux /boot/vmlinuz〈...tab here!...〉.efi.signed root=UUID=〈the UUID from above〉

The GRUB console can do tab completion, so if you just type out the vmlinuz part and hit tab, then hit . and tab again, you won't have to type the whole file name. make sure that the efi.signed part is present.
Now, set the initial RAM disk
grub> initrd /boot/initrd〈...tab here!...〉

You should be able to boot with the command
grub> boot

This will reboot and get you to the login screen as if you had a perfect install and rebooted. If you have an internet connection you can get the system up-to-date at this point but do NOT reboot untill you fix grub. NOTE the boot partition is incorrect, the boot loader actually needs to be reformatted as FAT32 with mount point /boot/efi with flags (boot,esp) which is done simply using gparted.According to rohiths answer, The system was initially unbootable because the Mac bootloader expects the EFI partition to be formatted as HFS+, the typical Mac filesystem, while the Ubuntu installer actually formats it as VFAT. But this is NOT correct on my machine.So now you can mount the new partition with boot/efi and re-install grub, check your config and update-grub then you can reboot.


Can't install ubuntu 16.10 alongside windows 10

When choosing to boot to the flash drive make sure to select the same BIOS mode either UEFI or BIOS that matches the windows instillation. You can usually find what mode your in the boot options of your BIOS. It should show boot using UEFI, BIOS or Both.


Which CUDA, CUDnn, Nvidia versions to install for Deep Learning?

Your Geforce 820M GPU has a CUDA capability of 2.1 (see Intel geforce gpu list
This capability is too low for CUDA 9.0+, but does support CUDA 8.0.  Try installing that CUDA version.  The Nvidia cudnn has its own set of requirements: on link cuDNN installation Guide First 2.1 requirements bullet:

2.1 *  A GPU of compute capability 3.0 or higher. To understand the compute capability of the GPU on your system, see: CUDA GPUs. Also see the cuDNN Support Matrix.

So your 820M GPU of capability 2.1 is not sufficient to run even the oldest cuDNN offered (See the cuDNN Support Matrix in the above link for details).  That prevents anything depending upon cuDNN from running too (like TensorFlow or Therano?).


What is the difference between the "Entire Partition" and "Entire Disc"?

[use entire partition] uses your currently selected partition and automatically creates partitions for Linux (root and swap, at least).

[use entire disk] is your option 2: remove everything and install Ubuntu, using whole disk. This will also automatically create partitions for Ubuntu. Difference is that it'll first remove all old partitions.

[Install now] is possible, if you already configured (manually or automatically) partitions (sizes, filesystems and mount points). If you didn't, it'll complain and tell what's missing.

Before making changes to your disk, remember to backup important files. There's always risk you'll choose wrong and delete important things.


Xbox controller won't work with Dishonered PC game (played through steam and wine)

The problem is that Wine doesn't have support for Xinput, which is the API used by most modern games for Xbox360 gamepad support. There is a workaround for it, the same you would use for Windows and an old non-Xbox360 gamepad, but it's a little complicated, see:

https://groups.google.com/forum/#!topic/xboxdrv/wgY0sp-drD8


Installed MATE on Lubuntu and still have leftovers from LXDE

Ubuntu allows you to install several desktop environments all at the same time, and you can switch among them when you log in. Unfortunately, most are not "refined" to work together (as you have seen) so you see pieces and applications for other desktops scattered about when you have them installed.

(Removing the lubuntu-desktop package doesn't necessarily remove all of lxde; it just removes the package that brought in the parts considered essential to lubuntu. The same is true of removing ubuntu-desktop.)

You can TRY using the terminal command

sudo apt-get autoremove

and see if more of the environments you don't want to use get removed, but there will likely be some additional extra packages hanging around regardless.

One solution is to start from scratch and install a distro that uses Mate as its desktop and isn't cluttered with the items that aren't made for it. Another option is to just ignore the things that don't seem to work with Mate.


A .desktop icon for a bash script works, but

There's not much of a way to deal with such thing. Make another .desktop file for the program that has gray icon and store it in your ~/.local/share/applications.

Information on how to do so can be found here: Apply icons to bash scripts


Snap version of vlc does not work on Ubuntu 20.04

Béné solved my issue on my other question connected to this issue!

The solution, which ALMOST worked for me can be found HERE!

HOWEVER, the second command in the post above gave me an error message. I modified them a little bit, the following solution worked for me and remained working after a system restart.:

sudo find /usr/share/fonts -type f -exec sudo chmod 644 {} \;
sudo fc-cache -r -v


Control which network interface is used by default

You can temporarily disable the unwanted interface - ifconfig eth0 down. Otherwise, if you want an interface disabled by default you can add the same command to /etc/rc.local.  I suppose you could also set up xbindkeys to disable interfaces with keystroke as well.


Moving /var from separate partition to /

You should be able to move the contents from the /var partition to the / position on the fly.  There is no special lock on it.

sudo cp -pr /var /var2
sudo umount /var
sudo rm -R /var
sudo mv /var2 /var

Then remove the line that mounts /var from /etc/fstab.

sudo nano /etc/fstab

If you receive an error /var: target is busy, you need to find out which processes are preventing unmounting of the device and stop them.

Disclaimer: I would still recommend doing this on a live system or from grub rescue. It should be safer.


Monit - issue to run program that displays image

I'm just posting how I did to solve it in case someday someone needs a similar help...

In the end I tried a few steps that made my program work

Not sure if necessary, but I executed the command line (according to monit manual) to make monit run on the foreground:

/usr/bin/monit -Ic /etc/monit/monitrc

I changed my script to set a display and to execute with my user. See how it's now:

#!/bin/bash
export DISPLAY=:0.0
su -c "java -jar /home/thais/Desktop/MediaHandler_RC2.jar" thais


Create user ID `root` to force `gedit` to create user configuration file

Once again, with feeling. DO NOT USE GRAPHICAL APPLICATIONS AS ROOT!

Now, there are some exceptions to the above rule. For example, any part of the Ubuntu control panel that requests root is generally safe, but only because it only keeps the privileges for as long as it needs to, at which point it will immediately dump them back to normal mode. Similarly, they're also specially designed to use root effectively and in a way that won't break things. In short, everything gedit and most other applications do not do.

If you really need gedit to have its own configuration in the /root folder, launch it like so:

sudo -i gedit

However, this still won't work for a number of reasons. Your menubar being gone is more or less a side effect of how Ayatana's menu system works. In short, the system is trying to create menu objects for/owned by the root user, which causes things to decidedly break.

You can get around the lack of a menu by using sudo's -E flag, but that will still cause DBus/DConf/whatever to be annoyed at you. In this mode, the menu will be embedded into gedit's window directly, because we still can't get a link to DBus/Ayatana.

This echoes the sentiment of the Ubuntu developers and is not a bug. They are of the opinion that the GUI is effectively "easy mode", and root access is effectively not "easy mode." If you want root, go to the terminal and use it there. In fact, this is pretty much a valid form of resistance -- if you can't use nano to edit files, you shouldn't be poking around as the root user.

If you absolutely must use root under the GUI (which I highly advise you not do, even as its own user), create a file called /etc/lightdm/lightdm.conf and put this into that file:

[SeatDefaults]
greeter-show-manual-login=true

Restart the lightdm service by using sudo systemctl restart lightdm.service and you should be able to login as root. If you don't use lightdm, find and follow the instructions respective to that display manager.

You'll also need to re-enable the root account, which you can do by simply running the following command:

sudo passwd root

Be sure you choose a very strong password, as this will allow root logins to your system. Note that this is also against every recommendation out there because sudo exists and is much safer/less likely to let you accidentally break something.

On that note, when you actually do this, gedit will work as root (as you expect) in the root user session. However, the second you come back to your main session, it will still refuse to work (for the reasons listed above).

The root account should not be used to bypass the much-hated Permission denied error willy-nilly. Think of that message as the following:

  Hey, what you're doing might have severe side effects on your system. Think very carefully and double-check your command to make sure you're doing exactly what you're intending to do. If you're sure this is what you want to do, escalate to the lowest possible privilege level that can be used to do what you want.

Even so, see if there's a solution that doesn't involve escalating to a privileged account. It's much easier to delete and recreate a broken user than it is to recreate a broken system.


cannot execute binary file: Exec format error Ubuntu 18.04 x86-64 target

The command that you used

gcc -g -Wall -c test1.c -o test1

creates a binary object file, not an executable file. From man gcc:

   When you invoke GCC, it normally does preprocessing, compilation,
   assembly and linking.  The "overall options" allow you to stop this
   process at an intermediate stage.  For example, the -c option says not
   to run the linker.  Then the output consists of object files output by
   the assembler.

To create an executable program, you need to allow gcc to proceed to the link phase by removing the -c option:

gcc -g -Wall test1.c -o test1


How do I install a bazaar fork in 13.10?

Install the pre-requisites:

sudo apt-get install bzr build-essential

And install the dependencies:

sudo apt-get build-dep indicator-bluetooth

Branch the fork from Launchpad:

bzr branch lp:~robert-ancell/indicator-bluetooth/dont-hide-on-rfkill

Jump to the directory:

cd dont-hide-on-rfkill

Install:

Now you have two options:

Compile from source

Run:

./configure
make
sudo make install

Install from compiled .deb

If you would rather install from a .deb run:

dpkg-buildpackage

Then:

cd

and

sudo dpkg -i indicator-bluetooth_0.0.6daily13.02.19-0ubuntu1_amd64.deb


For anyone having trouble with this, I found a simple solution which works if you are sure that the USB stick is properly formatted to NTFS and is mounted.

Start by finding the name of the mounted disk by running sudo fdisk -l. Once you find it (it'll be something like /dev/sdc1), run the command based winusb command:

sudo winusb --install <iso path> <partition>

And with that, it should work.


Ubuntu freezes on startup after update (18.04.3 LTS)

After doing some research this morning, I came across an article that described similar issues with the same version. I had to edit the grub file using sudo gedit /etc/default/grub and add 'nomodeset' to the GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" line.
I had to do something similar while installing before, but I guess maybe something changed during the accidental update.
Anyway, that seems to be working for now. Hopefully this helps someone else.

Here is the page I drew from:
https://www.dell.com/support/article/us/en/04/sln306327/manual-nomodeset-kernel-boot-line-option-for-linux-booting?lang=en


The official java packages has been removed from the Ubuntu repositories. You can install open-jdk instead:

sudo apt-get install openjdk-7-jdk

If you need the real thing you need to install the oracle java package:

sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer


Can i boot a password for my Ubuntu while booting

You have to re-install and perform full disk encryption (LUKS). You will then be prompted to enter a password when you boot.


Ubuntu install from ISO always kicks back to "Ubuntu installer main menu"

As I wrote in the comments, I had the same problem. Turned out that the reason for this was a faulty network cable, after switching it out the installer went through.


A 100+ GB tar.gz file does not properly extract

Could the file be corrupted?

Yes. That site also provides a tool for you to check yourself. From the link I see 4 checksums where the 1st one is for your download.

md5sum train_val2018.tar.gz should produce b1c6952ce38f31868cc50ea72d066cc3
md5sum train2018.json.tar.gz should produce bfa29d89d629cbf04d826a720c0a68b0
md5sum val2018.json.tar.gz should produce f2ed8bfe3e9901cdefceb4e53cd3775d
md5sum test2018.tar.gz should produce 4b71d44d73e27475eefea68886c7d1b1
md5sum test2018.json.tar.gz should produce fc717a7f53ac72ed8b250221a08a4502

If you get a different result your download is corrupted.


How do I set up the permissions on an automounted USB drive in 11.04

NTFS and FAT do not store permissions, so they are faked, making it look like you ( the person logged into the console ) own and can access the files, but not other users.  If you add an entry to /etc/fstab, you can specify the umask option and set whatever permissions you want.


Ubuntu 14.04 LTS identifying Wireless/Lan but will not connect

According to TP-Link your card supports Linux with the Atheros9k (ath, ath_9k modules) driver. This should come default on an Ubuntu installation. I am using an Atheros card and it works flawlessly.

from a command line try:

lsmod|grep ath

and you should see something like this:

ath3k                  13318  0
bluetooth             395387  28 bnep,hidp,ath3k,btusb,rfcomm
ath9k                 164164  0
ath9k_common           13551  1 ath9k
ath9k_hw              453856  2 ath9k_common,ath9k
ath                    28698  3 ath9k_common,ath9k,ath9k_hw
mac80211              638933  1 ath9k
cfg80211              496328  3 ath,ath9k,mac80211

If not then the module is either not loading or the wrong one is for some reason.

The output you posted is from iwconfig, not from ifconfig. However the fact that your device shows up means that it is recognized and the driver is loading.

The fact that neither wired or wireless works makes me think something is up with your network manager, router/local network, o,r maybe BIOS settings (probably not). Try rebooting the router and ensuring that all the settings there are OK. Make sure DHCP is enabled and/or try connecting with a static IP. Also try with and without encryption on your router. Finally you can try enabling 2.4ghz and disabling 5ghz, and/or try vise-versa to see if that works.

Atheros is well supported in Linux and should work out of the box.

You can get more information with the following commands:

lspci -vv -s
dmesg
ifconfig
rfkill list all

You can disable hardware encryption and see if that helps:

echo "options ath9k nohwcrypt=1" | sudo tee /etc/modprobe.d/ath9k.conf options ath9k nohwcrypt=1

sudo modprobe -rfv ath9k

I have also found that on a fresh install DNS is wonky sometimes. As root, edit the file /etc/resolv.conf

sudo nano /etc/resolv.conf

and add the following lines.

nameserver 208.67.222.222
nameserver 208.67.220.220

Save the file and try again. More info here:

https://wiki.archlinux.org/index.php/resolv.conf


Probably not, looks more like an Intel drivers thing. 11.04 needed a PPA to have good drivers working, 11.10 already has those drivers without need to get them from a PPA. Probably that PPA was used when you upgraded from 10.10 to 11.04 before and the packages were updated.

It was very likely a driver thing and not the BIOS update.


even i have the same issue.
i have connected my DELL XPS L502X to Yamaha Receiver, the setup works perfectly in Windows but in Ubuntu 15.10 /Mint 17.3, i am not getting Audio from HDMI(laptop speaker works fine).

This problem persist from past 5 Years. :), i never heard sound from my 5.1 setup in linux.

i have installed latest proprietary nvidia driver.
still cannot see HDMI port in "Sound Settings".  aplay -l is same as above.

but NONE of the below fixes are working for me.
1) selecting HDMI configuration in pauvcontrol does not work.
2) installed alsa daily oem does not worked.
3) Cannot disable Intel Graphics card with Dell BIOS.
4) using nouveau  drivers also does not provide sound/hdmi output.
5) Hardware, cable, etc are fine, as windows os works fine with this setup.

Please let me know, solution for this 5 year old problem.
i am ok to change distribution ArchLinux, Fedora, etc if they have fixed this issue.

Regards
Sandeep


Error while loading shared libraries, but I've installed the libraries

I think Psychonauts is a 32bit application. You will need to install:

sudo apt-get install lib32stdc++6


How to sort the files in the download folder by date of download?

I believe Date Modified would pretty much be the same as the date downloaded. View > List > Click on Date Modified


It won't affect the already burnt cd/dvd, checksum creation is just a means to verify the contents. You can hit cancel if you like.


The transition between 11.04 to 11.10 was quite dramatic since it involved moving from GTK+2/gnome libraries to GTK+3/gnome libraries.  This is the support route that was well tested.

Similarly well tested is the similar 10.04LTS to 12.04 LTS upgrade.

Moving from 11.04 to 12.04 in one step is not supported and I urge you not to go down this route since you are more likely to break your desktop & installation.

Since you have downloaded 12.04 - I would go for a fresh install.

If you have any files & folders from your 11.04 install, back these up - you can reinstall these later.


Proper way to restart sshd and other daemons

The command should be:

sudo service ssh restart

or:

sudo systemctl restart ssh.service


You only removed the PPA containing the program for downloading. You need to remove the program itself:

sudo apt update
sudo apt install remove --purge indicator-netspeed

If that doesn't work you probably need to add back the PPA first (granted I'm not sure on this one):

add-apt-repository ppa:nilarimogard/webupd8
sudo apt update
sudo apt install remove --purge indicator-netspeed


Installation of Ubuntu 18.04 on iMac 21,5-inch late 2009

Hello I found the solution just if you hold CMD + v at the start of Macintosh you will be in the verbose mode 20 there you will be able to add the nomodeset instruction in the grub


Wifi stops working during upgrade attempt Ubutu 20.04

Same thing happened to me, with a Dell laptop. It's an updated kernel (~5.8.0.36) issue. try listing your network devices first:

sudo lshw -c network

If your wireless interface appears 'unclaimed', this is what fixed things:

sudo apt purge bcmwl-kernel-source
sudo apt-get install broadcom-sta-source
sudo apt-get install broadcom-sta-dkms
sudo apt-get install broadcom-sta-common

more on this link:  Ubuntu bcmwl package
Good luck :)


Before buying a laptop, make sure that you do some due diligence by checking if its hardware components are known to be supported by Linux: At Present Which is the best choice for a Ubuntu graphics card, AMD or nVidia?. Numerous hardware compatibility lists exist on the web (I'm not sure which is the most useful), including Phoronix.

If the device that you're looking into has an ARM-based processor, then you might want to look at ARM Processor support on the wiki.

Another avenue would be Ubuntu Touch. They even talk about Ubuntu for Android. For a list of compatible devices check Ubuntu Touch devices support on the wiki (they also have a mailing list) and these related questions:

What is Ubuntu Touch (Ubuntu for Phones)
What hardware does Ubuntu Touch support?
How do I go about porting Ubuntu Touch to different devices?


MATLAB Startup Error: no write permission

This can happen if the ~/.matlab directory is owned by root. Make yourself owner of the directory:

sudo chown -R $USER: ~/.matlab

This is useful if you have tried to launch MATLAB with sudo or straight from the install.

Reference: Matlab not starting properly on Unix/Linux


Making the xinput --set-button-map changes permanent

I put some wait time and retries into my script and lived with that for a few days, but this weekend I had some spare time to find the "correct" solution.

That is, add the button map into a config file for X.

#/usr/share/X11/xorg.conf.d/logitech-mx-revolution.conf

Section "InputClass"
    Identifier  "Logitech MX Revolution Mouse"
    Option  "ButtonMapping" "1 2 3 4 5 6 7 9 8 10 11 12 13 14 15 2 17 18 19 20 21 22 23 24"
EndSection

Hopefully this helps someone else one day.


What's the best driver for NVIDIA GeForce GT 230 M

sudo apt-get install nvidia-313-updates

is the latest stable nvidia driver


How can I switch a 32-bit installation to a 64-bit one?

Such an approach is very complicated, and is unlikely to ever result in all your packages being the amd64 version instead of the i386 version. Only packages that actually receive upgrades will likely be changed in architecture, and probably only if no other packages not being upgraded rely on their being of the i386 architecture. Since some packages will not receive any updates throughout the entire support cycle of your Ubuntu release, you will likely never have a fully amd64 system using such a technique. Furthermore, there is certainly no official support for such an approach.

You would be well-advised to instead replace your existing Ubuntu system with a new, 64-bit installation.

However, if you do wish to attempt this technique, you will have to manually download the .deb files for dpkg and apt. You can find them at the dpkg in Ubuntu and apt in Ubuntu pages on Launchpad--expand the latest version under "The Oneiric Ocelot" that is marked as release, security, and/or updates (but you probably don't want a version marked only proposed and/or backports, if there ever is one). Then download the .deb files marked amd64. Specifically, the files you'll want are: this one for dpkg (and the others listed, too, if you have those packages installed) and this and this and this and this and this for apt.

Before you do anything with these files, you should make sure to back up all important documents in your installed Ubuntu system and any other important files (e.g., music, ebooks, videos), because it is rather likely that attempting this technique will backfire badly and leave your Ubuntu system completely unusable.

You can install all these packages by putting them in a folder that contains nothing else (suppose the folder is called debs and is inside your Downloads directory), and then running this command:

sudo dpkg -Ri ~/Downloads/debs

Of course, once you've installed them, they won't actually run, because their executables are 64-bit and your 32-bit Ubuntu system is running a 32-bit kernel (which will only run 32-bit executables). In fact, they might not even finish installing, as they might have post-install scripts that invoke their unrunnable 64-bit executables.

There are various ways of attempting to install a 64-bit kernel onto a 32-bit system, but they are all extremely complicated, so instead I recommend that you boot from a 64-bit Oneiric live CD (which itself runs a 64-bit kernel), chroot into the installed Ubuntu system, and use the recently installed 64-bit apt and dpkg to install a 64-bit kernel.

Here are specific instructions for doing that...but please do not take this to mean that I'm saying it will work. I have not attempted this. (I have chrooted into installed Ubuntu systems from live CD's and performed package management and other operations, but I have not attempted the cross-architecture operations suggested here.)

In your installed Ubuntu system, open a Terminal window (Ctrl+Alt+T) and run mount | grep ' on / ' (by pasting it into the Terminal and pressing enter). You should see something like /dev/sda2 on / type ext4 (rw,errors=remount-ro,commit=0). The part you're interested is the device name before on (in this example, it's /dev/sda2). Remember that, or write it down.
Step 1 gave you the device name of the / partition. If you have a separate /boot partition, then you'll need to know the device name for that as well. So in that case, run mount | grep ' on /boot '. You'll see something like /dev/sda1 on /boot type ext2 (rw). Remember or write this down as well.
Boot from an Oneiric amd64 (i.e., 64-bit) live CD and select "Try Ubuntu" rather than "Install Ubuntu".
Go into a web browser and make sure that Internet connectivity is fully functional. If it isn't, set it up.
Open a Terminal window and run sudo mount /dev/sda2 /mnt (replace /dev/sda2 with the device name you got in step 1, if different).
If your installed system has a separate /boot partition, run sudo mount /dev/sda1 /mnt/boot (replace /dev/sda1 with the device name you got in step 2, if different).
Now, run these commands to chroot into your installed system:

sudo mount --bind /dev /mnt/dev
sudo chroot /mnt
mount -t proc none /proc
mount -t sysfs none /sys
mount -t devpts none /dev/pts

Run ping -c 4 launchpad.net to see if Internet connectivity works fully from within the chroot. You're hoping for something like this:

PING launchpad.net (91.189.89.223) 56(84) bytes of data.
64 bytes from launchpad-net.banana.canonical.com (91.189.89.223): icmp_req=1 ttl=41 time=141 ms
64 bytes from launchpad-net.banana.canonical.com (91.189.89.223): icmp_req=2 ttl=41 time=143 ms
64 bytes from launchpad-net.banana.canonical.com (91.189.89.223): icmp_req=3 ttl=41 time=142 ms
64 bytes from launchpad-net.banana.canonical.com (91.189.89.223): icmp_req=4 ttl=41 time=140 ms

--- launchpad.net ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3003ms

If, instead, you were unable to transmit or receive packets, then you'll have to set up Internet connectivity in the chroot. To do that, run these commands (to leave the chroot, copy the relevant configuration files from the live CD system into the chroot, and re-enter the chroot):

sudo cp /mnt/etc/resolv.conf /mnt/etc/resolv.conf.old
sudo cp /mnt/etc/hosts /mnt/etc/hosts.old
sudo cp /etc/resolv.conf /mnt/etc/resolv.conf
sudo cp /etc/hosts /mnt/etc/hosts

While generally you should stop this process if there is an error, don't worry if the first and/or second of those four commands fail, provided that the specific way in which it fails is by telling you that /mnt/etc/resolv.conf (or /mnt/etc/hosts) does not exist.

The chroot back in and try again:

sudo chroot /mnt
ping -c 4 launchpad.net

Run these commands to make your chrooted environment fully ready to use:

export HOME=/root
export LC_ALL=C

If you haven't installed the .deb files for the 64-bit versions of dpkg and apt, so do now. If you did install them but there were configuration errors, run dpkg --configure -a to fix them. (Hopefully that will work...it might be better to wait to attempt to install them until you're in the live CD environment, in case installing the 64-bit dpkg while booted into the installed system leaves dpkg in an unusable state.)
With the 64-bit versions of dpkg and apt installed, assuming that they will automatically install 64-bit packages, you can now remove all your 32-bit kernels and install a 64-bit kernel. To remove your 32-bit kernels, run dpkg -l | grep linux-. This lists installed packages that start with linux-. You're more specifically interested in packages that start like linux-generic, linux-image, linux-server, and/or linux-headers. Remove these files with apt-get purge ... where ... is replaced with a space-separated list of the packages you're removing.
Now reinstall the packages you removed. (Actually, for packages that contain version numbers in the package name, like for example linux-image-3.0.0-13-generic, you only need to install the latest versioned package names.) Do this by running apt-get install ... where ... is replaced with a space-separated list of the packages you're installing.
Update the boot loader configuration, unmount some devices, and leave the chroot:

update-grub
umount /proc || umount -lf /proc
umount /sys
umount /dev/pts
exit
sudo umount mnt/dev

If you ran sudo cp /mnt/etc/resolv.conf /mnt/etc/resolv.conf.old and it did not fail, then now run sudo cp /mnt/etc/resolv.conf.old /mnt/etc/resolv.conf.
If you ran sudo cp /mnt/etc/hosts /mnt/etc/hosts.old and it did not fail, then now run sudo cp /mnt/etc/hosts.old /mnt/etc/hosts.
If your installed system has a separate /boot partition, unmount that: sudo umount /mnt/boot
Unmount your installed system's / partition: sudo umount /mnt
Leave the Terminal window (run exit), then reboot (or shut down) the live CD system and boot into the installed system.
See if the system is usable and running a 64-bit kernel (uname -m should say the architecture is x86_64).

There might well be additional packages you need to install, such as ia32_libs and/or the 64-bit version of libc6, for this to work. For some of them, you might be informed you need them when attempting to install the 64-bit version of dpkg and/or apt. For others, you might not be informed.

(The above instructions for chrooting and operating in the chrooted environment are based in significant part on this related but different procedure and also on some Launchpad Answers posts of mine, especially #6 here and #6 here. And special thanks to Caesium for pointing out that the 64-bit dpkg and apt executables won't run on a system running a 32-bit kernel.)


First is, when you selected to add a new ext4 partition, have you set mount point as /. Other wise you will get error about root system.

Secondly, choose booloader location as your hard disk (probably sda) not your usb (sdb). This options is located in the same screen where partition are shown (just after something else)

If it fails again after installation,boot with live disk (Try ubuntu) & use boot-repair


Gnome-terminal and solarized theme Coloring

Not sure of the reason exactly, but in any of the scripts that install Solarized for gnome that I've seen it is mostly just shades of grey for the most used colours.

This site has some commands for updating the Gnome colour profile: XORCode website.

The commands are:

gconftool-2 --set "/apps/gnome-terminal/profiles/Default/use_theme_background" --type bool false
gconftool-2 --set "/apps/gnome-terminal/profiles/Default/use_theme_colors" --type bool false
gconftool-2 --set "/apps/gnome-terminal/profiles/Default/palette" --type string "#070736364242:#D3D301010202:#858599990000:#B5B589890000:#26268B8BD2D2:#D3D336368282:#2A2AA1A19898:#EEEEE8E8D5D5:#00002B2B3636:#CBCB4B4B1616:#58586E6E7575:#65657B7B8383:#838394949696:#6C6C7171C4C4:#9393A1A1A1A1:#FDFDF6F6E3E3"
gconftool-2 --set "/apps/gnome-terminal/profiles/Default/background_color" --type string "#00002B2B3636"
gconftool-2 --set "/apps/gnome-terminal/profiles/Default/foreground_color" --type string "#65657B7B8383"

I found that replacing the third line with one of my own making made the terminal look just right:

gconftool-2 --set "/apps/gnome-terminal/profiles/Default/palette" --type string "#070736364242:#D3D301010202:#858599990000:#B5B589890000:#26268B8BD2D2:#D3D336368282:#2A2AA1A19898:#EEEEE8E8D5D5:#00002B2B3636:#CBCB4B4B1616:#858599990000:#B5B589890000:#26268B8BD2D2:#6C6C7171C4C4:#2A2AA1A19898:#FDFDF6F6E3E3"

The shell script at the following site can show what is different in the original scheme and the one I found to work: ColourTable script on GitHub.


Upgrade from ubuntu 16.04 to 18.04 aborted without showing any error message

When i tried to do: sudo do-release-upgrade i also have same error. It seems to be an error due to the command. I suggest you to install 18.04 from bootable usb drive.


Where to locate a tgz file and contents of it?

Firstly a .tgz file is not a program file.  It is an gz compressed tar archive file, and as such is not runnable.  Usually, this will be a source package and will need to be built.

It appears you have already expanded it into a directory.  If not the command tar xzf processing-2.0.1-linux64.tgz' will expand it.  I would copy or move it to/opt` and expand it there

From the contents it appears to be Java based program.  And will fail if you don't have Java installed.

Open a terminal window and cd to directory where you have expanded the archive.  Try running processing and processing-java.  Remember which one starts the program as you want.

To run the program from the classpath (assumes expanded to /opt/processing-2.0.1) create the following file in a different directory. (I'll use the name processing ).

#!/usr/bin/bash
cd /opt/processing-2.0.1
./processing

Then run the following command to add make it executable it to /usr/local/bin.

sudo mv processing /usr/local/bin
sudo chmod +x /usr/local/bin/processing

You can also edit the menu to add a new item, or create a desktop icon.   In either case you would use the full path to the program.

To understand where linux puts its file read the output of the command man hier.


Uninstalling a package completely including all log files

In short: "You can't".

There is no general way to remove all files a package produces - and for a good reason. If you install a web server and later remove it, you may want to keep the logs for analysis. If you install some office software and later replace it with a better one, you definitely don't want to get rid of all the documents you authored.

Short - not very exact - description of your apt command's elements:

apt remove PACKAGE – deinstalls PACKAGE's binaries
apt purge PACKAGE – removes the above plus config files that came with PACKAGE
apt autoremove – removes any packages that were once needed but are not any more - like old kernels or depencencies of uninstalled software


According to this link:

  Shell config files such as ~/.bashrc, ~/.bash_profile, and
  ~/.bash_login are often  suggested for setting environment variables.
  While this may work on Bash shells for programs started from the
  shell, variables set in those files are not available by default to
  programs started from the graphical environment in a desktop session.

If you are running eclipse from your desktop session, you should modify your ~/.profile.

  In this file you can also place environment variable assignments,
  since it gets executed automatically by the DisplayManager during the
  start-up process desktop session as well as by the login shell when
  one logs in from the textual console.


They are located in folders in /usr/share/icons, named according to the theme, irrespective of the desktop environment:

$ ls -d /usr/share/icons/*/cursors
/usr/share/icons/Adwaita/cursors
/usr/share/icons/DMZ-Black/cursors
/usr/share/icons/DMZ-White/cursors
/usr/share/icons/handhelds/cursors
/usr/share/icons/redglass/cursors
/usr/share/icons/whiteglass/cursors


I noticed on another forum that a user had issues with "GFX Hardware Acceleration" in chrome causing wierd colors.  In his case, turning it off fixed the issue, but in my case, turning settings => advanced => Use Hardware Acceleration when available to ON fixed the issue.


It depends. If you have 2GBs of RAM or less, you should probably stick with 32-bits, as 64-bit applications use more memory and some apps don't have 64-bit versions (you may run most 32-bit apps by installing ia32-libs, however)

If you have 4GBs or more of RAM, however, you should definitely move to 64-bit. The 32-bit kernel can't address more than 3GBs of RAM on most computers, and although you can install the PAE kernel which can address +3GBs of RAM, the future is obviously 64-bit :)


Live CD crashes when removing it after installation

Everything sounds normal to me.  While the live Linux system is shutting down, it reads off the CD for the shutdown programs, and when that's done, it prompts you to remove the disk for restart.

Since it's a read-only system on the CD, there's no danger of shutdown while in the middle of doing something, which is probably stuff like seeing if it needs to write logfiles (it doesn't), shut down servers gracefully (who cares, they don't save their state), etc.

So, don't worry, be happy. :)  Enjoy your new system.

PS.  Don't be afraid of problems; consider them to be challenges.  You'll learn a lot more that way, like it or not. :)


Try booting into Ubuntu and install a program called boot-repair.
Install it by opening the terminal then typing this in:

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

To open it by either typing in the terminal:boot-repair,or from the launcher.
Then click on recommended repair and follow the instruction.
Hope this helped!


Minecraft flickers sometimes and colors get buggy on an Intel HD Graphics 3000

I run minecraft on archlinux with the same IGP and have the same graphical glitches.

Since arch has a newer kernel, I think it is safe to say, a newer kernel will not help. Switching to Oracle jre does not help either. I suspect a bug in the intel graphics driver.


Ubuntu 11.10 very slow compared to Windows

To get Ubuntu 2D to work, you should try running nvidia-settings to configure the X server more precisely.  Under "X Server Display Configuration", set the desired resolution instead of leaving it on auto.  Then click "Save to X configuration file" (it should be /etc/X11/xorg.conf) and reboot. Then try logging into Ubuntu 2D.

Another possible explanation is that you are feeling the performance penalty from running off a Wubi-installed partition.  See What performance differences are there when installing with Wubi? for example.  To get better performance, install ubuntu directly onto a fresh partition.


Installing Oracle Java SE SDK 8u31 via apt-get

You'll have to install the JDK manually if you want to pin the version.  This is a pretty good guide for doing just that.

https://www.digitalocean.com/community/tutorials/how-to-manually-install-oracle-java-on-a-debian-or-ubuntu-vps

Keep in mind no updates, so you'll have to upgrade the java version yourself for security updates and such.


IP address problem after messing with /etc/network/interfaces

Add these lines to /etc/network/interfaces:

auto lo
iface lo inet loopback


How to eliminate/deactivate Ubuntu One account?

From the FAQ

How do I downgrade or cancel my Ubuntu One account?

Do you want to either downgrade or cancel you Ubuntu One plan? Both the downgrade and cancel options are available in the Account area. Click on "View/Edit" and you will find links to downgrade or cancel your subscription.


wlan0 not showing up in ifconfig/iwconfig

Are you running Kali, or any other Linux distribution inside of Virtualbox, VMWare?

If you're running Linux in a virtual container you need an external wireless card. Also your on an HP notebook that was built to run Windows 10, you would need to live boot from a USB or CD, and try configuring your network adapter with ifconfig then, also your wireless network adapter might have a different name other than wlan0 (Kali configures this).

INFO: The network card ("wifi card") that's in your PC may not even support packet injection, or monitor mode.

Also make sure that if you put wlan0 into monitor mode you run these commands:

sudo ifconfig wlan0 down
sudo iwconfig wlan0 mode monitor
sudo ifconfig wlan0 up

Verify that you put wlan0 up before you try running reaver

You may have not properly brought up your wireless network adapter wlan0 You should restart your computer, run the above commands to configure your network adapter, and rerun reaver. If that didn't work continue below:

INFO: If there is a hardware switch that controls your network adapter switch it on before executing the following command

The command is usually:

sudo ifconfig wlan0 up ; sudo rfkill unblock all ; sudo rfkill unblock wifi

If that is not successful, try restarting your PC (at bootup if you have a wireless switch on your PC switch it on now), and repeating the above command. You may also want to try:

sudo ifconfig wlan0 ; sudo ifconfig wlan0 down ; sudo ifconfig wlan0 up

If it still is not working, the order of precedence with the above commands matters. If you didn't bring your network card wlan0 back up before running reaver, restart your PC and try again. You also might need to look into rfkill (radio frequency kill), and unblock your network adapter by sudo rfkill unblock all ; sudo rfkill unblock wifi (run command a few times, and restart PC)

If all else fails, don't give up the world of IT and Cyber security is amazing. Learn the basics, look up how to install Ubuntu from USB, or if you want to skip learning and use tools, `how to download Kali Linux on USB* after that look up hp boot from USB


Set Wine application icons in Cinnamon or Gnome3

Create your icon as a png file
copy an application file from

/usr/share/applications
open it in a text editor
customize  it.

You could just copy my template blow, also:

[Desktop Entry]
Name=Your App
Comment=Comments shown as tooltip
Exec= wine /path/to/executable
Icon=/path/to/icon.png
StartupNotify=true
Terminal=false
Type=Application
MimeType=text/plain;
Categories=Wine;Applications;

Propose:

You're icon should be placed on: /usr/share/icons/ownicons

create this directory with

sudo mkdir /usr/share/myicons/
sudo chown yourusername:yourusername /usr/share/myicons/

Look at Gnome Desktop entry specification  for more information.


How do have icons in a listview on Desktop

Alright, answer is finally here. You have to change line or two in nautilus source and than recompile the source...

Text besides icons on Ubuntu Desktop

Text besides icons on Ubuntu Desktop

1-$ mkdir /home/nautilus-source & cd /home/nautilus-source

2-$ apt-get source nautilus #in my case it downloaded source for nautilus-3.4.2

3-$ sudo apt-get install fakeroot build-essential dpkg-dev

4-$ sudo apt-get build-dep nautilus

5-$ cd /home/nautilus-source/nautilus-3.4.2/

6-$ vim src/nautilus-desktop-icon-view.c

7-$ /NAUTILUS_TYPE_DESKTOP_ICON_VIEW

Change from:

g_object_new (NAUTILUS_TYPE_DESKTOP_ICON_VIEW, "window-slot", slot, "supports-zooming", FALSE, "supports-auto-layout", FALSE, "supports-scaling", TRUE,"supports-keep-aligned", TRUE, "supports-labels-beside-icons", FALSE, NULL);

to:

g_object_new (NAUTILUS_TYPE_DESKTOP_ICON_VIEW, "window-slot", slot, "supports-zooming", TRUE, "supports-auto-layout", FALSE, "supports-scaling", TRUE,"supports-keep-aligned", TRUE, "supports-labels-beside-icons", TRUE, NULL);

Line numbers in in src/nautilus-desktop-icon-view.c > 785-792

8-$ dpkg-buildpackage -rfakeroot -us -uc -nc -b

9-$ sudo dpkg -i ../nautilus_3.4.2-0ubuntu4_i386.deb

10-$ killall nautilus

11- Open your home folder from launcher -

12- Edit > Preferences > Views > Check Text Besides Icons

ps. also now Ctrl+Scroll - will zoom in zoom out desktop icons

ps2. you can also change location of launcher # edit src/nautilus-places-sidebar.c


You can use id3ren which is a ID3Tag file renamer.  The application is in the repositories, so it can be easily installed.  This should work as well with .m4a files.

sudo apt-get install id3ren

To use it, go to the folder where your music is, preferably into an actual folder where you have music that you want renamed.  Then you can rename using a template that is offered by id3ren.  Template options are as follows:

   -template=TEMPLATE
          Use TEMPLATE as the basis for renaming files.  The default tem‐
          plate used is '[%a]-[%s].mp3'.  Identifiers that can be used in
          the template are:
            %a  - Artist name
            %c  - Comment
            %s  - Song name
            %t  - Album title
            %n  - Track Number
            %y  - Year
            %g  - Genre

Using a directory from my system here that I know is named incorrectly we can see the files before running id3ren on the files:

$ ls -l *.mp3
-rwxrwxrwx 1 root root 3851479 Jul 10 20:31 01 - Track 1.mp3
-rwxrwxrwx 1 root root 3726796 Jul 10 20:31 02 - Track 2.mp3
-rwxrwxrwx 1 root root 5001982 Jul 10 20:31 03 - Track 3.mp3
-rwxrwxrwx 1 root root 3111721 Jul 10 20:32 04 - Track 4.mp3
-rwxrwxrwx 1 root root 4680892 Jul 10 20:32 05 - Track 5.mp3
-rwxrwxrwx 1 root root 4504918 Jul 10 20:32 06 - Track 6.mp3
-rwxrwxrwx 1 root root 5135839 Jul 10 20:32 07 - Track 7.mp3
-rwxrwxrwx 1 root root 5397715 Jul 10 20:32 08 - Track 8.mp3
-rwxrwxrwx 1 root root 3229732 Jul 10 20:32 09 - Track 9.mp3
-rwxrwxrwx 1 root root 3760156 Jul 10 20:32 10 - Track 10.mp3

Now, running id3ren on the folder with the template options for Track Number - Song Name.mp3 using all mp3 files (*.mp3) in that folder:

$ id3ren -template='%n - %s.mp3' *.mp3
01 - Track 1.mp3                       => 01 - Your Song.mp3
02 - Track 2.mp3                       => 02 - Daniel.mp3
03 - Track 3.mp3                       => 03 - Honky Cat.mp3
04 - Track 4.mp3                       => 04 - Goodbye Yellow Brick Road.mp3
05 - Track 5.mp3                       => 05 - Saturday Nights Alright.mp3
06 - Track 6.mp3                       => 06 - Rocket Man.mp3
07 - Track 7.mp3                       => 07 - Benny and the Jets.mp3
08 - Track 8.mp3                       => 08 - Dont Let the Sun Go Down on Me.mp3
09 - Track 9.mp3                       => 09 - Border Song.mp3
10 - Track 10.mp3                      => 10 - Crocodile Rock.mp3
Processed: 10  Failed: 0  Total: 10

As we can see now, the folder has had the files renamed to match the ID3Tag contained in the .mp3 file itself:

$ ls -l *.mp3
-rwxrwxrwx 1 root root 3851479 Oct 24 15:39 01 - Your Song.mp3
-rwxrwxrwx 1 root root 3726796 Oct 24 15:39 02 - Daniel.mp3
-rwxrwxrwx 1 root root 5001982 Oct 24 15:39 03 - Honky Cat.mp3
-rwxrwxrwx 1 root root 3111721 Oct 24 15:39 04 - Goodbye Yellow Brick Road.mp3
-rwxrwxrwx 1 root root 4680892 Oct 24 15:39 05 - Saturday Nights Alright.mp3
-rwxrwxrwx 1 root root 4504918 Oct 24 15:39 06 - Rocket Man.mp3
-rwxrwxrwx 1 root root 5135839 Oct 24 15:39 07 - Benny and the Jets.mp3
-rwxrwxrwx 1 root root 5397715 Oct 24 15:39 08 - Dont Let the Sun Go Down on Me.mp3
-rwxrwxrwx 1 root root 3229732 Oct 24 15:39 09 - Border Song.mp3
-rwxrwxrwx 1 root root 3760156 Oct 24 15:39 10 - Crocodile Rock.mp3

EDIT: Also ran with Artist name for batch rename.  This works as long as the Artist tag is correct in the ID3 tag:

This with [artist] - [track] - [name]

$ id3ren -template='%a - %n - %s.mp3' *.mp3
01 - Your Song.mp3                     => Elton John - 01 - Your Song.mp3
02 - Daniel.mp3                        => Elton John - 02 - Daniel.mp3
03 - Honky Cat.mp3                     => Elton John - 03 - Honky Cat.mp3
04 - Goodbye Yellow Brick Road.mp3     => Elton John - 04 - Goodbye Yellow Brick Road.mp3
05 - Saturday Nights Alright.mp3       => Elton John - 05 - Saturday Nights Alright.mp3
06 - Rocket Man.mp3                    => Elton John - 06 - Rocket Man.mp3
07 - Benny and the Jets.mp3            => Elton John - 07 - Benny and the Jets.mp3
08 - Dont Let the Sun Go Down on Me.mp3 => Elton John - 08 - Dont Let the Sun Go Down on Me.mp3
09 - Border Song.mp3                   => Elton John - 09 - Border Song.mp3
10 - Crocodile Rock.mp3                => Elton John - 10 - Crocodile Rock.mp3
Processed: 10  Failed: 0  Total: 10

This with [track] - [artist] - [name]

$ id3ren -template='%n - %a - %s.mp3' *.mp3
Elton John - 01 - Your Song.mp3        => 01 - Elton John - Your Song.mp3
Elton John - 02 - Daniel.mp3           => 02 - Elton John - Daniel.mp3
Elton John - 03 - Honky Cat.mp3        => 03 - Elton John - Honky Cat.mp3
Elton John - 04 - Goodbye Yellow Brick Road.mp3 => 04 - Elton John - Goodbye Yellow Brick Road.mp3
Elton John - 05 - Saturday Nights Alright.mp3 => 05 - Elton John - Saturday Nights Alright.mp3
Elton John - 06 - Rocket Man.mp3       => 06 - Elton John - Rocket Man.mp3
Elton John - 07 - Benny and the Jets.mp3 => 07 - Elton John - Benny and the Jets.mp3
Elton John - 08 - Dont Let the Sun Go Down on Me.mp3 => 08 - Elton John - Dont Let the Sun Go Down on Me.mp3
Elton John - 09 - Border Song.mp3      => 09 - Elton John - Border Song.mp3
Elton John - 10 - Crocodile Rock.mp3   => 10 - Elton John - Crocodile Rock.mp3
Processed: 10  Failed: 0  Total: 10

Hope this helps!


I also use a dark theme and had the same problem. This is how you fix it:

If the Server connection is open, close it (right click ->
Disconnect server)
Right click on the Server connection and choose Properties…
In the Properties tab click the button in the the second to last
item, named Colour
Select a new colour, say #3C3B37
Restart pgAdmin


The ls command tries to print the user name and group name when doing the long listing.  However, the user and group are stored as the UID and GID in the file's metadata.  If the UID cannot be looked up or the GID cannot be looked up, the ls -l command will just print out the UID and/or GID.  That is what you are seeing.  The file, "shared.md" is owned by UID 1000 and GID 1000, but there is no user on the system that has UID 1000, and no group on the system that has GID 1000.  That is why ls -l prints out 1000 for the user and group.

For the file, "locknoblank.sh" the owner is greedy, but the group is GID 1000, for the same reason as above.


Does gnome 3.4 perform better when using 64-bit Ubuntu than when using  32-bit Ubuntu?

If you are having problems with video drivers on an XPS17, your main problem is that you have an optirun video card setup, as do I, where you have an onboard intel video card that sucks, and the optirun nvidia card, that you cannot enable without a plugin called bumblebee.  Your problem isn't gnome, your problem is that you cannot simply disable the intel card and use an nvidia driver; X doesn't like using two different drivers in one session, and you can't simply disable the intel one or you won't be able to boot.   Unless you can rig up two different X sessions, one with shitty intel card to boot up, and the second with nvidia drivers setup, the only way to run 3D is sudo apt-get install bumblebee, then call optirun app-to-run-with-3d.

I would recommend setting up one user account to boot into the computer with, and a second account you can load to a different session.  So, you boot into Alt+Ctrl+F7 using intel+unity/whatever, and load up a new X session for a different user on Alt+Ctrl+F8 with nvidia+gnome 3.4.

If you choose the route of running multiple xservers, make sure to read up on xinit: http://manpages.ubuntu.com/manpages/lucid/man1/xinit.1.html


There is no password, something must of gone wrong while burning it to a disk.

Re download  Kubuntu and burn it again.

Or you might want to try the live USB instead of a DVD. Live USB Installation Guide is found Here


LibreOffice Writer: how to set a custom background color for a table cell

The current version of LibreOffice is 6.3.1.2 so you are in fact using an older version of LibreOffice with version 6.0.7.1. Later versions have much better colour management and will resolve your issue.

You need to install the fresh LibreOffice PPA by opening a terminal and running the command:

sudo add-apt-repository ppa:libreoffice/ppa

Next, update your system sudo apt update

Then upgrade sudo apt install libreoffice

That should allow LibreOffice to be upgraded to the current version.

Now, turning to the selection of colour palate for the Table background I believe the arrangements have changed under more recent versions.

By selecting the Table in Writer and right clicking it and selecting Table Properties selecting the Background Tab then Colour you are presented with the following:

allowing you to set the cell background colour. There is a separate drop down menu for selecting whether to change Cell Row or Table.


Audio Recorder not saving files on Ubuntu 18.04

I solved the problem by uninstalling and reinstalling through the terminal, for some reason I wasn't able to select the audio source through refresh.


Acer laptop with Intel core i5-6200U Intel HD Graphics 520, can't resume from suspend

Disabling the Intel proprietary CPU driver solved the problem...

go to System Settings > Software & Updates > Additional Drivers
click Do not use the device >
click  apply changes
restart the system


maybe you solution is ifdown (name of you network interface) and ifup (name of interface) if you jus try this, so


Select Anthy, then Preferences-Anthy. In the Setup window go to the Key Binding tab.

Normally the shortcut listed for "hiragana-mode", katakana-mode, etc. is [ ] for no shortcut.

Doubleclick on an item and you can add a shortcut key description. I used Ctrl+H and Ctrl+K (of course use whichever you want). Then you can use those keys directly to select the kana mode, rather than cycling through the options.


xeyes in each of my Ubuntu 14.04 install is missing the title bar

Is a right-click on the launcher not an option? After starting xeyes it also brings up that icon on the launcher. You can right-click on it and choose Quit.


Firefox version check shows wrong version

If you are running simply firefox from the command line, then you are actually running the 'default' Firefox installation, likely installed and updated by your package manager. You can verify with which firefox. You'll probably get /usr/bin/firefox which is a link for /usr/lib/firefox/firefox.sh. If you have indeed another installation of Firefox, you need to call the executable for this other version. You can do this by doing something similar to ./relative/path/to/this/other/firefox.sh, or simply going to the folder of this executable and ./firefox.

Alternatively, you can add this other version to your $PATH, but you'll likely want to name it differently than simply Firefox to avoid conflicts.


Finding and installing a good bitmap font for xterm

You have 80+ standard packages with "xfont" in their name. Some of these are bundles for specific purposes like "web", "biz", etc. so hundreds of x fonts available to install.

Setting up default fonts in an xterm is well covered in How to Change the Default font size of XTerm

One additional method of selection not covered in the above link using an escape sequence to change the font in an xterm.
First, ensure that "Allow Font Ops" is checked in the ctrl-R mouse button menu (near the bottom).
The echo command:

echo -n -e "\033]50;8x16\007"

sets the font to 8x16.  Put the command into a script  you can run, passing the font as an argument:

#/bin/bash
# mychfnt script
MYFNT=${1-8x16}
echo -n -e "\033]50;$MYFNT\007"

e.g. put an executable file named chfnt with the above into your $HOME/bin directory, and whenever you want to change fonts, use

xlsfonts

to list the available fonts, and then select one and

chfnt "-sony-fixed-medium-r-normal--24-230-75-75-c-120-iso8859-1"


The PDF file should be opening in the Evince document viewer. You need to hover the mouse over the top panel to reveal the menu (AKA global menu).

Under "File" you will find the "Print..." option. Alternatively, press Ctrl+P to access the print dialogue.


First off, make sure you backup everything you've got on the Windows partitions. I would then suggest trying gparted. It might let you remove the existing Windows partitions and expand the Ubuntu partitions without losing any data (depending on how the partitions are laid out).


Snap Package installation in Chroot environment

Here's the bug report from 2016 (unresolved as of September 2020):

Bug Description
Cloud images are built using livecd-rootfs and then modified for
specific clouds by using chroot to modify the contents of the image
(without ever booting it).
In order to use snaps to deliver functionality required by clouds on
first boot (generally speaking, the agents that they provide), we need
some way of installing snaps within these chroots.
Currently, running snap install ... within a chroot fails because
snapd is (of course) not running.


For futur reference, I've resolved this with stopping dpkg with :

sudo rm -rf /var/lib/dpkg/lock

then :

apt-get update

I got a message like dpkg was stopped, do you want to resume ?, I typed yes and all worked fine.


How to encrypt full disk after installing?

The process of encryption is destructive to your data as you "should" first write random data to the disk, which will over write your data.

IMO the best way to use LUKS (full encryption) is to back up your data re-install.

In terms of the initramfs, it is a set of commands that run in busybox (a minimal shell) to initialize your hardware, peform LVM or manage LUKS, and load the kernel. These days distros build an initramfs for you so you do not need to manually edit the initramfs at all.

If you want to look at the internals, see http://blog.bodhizazen.com/linux/initramfs/

If you want to look at how Ubuntu generates an initramfs, see https://wiki.ubuntu.com/Initramfs

If you have a specific question about a specific step ask a more detailed question.

There are several tools to encrypt data post install, everything from an encrytped home (ecryptfs) to gpg.

See https://help.ubuntu.com/community/EncryptedHome

and for post install see http://www.howtogeek.com/116032/how-to-encrypt-your-home-folder-after-installing-ubuntu/

and http://blog.dustinkirkland.com/2009/06/migrating-to-encrypted-home-directory.html


Ubuntu One for other Linux Distributions?

Yes, there is no lock-in. The Ubuntu One client is written in Python, so it should run well on any GNU/Linux distro. I don't know if it's been packaged for other distros though, but all dependencies should be easily resolvable.


Webcam mounted on /dev/video0 and usable by VLC but nothing else detects it

Some programs like Skype use the older Framework v4l instead of the newer v4l2.
This is not supported by every module out of the box.

env LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libv4l/v4l1compat.so /usr/bin/skype

This way, the older framework is forced to use for skype. I'm not good in explaining in english. Sorry.


Installing Intel graphics driver in Ubuntu 16.04

Update 30 Aug, 2016: Latest drivers from Intel are now available

Default installation Ubuntu 16.04 should work somehow fine. Intel drivers are included in the default installation of Ubuntu 16.04 with Linux 4.2 kernel, and you the hardware acceleration works in VLC if you choose "XCB" output. But this is not the latest drivers from Intel. Here we read:

u16.04 already contains the latest intel driver that has passed full QA
There is no point in installing the u15.10 updates on u16.04 - even if you succeeded it would be a downgrade

Recent update:

Recently, Intel released Intel Graphics Update Tool 2.0.2 which supports Ubuntu 16.04. Download it from here:

https://01.org/linuxgraphics/downloads/intel-graphics-update-tool-linux-os-v2.0.2


You need to install libusb-1.0-0-dev

To install the package

sudo apt-get install libusb-1.0-0-dev

To find out the dependency of the package use the command apt-cache search libusb-1.0

Here is the output of the command

$ apt-cache search libusb-1.0
libusb-1.0-0 - userspace USB programming library
libusb-1.0-0-dev - userspace USB programming library development files
libusb-ocaml - OCaml bindings to libusb-1.0 (runtime)
libusb-ocaml-dev - OCaml bindings to libusb-1.0

Hope this helps


Application icon not appearing next to application name in top bar while using Arc GNOME shell theme

Open the gnome-shell.css file in /usr/share/themes/Arc-Dark/gnome-shell/, and edit the .app-menu-icon class. Change the width and height from 0 to 100%. Also adjust the padding if needed.

It should now work perfectly.

Source: Comment by OP (should have been posted as an answer)


After I installed wicd my wireless network interface disappeared. How do I fix it?

In the end I just reinstalled ubuntu and it works now. I had gone through all the ubuntu wireless troubleshooting guides out there. Nothing worked.


How to ssh to the controller in Juju 2.0?

Juju 2.0 supports multiple models in a single controller. When you bootstrap, Juju creates two models: "controller", and "default". When bootstrap completes, the client will switch to the default model. The controller machines are all within the controller model.

So, to SSH to a controller machine, you need to operate within the controller model. You can switch to it first using "juju switch controller", or you can use "-m controller" to specify the model without switching to it for future commands. e.g.

juju ssh -m controller 0