fatal: no SASL authentication mechanisms - Postfix + Dovecot I am trying to configure a simple email server that uses dovecot for the auth. I am inexperienced with the email procedures and I can't figure out what the problem is here:

postfix/smtpd[26148]: fatal: no SASL authentication mechanisms

My postfix's config file:

tpd_banner = $myhostname ESMTP $mail_name (Ubuntu/GNU)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

myhostname = localhost
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = $myhostname
mynetworks = 127.0.0.0/8, 10.0.0.0/24
mailbox_size_limit = 0
home_mailbox = Maildir/
virtual_mailbox_domains = /etc/postfix/vhosts
virtual_mailbox_base = /home/vmail
virtual_mailbox_maps = hash:/etc/postfix/vmaps
virtual_minimum_uid = 1000
virtual_uid_maps = static:5000
virtual_gid_maps = static:5000
recipient_delimiter = +
inet_interfaces = all
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noplaintext,noanonymous
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth-client

My dovecot config:

auth_mechanisms = plain cram-md5
auth_verbose = yes
base_dir = /var/run/dovecot/
info_log_path = /var/log/dovecot.info
log_path = /var/log/dovecot
log_timestamp = "%Y-%m-%d %H:%M:%S "
mail_location = maildir:/home/vmail/%d/%n
passdb {
  args = /etc/dovecot/passwd
  driver = passwd-file
}
protocols = imap pop3
service auth {
  executable = /usr/lib/dovecot/auth
  user = root
}
service imap-login {
  chroot = login
  executable = /usr/lib/dovecot/imap-login
  user = dovecot
}
service imap {
  executable = /usr/lib/dovecot/imap
}
service pop3-login {
  chroot = login
  executable = /usr/lib/dovecot/pop3-login
  user = dovecot
}
service pop3 {
  executable = /usr/lib/dovecot/pop3
}
ssl = no
userdb {
  args = /etc/dovecot/users
  driver = passwd-file
}
valid_chroot_dirs = /var/spool/vmail
protocol pop3 {
  pop3_uidl_format = %08Xu%08Xv
}

What is wrong with this configuration?

I'm not sure if your socket private/auth-client exists. Try to replace with:
smtpd_sasl_path = private/auth in main.cf.

The problem was that I had to generate a TLS certificate and make dovecot and postfix use it.
The private/auth file will be generated by dovecot automatically after that.


scheduled tasks running but have disappeared I had recently installed gnome-schedule 2.1.1-4 onto my ubuntu 12.10 so that i may be able to schedule a recurrent shutdown on my laptop everyday at 1:55 pm.

After a few days when i didn't need the scheduled shutdown task any more so i wished to remove it.

Even though it still shuts down at 1:55 pm but the task isn't visible in the task  schedule window on gnome-schedule 2.1.1-4.

how do i remove this task?

I have a solution, just open your terminal, and type
"sudo gnome-schedule" I guess your scheduled task will appear :)


USB installer just exits when trying to install on a Chromebook C720 I am trying to reinstall a full (not Crouton, not ChrUbuntu) version of Linux on my C720 Acer Chromebook.

I already have Ubuntu on there, but it's having some problems, and requires a reinstall. I already have SeaBIOS (CoreBoot).

I've created a live image on a bootable USB, and managed to start the installer on my C720. But after selecting "Install", the computer just restarts. Clarification: the live distro doesn't even boot, the installer from the USB only shows its menu.

I've tried:

Ubuntu 14.10
Fedora 21

What's going on? How do I boot a live OS on C720?

(The architectures are correct, x86_64)

This seems related to this bug:https://bugzilla.redhat.com/show_bug.cgi?id=1135793

I'd keep an eye on that and see if they come up with any workarounds. In the meantime you could try booting Fedora 20 with mem=1024 kernel parameters and using that or try to upgrade to Fedora 21 from there with fedup.

How did you install it on there before?  It probably seems obvious, but maybe you could try the following?:

Boot up into the live USB
Back up any important files/data externally
Reformat the drive, so you know you're starting form a 'clean slate'.  Probably doing a thorough drive scan and system diagnostic check wouldn't be a bad idea either
Try reinstalling your OS(s)


12 Hour Time Instead Of 24 in linux I want to set my linux machine box 12 hours format,how to set it ,please advise

I am able to display with #date +%r,but wanted to set it permanently

You can set LC_TIME to a different locale. Using Date:

$ LC_TIME=en_US.UTF_8 date "+%c"
Thu 20 Aug 2015 04:28:21 PM EDT
$ LC_TIME=en_UK.UTF_8 date "+%c"
Thu Aug 20 16:28:27 2015

This can be changed permanently in etc/default/locale.

Note however that not all programs honor this setting. So it may not work system-wide. For instance the clock in the Ubuntu top menu has its own configuration for time format.


How to add existing user to an existing group? I want to add the Apache user (www-data) to the audio group. I've read the man page for useradd, but I'm not having any luck. I'm running xubuntu 11.10. Here's what I'm doing:

$ sudo useradd -G audio www-data
useradd: user 'www-data' already exists

If I leave out the -G option, bash, prints the help info for useradd:

$ sudo useradd  audio www-data
Usage: useradd [options] LOGIN
Options: -b, --base-dir BASE_DIR       base directory for the home directory...

It's not clear to me from the man page what options I should use to make this work.

The useradd command will try to add a new user. Since your user already exists this is not what you want.

Instead: To modify an existing user, like adding that user to a new group, use the usermod command.

Try this:

sudo usermod -a -G groupName userName

The -a (append) switch is essential. Otherwise, the user will be removed from any groups, not in the list.
The -G switch takes a (comma-separated) list of additional groups to assign the user to.

In general (for the GUI, or for already running processes, etc.), the user will need to log out and log back in to see their new group added. For the current shell session, you can use newgrp:

newgrp groupName

newgrp adds the group to the current shell session.

On Ubuntu, since logging in as root is not enabled, users in the sudo group can elevate privileges for certain restricted commands. Any restricted command must be prepended with sudo to elevate privilege.

sudo usermod -a -G group user

will add the existing user user to a supplemental group named group. The user's primary group will remain unchanged.


OS - Does not Show 100% HDD Capacity I am from Dell Technical Support -- One of our customers has a Dell System Model T5610 and has installed 2-256GB SSD HDD and 2- 4TB HDD and Configured RAID-0 of 2 Arrays on Intel Based Chipset (ROMB)--- 256GB HDDs is primary for OS installed Ubuntu 14.04 64bit, However when he creates RAID-0 on 2-4TB HDD Using ROMB he sees 100% HDD Capacity in RAID BIOS but in the OS he get to see only 3.2 TB Space,

If he deletes the RAID in RAID BIOS and configure the same in OS level in Ubuntu then he gets 100% Capacity---- Help appreciated, why 100% HDD Capacity is not shown in the OS when the RAID-0 is configured in RAID BIOS (ROMB)

The RAID normally done in BIOS is not full RAID, it is basically "RAID Assistance". It is there to help Windows do RAID as Windows cannot do full software RAID on it's own without some sort of hardware assistance. Linux on the other hand can do software RAID on it's own without any hardware assistance. Trying to use the "RAID Assistance" actually gets in the way and confuses the software RAID. It is generally recommended not to use this "RAID Assistance" when using Linux. (I learnt this one the hard way) As far as I can tell this "RAID Assistance" feature in BIOS's does not bring any performance advantage, it is merely a "compatibility layer" for Windows.

I think the reason for the 4TB volume only being recognized as less than 4 TB is because storage is sold on base 10 and measured in base 2 and formating takes some space. A base 2 terabyte is 1024 gigabytes, a gigabyte is 1024 megabytes and so fourth. Storage is sold in base 10 teragytes, 1TB=1000GB, 1GB=1000MB, and so fourth.so a 4TB drive is 4 X 10^12 and the os sees that as 3.637978807 * ((2^10)^4) and some of the space will be used for swap and formatting.


Why does my keyboard suddenly stop working? I have been using dual-boot on a Lenovo Flex for about 3 weeks now with Windows 8.1 and Ubuntu 14.04.
Ubuntu started getting funny with unreliable connection (Wifi was connecting but not transfering data.) the same happened with cable
3 days ago it suddenly started to work fine for 1 hour then came funny again and accompanied by my keyboard not responding.
It works when I type my login but not once I am logged in. It works when I am under a guest session and it works with Windows.
There is no difference whether I use the on board keyboard or a USB keyboard. So it's not a hardware / driver issue.
Can anyone explain?
Update:
Thanks for asking. Yes, I think the issue was raised following some update (although not immediately after) and yes, I have managed to run updates both via the updater and via the apt-get update command. Nothing changed even after reboot.
Regards
Thanks for asking and your input. Yes, I think the issue was raised following some update (although not immediately after) and yes, I have managed to run updates both via the updater and via the apt-get update command. Nothing changed even after reboot.
Replying to the question "Can you get to TTY with Ctrl+Alt+F1?"
Nope1 The only key that works is the airplane mode one which is on F7. I can get to the terminal if I have prepared what I need to type beforehand with windows or another computer / phone then saving a Gedit doc...
A question:
Would a restore be possible and if yes would it help? My data is on a separate partition which I can easily back-up via Windows. Tks
Gnome-Do is not running and impossible to copy / print-screen the list of applications to display here.
No possibility to use the terminal as Enter key does not work either...

Try this
So, to fix this, go to:

System Settings → Universal Access → Typing (tab): switch off "Slow keys"

Also switch off "Enable by Keyboard" if you want to stop it happening again.

It don't know why the login screen ignores this setting, tho.

Update

I just did this again (d'oh!) which brought me back to this answer and gave me the initiative to find out what triggered it.

Apparently, if you have Enable by keyboard on and then you hold down the Shift key for eight seconds, it will enable/disable slowkeys.

This was a new setup, and I had enabled Enable by keyboard because I wanted a way to flip between touchscreen and keyboard mode easily. Might not be worth the effort, tho!

Thanks to tudor, I guess.
All keyboards stopped working after login screen

An application seems to be messing with the keyboard. Trying to stop such an application like that (like "GNOME Do" or similar) would be my first guess.

I'm assuming this, since they keyboard works before logging in and since it works in a guest session. Also I don't think it's driver related (or graphics related), for the same reasons. So an application seems to load for this one user and mess things up.

Can you get to TTY with Ctrl+Alt+F1?


Unable to upgrade from 11.10 to 12.04? I cannot find reference to the new release (12.04) in the update manager (it was there, now no longer), while

mark@Athene:~$ sudo do-release-upgrade
Checking for a new ubuntu release
No new release found

although I am running 11.10.

Check your system with cat /etc/issue. Is it really 11.10?
Use Update Manager: update-manager -d.

This should work

open terminal by pressing Ctrl+Alt+T

type:

sudo do-upgrade-release -d


Getting error from apt-get when trying to install php5 package I am new in ubuntu and I try to run a website by my own computer but I can't install php5. When i typed:

sudo apt-get install php5

I received:

  Package php5 is not available, but is referred to by another package.
  This may mean that the package is missing, has been obsoleted, or is
  only available from another source

  E: Package 'php5' has no installation candidate

What does it mean?

php5 is actually a meta-package. You should decide, whether you want to use the php5-module for apache or install the CLI/CGI-version and use that.

I'll just assume you want to go with the first option: try apt-get install libapache2-mod-php5. If that still doesn't work, check apt-cache search php5 and see if the packages are even in there, might be some mishap in your apt repository configuration.

Note: For php7, the package name is libapache2-mod-php7.0 and NOT libapache2-mod-php7 (Ubuntu 16.04).

Maybe php has another package name? I don't know, i don't use it.

But you can try install this: http://www.apachefriends.org/en/xampp-linux.html
I use it and it works.


Ubuntu Touch (of Aquaris E4.5 Ubuntu Edition) freezes when booting up After I fully charged and rebooted my Aquaris E4.5 Ubuntu Edition, it freezed instantly. I am not able to complete any touch gesture.

pic: http://imgur.com/UuXxhOq

When I try to boot 'recovery' (Volume Up + Power), it will boot regularly without any change.

Can I reset my phone by connecting it via USB to an PC??

Yes. The standard recovery image does not permit adb access, so you need to supply one to ubuntu-device-flash which will allow adb to work. This image is a good choice:

http://people.canonical.com/~jhm/barajas/recovery.img

You can then type

ubuntu-device-flash touch --bootstrap --channel ubuntu-touch/stable/bq-aquaris.en --recovery-image recovery.img

Which will reset your phone (including a data wipe!) to factory state.

Try recovery with wipe/data factory reset option during boot before flashing device from image. I had to do this on same new phone :-(


How to install Tor with Meek support Is there any easy way to install and run tor with meek support on Ubuntu ?
https://trac.torproject.org/projects/tor/wiki/doc/meek

Beside it is possible to download the bundle archive I'm interested in a native way:
 - installing Tor is enough or I need any extra software to enable meek ?
 - how to configure torrc ?

At the moment the meek packages are landing in debian so we can expect them to arrive in ubuntu too.

UPDATE
Previous info are not working fine anymore, it looks there is now a repository for debian unstable ... so I changed my previous answer with this one:

1 Add Repository

Repository (info on the repository page).

2. Install meek-client package

sudo apt-get install meek-client

3. Update your tor configuration

Now edit you tor configuration file /etc/tor/torrc:

sudo gedit /etc/tor/torrc

Add the meek plugin to it

ClientTransportPlugin meek exec  /usr/bin/meek-client

And some meek bridges:

Bridge meek 0.0.2.0:3 url=https://az668014.vo.msecnd.net/ front=ajax.aspnetcdn.com
Bridge meek 0.0.2.0:2 url=https://d2zfqthxsdq309.cloudfront.net/ front=a0.awsstatic.com

You can install the browser bundle with meek installed here : https://trac.torproject.org/projects/tor/wiki/doc/meek
Just follow the steps :)


What should I do to avoid my roommate from changing my password through using system recovery mode .? He did this last time when I left my laptop at room. Opened the system recovery mode from advanced Ubuntu options and changed the password using 'passwd usrname ' command.Is there anything I can do for this to not happen in future.

For this user case probably the best "solution" is to re-install Ubuntu with full encryption (LUKS). This would secure the data and prevent changing the  root/users password(s).

This could be defeated with a few methods, both hardware (key loggers) and software (custom kernels), but both of those options are unlikely. The OP can assess these risks.

With the above suggestion, I agree with the advice that the ultimate solution is to prevent physical access. In general physical access is root access via any number of techniques.

Yes. Set the root password. Open a terminal, and do:

sudo passwd

Enter a password. Then the root shell in recovery mode will always ask for this password.

Note that all this is futile as he can boot into a live USB and change your password.

Ultimately, given physical access, the security battle is lost.


Is Lenovo Ideapad gamming 3 15ARH05 Support Ubuntu 18.04 Installation? Everyone
i buy lenovo idepad  gamming 3 15ARH05 but when i try to install ubuntu on this laptop it did not support ubuntu installation after that i go for some technician but they are also not able to install ubuntu or any others version on my laptop
so can anyone tell me that this model laptop support ubuntu installation

Sanjay,
This model is to new for Ubuntu  ....
for more info/details see 9to5linux[.]com/best-linux-distros-for-the-lenovo-ideapad-gaming-3-amd-gaming-laptop
Besides the touchpad also the wifi disappears


Keyboard layout reverts at every boot I am using 12.10 with Gnome 3. I changed LightDM to GDM. When I boot up keyboard layout changes to default US layout. When I add another layout to end of list at Region settings my selected layout becomes active. What should I do ?

I also have the same problem. I did a lot of research, but I have not found a solution for me. Instead, for many people, this was the solution:

Open Terminal
Type sudo vim /etc/default/keyboard
The values within the file should be as follows:

XKBMODEL="pc105"
XKBLAYOUT="it"
XKBVARIANT=""
XKBOPTIONS=""

XKBLAYOUT is the code of your keyboard layout. Type man xkeyboard-config for shows the codes for keyboard model and layout.
exit

Reboot and check. I hope this is the right solution for you too ;)

Another solution:

Open Terminal
Login with root su
Enter password of root
Update and Upgrade all with sudo apt-get update && sudo apt-get upgrade
Type the following:

apt-get install console-data
apt-get install console-setup
apt-get install console-locales
apt-get install keyboard-configuration

Reboot and recheck.


How to avoid using sudo when working in /var/www? I want to stop having to use sudo everytime I work in /var/www. How can I do that? I simply want to put all of my sites into this directory and work with them without too much pain.

Most answers here are not written with security in mind. It's good to get a feeling that running sudo each time is not very wise. If you make a typo (for example a single space in a wrong place, such as recursively deleting / var/www/dir, which means / and var/www/dir, instead of /var/www/dir—please do not attempt), you might trash your system.
Note: Starting with Apache 2.4.7 / Ubuntu 14.04, /var/www has been moved to /var/www/html Adjust the commands in this answer accordingly.
See:

Where to place my local website starting with the 2.4.7 version of apache2?

Why has the apache2 www dir been moved to /var/www/html?

Changing the default document root for HTTP server

Bad ideas:

chmod 777 (sagarchalise) - this allows anyone with access to your system write into the directories and files and thereby allowing the intruder to execute any code under the www-data user
chgrp -R www-data $HOME (cob) - this allows www-data to read or write any files in the home directory. This is not keeping the Least Privilege rule in mind
chown -R $USER:$USER /var/www (kv1dr) - unless the world has read permissions on /var/www, the webserver running under www-data will not be able to read (serve) the files. If the file is a public-accessible plain HTML document, it might not be an issue if the world can read the file. But if the file is a PHP file containing passwords, it is.

NOTE: in the below solutions, I've granted www-data write privileges. However, /usr/share/doc/base-passwd/users-and-groups.txt.gz states:

www-data
Some web servers run as www-data. Web content should not be owned by this
user, or a compromised web server would be able to rewrite a web site. Data
written out by web servers will be owned by www-data.

Where possible, do not grant write permissions to the www-data group. www-data only needs to be able to read the files so the webserver can serve it. The only case where www-data needs write permissions is for directories storing uploads and other locations which needs to be written.
Solution 1
Add yourself to the www-data group and set the setgid bit on the /var/www directory such that all newly created files inherit this group as well.
sudo gpasswd -a "$USER" www-data

Correct previously created files (assuming you to be the only user of /var/www):
sudo chown -R "$USER":www-data /var/www
find /var/www -type f -exec chmod 0660 {} \;
sudo find /var/www -type d -exec chmod 2770 {} \;

(even safer: use 640 or 2750 and manually chmod g+w file-or-dir that needs to be writable by the webserver)
Solution 2
Create a symlink for each project to your home directory. Say your project is located at ~/projects/foo and you want to have it located at /var/www/foo, run:
sudo ln -sT ~/projects/foo /var/www/foo

If your home directory has no execute bit (descend) set for other (for security reasons), change the group of it to www-data, but set the execute bit only (no read/write). Do the same for the ~/projects folder as it may contain other projects than www. (You don't need sudo if you have previously added your user to the www-data group.)
sudo chgrp www-data ~ ~/projects
chmod 710 ~ ~/projects

Set the group to www-data on ~/projects/foo and allow the webserver to read and write to files and files+directories and descend into directories:
sudo chgrp www-data ~/projects/foo
find ~/projects/foo -type f -exec chmod 660 {} \;
find ~/projects/foo -type d -exec chmod 2770 {} \;

Even safer: use 640 and 2750 by default and manually chmod files and directories that need to be writable by the webserver user. The setgid bit should be added only if you want every newly created file in ~/projects/foo to be accessible by the group.
From now on, you can access your site at http://localhost/foo and edit your project files in ~/projects/foo.
See also

Permissions issue: how can Apache access files in my Home directory?
Reasons why /var/www should not have chmod 777

You could start a www-session in a terminal by

sudo su www-data

Combined with a differently colored prompt*, to make it more obvious that it is the shell of a different user, and a policy always to put the corresponding xterm (and editor and such) on - for example - the virtual desktop 4, so that you get used to it, to avoid confusion.

*) For a differently colored prompt with a differnt character, create a file /etc/prompt like this:

# PROMPTING
#       When  executing  interactively, bash displays the primary prompt PS1 when it is ready to read a command, and the sec-
#       ondary prompt PS2 when it needs more input to complete a command.  Bash allows these prompt strings to be  customized
#       by inserting a number of backslash-escaped special characters that are decoded as follows:
#              \a     an ASCII bell character (07)
#              \d     the date in "Weekday Month Date" format (e.g., "Tue May 26")
#              \D{format}
#                     the  format is passed to strftime(3) and the result is inserted into the prompt string; an empty format
#                     results in a locale-specific time representation.  The braces are required
#              \e     an ASCII escape character (033)
#              \h     the hostname up to the first `.'
#              \H     the hostname
#              \j     the number of jobs currently managed by the shell
#              \l     the basename of the shell's terminal device name
#              \n     newline
#              \r     carriage return
#              \s     the name of the shell, the basename of $0 (the portion following the final slash)
#              \t     the current time in 24-hour HH:MM:SS format
#              \T     the current time in 12-hour HH:MM:SS format
#              \@     the current time in 12-hour am/pm format
#              \A     the current time in 24-hour HH:MM format
#              \u     the username of the current user
#              \v     the version of bash (e.g., 2.00)
#              \V     the release of bash, version + patchelvel (e.g., 2.00.0)
#              \w     the current working directory
#              \W     the basename of the current working directory
#              \!     the history number of this command
#              \#     the command number of this command
#              \$     if the effective UID is 0, a #, otherwise a $
#              \nnn   the character corresponding to the octal number nnn
#              \\     a backslash
#              \[     begin a sequence of non-printing characters, which could be used to embed a terminal  control  sequence
#                     into the prompt
#              \]     end a sequence of non-printing characters
#
#       The  command  number and the history number are usually different: the history number of a command is its position in
#       the history list, which may include commands restored from the history file (see HISTORY below),  while  the  command
#       number  is  the  position in the sequence of commands executed during the current shell session.  After the string is
#
# colors:
# \[...\]   wird benötigt, damit die shell weiß, daß hier kein printable output ist, und die Umbrüche richtig plaziert.
#
# ANSI COLORS
CRE="\[
[K\]"
NORMAL="\[[0;39m\]"
# RED: Failure or error message
RED="\[[1;31m\]"
# GREEN: Success message
GREEN="\[[1;32m\]"
# YELLOW: Descriptions
YELLOW="\[[1;33m\]"
# BLUE: System messages
BLUE="\[[1;34m\]"
# MAGENTA: Found devices or drivers
MAGENTA="\[[1;35m\]"
# CYAN: Questions
CYAN="\[[1;36m\]"
# BOLD WHITE: Hint
WHITE="\[[1;37m\]"
#
# default:
# postgres, oracle, www-data
#
# PS1=$BLUE"machine]->"$NORMAL\\w"$BLUE ø $NORMAL"
PS1=$BLUE"machine]:"$NORMAL\\w"$BLUE > $NORMAL"
#
# root, stefan:
#
case "$UID" in
    '0')
        PS1=$RED"machine:"$NORMAL\\w"$RED # $NORMAL"
    ;;
    '1000')
    PS1=$GREEN"machine:"$BLUE\\w$YELLOW" > "$NORMAL
    ;;
#    default)
#    ;;
esac

and source it from /etc/bash.bashrc for instance.

As additional tool to help distinction, you could always edit your files with an alias 'edit' or a symlink, which points, depending on your identity (taylor/www-data) to either gedit or mousepad, vim or pico. Or you could use different editor profiles, at least in gedit you may set your preferences to black text on white ground or white text on black ground for instance.

I only have such a policy for working as root, so I'm not sure how good it will fit to working with www-data. Combined with ssh-sessions to differnt hosts, which have their own prompts, it didn't stop me from being sometimes wrong, but if it happens, I realize fast, what is wrong, and it happens rarely.

note: The prompt-script is partly a copy of the manpage of bash.


Do I need to install a package (openSWAN or strongSWAN maybe) to use ipsec? I want to connect to a windows share that only accepts ipsec transport mode. I have a list of security policies and a shared secret. I've skimmed through the man page on ipsec.conf on the web and it seems to be the place to put these polices. If ipsec is part of the kernel (and I think it is, I'm using Ubuntu 12.04) do I need to install some other package in order to get this working? I'm guessing it's either openSWAN or strongSWAN but don't know the difference.

Did you see this Article.It might help you.


What is the shortcut to move between two Terminator tabs? When I open Terminator, I can move two Terminator in same tab using Ctrl + Tab.

How to move between two Terminator tabs?

go to next tab: ctrl+pgdown
go to previous tab: ctrl+pgup

Key commands in Terminator

Toggle fullscreen: F11
Split terminals horizontally: Ctrl + Shift + O
Split terminals vertically: Ctrl + Shift + E
Close current Panel: Ctrl + Shift + W
Open new tab: Ctrl + Shift + T
Move to the terminal above the current one: Alt + ↑
Move to the terminal below the current one: Alt + ↓
Move to the terminal left of the current one: Alt + ←
Move to the terminal right of the current one: Alt + →

This maybe useful.

Use the shortcut Ctrl+Alt+PgDown or PgUp.


Can I set up a symbolic link-esque alias from (e.g.) "mybinary dothing" to "dothing"? I have a script that takes some gene data and runs it through dozens of programs to try to tease out as much information as possible and make me some pretty reports.  However, while it seems to work under Windows fine, I can't get it working on Ubuntu 12.10.

It wants to use some software from the tigr-glimmer package, long-orfs, extract, etc. (see below), and it seems like the script provided expects them to be separate binaries.  When installed, however, they actually seem to be "sub-programs"(?) of a binary tigr-glimmer, that need to be run as tigr-glimmer long-orfs, or the like.  I attempted making an alias to turn long-orfs into tigr-glimmer long-orfs, but that seems to have no effect.

Can I somehow make a link between the two, or rather, how should I go about fixing this?  The Python script is open to me, but I would rather avoid opening that can of worms.  It seems to scan through the env. paths for a set of given strings (e.g. long-orfs...) looking for an executable file, which apparently my alias doesn't qualify as.  If I change how that works, then I'll need to change dozens of the calls strewn about several files...

I have nearly no Linux experience, so my sense of how to do this is almost certainly wrong.  Please set me straight :P

ubuntu@domU:~$ python run_antismash.py --clusterblast P115_92.gb
ERROR: Failed to locate executable for 'long-orfs'
ERROR: Failed to locate executable for 'extract'
ERROR: Failed to locate executable for 'build-icm'
ERROR: Failed to locate executable for 'glimmer3'
ERROR: Not all prerequisites met
ubuntu@domU:~$ alias long-orfs
alias long-orfs='tigr-glimmer long-orfs'
ubuntu@domU:~$ long-orfs
Starting at Fri Mar 15 22:08:17 2013

USAGE:  long-orfs [options] <sequence-file> <output-file>

Read DNA sequence [...]

For my particular case with tigr-glimmer, the individual sub-commands are actually individual binaries in /usr/lib/tigr-glimmer, so adding that to PATH should be sufficient.
More generally, making a faux binary shell script would also work, e.g.
long-orfs
#!/bin/bash
tigr-glimmer long-orfs "$@"

Add the directory it's in to the PATH envvar, or just dump it into /usr/bin or something already in PATH.

You should check the download page of the bitbucket repository.  There's a nice script (install_ubuntu.sh) for installing on ubuntu and setting up a wrapper script for antismash.

https://bitbucket.org/antismash/antismash2/downloads


how to know the exact partition of ubuntu in windows 7 How could I know which partition belongs to Ubuntu and not Windows , when I'm trying to delete the Ubuntu partition ?

Easiest solution I can think of is booting up a live cd and then loading Gnome Disks or GParted and then look at the partitions.  If you are still confused at this point you can open Nautilus and look at the contents of the partitions.  This should remove all doubt.  Now remember the size and the id of the partition along with the format structure for example /sdd/sdd1 or /sdd/sdd2 something to that effect.  Once you have these bits of information it should be easy.

Also make sure to always make a backup.  Gnome Disks makes it really easy to back up an entire drive or partition from the live cd to for example an external usb drive.

Here is a howto to make a backup
https://www.maketecheasier.com/backup-hard-drive-gnome-disk-utility/

find the partition that isn't formatted as ext4 last I checked,linux doesn't play nicely with a windows partition as "/"


VMware Player(14.1.1) segfaults on clang-built kernel and clang-built VMware kernel modules As part of my clang/LLVM experiments and explorations with different clang-built kernel versions, I tried to install VMware Player 14.1.1(x86_64) on Ubuntu 17.10 x86_64 with clang-built VMware kernel modules (vmmon and vmnet) on clang-built host kernel 4.16 (latest stable as of now).

The problem

When I installed VMware Player 14.1.1 using VMware-Player-14.1.1-7528167.x86_64.bundle. The GUI installer showed "Installation was successful...". But, when I tried to run vmplayer from command-line, it led to a segfault/crash:

Segmentation fault (core dumped)
  "$BINDIR"/vmware-modconfig --appname="VMware Player" --icon="vmware-player"

It was not clear what actually went wrong - was it some installer's internal silent failure that went unnoticed or were kernel modules not successfully built/installed/loaded, or was it some compatibility issue of VMware Player with underlying host clang-built kernel and not gcc-built kernel.

So, I manually built vmmon and vmnet from /usr/lib/vmware/modules/source/(vmmon|vmnet).tar using clang/LLVM compiler itself as the host Linux kernel 4.16.0 was clang-built as well. After successfully building it, installing it and loading them and verifying them that thay are correctly loaded (lsmod, etc), I reran the vmplayer command - it again failed with the same segfault as shown above.

$ cat /proc/version
Linux version 4.16.0 (exp@exp) (clang version 5.0.0-3 (tags/RELEASE_500/final)) #4 SMP Thu Apr 5 02:12:22 PDT 2018

$ lsmod | grep "vmnet\|vmmon"
vmnet                  53248  13
vmmon                  90112  0

$ vmplayer --version
.
.
VMware Player 14.1.1 build-7528167

$ vmplayer
+ /usr/bin/vmware-modconfig '--appname=VMware Player' --icon=vmware-player
/usr/bin/vmplayer: line 109:  1467 Segmentation fault      (core dumped) "$BINDIR"/vmware-modconfig --appname="VMware Player" --icon="vmware-player"
+ exit 1

For my earlier report on successful bringup of clang-built kernel for Ubuntu 17.10 x86_64 along with clang-built Nvidia driver (v390.25, v390.42, etc), see: How do I build a 4.15.7 kernel with LLVM/clang and a Nvidia 390.25 x86_64 driver on Ubuntu 17.10 x86_64?

Stage 1 : I tried to use gdb invidually with vmware-config/vmplayer binary to look at the failing point in their code. Running gdb on /usr/bin/vmware-config and /usr/bin/vmplayer is useless as they are just scripts and running directly on their binary counterparts: gdb --args /usr/lib/vmware/bin/vmware-modconfig --appname="VMware Player" --icon="vmware-player" and gdb /usr/lib/vmware/bin/vmplayer, didn't result in any segfault/crash either.

So, I had to invoke a gdb session as part of /usr/bin/vmware-config itself while it launches /usr/lib/vmware/bin/vmware-modconfig --appname="VMware Player" --icon="vmware-player" within itself. That worked and I saw ModConf_NewKernelInfo() within libvmware-modconfig.so was trying to get current kernel version information and while doing so or parsing the version information after getting it, it segfaulted.

$ vmplayer
GNU gdb (Ubuntu 8.0.1-0ubuntu1) 8.0.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/lib/vmware/bin/vmware-modconfig...(no debugging symbols found)...done.
(gdb) r
Starting program: /usr/lib/vmware/bin/vmware-modconfig --launcher=/usr/bin/vmware-modconfig --appname=VMware Player --icon=vmware-player
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
process 24600 is executing new program: /usr/lib/vmware/bin/appLoader
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffe4b15700 (LWP 24633)]
[New Thread 0x7fffdffff700 (LWP 24634)]

Thread 1 "vmware-modconfi" received signal SIGSEGV, Segmentation fault.
0x00007ffff73312e8 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
(gdb) bt
#0  0x00007ffff73312e8 in  () at /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007ffff674d72b in ModConf_NewKernelInfo () at /usr/lib/vmware/lib/libvmware-modconfig.so/libvmware-modconfig.so
#2  0x00007ffff6749540 in main () at /usr/lib/vmware/lib/libvmware-modconfig.so/libvmware-modconfig.so
#3  0x000055555556db6b in  ()
#4  0x0000555555569fd7 in main ()

Stage 2: I used strace on vmware-modconfig to get further in the direction of the kernel version retrieval/parsing which is resulting in crash. It turned out that, the above crash is likely related to parsing of the content of /proc/version.

$ strace /usr/bin/vmware-modconfig --appname="VMware Player" --icon="vmware-player" 2>&1 | tail
write(10, "2018-04-07T00:16:17.901-07:00| v"..., 89) = 89
openat(AT_FDCWD, "/proc/version", O_RDONLY) = 11
fstat(11, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
fcntl(11, F_GETFL)                      = 0x8000 (flags O_RDONLY|O_LARGEFILE)
fstat(11, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(11, "Linux version 4.16.0 (exp@exp) (clan"..., 4096) = 111
read(11, "", 3072)                      = 0
close(11)                               = 0
--- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=NULL} ---
+++ killed by SIGSEGV (core dumped) +++

$ cat /tmp/vmware-g/vmware-17594.log
2018-04-07T00:16:17.768-07:00| vthread-1| I125: Log for VMware Workstation pid=17594 version=14.1.1 build=build-7528167 option=Release
2018-04-07T00:16:17.768-07:00| vthread-1| I125: The process is 64-bit.
2018-04-07T00:16:17.768-07:00| vthread-1| I125: Host codepage=UTF-8 encoding=UTF-8
2018-04-07T00:16:17.768-07:00| vthread-1| I125: Host is Linux 4.16.0 Ubuntu 17.10
2018-04-07T00:16:17.768-07:00| vthread-1| I125: DictionaryLoad: Cannot open file "/usr/lib/vmware/settings": No such file or directory.
2018-04-07T00:16:17.768-07:00| vthread-1| I125: [msg.dictionary.load.openFailed] Cannot open file "/usr/lib/vmware/settings": No such file or directory.
2018-04-07T00:16:17.768-07:00| vthread-1| I125: PREF Optional preferences file not found at /usr/lib/vmware/settings. Using default values.
2018-04-07T00:16:17.768-07:00| vthread-1| I125: DictionaryLoad: Cannot open file "/home/g/.vmware/config": No such file or directory.
2018-04-07T00:16:17.768-07:00| vthread-1| I125: [msg.dictionary.load.openFailed] Cannot open file "/home/g/.vmware/config": No such file or directory.
2018-04-07T00:16:17.768-07:00| vthread-1| I125: PREF Optional preferences file not found at /home/g/.vmware/config. Using default values.
2018-04-07T00:16:17.813-07:00| vthread-1| W115: Logging to /tmp/vmware-g/vmware-17594.log
2018-04-07T00:16:17.901-07:00| vthread-1| I125: Obtaining info using the running kernel.

Stage 3: After looking at the strace and gdb specific information from the above stages, I thought of running the usually suggested vmware-modconfig --console --install-all to fix any VMware kernel modules issue, since I didn't have the source code of /usr/lib/vmware/lib/libvmware-modconfig.so/libvmware-modconfig.so to debug further for finding what's with the kernel version information(/proc/version, etc) determining and parsing method within ModConf_NewKernelInfo() of libvmware-modconfig.so. It also segfaulted as I expected since it involves the same vmware-modconfig*.

$ sudo vmware-modconfig --console --install-all
[AppLoader] GLib does not have GSettings support.
Segmentation fault

Stage 4: Going one step further, I spent time on the output of cat /proc/version - one thing that I paid attention to was the compiler information of the compiler used to build kernel. That was the hitting-the-nail-on-its-head moment! I understood that VMware Player config/scripts probably assumes underlying host Linux kernel is built using some gcc-* version compiler and expects the output of cat /proc/version to have some gcc ... and if it doesn't find that (in this case, it's clang... as that's the compiler used for building host kernel), it doesn't seem to report any error/warning and simply segfaults - probably due to a NULL(from substring search on output of cat /proc/version for gcc...) dereference.

Below is what seems to be happening within vmware-modconfig and/or internal programs/scripts:

## My visualization of crash(SIGSEGV) case when compiler used to build kernel is clang-*/LLVM :
##
## == Likely a dereferencing of NULL similar to the below case ==

const char *gcc_ver = strstr("Linux version 4.16.0 (exp@exp) (clang version 5.0.0-3 (tags/RELEASE_500/final)) #4 SMP Thu Apr 5 02:12:22 PDT 2018", "gcc...");
if (strcmp(gcc_ver, "gcc...") == 0) { // Here, there's no check on gcc_ver to be
                                       // non-NULL - since it's likely that the compiler used to build the kernel
                       // is *assumed* to be always some gcc and so on. Probably, it's not designed to work
                       // work with clang/LLVM if the compiler used to build kernel is clang/LLVM.
         .
         .
         .
         .
}

##
##  My visualization of working case when compiler used to build kernel is gcc-* :
##

const char *gcc_ver = strstr("Linux version 4.16.0 (exp@exp) (gcc version 7.3.0 (Ubuntu 7.3.0-8ubuntu3)) #4 SMP Thu Apr 5 02:12:22 PDT 2018", "gcc...");
if (strcmp(gcc_ver, "gcc...") == 0) { // Works as always
         .
         .
         .
         .
}

Stage 6 : For the sake of VMware Player configuration script check, modified linux-4.16/fs/proc/version.c to report GCC 7.3.0 on a *need* basis, as the Linux compiler used to build the current kernel(4.16) instead of the actual clang/LLVM compiler used in building the current kernel(4.16). This took past the vmplayer invocation past the point where it would segfault, otherwise since the compiler information in /proc/version not being gcc-specific but clang-specific! This confirmed that my understanding and interpretation of VMware Player config/script being incapable of correctly translating the clang-compiler information in /proc/version into the actual clang/LLVM compiler used to build the underlying host kernel and hence the unexpected SIGSEGV/segfault.

$ eclang /lib/modules/4.16.0/build/vmlinux | head -1
++ strings -a /lib/modules/4.16.0/build/vmlinux
++ grep 'clang version'
Linux version 4.16.0 (exp@exp) (clang version 5.0.0-3 (tags/RELEASE_500/final)) #4 SMP Thu Apr 5 02:12:22 PDT 2018

$ egcc /lib/modules/4.16.0/build/vmlinux
++ strings -a /lib/modules/4.16.0/build/vmlinux
++ grep 'GCC: ('

###
### [procfs] - version logic updated.
###

$ cat /proc/version
Linux version 4.16.0 (exp@exp) (gcc version 7.3.0 (Ubuntu 7.3.0-8ubuntu3)) #4 SMP Thu Apr 5 02:12:22 PDT 2018

$ strace /usr/bin/vmware-modconfig --appname="VMware Player" --icon="vmware-player" 2>&1 | grep -A 40 -B 1 "/proc/version"
write(10, "2018-04-07T00:37:09.944-07:00| v"..., 89) = 89
openat(AT_FDCWD, "/proc/version", O_RDONLY) = 11
fstat(11, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
fcntl(11, F_GETFL)                      = 0x8000 (flags O_RDONLY|O_LARGEFILE)
fstat(11, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(11, "Linux version 4.16.0 (exp@exp) (gcc "..., 4096) = 106
read(11, "", 3072)                      = 0
close(11)                               = 0
write(10, "2018-04-07T00:37:09.944-07:00| v"..., 71) = 71
access("/sbin/gcc-7.3", X_OK)           = -1 ENOENT (No such file or directory)
access("/home/g/CodeSourcery/Sourcery_G++_Lite/bin/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/home/g/bin/gcc-7.3", X_OK)     = -1 ENOENT (No such file or directory)
access("/home/g/.local/bin/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/usr/local/sbin/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/usr/local/bin/gcc-7.3", X_OK)  = -1 ENOENT (No such file or directory)
access("/usr/sbin/gcc-7.3", X_OK)       = -1 ENOENT (No such file or directory)
access("/usr/bin/gcc-7.3", X_OK)        = -1 ENOENT (No such file or directory)
access("/sbin/gcc-7.3", X_OK)           = -1 ENOENT (No such file or directory)
access("/bin/gcc-7.3", X_OK)            = -1 ENOENT (No such file or directory)
access("/usr/games/gcc-7.3", X_OK)      = -1 ENOENT (No such file or directory)
access("/usr/local/games/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/snap/bin/gcc-7.3", X_OK)       = -1 ENOENT (No such file or directory)
access("/usr/lib/jvm/java-8-oracle/bin/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/usr/lib/jvm/java-8-oracle/db/bin/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/usr/lib/jvm/java-8-oracle/jre/bin/gcc-7.3", X_OK) = -1 ENOENT (No such file or directory)
access("/sbin/gcc-7", X_OK)             = -1 ENOENT (No such file or directory)
access("/home/g/CodeSourcery/Sourcery_G++_Lite/bin/gcc-7", X_OK) = -1 ENOENT (No such file or directory)
access("/home/g/bin/gcc-7", X_OK)       = -1 ENOENT (No such file or directory)
access("/home/g/.local/bin/gcc-7", X_OK) = -1 ENOENT (No such file or directory)
access("/usr/local/sbin/gcc-7", X_OK)   = -1 ENOENT (No such file or directory)
access("/usr/local/bin/gcc-7", X_OK)    = -1 ENOENT (No such file or directory)
access("/usr/sbin/gcc-7", X_OK)         = -1 ENOENT (No such file or directory)
access("/usr/bin/gcc-7", X_OK)          = 0
getuid()                                = 1000
stat("/usr/bin/gcc-7", {st_mode=S_IFREG|0755, st_size=287, ...}) = 0
access("/usr/bin/gcc-7", X_OK)          = 0
getuid()                                = 1000
write(10, "2018-04-07T00:37:09.944-07:00| v"..., 119) = 119

Stage 6: With the above update to /proc/version(fs/proc/version.c) to show gcc-* on a *need* basis, vmplayer would no longer segfault/crash - but, was using gcc(7.3.0) to build VMware kernel modules(vmnet and vmmon) which was of course "expected" as that was what was in /proc/version - I did not want this - I wanted clang/LLVM to be used for building VMware kernel modules like I have done the same for other kernel modules (Nvidia driver, VirtualBox, etc) that are working without any issues. Simply put, I want both underlying kernel and all the kernel modules to be built by clang/LLVM and not gcc.

I observed that the VMware configuration script performs a preprocessor check with the determined compiler (gcc-7.3.0 in this case) And that command looks like:

/usr/bin/gcc-7 -E -I/lib/modules/4.16.0/build/include - ....

Once that's complete and succeeds, it moves onto check if it's needed to build VMware kernel modules - vmnet and vmmon.

Stage 7: Manually the VMware kernel modules(from source : vmmon.tar and vmnet.tar) can be built with clang/LLVM and I have built them(with any needed patches for hostif.c (vmmon-only) and bridge.c (vmnet-only), installed, and used it without any issues by invoking /usr/lib/vmware/bin/vmplayer directly. But, when invoking VMware player by just vmplayer or by clicking on VMware Player icon from app menu/list, vmware-modconfig performs the checks on the compiler and its version used to build the current kernel and then checks if VMware kernel modules are built and loaded, before launching finally vmplayer. And the compiler-check that vmware-modconfig does, doesn't seem to work if the compiler(as shown by /proc/version) is clang/LLVM instead of gcc as shown above.

$ ~/vmware_modules_compiler.sh
++ eclang /lib/modules/4.16.0/misc/vmmon.ko
++ head -1
+++ strings -a /lib/modules/4.16.0/misc/vmmon.ko
+++ grep 'clang version'
clang version 5.0.0-3 (tags/RELEASE_500/final)
++ eclang /lib/modules/4.16.0/misc/vmnet.ko
++ head -1
+++ strings -a /lib/modules/4.16.0/misc/vmnet.ko
+++ grep 'clang version'
clang version 5.0.0-3 (tags/RELEASE_500/final)

$ ~/vmware_modules_metadata.sh
++ strings -a /lib/modules/4.16.0/misc/vmnet.ko
++ grep VMware
author=VMware, Inc.
description=VMware Virtual Networking Driver.
++ strings -a /lib/modules/4.16.0/misc/vmmon.ko
++ grep VMware
author=VMware, Inc.
description=VMware Virtual Machine Monitor.

$ lsmod | grep "vmnet\|vmmon"
vmnet                  53248  13
vmmon                  90112  0

Stage 8: With the above understanding how VMware config/script performs initial preprocessor check with the compiler determined to be gcc-7(.3.0) and how subsequent invocations happen for building the VMware kernel modules, I worked upon the compiler invocation logic for both the instances by vmware-modconfig script/program :

First to perform "preprocessor check" with the actual gcc (7.3.0) compiler itself.
Second and for all the subsequent invocation of compiler with clang/LLVM instead of gcc 7.3.0 - to have VMware kernel modules to be built with clang/LLVM itself like the underlying host kernel.

Stage 9: With that, I was able to completely automate the whole VMware Player installation, first invocation, configuration, and overall setup with clang-built (via installer itself) VMware kernel modules on underlying host clang-built Linux 4.16.0 kernel.

## Compact log of VMware kernel modules built using clang/LLVM instead of gcc, automatically by vmware-* config/scripts
##

## NOTE : Needed to run "vmplayer" as root(sudo) for (only) the first time for building kernel modules and install them.
## Normal user mode didn't go beyond the start of "VMware kernel modules build..." step.

$ sudo vmplayer
Stopping VMware services:
   VMware Authentication Daemon                                        done
   VM communication interface socket family                            done
   Virtual machine communication interface                             done
   Virtual machine monitor                                             done
   Blocking file system                                                done
make: Entering directory '/tmp/modconfig-sImz9k/vmmon-only'
Using kernel build system.
/usr/bin/make -C /lib/modules/4.16.0/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/media/exp/ext/linux-4.16'
+ /usr/bin/clang -print-file-name=include
  CC [M]  /tmp/modconfig-sImz9k/vmmon-only/linux/driverLog.o
    .
    .
++ /usr/bin/clang -Wp,-MD,/tmp/modconfig-sImz9k/vmmon-only/linux/.hostif.o.d -nostdinc -isystem /usr/lib/llvm-5.0/lib/clang/5.0.0/include -I./arch/x86/include -I./arch/x86/include/generated -I./include -I./arch/x86/include/uapi -I./arch/x86/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -DCONFIG_CC_STACKPROTECTOR -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -fno-PIE -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m64 -mno-80387 -mstack-alignment=8 -mtune=generic -mno-red-zone -mcmodel=kernel -funit-at-a-time -DCONFIG_X86_X32_ABI -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_FXSAVEQ=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -O2 -Wframe-larger-than=1024 -fstack-protector-strong -Wno-unused-const-variable -g -gdwarf-4 -pg -mfentry -DCC_USING_FENTRY -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fno-merge-all-constants -fno-stack-check -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -Wall -Wstrict-prototypes -DVMW_USING_KBUILD -DVMMON -DVMCORE -I/tmp/modconfig-sImz9k/vmmon-only/./include -I/tmp/modconfig-sImz9k/vmmon-only/./common -I/tmp/modconfig-sImz9k/vmmon-only/./linux -I/tmp/modconfig-sImz9k/vmmon-only/./vmcore -DMODULE '-DKBUILD_BASENAME="hostif"' '-DKBUILD_MODNAME="vmmon"' -c -o /tmp/modconfig-sImz9k/vmmon-only/linux/.tmp_hostif.o /tmp/modconfig-sImz9k/vmmon-only/linux/hostif.c
    .
    .
    .
    .
    .
    .
 LD [M]  /tmp/modconfig-sImz9k/vmmon-only/vmmon.ko
make[1]: Leaving directory '/media/exp/ext/linux-4.16'
/usr/bin/make -C $PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= postbuild
make[1]: Entering directory '/tmp/modconfig-sImz9k/vmmon-only'
make[1]: 'postbuild' is up to date.
make[1]: Leaving directory '/tmp/modconfig-sImz9k/vmmon-only'
cp -f vmmon.ko ./../vmmon.o
make: Leaving directory '/tmp/modconfig-sImz9k/vmmon-only'
make: Entering directory '/tmp/modconfig-sImz9k/vmnet-only'
Using kernel build system.
/usr/bin/make -C /lib/modules/4.16.0/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/media/exp/ext/linux-4.16'
+ /usr/bin/clang -print-file-name=include
  CC [M]  /tmp/modconfig-sImz9k/vmnet-only/driver.o
    .
    .
    .
++ /usr/bin/clang -Wp,-MD,/tmp/modconfig-sImz9k/vmnet-only/.bridge.o.d -nostdinc -isystem /usr/lib/llvm-5.0/lib/clang/5.0.0/include -I./arch/x86/include -I./arch/x86/include/generated -I./include -I./arch/x86/include/uapi -I./arch/x86/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -DCONFIG_CC_STACKPROTECTOR -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -fno-PIE -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m64 -mno-80387 -mstack-alignment=8 -mtune=generic -mno-red-zone -mcmodel=kernel -funit-at-a-time -DCONFIG_X86_X32_ABI -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_FXSAVEQ=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -O2 -Wframe-larger-than=1024 -fstack-protector-strong -Wno-unused-const-variable -g -gdwarf-4 -pg -mfentry -DCC_USING_FENTRY -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fno-merge-all-constants -fno-stack-check -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -Wall -Wstrict-prototypes -DVMW_USING_KBUILD -I/tmp/modconfig-sImz9k/vmnet-only/. -DVMW_NETIF_TRANS_UPDATE -DMODULE '-DKBUILD_BASENAME="bridge"' '-DKBUILD_MODNAME="vmnet"' -c -o /tmp/modconfig-sImz9k/vmnet-only/.tmp_bridge.o /tmp/modconfig-sImz9k/vmnet-only/bridge.c
    .
    .
    .
    .
    .
    .
  LD [M]  /tmp/modconfig-sImz9k/vmnet-only/vmnet.ko
make[1]: Leaving directory '/media/exp/ext/linux-4.16'
/usr/bin/make -C $PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= postbuild
make[1]: Entering directory '/tmp/modconfig-sImz9k/vmnet-only'
make[1]: 'postbuild' is up to date.
make[1]: Leaving directory '/tmp/modconfig-sImz9k/vmnet-only'
cp -f vmnet.ko ./../vmnet.o
make: Leaving directory '/tmp/modconfig-sImz9k/vmnet-only'
Starting VMware services:
   Virtual machine monitor                                             done
   Virtual machine communication interface                             done
   VM communication interface socket family                            done
   Blocking file system                                                done
   Virtual ethernet                                                    done
   VMware Authentication Daemon                                        done
   Shared Memory Available                                             done
.
.

$  ls -lrt /lib/modules/4.16.0/misc/vm*.ko
-rw-r--r-- 1 root root 2597952 Apr  7 01:55 /lib/modules/4.16.0/misc/vmmon.ko
-rw-r--r-- 1 root root 2614432 Apr  7 01:55 /lib/modules/4.16.0/misc/vmnet.ko

$ ~/vmware_modules_compiler.sh
++ eclang /lib/modules/4.16.0/misc/vmmon.ko
++ head -1
+++ strings -a /lib/modules/4.16.0/misc/vmmon.ko
+++ grep 'clang version'
clang version 5.0.0-3 (tags/RELEASE_500/final)
++ eclang /lib/modules/4.16.0/misc/vmnet.ko
++ head -1
+++ strings -a /lib/modules/4.16.0/misc/vmnet.ko
+++ grep 'clang version'
clang version 5.0.0-3 (tags/RELEASE_500/final)

$ ~/vmware_modules_metadata.sh
++ strings -a /lib/modules/4.16.0/misc/vmnet.ko
++ grep VMware
author=VMware, Inc.
description=VMware Virtual Networking Driver.
++ strings -a /lib/modules/4.16.0/misc/vmmon.ko
++ grep VMware
author=VMware, Inc.
description=VMware Virtual Machine Monitor.

##
## Subsequent invocation of "vmplayer" as usual(without any root/sudo usage).
##

$ vmplayer
+ /usr/bin/vmware-modconfig '--appname=VMware Player' --icon=vmware-player
+ vmware_module_exists vmmon
+ modalias=vmmon
+ /sbin/modprobe -n vmmon
+ set +x

$ vmplayer --version
.
.
VMware Player 14.1.1 build-7528167

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 17.10
Release:    17.10
Codename:   artful

Installed VMware Player version after all of the above steps:

VMware Player guest - Ubuntu 17.10 x86_64 - Successfully running in thus installed VMware Player:


How to install downloaded scanner driver When I try to use my Epson 1630 scanner in Ubuntu 15.10, with either Scanlite or Easy Scan software, I get a message saying I need to download the driver from the Epson web site first.
The Epson web site has both tar.gz and rpm versions of the driver.
Which one should I use and how do I install it?

First download drivers from http://support.epson.net/linux/en/iscan_c.html
Extract the .tar file with - tar -zxf iscan-bundle-1.0.0.x64.deb.tar.gz
move into directory with - cd iscan-bundle-1.0.0.x64.deb/

run sudo bash install.sh

`Hope This works !

In addition to installing iscan-bundle-1.0.0.x64.deb.tar.gz you have to modify two files:

/etc/sane.d/epson2.conf
/etc/sane.d/epkowa.conf

...to modify the following line in both:

net 192.168.1.xxx ### put local printer/scanner

With this I solved the problem of not detecting the scanner.


Where can I motivate for Ubuntu support? Occasionally I find projects with limited or no Ubuntu support. As an individual with limited time, I can't do much about it except log a ticket requesting Ubuntu support (or packaging, or Unity integration, etc). Often the response is that the development team don't have Ubuntu expertise.

Is there a meaningful location to log tickets/suggestions where Canonical / the Ubuntu community (people who share the motivation and wherewithall to investigate the issue) can see it?

My understanding is that:

Logging Launchpad issues for universe packages is largely meaningless if the package maintainers/developers don't already use Launchpad.
Brainstorm didn't work out. (which means the answer may be, "there is no such place")

You know, it is actually Ubuntu's decision to build a custom DE that does not support the commonly accepted ways to create tray icons, notifications and stuff.
So it must be Ubuntu's task, not the application developer's one, to add a support for Unity to all applications that need it. So yes, the Launchpad. Don't annoy the application developers too much if, say, tray icon does not show up in Unity.


Is there a NATIVE password manager and generator for Ubuntu 16.04? I already looked for a lot of usefuls password generators, but what I want to know if this distribution has a build-in or native tool. Thanks in advance.

Edit 1: My main doubt was if there is some software already installed on Ubuntu 16.04. I already know and use Seahorse, but it doesn't generate any strong web passwords.

Of course other apps could work too, like @Gus in The Netherlands and @Ravexina recommended (indirectly) Keepass, but that is not what I am curious about

I thought there was something else there that I am missing.

I have a couple of years experience with several versions of the open-source (OSI certified) password manager KeePass on Windows and the last few weeks with the latest version on Ubuntu. I can recommend Keepass.
It is available for most other platforms (Windows and Apple devices, Android etc.) and uses the same encrypted database (so you can sync via the cloud).
See http://www.keepass.info/download.html.
For Ubuntu Keepass2 is the best version (works better than KeepassX(C) from the repository. To obtain the latest and best version of Keepass2 see http://ubuntuhandbook.org/index.php/2017/04/install-the-latest-keepass2-2-35-in-ubuntu-16-04-16-10-14-04/.
I sync my Keepass database (and Firefox browser and Thunderbird mail) between Ubuntu en Windows computers via the cloud and this works great.
If you decide to go for Keepass2, the desired user interface language file may possibly be found on: http://www.keepass.info/translations.html.
In my installation this file (after unpacking) must be placed in /usr/lib/keepass2/ where the KeePass.config.xml and KeePass.exe.config files are located.

Success,
Gus

use sudo apt install pass to install the Linux native password manager (command-line based).


How can I set a single .bashrc file for several users? during my work I need to constantly add alias commands to bashrc, most of those commands needs to be runed by other users. is there any way I could add alias commands to a bashrc from external source?

Many config files in users home directory just override/add to ones in the /etc - for example the settings for GIMP in the users home are in ~/.gimp-2.*, which adds to the system-wide config /etc/gimp/2.0.
So for ~/.bashrc, you could edit the system wide config files /etc/bash.bashrc (for functions/aliases) or /etc/profile (for environment stuff) - you can the full list from man bash:
FILES
       /bin/bash
              The bash executable
       /etc/profile
              The systemwide initialization file, executed for login shells
       /etc/bash.bash_logout
              The systemwide login shell cleanup file, executed when a login shell exits
       ~/.bash_profile
              The personal initialization file, executed for login shells
       ~/.bashrc
              The individual per-interactive-shell startup file
       ~/.bash_logout
              The individual login shell cleanup file, executed when a login shell exits
       ~/.inputrc
              Individual readline initialization file

This warning is given for a few Linux systems in the files:
# It's NOT a good idea to change this file unless you know what you
# are doing. It's much better to create a custom.sh shell script in
# /etc/profile.d/ to make custom changes to your environment, as this
# will prevent the need for merging in future updates.

So you could edit those files, you may want to back them up first (cp /etc/bash.bashrc /etc/bash.bashrc-backup for example), or create a shell script in /etc/profile.d - for example you can create one with these commands (with sudo/as root):
touch /etc/profile.d/custom.sh
chmod +x /etc/profile.d/custom.sh

Then open it with nano /etc/profile.d/custom.sh
#!/bin/sh
alias ls='ls -lah'

And check whether it works by seeing if it appears in the output of alias - Note that you may need to logout/login or reboot to see any changes (if you don't want to, running source /etc/profile after any changes might work)

I'm really new to Linux operativ system, but i did a sketch of a bash script that works to modify all the users .bashrc file and not the system file /etc/.bashrc file.

#!/bin/bash

X=$( cat etc/passwd | cut -f1 -d: ) #All-users

For X in /home/*/.bashrc ; do

echo "alias ls='ls -al'" >> $X

2>/dev/null

done

source $X

exit 0

Okay so i know that that script works, but i don't if it's fault free :)
Also u can modify it so it doesn't involves all the users, maybe u make a file for all the users that need their .bashrc file customized.


How to install MySQL 5.6? I just installed Ubuntu 12.10 (amd64), and want to install a recent version of MySQL 5.6.

If possible, I would like to install (not upgrade) it the "Debian Way' (i.e., using apt-get or dpkg).

For older releases like 12.10:

(This release is End of Lifed, consider upgrading!)

I have prepared PPA with MySQL 5.6 packages based on MySQL 5.5 Debian packages.  No guarantee that it will work right away, but I would be grateful if you can try it and report back success (or failure).

There are PPAs for MySQL 5.5 and MySQL 5.6, both with latest upstream source.

MySQL 5.5: https://launchpad.net/~ondrej/+archive/mysql-5.5

MySQL 5.6: https://launchpad.net/~ondrej/+archive/mysql-5.6

Update: The MySQL 5.6 packages failed on clean install and that has been fixed.  If you find more errors please contact me directly via launchpad, or on https://github.com/oerdnj/deb.sury.org/issues

Here you have all the instructions to install it from binaries, plus the steps to install it in /usr/bin and configure as service as you asked for...

Mysql 5.6 installation


upgraded to 12.04 now no audio over AMD HDMI I've looked this issue up a bunch, but most of the solutions are unity solutions. i am using XFCE and Can't seem to find the new ubuntu settings control panel.

I am using mythbuntu, and I upgraded from 11.10 to 12.04. Now I am not getting audio over HDMI. I'm sure it's a simple problem, but all the solutions I've looked up have not resolved it.

It's a kernel problem

Do this an the sound will come back

No sound on HDMI with Radeon driver

Are you using an nvidia video card for your HDMI output? If so, refer to this solution, it might just be a driver issue.

How do I get 1366x768 resolution working on 12.04 with nvidia GTX275

Let me know if this solves your problem.


Ubuntu on Dell Inspiron 5491 Has anyone managed to install Ubuntu 18.04 or 19.10 on Dell Inspiron 5491 2-in-1 with intel i5-10210u?

I tried the "try it without installing option" and the WiFi adapted was not detected, does the same thing happen after the installation?

Also, if you have it installed on the same computer, it would be really helpful if you could mention any problems, or things not working with Ubuntu?

Thanks,

I installed ubuntu 18.04 just to find that Ubuntu doesn't have necessary drivers to support the hardware of inspiron 5491. None of the wifi, sound, etc. works.
But manjaro is the best alternative, and I surely recommend to go for it.


How do I print a large single page in several small pages? My use case is an A3 pdf landscape sheet that I needed printed in two A4 portraits. I am using desktop ubuntu 16.04.
What I have tried
What I have managed to do is use a command-line program that helps:
Split/Tile A3 (landscape) pdf to A4 (portrait)
or
how to print a single image in the 4 corners of the paper?
Also I have found Printing a poster (over several sheets of paper) but the solution uses a GUI version of the above command line options but does not seem to work with PDF or SVG.
Another option would be the print to file option mentioned in this answer. But even though I request it to print A4 size it just prints a new PDF which is A3 size.
What I would like is to have the option in the print dialogue.
I have a feeling that if I use the right settings it should work. But for example, the following settings on Page Setup and on Page Handling:

When I click preview I see the full A3 sheet in one landscape page I still press print in the hope that it will do what I want but:
It prints only the top right corner in landscape which I do not understand the logic.
Following the comment: If the box labelled "select page size using document page size" under the Page Handling tab is un-ticked then I get half the job done: It will print only the left hand side in an A4 portrait which is what I want. But I will still be missing the right hand side.
Use cases: Printing posters A2, A1 and A0 size when you don't have access to a plotter or to check for typos, printing engineering drawings when you don't have access to A3 printer or simply ran out of A3 paper and printing large images into  parts

pdftools.PDFposter
sudo apt install pdfposter
pdfposter --help

Example, convert poster to 3x3 letter size
pdfposter -p3x3 Let my_1_large_page.pdf my_9_small_pages.pdf

This article solved my problem by recommending pdfposter.  The steps I used to posterize my image were:

Use an application (Inkscape, Gimp, etc.) to size the image to the desired size and save it to a PDF file.

Use this command to print it without further scaling:
pdfposter -s1 -mlet input.pdf output.pdf

Thanks to Hartmut Goebel (h.goebel@crazy-compilers.com) for a great utility application!


How to configure ADB access for Android devices? I'm using Ubuntu 12.10 and I have installed Android SDK, set it's path in my user .bashrc and it works.

The problem is that my phone requires adb to be ran by root for permissions, but running adb with sudo I get the following error:

sudo: adb: command not found

I tried to simply use sudo -E adb start-server, but it doesn't work. Tried to add the export path line to /root/.bashrc and (after realizing it didn't help) to /etc/bash.bashrc.

I remember I could set it on my Arch Linux, but I guess my problem now is connected to Ubuntu root account not behaving like I expect it.

What I don't understand is the following:

These don't work:

martin@alyx:~$ sudo adb devices
sudo: adb: command not found

This does (typing the full path):

martin@alyx:~$ sudo /opt/android-sdk-linux/platform-tools/adb devices
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
List of devices attached
CM7-Blade   device

This doesn't work (using -E with sudo):

martin@alyx:~$ sudo -E adb devices
sudo: adb: command not found

This works (as root):

martin@alyx:~$ sudo su
root@alyx:/home/martin# adb devices
List of devices attached
CM7-Blade   device

I'm totally confused now and I'd appreciate some clarifying on how to set a path for sudo or how else I could solve my problem.

(And please, don't say adb shouldn't be ran as root.)

Thanks in advance!

Edit:
By requiring root permissions I mean that I need them because otherwise I get:

$ adb devices
List of devices attached
????????????    no permissions

which doesn't occur as superuser. Sorry if it was misunderstanding.

Please read the following first: How do I set up Android ADB?

Configuring USB access

First, you don't need root permissions to run ADB if you have set the permissions accordingly. The AOSP site provides examples for Configuring USB Access for Pixel/Nexus devices. You can use the following scheme for non-Nexus devices:

SUBSYSTEM=="usb", ATTR{idVendor}=="xxxx", ATTR{idProduct}=="xxxx", MODE="0600", OWNER="<username>"

Vendor and product ID can be obtained by using lsusb and searching for your device. (Note: The device actually is a Galaxy Nexus.)

$ lsusb | grep -i samsung
Bus 002 Device 103: ID 04e8:6860 Samsung Electronics Co., Ltd GT-I9100 Phone [Galaxy S II]

So my /etc/udev/rules.d/51-android.rules udev rule looks like this:

# adb protocol on maguro/toro (Galaxy Nexus)
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", ATTR{idProduct}=="6860", MODE="0600", OWNER="username"

You may want to repeat this for the other phone states like fastboot if needed. To let the changes take effect either reload udev (sudo udevadm control --reload) or reboot (recommended).

Making programs available

Instead of modifying the path variable I would suggest adding a symbolic link to the executable either in ~/bin/ (user only) or in /usr/local/bin/ (system wide).

mkdir ~/bin/
ln -s /opt/android-sdk-linux/platform-tools/adb ~/bin/

Try this command: sudo tools/android update sdk --no-ui

SDK README:

  Welcome to the Android SDK!
  The Android SDK archive initially contains only the basic SDK tools. It does
  not contain an Android platform or any third-party libraries. In fact, it
  doesn't even have all the tools you need to develop an application.
  In order to start developing applications, you must install the Platform-tools
  and at least one version of the Android platform, using the SDK Manager.
  Platform-tools contains build tools that are periodically updated to support new
  features in the Android platform (which is why they are separate from basic
  SDK tools), including adb, dexdump, and others.
  To install Platform-tools, Android platforms and other add-ons, you must
  have an Internet connection, so if you plan to use the SDK while
  offline, please make sure to download the necessary components while online.
  To start the SDK Manager, please execute the program "android".
  From the command-line you can also directly trigger an update by
  executing: tools/android update sdk --no-ui


Change Icon of Wine Application in Unity Launcher I frequently run a windows program with wine. When I open this program it shows up in the unity launcher as wine instead of the actual opened program.

I have made a desktop launcher with the right icon but dragging this to the unity launcher reverts the icon back to the wineglass icon. When starting the application it's denominated as Wine Windows Program Loader instead of its actual name.

Screenshot:

Workaround on Ubuntu 12.04 LTS and up

Note
This workaround requires a working launcher for your Wine application. Here's a tutorial on how to create one. The workaround also applies to applications installed with PlayOnLinux scripts. More recent versions of PlayOnLinux automatically add the StartupWMClass line to their launcher.
Instructions
Open your .desktop launcher in your favorite text editor and append this line to the file:
StartupWMClass=application.exe

where application.exe is the base name of the executable you want to launch in Wine.
Don't use the the full path, only the base name. And make sure it's unqoted (a general rule you should follow with desktop files).
Result
Application icons and descriptions should be rendered fine now:

Source: https://bugs.launchpad.net/unity-2d/+bug/702452

Use Alacarte (the old menu editor, you might need to install it) to create an old style menu entry with an icon and a executable that launches your program. Than search for this via alt + F2 and pin it to the launcher.


Could not connect to in.archive.ubuntu.com I am new with Ubuntu, so please give detailed answers.
I want to fix this error:
Could not connect to in.archive.ubuntu.com

Each time I try to update, it shows up.
I have included the following additional packages:

packages.microsoft.com/repos/vscode
packages.microsoft.com/repos/ms-teams

Screenshot of my terminal:

Somehow I found the solution, thanks for the help though.
There are more answers for this on the original question:
Connection Refused while apt-get update ubuntu 18.04 over proxy
This solution worked for me,
The issue is that the proxy settings are not being passed to the sudo level. You are able to ping and wget stuff as a normal user since you have the http_proxy and https_proxy settings set for that current user. When you use sudo, those environment variables are not passed to the elevated user.
The solution is to use -E with sudo to pass on those environment variables to the elevated user.
For example, do the following:
sudo -E apt-get update

It should work.

Looks like you've added some "Other Software" to your apt list. A clean one looks like this:

If you've added more remove them one by one...
If that ppa is not on the list, you might change the server on the "Ubuntu Software" Tab, left of the one on the picture...
Update
It looks like that the additional packages are not responsible for the missing server. Select another server as described above..
Since I can connect to in.ubuntu.archiveyour updateserver can't


Backup ubuntu and eliminate windows Laptop is currently configured for dual boot of Ubuntu and Windows7, Windows7 was the original OS, Ubuntu 14.4 was added later. 500G harddrive has multiple partitions. VirtualBox was added under Ubuntu and has multiple VMs.

I want to eliminate the old Windows7, eliminate the harddrive multiple partitions, run Ubuntu as the single bootable OS & keep the multiple VMs under VirtualBox.

Keeping the multiple VirtualBox VMs looks doable, if complex and I have plenty of backup disk space. I would rather not re-install Ubuntu as I have been adding to it regularly but will if I have to.

Any suggestions, guidance would be helpful.

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

use

sudo cfdisk

If you dont know how to use cfdisk this might help


How can I create launcher icon for PhpStorm? I have PhpStorm on my PC, to launch it I have to go to phpstorm/bin/ and launch phpstorm.sh, how can I pin this to launcher so that I dont have to go into folders every time?

Run Tools —> Create Desktop Entry in top menu of IDE.

As of 2017-12-14, you can install PhpStorm as a snap, either from the Ubuntu Software application, or the command line.  See Install PhpStorm with Snaps for details.

This will automatically add a launcher icon to your desktop.


Sound Icon Red With Dashes Why does the sound icon turn red with dashes whenever I attempt to play something with sound?

Sound Icon With Red Dashes When Attempting to Play Something

Normal Sound Icon When Not Attempting to Play Something

The dashes are the normal indicator that you have sound muted. The red is an extra reminder that happens when you try to play sound while it's still muted.

It means sound is muted.

It is confusing that the icon sometimes appears with the dashes as illustrated above, and sometimes the normal icon, as though the sound is changing state even though the mute state is not being changed.


Disabling sudo su in Ubuntu 14.04 I need to accomplish the following things.

Disable Ubuntu user.
Disable sudo su for all users.
Each user should able to execute sudo <command>.

I have modified my sudoer file as below:

# This file MUST be edited with the 'visudo' command as root.
#
# Please consider adding local content in /etc/sudoers.d/ instead of
# directly modifying this file.
#
# See the man page for details on how to write a sudoers file.
#
Defaults        env_reset
Defaults        mail_badpass
Defaults        secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
Cmnd_Alias   NSHELLS = /bin/sh,/bin/bash
Cmnd_Alias   NSU = /bin/su
# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root    ALL=(ALL:ALL) ALL

# Members of the admin group may gain root privileges
%admin ALL=(ALL) ALL

**%sysadmins ALL=(ALL) NOPASSWD:ALL ,!NSHELLS, !NSU**

# Allow members of group sudo to execute any command
%sudo   ALL=(ALL:ALL) ALL

# See sudoers(5) for more information on "#include" directives:

Still, I can access sudo using the command:sudo sudo su

How to disable this? Any help is highly appreciated.

With respect, if you get what you ask for and somebody can run sudo <anything but su>, they can:

Run sudo bash
Run sudo -i
Create a script that does something similar (including directly running su).
Just edit the configuration with sudo visudo

The point I'm trying to make is that if you allow people to run anything (or even nearly anything), they are as good as root. There are incalculable numbers of ways they could circumvent you.

If you only want them to be able to run a finite number of commands as root, create a new group (eg semisudo) and add each command to sudoers, like so:

%semisudo    localhost=/path/to/command
%semisudo    localhost=/path/to/another/command

And then add the user to that group and kick them out of admin/sudo.

I got  work around to disable sudo sudo su . Just need to comment below line in sudoer file .

#root    ALL=(ALL:ALL) ALL

It is working for me . Thanks all for your help .


How to convert all footnotes to endnotes in LibreOffice Writer? Could somebody advise how I can convert my footnotes in LibreOffice to endnotes?

I have a few hundred, and I want to keep my continuous numbering. In LibreOffice, I know how to convert them; butm it does not keep my numbering, and it divides the notes into several sections. I found on Google that Microsoft Office converts them, but I did not find it in Libre- or OpenOffice. Also, Microsoft Word did not do that in my 2007 version.

Try going to Tools / Footnotes & Endnotes.  Select the Footnotes tab.  Change the selection from "end of page" to "end of document".  It changed all of mine in the whole document, just like I was hoping for.

If you inserted the footnotes at first, you will see the changes, just like you hope for. But if you inserted the endnotes at first, you won't do.


Computer running very slowly under 13.04 After having some bouts with windows 8 I decided to throw it out and run Ubuntu as the main operating system.

Currently I am having some problems with performance:

Even when running the simplest tasks, such as logging in to the UI or console, or running apt-get upgrade, it takes a very long time, and the CPU fan is spinning at full speed.
I run top, and the top application itself takes about 13%.
As a comparison, if I run top on a 2007 Macmini also running Ubuntu 13.04, top uses about 0,5%. Cold-boot to login-prompt GUI takes minutes, compared to about 15 seconds on Windows 7 and less than a minute on the Macmini. Starting a terminal window by ctrl-alt-t takes perhaps 20 seconds, and even editing a command line has significant delays.

Question: How do I solve this performance problem?

I have installed Ubuntu 13.04 (64 bit) on an Acer Aspire 8951G on the 120 GB SSD in ext4 format, with a 32 GB swap on an HDD.
Then, coming from a Windows environment, I started by doing an update: sudo apt-get update && apt-get upgrade. It also was very slow.
I have 32 GB RAM installed (which works in the BIOS, Windows in Ubuntu). I have the most current BIOS (1.13) I could find on the Acer support site.

If I start partedmagic from the current ultimate boot cd, there is the same performance problem.
If I try the partedmagic on another Acer I have (Acer Aspire V3-571G), there is the same performance problem.
In Windows 7 that I had installed yesterday as the main operating system, there were no performance problems.

I tried hardinfo with results hardinfo.
/var/log/syslog contains /var/log/syslog

More info 2013-05-30:

I tried Ubuntu Live USB-Stick 13.04 x86_64 on my:

Acer V3-571G (the one that was slow earlier with partedmagic) with the following hardinfo. Ubuntu was very responsive and I was happy with the performance on that computer. Here is the /var/log/syslog.

Acer Aspire 8951G (my problem-computer) with the resulting /var/log/syslog contents. I selected to try ubuntu from the stick. The system did not even get to the login screen before I gave up.

An interesting part from the end of the problem-syslog:
timeout: killing 'keymap input/event, ------ rcu_sched self-detected stall on CPU, ------ BUG: soft lockup - CPU#3 stuck for 22s!

A memory test using Memtest86+ for several hours (1 iteration) passed ok.

I tried installing bumblebee and its suggested dependencies with no noticeable change in performance.

sudo powertop --time=60 --html produces the report PowerTop.html

Edit 2013-06-06:

grep Graphics /var/log/Xorg.0.log and cat /var/log/Xorg.0.log results are at paste.ubuntu.com

i cat /proc/cpuinfo | grep "cpu MHz" and cat /proc/cpuinfo results are also at paste.ubuntu.com

I think you could have too much swap RAM configured. At a certain point, more swap RAM slows down the computer considerably. Maybe try keeping the RAM+swap to a reasonable level (not 64GB), except if you really need it.
A good alternative would be to change the swappiness (how much the computer uses SWAP) to a lower level. The following command checks your swappiness.

cat /proc/sys/vm/swappiness

Swappiness is default at 60, meaning it will use your slower hard drive instead of your faster RAM a lot of the time.
You can modify the swappiness with the next command, you will have to try around with the value a bit, maybe even set it to 0 (having 32GB of RAM is plenty):

sudo sysctl vm.swappiness=[enter value here]

However this works only for the current session. To change the swappiness on startup (when it really matters), you will have to edit a config file

gksudo gedit /etc/sysctl.conf

Find the vm.swappiness line; if none exists, add it.

vm.swappiness = [enter value here]

To use the settings without rebooting, toggle swapping

  sudo swapoff -a; sudo swapon -a

source: http://www.n00bsonubuntu.net/content/change-swappiness-settings/

You might also want to delete the partition completely using gparted (using puppy linux of which most if not all have gparted, or use gparted live pendrive/cd or using the live UBUNTU CD if you have an internet connection and install gparted) and recreate it, making sure that "align to MB" is chosen and create an EXT4 partition in the empty space.

It is possible that the installer did not align the partition to MB as what happened to me and the machine was deadly slow.  Once i did this, my machine flew.


How to back up and restore chrome in ubuntu? I back up chrome in Windows with Google Chrome Backup, That it saves a file with *.gcb format. Now, How could I restore it in ubuntu 11.10 ?

in other word: How could I back up and restore chrome in ubuntu?

One possible way to do this would be to set up Google Sign in with Chrome, this will then sync your settings inbetween your windows and ubuntu computers.

The question was edited several times, with the final result that this answer does no more answer the present question (the original was about a Windows-specific software), so please stop downvoting it.

You can't.

As you can see that is not an official tool made from Google and, more important, it is only for Windows.
So you can restore a backup done with it only on Windows (with the same program I think).

Use official guides to backup your works and understand softwares, not just some_junks_made_by_unknown_people_that_promise_to_be_the_BEST_solution.


How do I install dig? How do I install dig (the DNS lookup tool)?  I can't figure out what the package name is.

You can install it by opening a terminal and typing

sudo apt-get install dnsutils

Or via the Ubuntu Software Center by clicking bellow:

For future reference, I found this out by doing a quick search with apt-cache:

apt-cache search dns dig

And then verified with aptitude.

Another command:

apt-file search /usr/bin/dig

You should install apt-file and update it beforehand:

sudo apt-get install apt-file
sudo apt-file update


How to see time stamps in bash history? Is there any way I can see at what time the commands were executed from the bash history? We can see the order but is there any way I can get the time also?

Bottom-Line: Execution time in the Bash history

Press Ctrl+Alt+T to open a terminal, then run one of the commands below:

HISTTIMEFORMAT="%d/%m/%y %T "  # for e.g. “29/02/99 23:59:59”
HISTTIMEFORMAT="%F %T "        # for e.g. “1999-02-29 23:59:59”

To make the change permanent for the current user run:

echo 'HISTTIMEFORMAT="%d/%m/%y %T "' >> ~/.bashrc  # or respectively
echo 'HISTTIMEFORMAT="%F %T "' >> ~/.bashrc
source ~/.bashrc

To test the effects run:

history

For more info see man bash or An A-Z Index of the Bash command line for Linux.

For commands that were run before HISTTIMEFORMAT was set, the current time will be saved as the timestamp. Commands run after HISTTIMEFORMAT was set will have the proper timestamp saved.

I know, I'm answering it very late, but to do this for all the users, you can create any .sh file in /etc/profile.d and add the following line to it:

echo 'HISTTIMEFORMAT="%Y-%m-%d %T "' >> /etc/profile.d/existing-foo-file.sh

If you not logged in as root or superuser, you need to use the tee command to do this:

echo 'HISTTIMEFORMAT="%Y-%m-%d %T "' | sudo tee /etc/profile.d/mytimestamp.sh

If you want to append to any existing file, pass -a flag to tee command:

echo 'HISTTIMEFORMAT="%Y-%m-%d %T "' | sudo tee -a /etc/profile.d/mytimestamp.sh


How Do I Remove Ubuntu and Install Windows 7? I have purchased a new Dell Insperion 620S desktop. It has Ubuntu installed by default.

I want to remove Ubuntu, and install Windows 7 instead.

Please help me understand the steps to remove Ubuntu.

Format the hard drive NTFS.
Install Win 7.

Load up a Gparted live CD and format the hard drive.


Are PPAs safe to add to my system and what are some "red flags" to watch out for? I see a lot of interesting programs out there that can only be obtained by adding a "PPA" to the system but, if I'm understanding correctly, we should stay within the official "repositories" for adding software to our system.

Is there any way for a novice to know if a "PPA" is safe or if it should be avoided? What tips should the user know about when dealing with a PPA?.

PPA (Personal Package Archive) are used to include a specific software to your Ubuntu, Kubuntu or any other PPA compatible distro. The "safeness" of a PPA depends mostly on 3 things:

Who made the PPA - An official PPA from WINE or LibreOffice like ppa:libreoffice/ppa and a PPA that I created myself are not the same. You do not know me as a PPA maintainer, so the trust issue and safety is VERY low for me (Since I could have made a corrupted package, incompatible package or anything else bad), but for LibreOffice and the PPA they offer in their website, THAT gives a certain safety net to it. So depending on who made the PPA, how long he or she has been making and maintaining the PPA will influence a little bit on how safe the PPA is for you. PPA's as mentioned above in the comments are not certified by Canonical.
How many users have used the PPA - For example, I have a PPA from http://winehq.org in my personal PPA. Would you trust ME with 10 users that confirm using my PPA having 6 of them saying it sucks than to the one Scott Ritchie offers as ppa:ubuntu-wine/ppa in the official winehq website. It has thousands of users (including me) that use his PPA and trust his work. This is work that has several years behind it.
How updated the PPA is - Let us say you are using Ubuntu 10.04 or 10.10, and you want to use THAT special PPA. You find out that the last update to that PPA was 20 years ago.. O.o. The chances you have on using THAT PPA are null. Why?. Because the package dependencies that PPA needs are very old and maybe the updated ones change so much code that they wont work with the PPA and possibly break your system if you install any of the packages of that PPA to your system.

How updated a PPA influences the decision to use it if he/she wants to use THAT PPA. If not they would rather go look for another one more up to date. You do not want Banshee 0.1 or Wine 0.0.0.1 or OpenOffice 0.1 Beta Alpha Omega Thundercat Edition with the latest Ubuntu. What you want is a PPA that is updated to your current Ubuntu. Remember that a PPA mentions for what Ubuntu version is made for or multiple Ubuntu versions was made for.

As an example of this here is an image of the versions that are supported in the Wine PPA:

Here you can see that this PPA is supported since Dinosaurs.

One BAD thing about how updated a PPA is, if the PPA maintainer tends to push into the PPA the latest, greatest and cutting edge version of a specific package. The down side of this is that if you are going to test the latest of something, you ARE going to find some bugs. Try to stick with PPAs that are updated to a stable version and not a unstable, testing or dev version since it might/will contain bugs. The idea of having the latest is also to TEST and say what problems were found and solve them. An example of this are the daily Xorg PPAs and Daily Mozilla PPAs. You will get about 3 daily updates for X.org or Firefox if you get the dailies. This is because of the work the put in there and if you are using their daily PPAs it means you want to help with bug hunting or development and NOT for a production environment.

Basically stick with this 3 and you will be safe. Always look for the maker/maintainer of the PPA. Always see if many users have used it and always see how updated the PPA is. Places like OMGUbuntu, Phoronix, Slashdot, The H, WebUp8 and even here in AskUbuntu are good sources to find many users and articles talking about and recommending some PPAs that they have tested.

Stable PPA Examples - LibreOffice, OpenOffice, Banshee, Wine, Kubuntu, Ubuntu, Xubuntu, PlayDeb, GetDeb, VLC are good and safe PPAs from MY experience.

Semi Stable PPA - X-Swat PPA is a in the middle PPA between bleeding edge and stable.

Bleeding Edge PPA - Xorg-Edgers is a bleeding edge PPA although I should mention that after 12.04, this PPA has become more and more stable. I would still mark it as bleeding edge but it is stable enough for end users.

Selectable PPA - Handbrake offers here a way for the user to choose, do you want a stable version or do you want the bleeding edge (Also referred to as Snapshot) version. In this case you can select what you want to use.

Note that in the case of using for example the X-Swat ppa with the Xorg-Edgers PPA, you will get a mixed between the two (With priority towards Xorg-Edgers). This is because both are trying to include almost the same packages, so they will overwrite each other and only the most updated one will show in your repositories (Except if you manually tell it to grab the package from X-Swat).

Some PPAs might update some of your packages when you add them to your repository because they will overwrite with their own version a certain package to make the PPA software work on your system correctly. This might be some code packages, python versions, etc.. Other like the LibreOffice PPA will remove all existence of the OpenOffice from your system to install the LibreOffice packages there. Basically read what other users have commented about a specific package and also read if the package is compatible with your Ubuntu version.

As the comment below suggest by Jeremy Bicha, some bleeding edge (PPAs that stay very up to date including adding Alpha, Beta or RC quality software in the PPA) could potentially damage your whole system (In the worst case). Jeremy mentions an example of many.

When you add ppa and install a program through it.

Basically you give permission to reside that program in allowed executable area (/bin/ /sbin/ /usr/bin/).

Now if program itself is/has somehow a malware then system won't complain about it as you are the one who added ppa considering its trustworthy.

When program comes from the Ubuntu repositories they are first checked (I would like to say thoroughly but I don't know :P) so those from Ubuntu repositories are free of malware/spywares for sure.

For any other ppa its upto you/user to decide whether to trust it or no.


Any known Ubuntu issues on Acer aspire S3-391? I'm in the market for a new laptop to run Ubuntu 12.10 on -- I have my eye on a very reasonably priced Acer aspire S3-391 with a i7 chip and a hybrid drive.

Does anyone have a S3 and does it work okay... Any known issues?

I currently run Ubuntu 12.04 on a Acer Aspire One, which has constant suspend issues, so I am a little wary to go with the same manufacturer.

I am running Ubuntu 12.10. Bluetooth doesn't work for me (though other people have got it working). There are some minor issues, but they are easy to fix.

There's more information at the Linux Laptop Wiki.


do-release-upgrade stopped, and couldn't re-run I tried ubuntu upgrade from 10.04 to 10.10, and 11.04. It was successful from 10.04 to 10.10, but while upgrading from 10.10 to 11.04, I felt something wrong, and stopped it. And I tried to re-run do-release-upgrade, but failed. Here are error messages.

Checking for a new ubuntu release
/usr/lib/python2.6/dist-packages/apt/progress/old.py:134: DeprecationWarning: apt.progress.FetchProgress is deprecated.
  FetchProgress.__init__(self)
/usr/lib/python2.6/dist-packages/UpdateManager/Core/DistUpgradeFetcherCore.py:202: DeprecationWarning: apt_pkg.GetAcquire() is deprecated. Please see apt_pkg.Acquire() for the replacement.
  fetcher = apt_pkg.GetAcquire(self._progress)
/usr/lib/python2.6/dist-packages/UpdateManager/Core/DistUpgradeFetcherCore.py:205: DeprecationWarning: apt_pkg.GetPkgAcqFile() is deprecated. Please see apt_pkg.AcquireFile() for the replacement
  af = apt_pkg.GetPkgAcqFile(fetcher,uri, descr=_("Upgrade tool signature"))
/usr/lib/python2.6/dist-packages/UpdateManager/Core/DistUpgradeFetcherCore.py:208: DeprecationWarning: apt_pkg.GetPkgAcqFile() is deprecated. Please see apt_pkg.AcquireFile() for the replacement
  af = apt_pkg.GetPkgAcqFile(fetcher,self.uri, descr=_("Upgrade tool"))
/usr/lib/python2.6/dist-packages/UpdateManager/Core/DistUpgradeFetcherCore.py:209: DeprecationWarning: Attribute 'Run' of the 'apt_pkg.Acquire' object is deprecated, use 'run' instead.
  if fetcher.Run() != fetcher.ResultContinue:
Failed Upgrade tool signature
Failed Upgrade tool
Done downloading
Failed to fetch
Fetching the upgrade failed. There may be a network problem.

Is there any way to re-run do-release-upgrade, or reset upgrade status?

Try running sudo dpkg --configure -a to clean up partially installed stuff, followed by apt-get update then apt-get upgrade.

This page - ubuntu site -  says you can upgrade from 10.10 to 11.04, just need to follow the instructions.

You can try the following commands to clean your system:
    apt-get clean
    apt-get update

before trying to upgrade again.