Bonding / Ubuntu 20.04 I recently installed Ubuntu 20.04 on a VM with 2 ethernet ports. I'm trying to bond those 2 ethernet ports, but I can't find the right way. For example, someone says without netplan, others with netplan, bond with bridge, etc.
I'm new in this, is there a way to do a simple bonding?
Update: I reached this point:
network:
version: 2
renderer: networkd
ethernets:
    eth1:
        dhcp4: false

    eth2:
        dhcp4: false

bonds:
    bond0:
        dhcp4: false
        interfaces:
        - eth1
        - eth2
        parameters:
            mode: balance-rr
            mii-monitor-interval: 100
bridges:
    br0:
        dhcp4: true
        interfaces:
        - bond0

And I can't get the IP  for br0. The same happens if I only use bond0 without br0.
Thanks
Update II

As on your screenshot, you have three ethernets: eth0, eth1, eth2 . eth0 has an IP, so you have some config for this (ie by ifupdown with /etc/network/interfaces config).
I hope eth1, eth2 is not connected to the same switch and network, to get this works it needs more settings.
You should check, that any other tools like ifupdown not used for bringing up eth1, eth2 and bond0, br0.
Do not use this tools with netplan.
Disable eth1, eth2 ifaces – remove lines with auto for eth1, eth2, add just one line: iface eth1 inet manual for each.
Or rename or delete file /etc/network/interfaces.
If you rename or delete /etc/network/interfaces, you should add config eth0 to netplan config.
For example, in my config I have em1, em2 ethernets. bond0 its together, and br0 at the top of bond0. br0 gets IP via DHCP. br0 is needed to get access to network from VMs on this server.
My config:
network:
  version: 2
  renderer: networkd
  ethernets:
    em1:
      dhcp4: no
      dhcp6: no
    em2:
      dhcp4: no
      dhcp6: no
  bonds:
    bond0:
      dhcp4: no
      dhcp6: no
      interfaces:
        - em1
        - em2
      macaddress: "xx:xx:xx:xx:2b:62"
      parameters:
        mode: 802.3ad
        lacp-rate: fast
        mii-monitor-interval: 100
        transmit-hash-policy: layer2+3
  bridges:
    br0:
      dhcp4: yes
      dhcp6: yes
      macaddress: "xx:xx:xx:xx:2b:62"
      interfaces:
        - bond0

You can remove part with bridges and set dhcp4: yes, dhcp6: yes to bond0. This should also works, and bond0 should get IP from DHCP.
Also I made a working config for ifupdown2 (maybe because old ifupdown can't handle ifaces dependency, but ifupdown2 can).

Based on yours and my own config, I would imagine something like this could work:
network:
    version: 2
    renderer: networkd
    ethernets:
        eth1:
            dhcp4: false
        eth2:
            dhcp4: false
    bonds:
        bond0:
            dhcp4: false
            interfaces:
              - eth1
              - eth2
            parameters:
                mode: balance-rr
                mii-monitor-interval: 100
    bridges:
        br0:
            dhcp4: true
            gateway4: your.gate.way.addr
            interfaces:
              - bond0


Plex won't enter my home directory or other partitions I just installed the Plex media server from the Ubuntu Software Center, and opened the web interface. I wanted to start by adding a collection. When it gave me a file browser, I wanted to go to /home/robin/Videos. /home is as far as I got. It showed robin, with an arrow in front of it, but when I tried to expand the directory tree it was empty. The same happened when trying to access /media/Data.
For me it's quite useless like this, as all of my media files are inside those 2 directories.

Help would be much appreciated.

My first guess seemed to be a correct one; It is, as always, a permissions problem.
How do I give plex access to my home folder without also giving other users access to it? My home folder is encrypted by the way, so that'll probably complicate things a little.

robin@RobinJ:~$ sudo -u plex bash
[sudo] password for robin:
bash: /home/robin/.bashrc: Permission denied
plex@RobinJ:~$ ls -al
ls: cannot open directory .: Permission denied
plex@RobinJ:~$ cd /home
plex@RobinJ:/home$ cd robin
bash: cd: robin: Permission denied
plex@RobinJ:/home$ ls -al robin
ls: cannot open directory robin: Permission denied

Plex is run under plex username, so you may encounter the following permission issues:

Ubuntu restricts access to /media/$USER through ACL (that's the "+" when you ls -l /media). Solution below.
Your drives may not be mounted to allow plex user to read it. Check it with ls -l on the drive or folder that cause issue, to see the group owner, group permissions and user permissions. Solution below.
Your folder may not allow plex user or group to read it. Use sudo chmod -R u+r FOLDER to allow all users. Or add flex user to the folder group (see below) and use sudo chmod -R g+r FOLDER.

Fix permissions to allow Plex to access /media/$USER

Check which group you and plex belong to:

groups
groups plex

Now, add plex user to your user group, and allow this group to access /media/$USER:

MYGROUP="$USER"
sudo usermod -a -G $MYGROUP plex
sudo chown $USER:$MYGROUP /media/$USER
sudo chmod 750 /media/$USER
sudo setfacl -m g:$MYGROUP:rwx /media/$USER
sudo service plexmediaserver restart

Fix permissions of NTFS partitions

NTFS partitions must be mounted with appropriate read rights in /etc/fstab:

Check your user and group id (1000 and 1000 in example):

id

Edit /etc/fstab to mount the drive with read permissions for your user group and for all users (cf. umask, which is 777 less the desired "chmod" number):

UUID="XXXXXX" /media/USERNAME/MOUNTPOINT ntfs rw,nosuid,nodev,allow_other,default_permissions,uid=1000,gid=1000,umask=002 0 0

Fix permissions of mdadm RAID disks

If you're using mdadm, this may be needed in /etc/mdadm/mdadm.conf:

CREATE mode=0775

Install Plex.
Open terminal.
Install samba - sudo apt-get install samba.
From ~ do cd ... This will take you to /home.
Create new plex folder in /home: sudo mkdir plex
Go to new folder: cd plex
Create new folder in plex/: sudo mkdir music
Set permissions: sudo chmod 777 * -R
Set owner if required sudo chown plex:plex -R

Do the same for other media if required, don't forget if you add new media you may need to set permissions/owner on that too.


Ubuntu Server and OpenVPN Client, SSH ACCES! i have instance on google cloud, it's running ubuntu server 18.04 LTS, i setup openvpn, and as soon as i connect it drops me out of SSH. i'am running nordvpn, i know port forwarding is not allowed, but is there a way to make it work to my origin IP adress to ssh?

MY PUBLIC IP IS: 35.246.229.999
MY eth0 is: 10.156.0.39
and loopback: 127.0.0.1

and VPN ip let's guess 89.9.8.1  (i doubt that's needed now)

Well how to set this up?
i has to do something with ip route, i just can't get it straight!, all this default gateway ,subnets, i'am noob, can someone help me set this up?

I am not an Ubuntu or Linux expert in no way but research this a lot last yeat and i have a solution that works pretty well for me.

Get the network information of the VM before connecting to your VPN client

ifconfig

ens4      Link encap:Ethernet  HWaddr 42:01:0a:8a:00:04
          inet addr:10.138.0.4  Bcast:10.138.0.4  Mask:255.255.255.255
          inet6 addr: fe80::4001:aff:fe8a:4/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1460  Metric:1
          RX packets:1981508 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1035619 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:12219837340 (12.2 GB)  TX bytes:3879977314 (3.8 GB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:56603 errors:0 dropped:0 overruns:0 frame:0
          TX packets:56603 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:30401852 (30.4 MB)  TX bytes:30401852 (30.4 MB)

Take note of the adapter and IP Address, since GCP is wired you will have to get the subnet directly from GCP Portal.

Image 1

Once you have IP/Network infromation the work begins.

Backup route table and add a VPNBypass to existing table.

sudo su
cp /etc/iproute2/rt_tables /etc/iproute2/rt_tables_orig
echo "250   vpnbypass" >> /etc/iproute2/rt_tables
exit

Use cat /etc/iproute2/rt_tables to confirm bypass entry in rt_table.

Make sure the entry is inthere before you proceed.
Update the vpnbypass table to bypass VPN for subnet communication

Note that i am using the subnet and Ethernet name to add the rule to the vpnbypass table

sudo ip rule add from 10.138.0.0/20 table vpnbypass #Allow communication from Subnet
sudo ip rule add to 10.138.0.0/20 table vpnbypass  #Allow communication to Subnet
sudo ip rule add to 169.254.169.254 table vpnbypass  #Allow communication to Metadata Service
sudo ip route add table vpnbypass to 10.138.0.0/20 dev ens4 #Selecting route for vpnbypass table
sudo ip route add table vpnbypass default via 10.138.0.1 dev ens4 #selecting gateway

Connect to your VPN, the connection should not drop.  You can use curl ipinfo.io to confirm you are on VPN.

OPTIONAL

You can edit tthe rc.local file to make sure configuration is re-apply on reboot.

sudo vi /etc/rc.local

Add the following lines to the file

sudo ip rule add from 10.138.0.0/20 table vpnbypass #Allow communication from Subnet
sudo ip rule add to 10.138.0.0/20 table vpnbypass  #Allow communication to Subnet
sudo ip rule add to 169.254.169.254 table vpnbypass  #Allow communication to Metadata Service
sudo ip route add table vpnbypass to 10.138.0.0/20 dev ens4 #Selecting route for vpnbypass table
sudo ip route add table vpnbypass default via 10.138.0.1 dev ens4 #selecting gateway


If I don't log in right away on my 14.04 LTS system, the login hangs My newly dual booting system is working great with this one annoyance scenario:

I boot the system, but don't touch anything.
The screen eventually goes dark.
I touch a key and get the login screen.
I enter my password and hit enter.
The login screen disappears, but I never get the desktop.  It just hangs.

I am able to ssh in and reboot the system.  If I log in promptly then it's fine.

I'd settle for an answer telling me how to make the power saver never kick in and make the login screen go dark.  Or, a fix for the root cause.

More info:
It's stock Ubuntu 14.04 so I assume it's Unity. Graphics are "Gallium 0.4 on AMD CEDAR" according to System Settings/Details.

Logs will be posted next time it happens.

***Update - this hasn't happened since I posted the bounty.

I was also on the Same Boat when I had 14.04 Now I am on Velvet !

Here is the solution script that I has worked for me:

#!/bin/bash
echo
echo Install BleachBit
echo
apt-get install bleachbit -y
echo
echo Clean
echo
apt-get autoclean
apt-get clean
echo
echo Update & Upgrade
echo
apt-get update
apt-get upgrade
apt-get dist-upgrade
echo
echo
echo BleachBit Cleaning
echo
bleachbit -c adobe_reader.*
bleachbit -c apt.*
bleachbit -c chromium.*
bleachbit -c deepscan.*
bleachbit -c epiphany.*
bleachbit -c evolution.*
bleachbit -c filezilla.*
bleachbit -c firefox.*
bleachbit -c google_chrome.*
bleachbit -c kde.*
bleachbit -c java.*
bleachbit -c system.cache
bleachbit -c system.clipboard
bleachbit -c system.custom
bleachbit -c system.desktop_entry
bleachbit -c system.localizations
bleachbit -c system.memory
bleachbit -c system.recent_documents
bleachbit -c system.rotated_logs
bleachbit -c system.tmp
bleachbit -c system.trash
bleachbit -c opera.*
bleachbit -c thumbnails.*
bleachbit -c transmission.*
bleachbit -c x11.*
bleachbit -c vlc.*
bleachbit -c wine.*
echo
echo Clean Up
echo
apt-get clean
apt-get autoclean
echo
echo BleachBit ReBleach System
echo
bleachbit -c system.cache
bleachbit -c system.clipboard
bleachbit -c system.custom
bleachbit -c system.desktop_entry
bleachbit -c system.localizations
bleachbit -c system.memory
bleachbit -c system.recent_documents
bleachbit -c system.rotated_logs
bleachbit -c system.tmp
bleachbit -c system.trash
echo
echo Processes Complete
echo


How do I configure keyboard commands? In Windows I never turn my NumLock on. I navigate through the page line with Home and End, and when I want to mark a line I use them in a combination with the Shift key. Pretty basic stuff right? Well I don't know how to do it in Ubuntu 10.04. The Home and End keys work but if I hold the Shift key it inputs respectively 7 and 1. If I turn the NumLock on it works but if I am not holding the Shift key it prints 7 and 1 again. Is there any way I can use my keyboard in Ubuntu the same way I do in Windows?

P.S. My roomy is much more experienced than me in Linux so he suggested that xmodmap might work, but even if this is the approach I should take, I still don't want to dig into the whole documentation, just the cliff notes for this exact task if you please.

Go to System > Preferences > Keyboard, tab Layout, click on Options, go to Miscellanous compatibility options and then click on Shift with numeric keypad keys works as in MS Windows.

I don't have a numeric keypad so I can't test if it works but it should.

i selected "Default numeric keypad keys", and it makes the system remember if numlock is on (ubuntu 12.10)


How could I list all super users? I want a command to list all users who have root privileges i.e. sudo  ?

Suppose I'm a sudoer user. How could I know all other sudoer users?

If you just need to list the sudoers listed in the sudo group, I think that the best way to do it would be to run this command (which should be computationally lighter than any of the other commands in this answer):

grep -Po '^sudo.+:\K.*$' /etc/group

Also as suggested in the comments by muru, the format of the entries in /etc/group can be easily handled by cut:

grep '^sudo:.*$' /etc/group | cut -d: -f4

Also again as suggested in the comments by muru, one can use getent in place of grep:

getent group sudo | cut -d: -f4

Any of these commands will print all the users listed in the sudo group in /etc/group (if any).

Command #1 breakdown:

grep: Prints all the lines matching a regex in a file
-P: makes grep match Perl-style regexes
o: makes grep print only the matched string
'^sudo.+:\K.*$': makes grep match the regex between the quotes

Regex #1 breakdown:

Any character or group of characters not listed matches the character or the group of characters itself
^: start of line
.+: one or more characters
\K: discard the previous match
.*: zero or more characters
$: end of line

Command #2 breakdown:

grep: Prints all the lines matching a regex in a file
'^sudo.+:\K.*$': makes grep match the regex between the quotes
cut: Prints only a specified section of each line in a file
-d:: makes cut interpret : as a field delimiter
-f4: makes cut print only the fourth field

Regex #2 breakdown:

Any character or group of characters not listed matches the character or the group of characters itself
^: start of line
.*: zero or more characters
$: end of line

I was stumped about how the vagrant user can use sudo even without being mentioned in /etc/sudoers nor in /etc/group nor found with getent.

Turns out sudo also reads entries from all files under /etc/sudoers.d/. So if you haven't looked through that directory, you may not realize how many users actually have sudo access.

This kind of sudo access can be detected by JoKeR's answer using sudo -l -U vagrant but is not detected by any of the other answers here which all rely on either getent or /etc/group.


How to stop screen from dimming when power cable is unplugged? On HP Pavilion with Ubu 14.04 LTS, screen automatically dims when power cable is unplugged. I sometimes want to have maximum brightness, even when power cable is unplugged, for personal reasons.

How can I do this?
Thanks for suggestions.

Using the GUI:

Open "System Settings"
Under "Personal", click on "Brightness & Lock"
To disable dimming, under "Brightness", untick "Dim screen to save power"
To re-enable dimming, under "Brightness", tick "Dim screen to save power"

Using the command line:

To disable dimming run:

gsettings org.gnome.settings-daemon.plugins.power idle-dim true

To re-enable dimming run:

gsettings org.gnome.settings-daemon.plugins.power idle-dim false

SOLVED: click on battery icon at bottom of desktop, where time & date appears. after click go to more options on battery icon, then create your own plan by name PLAN 1 or PLAN 2 as you wish. then set all settings like battery, power and other option to NEVER. then click on next.

Now your laptop screen will not be dim if you unplug the charger.

EnJOY..... RASHID JATOI.


Is scrolling down Facebook web page causes high CPU usage normal? CPU: Intel i5-2400
RAM: 8GB (dual channel)
No graphic card

I've tried the command below but it didn't work for me.

sudo echo > "options drm_kms_helper poll=N" > /etc/modprobe.d/local.conf

Please can you guys help me solve this problem?

Does Facebook page in new tab share the same CPU resource with others?

If this is true, how to separete them from using the same distributed CPU resource?

The information below retrieved by command line sudo '/usr/bin/intel_gpu_top' when I keep pressing page down button on the keyboard in browsing Faceook web page for testing the GPU status.

 render busy:  12%: ██▌                                    render space: 12/131072
            bitstream busy:   0%:                                     bitstream space: 0/131072
              blitter busy:   1%: ▎                                     blitter space: 0/131072

                      task  percent busy
                        CS:  11%: ██▎                     vert fetch: 7542782 (1686/sec)
                       GAM:  11%: ██▎                     prim fetch: 2756058 (592/sec)
                     EU 00:  11%: ██▎                  VS invocations: 7512722 (1683/sec)
                     EU 10:  11%: ██▎                  GS invocations: 0 (0/sec)
                     EU 11:  11%: ██▎                       GS prims: 0 (0/sec)
                       PSD:  11%: ██▎                  CL invocations: 2738436 (590/sec)
                     EU 01:  11%: ██▎                       CL prims: 2746022 (591/sec)
                     EU 12:  11%: ██▎                  PS invocations: 462796763240 (101142779/sec)
                     EU 02:  11%: ██▎                  PS depth pass: 462802984040 (101142779/sec)
                        IZ:  11%: ██▎
                        SC:  11%: ██▎
                       HIZ:  11%: ██▎
                      WMFE:  11%: ██▎
                        MT:  11%: ██▎
                       SVG:  11%: ██▎
                      WMBE:  11%: ██▎
                     RCPFE:  10%: ██
                     RCPBE:  10%: ██
                       RCC:  10%: ██
                       DAP:  10%: ██
                        PL:   8%: █▋
                      IC 0:   8%: █▋
                      IC 1:   8%: █▋
                        TD:   8%: █▋
                        SO:   8%: █▋
                        SI:   7%: █▌
                        FL:   7%: █▌
                      SVRW:   7%: █▌
                        FT:   6%: █▎
                        DG:   6%: █▎
                      SVSM:   5%: █
                        QC:   5%: █
                        DM:   3%: ▋
                        SF:   0%:
                        CL:   0%:
                       ISC:   0%:
                       VS0:   0%:

In Firefox you can disable "smooth scrolling" which saves RAM and CPU. I don't use Chrome very often, so I don't know how to disable it there, but it should be possible.

Yes, it is normal. Rendering web pages with lots of graphics (photos) is a heavy task in Chrome.

This happens mostly with low-end graphics adapters, like your built in Intel.


Problem with the installation of VirtualBox I am trying to install virtualbox and make it work but it doesn't seem like I can. In the image
you can see the output.

If I run VBoxManage --version I get:

WARNING: The character device /dev/vboxdrv does not exist.
Please install the virtualbox-dkms package and the appropriate
headers, most likely linux-headers-generic.

You will not be able to start VMs until this problem is fixed.
4.3.10_Ubuntur93012

But virtualbox-dkms is already installed and at the latest version. So I tried to reinstall it and i got this:

Any help will be appreciated.

EDIT:

The output after reconfigure (@M.Tarun suggestion):

EDIT 2:

Also installed the sources as @Hmayag instructed, purged virtualbox and installed it again but I got the same problem.

Basically after you install those two packages you also need to do the reconfiguration:

sudo dpkg-reconfigure virtualbox-dkms
sudo dpkg-reconfigure virtualbox
sudo modprobe vboxdrv

And to fix eth0:

sudo modprobe vboxnetflt


ZFS doesn't allow me to follow kernels with updates I installed ubuntu 20.04 sometime in june.
by now I'm updated to ubuntu 20.04.1 LTS
there's been a few kernel updates. end everytime I run updates Zsys tries to put new kernel version as the first option.
And I'd like nothing more but to use the new kernels.
but they simply won't boot.
when I say won't boot, I mean some kinda freeze happens during the boot process I can't drop to TTY/boot command line and I don't get any error messages (maybe I'm not hitting the right key)
I just have my motherboard logo and that's it.
the ubuntu logo and spinner don't show up and it could stay like this indefinitely if I did nothing.
luckily i still have my old grub entry and with grub customizer I've been keeping it at the top of the list.
but I want to solve this issue now before ubuntu decides I've been hoarding an old kernel for too long.
is there something in particular I'm supposed to do to boot a new kernel with ZFS?
I'm guessing it has nothing to do with the specific kernel version and more to do with zfs being a block that's not yet intricately tied into the rest of the OS. and where ubuntu is able to automatically update the kernel references everywhere else it doesn't yet automatically update a variable inside ZFS that points to the kernel version, or something like that?
I don't know.
Anyways :
t@tsu:~$ dpkg -l | tail -n +6 | grep -E 'linux-image-[0-9]+'
ii  linux-image-5.4.0-40-generic                                5.4.0-40.44                                                 amd64        Signed kernel image generic
ii  linux-image-5.4.0-45-generic                                5.4.0-45.49                                                 amd64        Signed kernel image generic
ii  linux-image-5.4.0-47-generic                                5.4.0-47.51                                                 amd64        Signed kernel image generic

5.4.0-40 boots and is the one my ubuntu 20.04 installed with
5.4.0-45 does not boot and was installed by updates not by me
5.4.0-47 does not boot and was installed by updates not by me
Ideally I'd like to boot 5.4.0-47
EDIT :
On kernel installs I do get an error :
Setting up linux-modules-5.4.48-050448-generic (5.4.48-050448.202006220832) ...
Setting up linux-image-unsigned-5.4.48-050448-generic (5.4.48-050448.202006220832) ...
I: /boot/vmlinuz.old is now a symlink to vmlinuz-5.4.0-47-generic
I: /boot/initrd.img.old is now a symlink to initrd.img-5.4.0-47-generic
I: /boot/vmlinuz is now a symlink to vmlinuz-5.4.48-050448-generic
I: /boot/initrd.img is now a symlink to initrd.img-5.4.48-050448-generic
Processing triggers for linux-image-unsigned-5.4.48-050448-generic (5.4.48-050448.202006220832) ...
/etc/kernel/postinst.d/dkms:
 * dkms: running auto installation service for kernel 5.4.48-050448-generic
   ...done.
/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-5.4.48-050448-generic
I: The initramfs will attempt to resume from /dev/sda2
I: (UUID=53c19176-f03e-4c40-a6ed-3a2627160647)
I: Set the RESUME variable to override this.
/etc/kernel/postinst.d/zz-update-grub:
Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/init-select.cfg'
Generating grub configuration file ...

and a ton of these :
Warning: Couldn't find any valid initrd for dataset rpool/ROOT/ubuntu_38tazy@autozsys_7lfyl1.

and here's update-grub :
(doesn't look optimal)
https://pastebin.com/8y6x36u4

Looking at your logs I was wondering if Ubuntu has been able to generate the boot files properly, and I was thinking if you have enough space in /boot.
Is /boot a partition or is a directory under root fs?.
Many default Ubuntu installations had small /boot partitions that got full and create problems.
Are you using encryption?.
Another idea is, those Kernels that fail are attempted to install by the updates; can you install one of those kernels manually with apt install?.
Cheers

Just thoughts and maybe worth trying out.
ZFS isn't build in the standard linux kernel, so you have to build it as a module which has to be rebuild for each kernel version.
I don't belive that ubuntu comes with zfs modules integrated (maybe it did at some point).
Try reinstalling them on your working kernel, this should build modules for the new kernel as well as create a new initrd image.
List the zfs packages you have installed:
apt list zfs*

use apt reinstall to reinstall them.
apt packages that you might need for zfs:
zfs-dkms
zfs-initramfs


Increase Swap in Ubuntu 18.04 Under Lvm and Encrypted File System I did a clean install of Ubuntu 18.04 Desktop.

I used the graphical installer and chose "Encrypt the new Ubuntu installation for security".

It used by default LVM and created a partition for the swap instead of the file. Here is sudo swapon -s result:

eviatan89@leviatan89-K55VD:~$ sudo swapon -s
Filename                Type        Size    Used    Priority
/dev/dm-2                               partition   1003516 999448  -2

I need to increase the size as I am having lots of problems running low on RAM.

As curiosity, problems come when using Cassandra and Firefox with several open tabs (including YouTube). My system got 6GB of RAM.

Thanks a lot for your help!

The easiest solution would be to add a swap file.  If you are already encrypting your root file system, I would not bother with an encrypted swap file, which is only a little more difficult, but it is slower.  The advantage of a swap file is that you can remove it later to regain the disk space.  And the disk is already encrypted!

The steps are straightforward.  First, make the file.  For example, this would make 1GB of new swap:

sudo dd if=/dev/zero of=/swapfile bs=1024 count=1024k

The of=/swapfile tells dd to put the new swap file in /swapfile.  You can call it anything you want.  You can add multiple swap files, too.  For recent Linux kernels, the speed is the same as a swap partition.

Then, you need to format the swap file as swap space, like so:

sudo mkswap /swapfile

This command will give you some output like:

Setting up swapspace version 1, size = 1048576 KiB

no label, UUID=83352590-ef57-49f5-84c4-7fb847e4e4e0

And that's your new swap file.  Finally, you need to activate the swap on your machine using the following command:

sudo swapon /swapfile

Now, sudo swapon -s should show you both the swap partition and the swap file.

I then recommend adding some security by changing permissions as follows:

sudo chown root:root /swapfile
sudo chmod 0600 /swapfile

If all seems good so far, you can add the swap file permanently by adding the the following line to /etc/fstab using your favorite editor:

/swapfile       none    swap    sw      0       0

You can add multiple swap files, of course.  And you can remove the swap file by using sudo swapoff /swapfile.

Hope this helps.

If you are running mint 19.X, here are some concise steps:

sudo dd if=/dev/zero of=/swapfile bs=1024 count=10240k # make 10G swapfile
sudo chown root:root /swapfile
sudo chmod 0600 /swapfile
sudo mkswap /swapfile

edit /etc/fstab

comment out line: /dev/mapper/mint--vg-swap_1 none swap sw 0 0

add line: /swapfile       none    swap    sw      0       0

Then reboot.


How do I backport VLC from 12.04 to 10.04? I just want to install VLC latest from 12.04 LTS to 10.04 LTS
How to do it?

One of the methods of installing a software not in the standard ubuntu repos but through apt-get is by using a Personal Package Archive (ppa). All ppa's are hosted on http://launchpad.net. On searching, i found that one of the ppa has the version of vlc that you require (vlc-2.0.4 ).
https://launchpad.net/~n-muench/+archive/vlc.

This has all the dependencies vlc-2.0.4 needs.

Add this ppa to your system like so:

sudo add-apt-repository ppa:n-muench/vlc2

Then update your sources by:

sudo apt-get update

Then install again:

sudo apt-get install vlc

That should do it. I tried and it works. You can install from other ppa as well but make sure it builds successfully by checking in the right hand side of the ppa's main page.

As of today, the latest version of VLC available now is 2.0.4, which is the same one available in Ubuntu 12.10, so if you upgrade to Ubuntu 12.10, you will have the latest version of VLC

Since you are in 10.04 release, the VLC version you can get from Synaptic is only the one in 10.04 repos.

If you want a more recent version of VLC, you can get the .deb package from the this website.

But the problem is that the dependencies of the latest VLC version may not be present in your current 10.04 repos. In that case, you would have to go manually install them and then their dependences and so on.

This defeats the purpose of having a package management system.

So, if you want to use a latest version of VLC (say available in 12.04 repos), I suggest you upgrade your system to 12.04.


"Disable touchpad button": touchpad won't re-enable My Acer Timeline has a "Disable touchpad button" which works too well. That is, once I've pressed it, pressing it again won't re-enable the touchpad. I've tried a couple of things like:

gconftool-2 --set --type boolean /desktop/gnome/peripherals/touchpad/touchpad_enabled true

which worked once, but now when I do it again, it doesn't work again...

In fact, I'd like to know how to work out what the "disable touchpad" button is actually doing, and why doing it again isn't fixing the issue.

Just load or unload the psmouse module from kernel

for example:

To disable touchpad:

# rmmod psmouse

To enable touchpad again:

# modprobe psmouse

and voila!

There is a way to do it. When i updated to 11.04 i had this problem. After searching I found a solution. It was by altering some file in the system. What was happening was that the software was disabling the mouse and the hardware was disabling the mouse but once you try to re-enable the mouse the software stays on disable and the hardware works again. All I had to do was make it so that the software keeps the mouse enabled.


How to drag a folder to the launcher from Nautilus How can I add a folder to the launcher for quick access to it. In this particular case I wish to drag it to the launcher.

I'm not sure if it's possible to drag and drop a folder onto your unity bar - but you can have the same functionality with a bit of editing.

Edit Nautilus .desktop file
1) In a terminal (Ctrl+ALT+T) type: gedit ~/.local/share/applications/nautilus-home.desktop
2) If this already exists, edit the following line to add your NEWFOLDER shortcut:

X-Ayatana-Desktop-Shortcuts=Videos;Documents;Music;Pictures;Downloads;Dropbox;NEWFOLDER

3) Below X-Ayatana-Desktop-Shortcuts add a new shortcut group:

X-Ayatana-Desktop-Shortcuts=Videos;Documents;Music;Pictures;Downloads;Dropbox;NEWFOLDER
[NEWFOLDER Shortcut Group]
Name=New Folder
Exec=nautilus ~/Documents/newfolder
TargetEnvironment=Unity

Where ~/Documents/newfolder is the location of the shortcut you want to add.
(N.B. if this file doesn't already exist you can use a copy of mine.)
4) Type into Run prompt (ALT+F2): unity --replace

Now when you right click your home folder/nautilus shortcut you will see an extra option for new folder.

Create a new .desktop file for your folder shortcut.
1) Run gedit again: gedit ~/.local/share/applications/folder-shortcut.desktop
2) Fill in the file with a sample as follows:

[Desktop Entry]
Exec=nautilus Documents/newfolder
Version=1.0
Name=New Folder
GenericName=ew Folder
X-GNOME-FullName=ew Folder
Comment=Open New Folder
Icon=/usr/share/pixmaps/gnome-computer.png
StartupNotify=true
Terminal=false
Type=Shortcut

2) Save the file and open the location in nautilus.
3) Drag it onto the unity bar.
4) Right click the new icon and click Keep in Launcher

N.B. you do not need to refresh unity for this one.

That's not possible, as that's not what the launcher is for. The bookmarks are displayed in the files lens. If you want an extra bar for your bookmarks, web links, etc, then I suggest adding an xfce4-panel.


How do I change my default browser? Is there an option to change my default browser for all my applications?

Have a look at your system-settings -> Details:

(Note that in older versions of Ubuntu Details is called System Info)

You can also change your default browser in the relevant browser settings - e.g.

Firefox:

Chromium:


Shrink volume of Primary Partition I currently run windows 8.0 and have 4 partitions. I will like to shrink the volume of my primary partition containing the win 8 OS so I can have more space to install ubuntu 14.04. My question is will it delete everything in that partition while shrinking the volume and how do I go about installing it on the new partition created.

I have done this from an application in the Windows 7. It should be in win 8 also.
We can shrink the size. Afterwards "Ubuntu"can be installed with C.D. This C.D can be created by down-loading an Image file(nrg)and running a virtual drive/burning Disc. 'How to create a virtual drive' may be known from Internet.But we should be careful not to lose Windows after the installation of "UBUNTU" by deleting any partition and leaving the space without DOS partition.If space is not there we can delete unwanted files and then shrink.


Resize hard drive partition I have installed ubuntu besides Windows XP and it is using only 5.9 GB of total drive space.

I would like to know how to increase the size?

You can unmount your hard drive using an external USB drive which would allow you to alter your partition.  The USB drive would have a burned iso of Gparted allowing you to resize the partition yourself.


php5 is already the newest version but in phpinfo i get 5.4 Details:

Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:        12.04
Codename:       precise

I want to install php5.5 so i try next step:

php -v

PHP 5.4.26 (cli) (built: Apr  8 2014 10:05:18)

sudo add-apt-repository ppa:ondrej/php5
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install php5

Reading package lists... Done
Building dependency tree
Reading state information... Done

php5 is already the newest version.

0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

When i use command:

sudo apt-cache policy php5

I get next:

php5:
  Installed: 5.5.29+dfsg-1+deb.sury.org~precise+3
  Candidate: 5.5.29+dfsg-1+deb.sury.org~precise+3
  Version table:
 *** 5.5.29+dfsg-1+deb.sury.org~precise+3 0
        500 http://ppa.launchpad.net/ondrej/php5/ubuntu/ precise/main amd64 Packages
        100 /var/lib/dpkg/status
     5.3.10-1ubuntu3.19 0
        500 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu/ precise-updates/main amd64 Packages
        500 http://security.ubuntu.com/ubuntu/ precise-security/main amd64 Packages
     5.3.10-1ubuntu3 0
        500 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages

But in my phpinfo() and php -v i see version 5.4. How i can switch version to 5.5 ? What i need to do? I try reboot server but nothing has changed.

locate bin/php

/opt/bitnami/php/bin/php
/opt/bitnami/php/bin/php-cgi
/opt/bitnami/php/bin/php-cgi.bin
/opt/bitnami/php/bin/php-config
/opt/bitnami/php/bin/php.bin
/opt/bitnami/php/bin/phpize
/opt/bitnami/php/sbin/php-fpm
/usr/bin/php
/usr/bin/php-cgi
/usr/bin/php-config
/usr/bin/php-config5
/usr/bin/php5
/usr/bin/php5-cgi
/usr/bin/phpize
/usr/bin/phpize5
/usr/lib/cgi-bin/php
/usr/lib/cgi-bin/php5
/usr/sbin/php5-fpm
/usr/sbin/php5dismod
/usr/sbin/php5enmod
/usr/sbin/php5query

It seems that you are having php installed in two locations. You can check that with locate php and with which php you will know actually what path your current shell using.


How to change the color of the 'Incorrect Password' text I want to be able to change the 'Incorrect Password' text to a different color in the lightdm login screen, but I can't figure out how.  I'm using Ubuntu 16.04 LTS, Unity 7.4, and I have the following programs installed:

Default system settings
Unity tweak tool
Ubuntu tweaks
CCSM
dconf editor

I can't find an option to change the text color anywhere, so if someone could help me out that would be much appreciated :)

You need to recompile unity-greeter for that. Here is how to do it.
Download the source
Download the unity-greeter package source for Xenial from (the one with .tar.xz extension) here https://launchpad.net/ubuntu/xenial/+source/unity-greeter and extract it into your home directory.
Change the source
Now open the file src/prompt-box.vala and go to the line no. 438 The relevant area of the source will be like this
...
        Gdk.RGBA color = { 1.0f, 1.0f, 1.0f, 1.0f };
        if (is_error)
            color.parse ("#df382c");
        label.override_color (Gtk.StateFlags.NORMAL, color);
...

Now change the hex value of the color to your desired value. I used #33A0FF to test it.
Recompile
Now you need to recompile it. You may need development packages to do so. I needed these package to install libindicator-dev libido3-0.1-dev liblightdm-gobject-1-dev libindicator3-dev libunity-settings-daemon-dev unity-settings-daemon-dev
All dependency requirements can be fulfilled by installing these packages
sudo apt install autoconf-archive gir1.2-gdesktopenums-3.0 gir1.2-gnomedesktop-3.0 gir1.2-gtk-2.0 gir1.2-ido3-0.1 gir1.2-xkl-1.0 gnome-common gnome-desktop3-data gsettings-desktop-schemas-dev libcanberra-dev libcanberra0 libdbus-glib-1-dev libgnome-desktop-3-12 libgnome-desktop-3-dev libgtk2.0-dev libido3-0.1-dev libindicator-dev libindicator3-dev libindicator7 liblightdm-gobject-1-dev libtdb1 libunity-gtk3-parser0 libvorbisfile3 libxkbfile-dev libxklavier-dev sound-theme-freedesktop unity-gtk-module-common unity-gtk3-module unity-settings-daemon-dev xvfb

Now, go to the root of the extracted folder and use these commands sequentically to build
./autogen.sh
make

If first command complains about some missing packages or header files, you need to research which package may contain that header file. Usually the package name would be something starting with the lib prefix and ending with -dev suffix and contain the name of the file that was missing.
Once you successfully make the build, install it using
sudo make install

Now just login and see the effect!
Here is a screenshot after I modified the text color (taken using dm-tool)

Short of rebuilding lightdm, you can't change the 'Incorrect Password' text or its colour as lightdm uses hardcoded messages. Running

sudo -u lightdm dbus-launch gsettings list-keys com.canonical.unity-greeter

gives you the list of settings which you can change. GDM and MDM have themes which may support changing the colour of the alert.


Can't install qt-components-ubuntu because I'm using full release of QT 5.0.0 It appears that since I didn't install the beta1 version of QT5 from the ppa, I'm unable to use the Ubuntu components package.  I have the released version QT5 already and not interested in installing a beta version now.  Is there a workaround?

The following packages have unmet dependencies:
qt-components-ubuntu : Depends: qtbase but it is not installable
                       Depends: qtdeclarative but it is not installable

The instructions to install the preview toolkit are here.  I skipped the step to install QT5 because I already have a newer version straight from qt-project.org.

These instructions were tested on Ubuntu 12.04, Ubuntu 12.10 both 32-bit and 64-bit.

First off we need to install some dependencies. Install these even if you already have Qt5 installed:

sudo apt-get install build-essential libgtk2.0-dev libgl1-mesa-dev

If you haven't already, download and install the QtSDK from http://qt-project.org/downloads.

For Ubuntu 64-bit run:

cd ~
wget http://releases.qt-project.org/qt5/5.0.0/qt-linux-opensource-5.0.0-x86_64-offline.run
mv qt-linux-opensource-5.0.0-x86_64-offline.run qt5-installer.run

For Ubuntu 32-bit run:

cd ~
wget http://releases.qt-project.org/qt5/5.0.0/qt-linux-opensource-5.0.0-x86-offline.run
mv qt-linux-opensource-5.0.0-x86-offline.run qt5-installer.run

Then make it executable:

chmod +x qt5-installer.run

Now run it as root in order to install it to /opt:

sudo ./qt5-installer.run

Follow the prompts and, when asked where to install, select /opt/QtSDK.
From now on I will assume that you have it installed to that location, if you already had the Qt installed to a different location, adapt the steps in order to reflect your installation.

After installation I suggest you delete the QtCreator configuration folder as the permissions are wrong. QtCreator will recreate them when restarted.

cd ~/.config
sudo rm -rf QtProject

Now for the Qt Ubuntu Components, download the source file and unpack it:

wget https://launchpad.net/~ui-toolkit/+archive/ppa/+files/qt-components-ubuntu_0.1.24%7Equantal1.tar.gz
tar -zxvf qt-components-ubuntu_0.1.24~quantal1.tar.gz

Now in order to compile and install the components we need to create some sim-links.

For Ubuntu 64-bit run:

sudo ln -s /opt/QtSDK/5.0.0/gcc_x64 /opt/qt5

For Ubuntu 32-bit run:

sudo ln -s /opt/QtSDK/5.0.0/gcc /opt/qt5

One more thing before we compile and install, we need to change two environment variables, PATH and QML_IMPORT_PATH:

export PATH=$PATH:/opt/qt5/bin
export QML_IMPORT_PATH=/opt/qt5/imports
echo 'export PATH=$PATH:/opt/qt5/bin' >> ~/.bashrc
echo 'export QML_IMPORT_PATH=/opt/qt5/imports' >> ~/.bashrc

Now we need generate a Makefile an build the Qt Ubuntu Components:

cd ~/trunk
qmake ubuntu-sdk.pro
make
sudo make install

If everything went OK, the the components should be built and installed, now we need to try it out to make sure everything went alright. I suggest you log out and the back in before doing the next steps.

Open QtCreator, go to Tools -> Options, select the External Tools
tab.
For Qt Quick 1 Preview (qmlviewer), in the Executable field write: /opt/qt5/bin/qmlviewer
For Qt Quick 2 Preview (qmlscene), in the Executable field write: /opt/qt5/bin/qmlscene.
Click Apply and close the Options window.

Everything should be working now, one thing to keep in mind is that in order to successfully execute a QML Ubuntu Phone Application, in the .qmlproject file you need to uncomment importPaths and add "/opt/qt5/imports" to it like so:

Project {
    ...
    /* List of plugin directories passed to QML runtime */
        importPaths: [ "/opt/qt5/imports" ]
    ...
}

That's about it. For any questions comment and I'll try to get back to you. Have Fun!

Easier way would be to add the PPA from https://launchpad.net/~canonical-qt5-edgers/+archive/qt5-proper to the sources.list. After that a

sudo apt-get update

followed by your installation command should fix the problem.


Upload dialogs for Firefox and Chrome now differ; FF's doesn't include network drives As long as I can remember (and I've been running 14.04 LTS since its release!), Firefox and Chrome have both used the same upload/download dialog for, e.g., Gmail, or StackExchange image uploads. Chrome, happily, is still using it (note circled option towards the bottom):

Very recently (not sure when -- this week?) Firefox has started to use a different dialog, which does not offer me access to my network drives (nicely mounted, accessible with Chrome dialog, etc.):

Obviously I want Firefox to use the same "uploader" that Chrome is (still) using. So my questions:

How do I make sure that it does?
Or, failing that, how can I convince FF to offer me a network share as a location from its upload/download dialogs?

This is a known issue in Firefox versions that use GTK3 (like the recently released v46.0). See this Bugzilla ticket for background information. In short, the support for non-local files in the file chooser has changed with GTK3 and Firefox would now explicitly have to support remote files.

If you don’t need this feature very often, then there may be a workaround: you can try to find out the absolute path to your network share as mounted locally via GVFS. This will only work, if your network share was mounted before, e.g., by opening it in the file manager. Type/copy the following command into a terminal and press Enter:

ls -d /run/user/$(id -u)/gvfs/*/

It should print one line for each mounted network share. Copy the line of the share that you would like to access. Then paste the line into the “Location” text field of the upload dialog and press Enter. The file chooser should now open your network share. (If you can’t see the “Location” line, then click the pencil icon in the upper left corner.)

Once the mounted network share locations are known, they can also be added to the ~/.config/gtk-3.0/bookmarks file to create a persistent bookmark which the GTK3 file chooser can use – in this format:

file://$your_location Your Boomark Name

For example:

file:///run/user/1000/gvfs/smb-share:server=share.datastore.example.org.uk,share=share/users/thisuser/ My Shortcut

Make sure the gtk2 and gtk3 themes match so the appearance is consistent across applications.  Downloading new themes to find something that work for your preference is a worthwhile option.

Personally, I use KDE instead on gnome, and updating to firefox 46.0 forced me to change my gtk3 theme because the oxygen-gtk theme wasn't working.


Windows 10 upgrade kills grub and boot-repair doesn't help I've just upgraded to Windows 10 from Windows 8.1 on my partitioned laptop that has Ubuntu 14.04 installed. Grub no longer appeared on boot so I ran boot-repair from an Ubuntu liveUSB. This didn't seem to have any effect. I've checked and secure boot is still disabled.
Log from boot-repair: http://paste.ubuntu.com/11972534/
So what's next?

Update: I've attempted to use chroot to update grub from my Ubuntu partition. update-grub runs successfully finding both linux and windows boot manager but the process still doesn't have any effect. grub-install complains that it cannot find EFI directory (but I have mounted everything correctly).

Update2: Just discovered that running efibootmgr after chroot into ubuntu shows ubuntu as not being in the boot order at all. I manually changed the order and rebooted to discover that the bootorder was reset. I run in windows: bcdedit /set {bootmgr} path \EFI\ubuntu\shimx64.efi But this has no effect either even after reporting 'Operation Successful'.

I just had to run this in Windows as an administrator:

bcdedit /set {bootmgr} path \EFI\ubuntu\grubx64.efi

Or, if you are using PowerShell:

bcdedit /set "{bootmgr}" path \EFI\ubuntu\grubx64.efi

GRUB appears fine on boot and I can boot into Ubuntu and Windows 10 fine.

As pointed out in the comments (by David Faure), the final argument to this command depends on your particular system configuration. You can use this command to determine the correct path for your system:

bcdedit /enum firmware

This will list all the installed boot managers and associated EFI paths, and grub should be somewhere in the list.

After upgrading to Windows 10 on Acer Aspire-AXC-605, I could not boot into ubuntu and F2 key would not bring up bios screen so could not boot from USB ubuntu live.

I had to use Esc key while booting this brought up a "Diagnose PC" screen and I could boot USB from there.


How run Dolphin as root on Kubuntu I am running a fairly current version of Kubuntu...

Kernel: 4.13.0-36-generic x86_64   bits: 64
Desktop: KDE Plasma 5.10.5   Distro: Ubuntu 17.10

In all the "KDE" distros I've used in the past I could easily run "gui" apps with elevated credentials:
ie. "sudo dolphin", "kdesu dolphin", etc.

With kubuntu I cannot get any of these to work. I managed to do a cli "cp" to get some scripts moved to /usr/local/bin but I'm not a Linux tekkie so it was a real fight for me. If I can't get the apps I normally use to run "elevated" on those rare occasions when I have that need then kubuntu is not a good fit for me. Is there a way I can continue using kubuntu and do what I need to do?

Specifically: I need to run Dolphin with root privileges.

Thank you

Clarification: your issue with Dolphin will be found in all recent KDE distros, not just Kubuntu.

The KDE developers are working on a polkit route to allow temporary elevated privileges as they have already done for Kate.

Until then, consider installing another file manager to use when you want to use a file manager with elevated privileges. sudo -H before the executable's name should do the job.

PCManFM, the default file manager in Lubuntu, and Thunar, the default in Xubuntu, are both lightweight and won't pull in too many dependencies. Midnight Commander, also in the sofware center, is another powerful file manager but it will take some getting used to.

sudo dolphin should work, if you want to input your password in a gui, use gksu dolphin. this should work both from cli and if you press alt-f2


High cpu usage when scrolling or moving windows Gnome in 18.04 I have an AMD a10-7850k apu in my computer and I also have an RX550 GPU. I have the RX550 GPU set up to be passed to a windows kvm for games and that works fine. But On my APU using the radeon driver the performance when scrolling or anything moving is pretty bad and the /usr/bin/gnome-sh process begins to use quite a bit of cpu on one core. I don't know why this happens. I've tried the AMDGPU driver with the apu but it just shows a lot of corrupted text on the login screen and either doesn't let me log in or it does but the performance is equally as bad. Games do launch under linux but the performance isn't as good as usual and I'm kinda stuck on this.

I have an RX580, so I was in the same boat as you. The problem was that Ubuntu had some Nvidia drivers that it was using. When it couldn't find an Nvidia card, it fell back to software rendering. Here is how I solved it:

Select the PPA that you want. (Default Ubuntu, Padoka, Oibaf, ect. I'm currently using the default.)
In the Terminal, type: sudo rm /etc/X11/Xsession.d/50_check_unity_support This will remove the 50_check_unity_support file, just in case. (https://bugs.launchpad.net/ubuntu/+source/nux/+bug/1767468)
Finally, type: sudo apt-get remove libnvidia-gl-390 It should install libegl-mesa0 as well as remove libnvidia-gl-390. If libegl-mesa0 does not install, install it by typing: sudo apt-get install libegl-mesa0
Reboot.

Tell me if this helps!


How to install Ubuntu on an Acer with preinstalled Windows 10 Home Following the guide for installing Ubuntu on a Windows 10 Home Edition system did not work with an Acer Aspire V3-575T. After installation usb is removed and the system is restarted, it gives a no boot media error.  I believe the solution will apply to other models with Windows 10 Home / secureboot and UEFI.

Detailed steps I used to successfully install:

Create a boot USB with the Ubuntu image file using Rufus as detailed here:
https://www.ubuntu.com/download/desktop/create-a-usb-stick-on-windows

Insert USB in the forward left hand side USB connector
(the USB connector on the right side of the computer will not work)

Reboot the computer and access the BIOS with F2:

Use arrow keys to navigate to BOOT screen
Select Secure Boot and change value to disable
On the Boot priority order move USB-HDD to the top
F10 to save and exit

Proceed with the installation type of choice.

After the installation has completed, and is prompting you to restart:

Remove the USB drive
(on reboot) Access the BIOS again  with F2
On the BIOS page Select an UEFI file as trusted for executing
Navigate to: HDD0 > EFI > 'ubuntu' and select SHIMX64.EFI
(Enter shimx64 as name)
Navigate to the BOOT tab:
Select Secure boot, change value to Enabled
F10 to save and exit

I followed these exact steps, installed without errors, and am using Ubuntu on
my Acer V3 now.

Instructions for an Acer Travelmate P249 Series below:

Reboot the computer
Enter the BIOS with F2
Use the arrow keys to navigate to the BOOT screen
Select Secure Boot and change value to disable
Select Boot priority order and move USB, HDD, DVD, etc. to the top
Press F10 to save and exit
Proceed with the installation type of choice.
After the Windows installation has completed, and is prompting you to restart:

Remove the USB drive
On reboot, Access the BIOS again with F2
On the BIOS page Select UEFI file as trusted
Navigate to:

HDD0
EFI
Ubuntu
select SHIMX64.EFI (Enter OS Name as your wish)

Navigate to the BOOT tab:

Select Secure boot
change value to Enabled
F10 to save and exit.

Install Ubuntu complete and reboot the computer.

Every time you boot the computer press F12 and select the operating system you want to boot.


No Alt+F2 in Ubuntu Netbook 10.10? I am stumped. I upgraded from 10.04 to 10.10 Beta 3 and for some reason I can't get Alt-F2 to do anything. Is this a known bug or am I just not doing the right thing?

This is a known limitation of the new Unity shell. The bug to track is here: https://bugs.launchpad.net/unity/+bug/580295

There shouldn't need to be a workround if this is going to be used as a default. More forward thinking from Canonical it seems is needed.


Will a Ubuntu LiveCD be affected by a BIOS virus? If I boot from Ubuntu DVD I notice that there are two options:

Run from DVD without installing it.
Install Ubuntu.

My question is, If the PC has a BIOS virus and the first option is chosen — will the Ubuntu (loaded into the RAM, I guess) be affected or would it be totally “safe and clean”?

... If the PC has a BIOS virus ...

Which virus is in the BIOS of that PC?

The answer depends on that data. Some viruses do affect the content of the OS in RAM, some don't.

However, if it's a Live CD, it's permanently closed to further writing, and the virus could not alter what's on the LiveCD.

Well if the BIOS is what has the "virus" then it should not affect other operating software. Although I may be wrong I don’t believe that it should affect the BIOS. If you could give us more information, as if it is affecting anything on your hard drive, or if you can easily tell that the BIOS had a virus that would be helpful. Oh, and one more thing, if you can boot from the disk how did you do it, you would have to pass it through the BIOS, and I would find it hard to believe that it would even be able to boot if the BIOS had a virus.


Can't delete very large (1.2TB) files from Trash-computer freezes I have three very large files .hdf5 (each 1.2TB) in my trash that I can't get rid of. Obviously I have tried simply emptying the trash. I have also tried deleting from Terminal with

 rm -rf ~/.local/share/Trash/*

I have also tried directly deleting the files from the .Trash-1000/files folder. All of these options have resulted in my computer freezing. The only thing I can do that works then is pressing. Once I restart, they are back in the Trash. Curiously I tried a 'move to' another folder which appears to move the files, but then my computer crashes and when I restart, they are back in the Trash.

alt-SySRq-REISUB

The only added information I can give is that I put these in the Trash by mistake and tried to restore them which crashed my computer.

Any help would be appreciated - I have been on this problem for 24 hours.

I would have a look on the SMART status of the disk, to make sure this is not the problem.

If that is fine, you can try and give the process lower IO, in order for it to not freeze the system

sudo ionice -c3 rm -rf ~/.local/share/Trash/*

EDIT:

I don't understand why this is downvoted here ? I checked and it is an acceptable answer on serverfault

Try trash-cli toolkit..
You can install it with apt-get.

  sudo apt-get install trash-cli

use trash-empty tool to remove trash, like:

  sudo trash-empty

best wishes


What will be the space requirements to upgrade to 12.04? I am using Ubuntu 11.10 and I want to update it via Internet connection but I am not sure if my / partition has enough space.So what is the proper amount of free space required before upgrading to Ubuntu 12.04 from Ubuntu 11.10?

The update should tell you how much space it will need before it goes ahead but an upgrade requires usually at least as much space as all the packages you have already installed take up.

This is because it needs to download all those packages before it can install them. That needs disk space.

If you're particularly worried, removing some of the bigger, non-essential applications that would be upgraded can help. You can reinstall them afterwards when the initial upgrade packages have been removed.

You need at least a 4.4 GB space in your hard disk to install Ubuntu 12.04.


can't install with usb pen drive, SYSLINUX problem i'm on ubuntustudio and i want to format my hd and try kubuntu
(install in my acer notebook, no partion, no double operating system problem, only istall it)
i've downloaded iso file ( kubuntu-10.10-desktop-i386.iso ), insert usb pen drive,
then: system > administration > startup disk creator
erased usb pen content, and "make startup disk"
finally, reboot computer with pen inside usb port

normal boot didn't start (as expected) but only black screen with this signal:

SYSLINUX 4.03 2010-10-22 EDD Copyright (c) 1994-2010, H. Peter Anvin et al
unknown keyword in configuration file
boot:

i've tried different usb pen stick and different iso files (ubuntu, kubuntu, netbook edition).. always same problem (sometimes only the first line without "unknow keyword in conf file" error)

some advice??
sorry for my bad english

In 10.10 there is a bug in usb-creator that may cause your problems. Try creating your stick using UNetbootin, as was just suggested.

There are reports that you can fix the bug by opening syslinux.cfg on the USB drive and replace the following line:

ui gfxboot bootlogo

with

gfxboot bootlogo

I solved this problem by copying syslinux.cfg from one folder near the kernel to the base of the Key.
In fact I once displaced it and the boot went one step further but syslinux.cfg was then missing to the boot. So I had to copy it back.


Inkscape doesn't open on ubuntu 12.04 It starts and appears on system monitor, but it doesn't open any window...

Any solution?

I'm using:
Inkscape 0.48.3.1 r9886 (Mar 29 2012)
Ubuntu 12.04 32bits - using gnome-shell

There should be a hidden directory in your home folder ~/.config/inkscape, try moving that inkscape directory elsewhere and then try restarting Inkscape. If that does not work you can bring back that inscape directory under .config again.

In my case I needed to re-install libgtkmm-2.4.so.1

See  https://bugs.launchpad.net/ubuntu/+source/inkscape/+bug/1005400 for details


How do I configure proxies without GUI? How do you configure proxy settings in the Ubuntu Server or Minimal (CLI) versions using the terminal?

System-wide proxies in CLI Ubuntu/Server must be set as environment variables.

Open the /etc/environment file with vi (or your favorite editor). This file stores the system-wide variables initialized upon boot.
Add the following lines, modifying appropriately. You must duplicate in both upper-case and lower-case because (unfortunately) some programs only look for one or the other:

http_proxy="http://myproxy.server.com:8080/"
https_proxy="http://myproxy.server.com:8080/"
ftp_proxy="http://myproxy.server.com:8080/"
no_proxy="localhost,127.0.0.1,localaddress,.localdomain.com"
HTTP_PROXY="http://myproxy.server.com:8080/"
HTTPS_PROXY="http://myproxy.server.com:8080/"
FTP_PROXY="http://myproxy.server.com:8080/"
NO_PROXY="localhost,127.0.0.1,localaddress,.localdomain.com"

apt-get, aptitude, etc. will not obey the environment variables when used normally with sudo. So separately configure them; create a file called 95proxies in /etc/apt/apt.conf.d/, and include the following:

Acquire::http::proxy "http://myproxy.server.com:8080/";
Acquire::ftp::proxy "ftp://myproxy.server.com:8080/";
Acquire::https::proxy "https://myproxy.server.com:8080/";

Finally, logout and reboot to make sure the changes take effect.

Sources: 1, 2. See 1 in particular for additional help, including a script to quickly turn on/off the proxies.

Proxy Environment Variables:

  http_proxy:  Proxy server for HTTP Traffic
  https_proxy: Proxy server for HTTPS traffic
  ftp_proxy:   Proxy server for FTP traffic
  no_proxy:    Patterns for IP addresses or domain names that shouldn’t use the proxy

The value for every proxy setting, except for no_proxy, uses the same template.
proxy_http=username:password@proxy-host:port

Temporary setting proxy:
export HTTP_PROXY=user:pass@my.proxy.server:8080

Persistent Proxy Settings:
use vim ~/.bash_profile to open bash setup file, then put following lines inside it

export http_proxy=username:password@proxyhost.com:8080
export https_proxy=username:password@proxyhost.com:8081
export no_proxy=localhost, 127.0.0.1, *.my.lan

use source ~/.bash_profile to apply the changes


Times New Roman font missing in LibreOffice Writer There is no Times New Roman Font present in LibreOffice Writer. I looked upon the question Installing Times New Roman font. But I have the fonts installed on my system already, but is it not showing
up on Libreoffice Writer?

My system specs

$ libreoffice --version
LibreOffice 5.1.2.2 10m0(Build:2)

Probably something happened during the installation of the fonts, and the package appears installed, although the fonts themselves were not. Simply purge the package and re-install it:

sudo apt-get remove --purge ttf-mscorefonts-installer
sudo apt-get install ttf-mscorefonts-installer

A screen will appear, where you will have to accept the license agreement. Then the fonts will be downloaded and installed one by one.

I always install the package ttf-mscorefonts-installer described here via Synaptic Package manager, or via terminal run these commands:

sudo apt-get update
sudo apt-get install ttf-mscorefonts-installer

and the fonts (Andale Mono, Arial Black, Arial (Bold, Italic, Bold Italic), Comic Sans MS (Bold), Courier New (Bold, Italic, Bold Italic), Georgia (Bold, Italic, Bold Italic), Impact, Times New Roman (Bold, Italic, Bold Italic), Trebuchet (Bold, Italic, Bold Italic), Verdana (Bold, Italic, Bold Italic), Webdings) are automatically available to use in LibreOffice.


Flash player (in Firefox) is unstable in 14.04 For 13.10, I used this guide to get Intel iGPU-supported playback of flash videos in Firefox: http://www.webupd8.org/2013/09/adobe-flash-player-hardware.html

All in all, Intel graphics acceleration for flash content was working just fine in 13.10, at least on my machine (with Xubuntu).

I basically followed the guide to do the same for 14.04, but about 2-3 weeks ago flash videos started acting up. Whenever I have one instance of flash paused or stopped in one tab and go to the next tab to continue some song on Soundcloud or something, it's game over.

I'm clueless as to what I can do here. Did anything change in the meantime?

These instructions will install Pepper flash player for Chromium and it will also be updated automatically. Because Google ended support for Chrome on 32-bit Linux in March, 2016, Pepper flash player can only be installed for 64-bit versions of Chromium.
To install flash player in Chromium web browser search the Dash for Software & Updates and open the Software & Updates window. Click the Other Software tab in the Software & Updates window and put a check mark in the checkbox to the left of where it says: Canonical Partners.

Click the Close button to close the Software & Updates window.
Open the terminal and type:
sudo apt remove pepperflashplugin-nonfree # remove pepperflashplugin-nonfree if it's installed
sudo apt-get update
sudo apt-get install adobe-flashplugin
sudo apt install browser-plugin-freshplayer-pepperflash # 16.04 and later

Original answer
The more up-to-date Pepper Flash Player that can be installed together with Chromium Web Browser will run with fewer glitches (such as fullscreen doesn't work, buttons on video don't work, video hangs after pausing and then pressing the play button to resume, etc.) than Adobe Flash Player for many Flash videos.
You can install Chromium web browser together with the Pepper Flash Player in Ubuntu 14.04 from the Ubuntu Software Center. Open the Ubuntu Software Center and search for Chromium Web Browser and Pepper Flash Player - browser plugin and install them.
If a more recent version of Pepper Flash Player has been released and you want to update Pepper Flash Player to the latest version, you can do this from the terminal using the following command:
sudo update-pepperflashplugin-nonfree --install

Pepper Flash Player cannot be updated with the following command anymore on 32-bit OSs since Google ended support for Chrome on 32-bit Linux in March, 2016. If you are using Ubuntu 32-bit were using Ubuntu 32-bit before March, 2016, you can update Pepper Flash Player to the latest version from the terminal using the following command:
sudo update-pepperflashplugin-nonfree:i386 --install

Either of these two commands will download the latest version of Google Chrome (the file is larger than 40MB) and then update only the Pepper Flash Player with the more recent version of Pepper Flash Player that comes with Google Chrome without installing Google Chrome.
If a more recent version of Pepper Flash Player has been released and you want to update Pepper Flash Player to the latest version, you can do this from the terminal using the following command:
sudo update-pepperflashplugin-nonfree --install

If you are using Ubuntu 32-bit, you can update Pepper Flash Player to the latest version from the terminal using the following command:
sudo update-pepperflashplugin-nonfree:i386 --install

Either of these two commands will download the latest version of Google Chrome (the file is larger than 40MB) and then update only the Pepper Flash Player with the more recent version of Pepper Flash Player that is bundled with Google Chrome without installing Google Chrome.
If updating Pepper Flash Player to the latest version fails with an error like this:
ERROR: failed to retrieve status information from google : W: There is no public key available for the following key IDs:
1397BC53640DB551

It happens because Google changed its signing key. To fix it run the following commands:
gpg --keyserver pgp.mit.edu --recv-keys 1397BC53640DB551
gpg --export --armor 1397BC53640DB551 | sudo sh -c 'cat >> /usr/lib/pepperflashplugin-nonfree/pubkey-google.txt'

...and then try to update Pepper Flash Player to the latest version again.

Pipelight will install the current windows version of flash for you. Other plugins, like Silverlight and Unity are also available through Pipelight.


Locating my backup files I have just installed ubuntu. I used to run XP and have backed up all my files to a WD backup drive which is connected to my wireless router. Trouble is, I do not know how to access this drive. My Android phone sees them but I do not know how to this with Ubuntu applications. Any suggestions/guidance will be most appreciated. Thank you.

Use your file manager (nautilus, pcmanfm ..) And search for the word network, or put  smb://  in the address bar.

If the address bar is locked use Ctrl+L to unlock it

By default the samba client is already installed on Ubuntu, but if it is not, just install it; in terminal type:

sudo apt-get install samba


Any real-time antivirus for Ubuntu? Is there any real-time anti virus for Ubuntu? Which antivirus is good and in real-time (I mean that, if I try to open an infected file or go to a bad website, it stops it).
I read a post in ubuntuguide and here is a part of it:
 Anti-virus

If you are running a file server, interface frequently with Windows drives or share files with Windows users, or use virtualization, you will want a virus checker for your Windows files.

Despite extensive misinformation, Linux is not immune from malware (witness the explosion of malware being created for the Linux-based Google Android systems). The malware is not usually spread within the OS itself (as long as the OS is a well-respected distribution obtained through official channels), but in trojan programs downloaded and installed by users outside of the normal software distribution channels (i.e. repositories) of the OS. There is always a danger to using programs downloaded from the Internet from sources other than respected repositories -- it is the primary reason that Debian and (K)Ubuntu retain tight control over their software repositories.

Any file can have malware embedded in it (which is trivial to achieve by concatenation, for example: cat originalfile.avi malware.exe > originalfileplusmalware.avi). The question is whether a user will try to open a file with a program (such as a media player) that has been compromised in a way that allows it to execute the code found in the infected media (e.g. .avi) file. This can occur not only for Windows users but for any OS (including Mac OSX and Linux) with a compromised program (e.g. media player). An example is the extensive problems the Mac OS community is currently having with the Flash player.

Routine scanning of any file downloaded from the Internet, any file imported from another user's computer (even a trusted source, since their attention to virus prevention may not be as compulsive as yours), or any attachment received in an email (even from a trusted sender) should be done with an anti-virus program. So I think that there is a need for anti-virus in Ubuntu.

As others have noted, you probably do not need it. However, comodo, kaspersky and few others offer real-time antivirus protection

Not sure but Avast might (it does in Windows)
How to Ubuntu
Also you can use Firefox and install the extension 'WOT'.  It's not an anti-virus but it will warn you about potential attack sites you might click on.


Very small sized ubuntu distro I want to create a very small sized ubuntu VM, preferably under 1 GB (500 to 700 MB). What is the way to create the smallest distro?

I tried minimal ubuntu but after installing it was also about 1.5 GB.

To put it simply, there's no Ubuntu or Debian based distro that will fit the size requirements you're stating.  Not even headless.

Your closest bet is Damn Small Linux which is a very TINY linux distro.  However, it is not Ubuntu nor Debian based, to my knowledge.

If your intent is to have Ubuntu or Debian, have your VM provision 10GB max for the virtual disk, and let it expand in size as needed - this will give it ample 'space' from the Linux point of view, but it will take at most 10GB + amount of vRAM you assign when you save the system.

U can check them out in this website "distrowatch.com".
You can create a very small sized distro just by removing all things which you think you don't need, while you do have that option while you were installing that kernel.


How to launch an application on a specific desktop from command line? The title says it all. I usually have a console window on my Desktop 1; I would like to be able to launch from there any application specifying on which Desktop the application window should appear. For example, from my console window on Desktop 1. I would like to launch thunderbird in such a way that its window opens on Desktop 2. Is this possible? (I'm running kubuntu 9.04)

Here are a few options.

Devil's Pie

Here's an old tutorial.

wmctrl

You can make a script to move to the desired workspace and then launch your app (source):

#!/bin/bash
wmctrl -s 1
firefox --new-tab $@ &

Or you could launch your app and then move it. I think something like this would work:

#!/bin/bash
thunderbird &
wmctrl -r :ACTIVE: -t 1
# if thunderbird takes a while to launch, you may need to find the window yourself:
#wmctrl -r `wmctrl -l | grep [t]hunderbird | cut -f1` -t 1

Compiz Place plugin

You can enable and configure this if you install compizconfig-settings-manager .

Allows you to set fixed positions for windows with specific titles.

FYI, previously I used wmctrl in Gnome. Some of its features don't work for me in 11.04 w/ Unity, but should be good in 9.04. Not sure about KDE though.

I am now using xmonad: I can easily move windows to any screen/desktop using keyboard.


How to disable mounting of external drive at boot? Okay so I'm not exactly sure how it happened, but recently Ubuntu has been trying to mount an external hard drive that I usually have plugged in during boot. A message comes up during boot asking me to either wait, or press S to skip if the drive isn't plugged in when I start up my laptop.

My question is, how do I disable this drive from mounting at startup so I don't have to prompt Ubuntu to skip it at boot? I've looked up a couple other solutions to this, but all of them only seem to completely disable automounting, which would require me to manually mount the device when it's plugged in, which is not what I want. I just want to disable it from mounting at startup.

If there is a line in /etc/fstab related to that drive, remove it.

The file is read only for all users other that root.

To edit it use the command gksu gedit /etc/fstab, but make a copy of the file before editing, and do not touch nothing other than removing that line.

It is not possible to prevent Ubuntu 11.10 from automounting media when it is plugged in or on booting. Neither of the above solutions work. Simply look in /media for all the automounted devices after trying the above solutions.


window title bars are not displaying correctly 13.10 when laptop plugged in )

As you can see the window title bars are completely messed up (partly transparent or white) when they should be all grey according to the ambiance theme when plugged in. And the weird thing is it seems to almost completely go back to normal when I unplug my laptop. I say almost because if you look closely at the window edges, you can see there is a boarder of pixels around each window doing weird things...

I do have laptop-mode-tools installed and I realize that is probably why things change when unplugged. But when I uninstalled laptop_mode the titles were just messed up all the time and never went back to normal at all.

Also it is only ambiance and radiance themes that are being messed up. High contrast and Adwaita are normal.

Turns out it must have been a bug with the opensource drivers in the oibaf ppa because it fixed itself today after updating.

In 13.10, you can run unity --replace from a terminal to restart Unity, hopefully getting rid of any errors.

Note that unity --reset is not a valid command anymore (as far as I know).


problem with Dolphin I am using kde neaon plasma 5
When I go to one folder in home for example : Music and then going back to first page ( home ), all folders selected. I do not know why.!!??

I will attach a pic about it.
pic 1
pic 2

If you have any Idea please inform me .
thanks

Ok This problem might be happens for KUBUNTU

So if anybody has this problem there is solution for that.

This problem will happens if you sort your folders by Rating
to solve this issue just sort them by name or something else except rating


Hibernation not working in 18.04 Linux/Ubuntu rookie here, so please be gentle :)

I've installed Ubuntu 18 in my laptop and I'm trying to configure hibernation. I've tried to follow these posts, but still without any results...

I've changed my partition so that it's 11GB (I've tried to follow what was written here):

sudo swapon --show
NAME      TYPE SIZE USED PRIO
/swapfile file   11G   0B   -2

If I try to use the pm-hibernate, nothing happens...

Looking at the logs, I can see these entries:

22:00:47 wpa_supplicant: dbus: Failed to construct signal
22:00:47 systemd: Failed to start Hibernate.
22:00:47 kernel: PM: Cannot get swap writer
22:00:42 kernel: wlp2s0: failed to remove key (2, ff:ff:ff:ff:ff:ff) from hardware (-22)
21:57:49 wpa_supplicant: dbus: Failed to construct signal
21:57:49 systemd: Failed to start Hibernate.
21:57:49 kernel: PM: Cannot get swap writer
21:57:44 kernel: wlp2s0: failed to remove key (2, ff:ff:ff:ff:ff:ff) from hardware (-22)
21:55:44 wpa_supplicant: dbus: Failed to construct signal
21:55:44 systemd: Failed to start Hibernate.
21:55:44 kernel: PM: Swap header not found!
21:55:35 kernel: wlp2s0: failed to remove key (2, ff:ff:ff:ff:ff:ff) from hardware (-22)
21:55:17 spice-vdagent: Cannot access vdagent virtio channel /dev/virtio-ports/com.redhat.spice.0
21:55:16 pulseaudio: [pulseaudio] backend-ofono.c: Failed to register as a handsfree audio agent with ofono: org.freedesktop.DBus.Error.ServiceUnknown: The name org.ofono was not provided by any .service files
21:55:10 spice-vdagent: Cannot access vdagent virtio channel /dev/virtio-ports/com.redhat.spice.0
21:55:07 wpa_supplicant: dbus: Failed to construct signal
21:55:03 kernel: [Firmware Bug]: TSC_DEADLINE disabled due to Errata; please update microcode to version: 0x25 (or later)

It's obvious there's some sort of problem when hibernation starts, but I really don't knohich the machine state is written to disk, eitw what's wrong...

Can somebody help?

Thanks.

Luis

To my information, hibernation to a swap file does not work, and might never do.

However, suspending to the swapfile usually works. The problem should usually just happen when you try to resume from it.

The file system is not mounted at the point Linux tries to find the swap to resume from, and thus will fail to do so.


Ubuntu 18.04 repeated "Anthentification required by Wireless network"? So I just installed Ubuntu 18.04 desktop alongside Windows 10.
But despite the fact that the password I typed is correct, I still get prompted by this message.

$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 0bda:b009 Realtek Semiconductor Corp.
Bus 001 Device 002: ID 05c8:03ab Cheng Uei Precision Industry Co., Ltd (Foxlink)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

$ iwconfig
lo        no wireless extensions.

wlo1      IEEE 802.11  ESSID:off/any
          Mode:Managed  Access Point: Not-Associated   Tx-Power=20 dBm
          Retry short limit:7   RTS thr=2347 B   Fragment thr:off
          Power Management:off

eno1      no wireless extensions.

$ lspci -knn | grep Net -A3; rfkill list
02:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. Device [10ec:d723]
    Subsystem: Hewlett-Packard Company Device [103c:8319]
    Kernel driver in use: rtl8723de
    Kernel modules: rtl8723de
0: hci0: Bluetooth
    Soft blocked: no
    Hard blocked: no
1: phy0: Wireless LAN
    Soft blocked: no
    Hard blocked: no

sudo nano /etc/modprobe.d/rtl8723de.conf

Copy and past this line and save and exit:

options rtl8723de fwlps=0

Reboot.

This should prevent the WiFi card from automatically sleeping and halting connection.


How can KVM be located by Android Studio on Ubuntu 14.04 LTS When running the emulator, Android Studio reports the following message:

  Please ensure KVM is properly installed and usable.

  CPU acceleration status: KVM is not installed on this machine
  (/dev/kvm is missing)

However, KVM is installed as shown by the following:

  which kvm

  /usr/bin/kvm

Thanks...

See the instructions here: https://help.ubuntu.com/community/KVM/Installation

In short:

sudo apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils
sudo adduser `id -un` libvirtd
sudo adduser `id -un` kvm

Then log out and back in again, and check that it is working by running:

virsh -c qemu:///system list

Some more instructions from Intel: https://software.intel.com/en-us/blogs/2012/03/12/how-to-start-intel-hardware-assisted-virtualization-hypervisor-on-linux-to-speed-up-intel-android-x86-emulator

I had same problem and in the end it was a BIOS issue. The problem is that you have disabled the virtualization option.

To solve it, you have to enter BIOS setup and activate this option.


Uninstalled Xubuntu desktop - now no login screen? I installed Xubuntu desktop environment but didn't like it. I found a thread which listed a large command to uninstall everything. Now when my machine boots, I get a black screen and no possibility of logging in.

How do I fix this? I don't particularly want to have to reinstall Ubuntu.

The command I entered to uninstall it was this:

sudo apt-get remove abiword abiword-common abiword-plugin-grammar abiword-plugin-mathview alacarte bison blueman brltty-x11 catfish espeak exo-utils flex fonts-droid fonts-lyx gigolo gmusicbrowser gnome-system-tools gnome-time-admin gstreamer0.10-gnomevfs gthumb gthumb-data gtk2-engines-pixbuf indicator-application-gtk2 indicator-sound-gtk2 leafpad libabiword-3.0 libbison-dev libdigest-crc-perl libexo-1-0 libexo-common libexo-helpers libfl-dev libgarcon-1-0 libgarcon-common libgdome2-0 libgdome2-cpp-smart0c2a libglade2-0 libgnomevfs2-0 libgnomevfs2-common libgnomevfs2-extra libgsf-1-114 libgsf-1-common libgstreamer-perl libgtk2-notify-perl libgtk2-trayicon-perl libgtkmathview0c2a libgtkspell0 libido-0.1-0 libindicate-gtk3 libintl-perl libjpeg-progs libjpeg-turbo-progs libkeybinder0 liblink-grammar4 libloudmouth1-0 libnet-dbus-perl liboobs-1-5 libotr2 libots0 librarian0 libsexy2 libtagc0 libthunarx-2-0 libtidy-0.99-0 libtie-ixhash-perl libtumbler-1-0 libunique-1.0-0 libvte-common libvte9 libwv-1.2-4 libxfce4ui-1-0 libxfce4ui-utils libxfce4util-bin libxfce4util-common libxfce4util6 libxfcegui4-4 libxfconf-0-2 libxml-parser-perl libxml-twig-perl libxml-xpath-perl lightdm-gtk-greeter link-grammar-dictionaries-en m4 orage parole pastebinit pavucontrol pidgin pidgin-data pidgin-libnotify pidgin-microblog pidgin-otr plymouth-theme-xubuntu-logo plymouth-theme-xubuntu-text python-configobj rarian-compat ristretto screensaver-default-images scrollkeeper shimmer-themes system-tools-backends tcl8.5 thunar thunar-archive-plugin thunar-data thunar-media-tags-plugin thunar-volman tumbler tumbler-common xbrlapi xchat xchat-common xfburn xfce-keyboard-shortcuts xfce4-appfinder xfce4-cpugraph-plugin xfce4-dict xfce4-indicator-plugin xfce4-mailwatch-plugin xfce4-netload-plugin xfce4-notes xfce4-notes-plugin xfce4-notifyd xfce4-panel xfce4-places-plugin xfce4-power-manager xfce4-power-manager-data xfce4-quicklauncher-plugin xfce4-screenshooter xfce4-session xfce4-settings xfce4-systemload-plugin xfce4-taskmanager xfce4-terminal xfce4-verve-plugin xfce4-volumed xfce4-weather-plugin xfce4-xkb-plugin xfconf xfdesktop4 xfdesktop4-data xfwm4 xscreensaver xscreensaver-data xscreensaver-gl xubuntu-artwork xubuntu-default-settings xubuntu-desktop xubuntu-docs xubuntu-icon-theme xubuntu-wallpapers && sudo apt-get install ubuntu-desktop

After getting blank screen type: ctrl +alt +f1.
Now edit your /etc/X11/default-display-manager file using by
typing: sudo vi /etc/X11/default-display-manager.
It will open file in vi editor.
Replace everything (if it contains something) with
/usr/sbin/lightdm
Press escape button and type :wq! to save change and exit.
Now restart your computer.

It should solve your problem.

I'm assuming you had installed "Xubuntu-desktop" on Ubuntu? In which case "sudo apt-get install lightdm" will re-install the Ubuntu default desktop manager. You should be able to login from the black screen, try pressing "enter" to see if it makes the text appear. If you still don't see anything then press "control + alt + F2", and then press "enter".

Lightdm = Ubuntu Desktop Manager (sudo apt-get install lightdm)

xfdesktop = Xubuntu Desktop Manager (sudo apt-get install xfdesktop4)

Gdm = Gnome Desktop Manager (sudo apt-get install gdm)

KDM = KDE Desktop Manager (sudo apt-get install kdm)


While loop help in Shell Script I am new to shell scripting so I am curious about using While Loops in Shell Script form.

I know how to declare a variable and use a while loop in java

int num = 0;
while(num <= 10)
{
    System.out.println(num)
    num = num + 1
}

But I don't know how to declare variables and use them in a while loop in a Shell Script.

There are various ways of doing this, but the shell script which most closely mirrors your Java example is this:

num=0
while test $num -le 10; do
    echo $num
    num=$((num+1))
done

A more 'shell-ish' ways to achieve the same would be

printf '%s\n' {0..9}

But note that the {0..9} construction is a 'bashism', which will not work in the standard (POSIX) shell.

This Bash Scripting site should help you, generally you don't have to declare variables before you use them:

http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO-7.html


Mount encrypted volumes from command line? If I have an encrypted external disk (or an internal disk that is not in fstab), I see an entry for it in Nautilus -- with an entry like "X GB Encrypted Volume".  I can click on this volume, and am prompted for a password to decrypt and mount the device.

But how do I do this from the command line?

This wiki page, and other docs I can find, only refer to GUI methods of decrypting the device; but this won't do in the context of headless servers or SSH logins.  Is there a simple way to get devices to mount to automatic locations in /media just like they would with the GUI?

(I'm not asking about encrypted home directories -- I'm aware of ecryptfs-mount-private.  This question is about additional encrypted volumes.)

Your volume is probably encrypted with LUKS, here's how to mount it:

You need:

sudo apt-get install cryptsetup

To decrypt the volume:

sudo cryptsetup luksOpen /dev/sda1 my_encrypted_volume

Now you can mount it as usual:

sudo mkdir /media/my_device
sudo mount /dev/mapper/my_encrypted_volume /media/my_device

To lock the container again, it needs to be unmounted first:

sudo umount /media/my_device
sudo cryptsetup luksClose my_encrypted_volume

To automatically put it in the /media location, use the udisks tool

sudo udisks --mount /dev/mapper/my_encrypted_volume

On my chromebook with (crouton) Ubuntu Xenial 16.04 I find that when I issue:

sudo cryptsetup luksOpen /dev/sda1 my_encrypted_volume

per the above posting and enter my passphrase, I get "No key available with this passphrase."  However, by accident I've found (and very strange it is!) the whole thing works when I add "--debug" to the cryptsetup command!  I am then able to mount the volume and access the files.

Asking the file manager Thunar to do the mounting results "Not authorized to perform operation." error.  I am unable to figure a way around that, but since I can do the mount at the command line, that's somewhat acceptable.


Not able to login into newly created user account I created a new user account from System Settings > User Accounts.

I can log in to new user account from the terminal but I can't log in to user account from GUI.

When I try to log in to the newly created user account from GUI it doesn't show any error and goes back to the login window. (When I type a wrong password it shows the incorrect password error but when I enter the right password, it simply goes back to the login window without any message.)

I am using Ubuntu 14.04.4 LTS

It seems like that account is disabled. Open the system settings, select the account, unlock changes. Look next to "password," and if it says "account disabled," click that and select an option. If that doesn't work, it is an issue I do not know how to fix. I was on 15.10, and all my logins broke. In that case, backup your computer, get a Live CD or USB from another computer, and reinstall Ubuntu. I had to do it. I hope it's the first.

Maybe your home directory's permission is set to root thats why it goes back to login window. I also had the same problem a while ago, i can log in  but after a seconds, it goes back to login window.

try changing your home directory using your terminal:

sudo chown -R $USER:$USER /home/user_name


Can Ubuntu be installed from a USB memory stick with bad blocks (or clusters) on it? I have spent a few days trying to install Ubuntu from a USB memory stick with at least one bad block (or Cluster) on it.

I have tried formatting it from an existing Ubuntu machine and from Windows using various means and file/system formats including Rufus.   It seems that though the formatter can be set to check the memory stick for bad blocks and exclude them, in the end the media creator still seems to write to the bad blocks blindly, creating a memory stick with corrupt data on it. I have tried this now with a couple of old memory sticks with bad blocks on them and the result is the same, regardless of what I try.

However, using a perfect USB memory stick with no bad blocks on it works first time every time.  Am I missing an option or setting somewhere? Alternatively can the formatter that detects the bad blocks be set to warn that the media will be corrupt if the creation process is continued and ask the user if they wish to continue?

I think most tools to create a USB drive assume that the USB memory stick is good. At least this is the case with mkusb (and obviously also with the tools that you have been trying to use).

1. Wipe the whole device might help if the memory cells can be re-allocated after wiping.

You could try to 'wipe the whole device' with mkusb, and after that try with your tool(s) to create a USB install system in the memory stick again. (The re-allocation process is nothing that we can manage. There is an internal processor in the USB memory stick, and it would do it automatically, if it can.)

2. ext4

An alternative is to create a partition with the ext4 file system in the memory stick, and to run the following command in linux in order to mark the bad clusters, so that the file system can avoid using them.

sudo e2fsck -cf /dev/sdxy

where x is the drive letter (a or b or c ...) and y is the partition number (1 or 2 or 3 ...). In your case it might be /dev/sdb1, the second drive's first partition. If this operation succeeds, you will get a USB memory stick, that can be used for storage by linux systems. It will also be possible to install Ubuntu into it (installed like into an internal drive). But this is not a USB install drive, that can install Ubuntu into another system.

3. NTFS

Another alternative would be to create a partition with the NTFS file system in the memory stick, and to run the following command in Windows in order to mark the bad clusters, so that the file system can avoid using them.

chkdsk /r X:

where X: is the drive letter (volume letter) for the target partition as seen from Windows. If this operation succeeds, you will get a USB memory stick, that can be used for storage by linux systems and Windows systems, but it does not help installers, that need a FAT32 file system.

4. FAT32 might fix it all the way in this particular case

Finally you can create a partition with the FAT32 file system in the memory stick, and to run the following command in Windows in order to mark the bad clusters, so that the file system can avoid using them.

chkdsk /r X:

where X: is the drive letter (volume letter) for the target partition as seen from Windows. If this operation succeeds, you will get a USB memory stick, that can be used for storage by linux systems and Windows systems, and it would help installers, that use a previously created FAT32 file system, for example Unetbootin. So this might be possible for you, if the problem is 'only' some bad sector in the USB memory stick alias pendrive.

5. See the following link for more details,

Repair the partition table and file system of a pendrive

Usually on the boot menu you can do a verification of the CD media, but I'm not sure if the USB booting gives you the same option. The installers take an all or nothing approach to the validity of the installation medium, it's either valid or not.

You may be able to get dd to do what you want by identifying the bad blocks, try this:

https://sourceforge.net/p/smartmontools/mailman/attachment/771ef40c0706252135s2ff0f76ej1c913f9cc93b601d@mail.gmail.com/1/


Is it possible to use nmcli completely without nm-applet? Since I don't use GNOME now and try wmii, the nm-applet is no longer available for me.I know there is nmcli for the control. What I'm really interested in is that can it really be a substitute for nm-applet.

man nmcli, there are these words, which makes me confused:

It is not meant as a replacement of nm-applet or other similar clients.

What does other similar clients mean?
The use case comprise:

Servers, headless machines:No GUI is available; then nmcli is used to talk directly to NetworkManager and control only system-wide connections.
User sessions: For this case, nmcli can talk to nm-applet to find user connections.It can still talk directly to NetworkManager for manipulating these connections.  As nmcli doesn't have direct access to user configuration data in GConf, nm-applet handles that itself.  That may, for example, cause the applet to pop up keyring dialogs when secrets are needed.

As nmcli can work directly without X, Why can't it work as well when secrets are needed?

PS. Is there any alternate easy approach to control connections using command line?

First of all let me say that nm-applet can be used in environments other than Gnome: I used it successfully in awesome and in openbox.

nmcli do not provide the same functionalities of nm-applet, e.g. you cannot configure new connections.

A valid alternative to connect to wired or wireless networks from command line is wicd-curses.

Yes, you can use nmcli to connect instead of nm-applet. you can totally control your network connection using command line.


Using a wifi card in virtual machine My objective is to use one of my spare wifi cards and run a virtual machine which will then control this wifi card.
I tried using virtual box for this purpose and kali linux but the only options available is to connect to a network using the host-device.
Is there any way for me to control to the wifi card directly to the virtual machine?

many virtual machine admin panels offer a way to grant a virtual machine access to physical hardware.

In kvm e.g. you can add this hardware via virtmanager to the virtual machine. So the access to this host-system's hardware is permitted to the virtual machine and you should be able to use it.

example for adding host.hardware to vm guest in virtmanager by redhat


How to check which version of KVM I am running? I have installed KVM using the instructions given on the wiki. However, when I try to check its version using

kvm --version

what I get as output is this

QEMU emulator version 1.2.0 (qemu-kvm-1.2.0+noroms-0ubuntu2.12.10.5, Debian), Copyright (c) 2003-2008 Fabrice Bellard

which I believe is QEMU's version, not KVM's.

I have tried the method given here, but this does give an output.

I wanted to know what is the correct method to get the version of KVM I am running.

Specifications:

Ubuntu 12.10
Linux 3.5.0-43-generic

The command you're looking for is:

dpkg -s qemu-kvm | grep Version

You can look up the version of any package using dpkg -s [package name]

Regarding the KVM, a quick Google search returned it is titled qemu-kvm.

Example output (if you're running Debian Jessie):

  Version: 1:2.1+dfsg-12+deb8u5a

As an FYI, the grep command is case-sensitive by default, which is important because Version is upper-case. You can use the parameter -i to ignore case.

The kvm version follows the kernel version.

uname -r

would therefore, in this case give you the correct version.

Look here for more information


How can I encrypt all data in /var/www so no one except root can access it? I have a situation that I sell my product on an virtual machine with Ubuntu installed on it and it has a LAMP on it and I do not want any one to be able to copy or access my code.

Of course I have a very secure password for the root, but this is not an issue. Bad guys mound a CD with a live Linux and boot up on my VM so they work around all the passwords and gain access to my code. That is the reason I would like to have all my files and data in the www folder to be encrypted.

If you means owner, I think you can try the chown command, also chmod. I think it will help you.


How can I install software or packages without Internet (offline)? I have a friend who has got a computer that is not connected to the Internet. Is there any way to install software offline easily?

Check out Keryx; it's an offline repository manager.

How does it work? It lets you download updates and new programs (with dependencies) to your flash drive.

Its interface is similar to synaptic, but it works from a pendrive (it doesn't need installation). Unfortunately, the GUI needs wxwidgets, which don't come preinstalled on Ubuntu (they're cross-platform and installable from here and Ubuntu repository here). It can only install software in a Ubuntu system, but you can download the updates or new packages in any Linux, Windows or OS X.

Here you can find a tutorial.

Another detailed step-by-step tutorial is in this answer.

Launchpad also hosts downloadable files.

A screenshot:

I suggest to customize Live CDs and install them.

You also can download the files on http://packages.ubuntu.com/filename, but then you have to pay attention to the dependencies, too.