From a comment of the OP:

This worked for me:

Ensure that numlockx is installed:

sudo apt-get install numlockx

Edit the file /etc/lightdm/lightdm.conf:

 gksudo gedit /etc/lightdm/lightdm.conf

Add the following line to the file:

greeter-setup-script=/usr/bin/numlockx on


Ubuntu can't see the D: windows partition

Your partition D is mounted on /windows :

cd /windows && ls -lA

If you have issue with the mountpoint, show us the line of your /etc/fstab which mounted the /dev/sda5:

grep -A1 "/dev/sda5" /etc/fstab

Maybe you just need to install the NTFS support on your distribution:

sudo apt-get install ntfs-3g


Relationship between file/folder's owner and group?

Is it possible to assign a "group" to a file/folder that the file user (owner) does not belong to?

Certainly. For example:

$ sudo ls -l /var/spool/cron/crontabs
total 8
-rw------- 1 muru     crontab 1136 Jul 21 12:30 muru
-rw------- 1 root     crontab 1090 Jan 20  2015 root

$ groups
muru adm cdrom sudo dip plugdev lpadmin sambashare
$ groups root
root : root

As you can see, neither root, nor muru, are members of crontab, yet the crontab files' group owner is crontab.

  Is there any restriction between file's owner and group?

None at all1.

1Well, there are restrictions on each individually: the UIDs and GIDs have to be 32-bit integers (IIRC), or the username and group names must exist:

# touch /tmp/foo
# chown 1000000000:2000000000 /tmp/foo
# ls -l !$
ls -l /tmp/foo
-rw-r--r-- 1 1000000000 2000000000 0 Sep 15 09:04 /tmp/foo
# chown gibberish:garbage /tmp/foo
chown: invalid user: ‘gibberish:garbage’

But, no, no relation between owner and group.


Where can I obtain a list of all virtual packages provided by a Ubuntu distribution / release (e.g. bionic)?

The aptitude package manager's search function can match virtual packages as follows:

aptitude search '?virtual'

However build-essential isn't such a package - in Debian terminology, a virtual package is described as follows:

  A virtual package is a generic name that applies to any one of a group
  of packages, all of which provide similar basic functionality. For
  example, both the konqueror and firefox-esr programs are web browsers,
  and should therefore satisfy any dependency of a program that requires
  a web browser on a system, in order to work or to be useful. They are
  therefore both said to provide the "virtual package" called
  www-browser.

So for example the virtual package xserver may be provided by any of

$ aptitude search '?provides(^xserver$)'
p   tigervnc-standalone-server                                              - Standalone virtual network computing server
p   tigervnc-standalone-server:i386                                         - Standalone virtual network computing server
p   tightvncserver                                                          - virtual network computing server software
p   tightvncserver:i386                                                     - virtual network computing server software
p   vnc4server                                                              - Virtual network computing server software
p   vnc4server:i386                                                         - Virtual network computing server software
p   xnest                                                                   - Nested X server
p   xnest:i386                                                              - Nested X server
p   xserver-xephyr                                                          - nested X server
p   xserver-xephyr:i386                                                     - nested X server
p   xserver-xephyr-hwe-18.04                                                - nested X server
p   xserver-xephyr-hwe-18.04:i386                                           - nested X server
i   xserver-xorg                                                            - X.Org X server
p   xserver-xorg:i386                                                       - X.Org X server
p   xserver-xorg-hwe-18.04                                                  - X.Org X server
p   xserver-xorg-hwe-18.04:i386                                             - X.Org X server
p   xvfb                                                                    - Virtual Framebuffer 'fake' X server
p   xvfb:i386                                                               - Virtual Framebuffer 'fake' X server

Unfortunately I don't think there's a specific search term that would let you identify "packages like" build-essential - I've seen it sometimes referred to as a dependency-only package, but that's not strictly true since it does install some files of its own.

References:

The Debian GNU/Linux FAQ: What is a Virtual Package?
Aptitude: Search term reference


Should I use Logical Volume Management and Encrypt the installation on SSD?

No, it will not wear out the drive any sooner.


Problem solved by installing mpv player.

It seems to do hardware acceleration for 10bit fullhd automatically.


how connect to internet from ubuntu in the middle of pc and internet

This Solutions used to work on previous version of Ubuntu , you may try it

for the computer the internet is coming from (the LAPTOP) follow these steps:

Open a terminal and type this:

sudo ifconfig ethX ip

where 'ethX' is the network card that is going to be connected to the second computer and 'ip' is your desired server ip address (Usually 192.168.0.1 is used)

Then configure the NAT as follows:

sudo iptables -t nat -A POSTROUTING -o wlanX -j MASQUERADE

where 'wlanX ' is the network card that the Internet is coming from, and then:

`sudo echo 1 > /proc/sys/net/ipv4/ip_forward`

Install dnsmasq and ipmasq using apt-get:

sudo apt-get install dnsmasq

Restart dnsmasq:

sudo /etc/init.d/dnsmasq restart

Repeat steps 1 and 2.
Add the line "net.ipv4.ip_forward = 1" to /etc/sysctl.conf

sudo gedit /etc/sysctl.conf

Reboot. (Optional)

For the second computer, follow these steps:

Set the network card ip to: 192.168.0.2
Gateway: 192.168.0.1
Netmask: like the first computer
DNS: 192.168.0.1

REF: http://www.webupd8.org/2009/02/ubuntu-internet-connection-sharing.html


I have had the exact same problem since yesterday as well. To fix it I had to install gnome-panel then run unity reset through unity tweak tools.

Switch to a virtual terminal (Ctrl+Alt+F1), log in and run the following commands:

sudo apt-get install gnome-panel
sudo mv ~/.Xauthority ~/.Xauthority.backup

Reboot and select gnome on login.
Once logged in open a terminal (e. g. with Ctrl+T) and run:

sudo apt-get install unity-tweak-tool
unity-tweak-tool --reset-unity

Log out and log in again using Unity this time and that fixed it for me.


You should not install individual package with dpkg -i. If you are doing so you must to run sudo apt-get install -f afterwards.

The better way is to use apt-get install for deb-package as follows:

cd ~/Downloads
wget https://release.gitkraken.com/linux/gitkraken-amd64.deb
sudo apt-get install ./gitkraken-amd64.deb


Trouble installing 12.0.4 into Virtual Box

In VirtualBox, click on Machine, and then choose Reset, and that will restart the machine for you.


VX Connectbot connects to bionic sshd but not to focal sshd, why and what can i do?

to be more secure focal sshd by default refrains from offering as many key options, see workaround here:  https://bugs.launchpad.net/ubuntu/+source/openssh/+bug/1877496


I'm a complete noob and I installed Ubuntu 14.04 LTS

The easiest way to check the connected repositories is in

System Settings -> Software & Updates


Why some user functions don't get recognised by bash with sudo?

For security reasons sudo throws away shell functions and most environment variables before running its child process.

You need to include the definition of myfunction into test.sh.


It might be an issue around the spacing in the forward directive. There should be a sample one in the config file prefixed with a '#'. I would comment the one you have and uncomment the preexisting one.


As @souravc suggested, instead of actually visually dragging it, you can copy paste using your mouse/touchpad and without involving the context-menu.

To copy select the text to be copied by dragging the mouse.

On a desktop: To paste, middle click where you want to paste.

On laptop: Press both the left click and right click together.


When I delete a file from a separate partition, it does not go to Trash

You can enable Trash on Windows partition by making yourself its owner.

Find out your user id:

$ id

Open the fstab file, which holds partition mounting configuration:

$ sudo gedit /etc/fstab

Find your Windows partition (the one of ntfs type). It will look like this:

/dev/sda3 /home/user/shared    ntfs    defauls,noatime 0 0

(Note, that it doesn't have to be /dev/sda3, and the mount point and options may differ).

Add uid=xxxx to its list of options, where xxxx is your user ID:

/dev/sda3 /home/user/shared    ntfs    defauls,noatime,uid=xxxx 0 0

Save the fstab file and unmount/remount the Windows partition or simply reboot the computer. If it doesn't help, you might have to also add your group ID as gid=yyyy.

Taken from here.


Ubuntu 14.04.3 LTS Screen Display crashing

As you are using very new GPU hardware, it is recommended to use the very latest stable drivers.

Install the latest stable NVIDIA drivers supporting TITAN X from the Proprietary GPU drivers PPA.

Before you install new drivers uninstall every NVIDIA related software you have installed before.

Open a terminal and execute :

sudo apt-get purge nvidia*
sudo reboot

Then install the latest current stable NVIDIA drivers from the short-lived branch by executing :

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update
sudo apt-get install nvidia-355
sudo reboot

In case you are using a notebook with a hybrid graphics solution install Optimus support as well.

sudo apt-get install nvidia-prime

To switch between intel and nvidia graphics - open NVIDIA X Server Settings -> Prime Profiles.


How to make non-ascii-armored public key from ascii-armored secret key

The easiest way is to import and subsequently export they key without using the --ascii flag.

Import the key

gpg --import 4secret-key.asc

If you don't know the key id, look it up

gpg --list-secret-keys

Export the public key, storing it in a file

gpg --export [key-id] >public-key.gpg

If you don't want to import the key to your keyring, set $GNUPGHOME to something temporary, eg. by running export GNUPGHOME=/tmp/gnupg before the commands given above. Deleting the folder afterwards might be reasonable.


Video Editor where I can select specific areas

Avconv/ffmpeg
Whenever we do not find an option to do a specific task we may find a command line tool more promising.
To achieve a video with clipped content from a time segment of our source we basically need the video filters trim, and crop from avconv/ffmpeg (whichever you prefer to use). Please read the documentation in the libav manual sections for all options.
Below example will produce a video from the first minute of our source with cropping a central area of 1024x768.
avconv -i <inputfile> -vf trim 0:60 crop=out_w=1024:out_h=768 <outputfile>

Cropping from another position than the center will need different parameters which can very nicely be fine-tuned (several examples are given in the libav documentatiton). Audio is not treated in this example. If your video contains audio you may have to trim the audio track as well.
The resulting clip will then have to be of course joined again with the orginal video which we will also have to trimm to the beginning, and the end of our transformed clip.
OpenShot
The crop feature is hidden in the clip's properties/layout settings. After we had selected an area (use the Razorblade too) of our clip we may select this sub-clip's properties with a right mouse click.
In the now opening menu choose the Layout tab to select an area to clip. Adjust height, width, and X, Y values until you are happy. A preview window will help doing so.
Below example uses a video with a constant view on the scene (as it is shown in the lower screen shot).

Enlarged to 200 % at the start of the clip

Back to 100 % at the end of the clip
Smooth transition
In the example above I started with a clipped region of the video at the beginning of my sample video fragment zoomed to 200% ("Start of Clip"). By undoing the enlagement at the end of my fragment to 100 % ("End of Clip") OpenShot will render a smooth transition between the two extremes (200% -> 100%) very much as if we had operated the camera zoom. With values for X or Y we can do the same resluting in an camera shift movement from the beginning to the end of the clip.
Static crop
In case we want a static clipped area only we just make the effect's value the same for the beginning and the end of the clip.
Details: OpenShot Manual


How restore /var/lib/mysql after i delete it?

Restoring /var/lib/mysql can be done by putting back a backup. If you did not have a backup, you've lost your database. The only thing that can be done is reinstalling the MySQL server:

sudo apt-get --reinstall install mysql-server-5.1

FYI, the MySQL root password is stored in /etc/mysql/debian.cnf.


Try taking a look at this: http://www.ubuntugeek.com/creating-custom-ubuntu-live-cd-with-remastersys.html.  Be careful, though I have never done this and I advise you to proceed with caution.


Decision for Ubuntu or Lubuntu on little bit Old notebook

Lubuntu uses LXDE for the Desktop Manager (the GUI), which supposedly runs with only 512 MB of RAM as opposed to Unity, which is a known memory hog. Thus, it would be "lighter". From the LXDE site:

Lightweight
It needs less CPU and performs extremely well with reasonable memory.
Fast
It runs well even on older computers produced in 1999, and it does not require 3D acceleration.

...

The hardware requirements of LXDE are similiar to Windows 98 (Maybe a little bit higher). An old Pentium II CPU is enough.
After X11 and LXDE are started, the total memory usage is about 45 MB on i386 machines. (This value may be higher or lower according to
different system configurations.)
Though LXDE itself doesn't require better hardware, other applications under X do need it. For example, Firefox and
OpenOffice.org 2 are quite memory-hungry. So it's recommended that you
have a RAM of more than 128 MB.

As for the applications that come default installed with Lubuntu, they are lighter and run on less RAM. They may have less features, but they are built to run on older equipment, such as my iBook G4 (downloading the iso for Lubuntu 12.04 now :D).
You can read here: https://wiki.ubuntu.com/Lubuntu#Lubuntu_vs_Ubuntu about the comparison. Basically, what makes Lubuntu lighter (faster) is the DE, LXDE.
Thus, LXDE itself runs lighter/better on older/limited hardware. You can read more about this on the LXDE about site: http://lxde.org/lxde.
As for which one to go with, I would try going with Lubuntu first and then if you want it, install Unity. I've heard (not confirmed though) that Lubuntu is faster overall and thus you can just add the apps you want after the install.
I have an old 7-8 yr old Toshiba Satellite A105 with 1GB of RAM and Unity runs, for the most part, great on that. If I have a large number of tabs open in Firefox or several apps running at once it slows down, but usually its fine!
So, it really comes down to the speed-features trade-off. Unity/Ubuntu seems to have more features, but LXDE/Lubuntu has more speed. It's really your choice.


What wifi cards will work out of the box for desktop computers?

Here is a link to a list that contains a lot (not most, just a lot) wifi cards and their support info.


Lubuntu 20.04: what do the files in /sys/power/suspend_states do?

The /sys folder is controlled by the Linux kernel.

You have to read some kernel documentation about it and find exact section then.


Make a CD of Super Grub Boot disc; it will find all the OSs and allow you to choose and boot. Also try 'Try Ubuntu' from the Live CD, and install into it Grub Customizer. Launch that and you may be able to adjust the settings to get back to booting normally. Super Grub disc has got me out of trouble many times. Good luck


USB Headphones Recognized but not Working on Ubuntu

In terminal type
alsamixer

Then hit F6 to open the menu we will use.
You may see three sections, Auto Gain Control, Headset, and Headset 1. In my case Headset 1 was muted and had no volume (red/white) in the bar. Both Headset and Headset 1 need to be unmuted and have some volume in the bar for your headphones to work.
Use the left and right arrow keys to scroll between sections. Pressing the M key unmutes. MM means muted while 00 means unmuted. Ensure both Headset and Headset 1 are unmuted (00). In my case, Headset 1 was muted.
Now use the up and down arrow keys to put volume in both bars. In my case, the volume buttons on my keyboard successfully controlled the Headset section but did nothing for the Headset 1 section which had volume all the way down. Press the up key on Headset 1 to put some volume in that bar.
If both bars are unmuted and have volume in them then your headphones should work if this was the issue. Press Esc to exit, changes will be saved automatically.


Use ipconfig in a dos shell to get the ip address. On Ubuntu use ifconfig in a terminal to get the same.

Now try to ping your boxen. If they ping then you know that they are 'on the same network'.

You can also put the IP address in the explorer window address bar on the Windows PC. If you have your shares etup correctly on Ubuntu machine it will show them.

A more useful tool from the Ubuntu box is zenmap. You have to run it as root and install nmap dependency. This lets you see everything visible on your network, even if you cannot see it normally as it is a clever network scanning tool.

Establish the basic connectivity, make sure your shares are setup, make sure they can be found by IP and then you will be part way there.

Another thing is you need DHCP rather than static IPs unless you want lots of 'hosts' files in your boxen.


How to control the permissions of a mounted usb drive?

When you mount the USB drives you can specify the owner and the group with options uid and gid. For example:

$ sudo mount -o uid=1000,gid=1000 /dev/sdX /path/to/mountpoint

If you want to change permissions you can add the umask option too:

$ sudo mount -o uid=1000,gid=1000,umask=022 /dev/sdX /path/to/mountpoint

umask=022 will set the Owner to read, write, execute. Group and Others will have read, execute.

You can read more about umask here: https://wiki.archlinux.org/index.php/Umask


still have "windows" partitions after installing ubuntu

The installer erases the disk when told so and needs to. By creating the unallocated space, unnecessary step given the goal was to have Ubuntu as a single OS, it allowed Ubuntu to be installed there.

You can now remove sda2, sda3 and sda4 and then, from a live session, move the Ubuntu partition to the left and resize to use the remaining unallocated space.


How can I make a shortcut to Gnome to login to a WWW-page?

one can open Chrome & Firefox with an URL (eg. a regular .desktop file), while one cannot inject JS alike that. most easy is to use a HTTP debugger (F12) and then script it server-side with PHP & cURL. if you really need to execute JavaScript, phantomJS can run it headless... there is still the alternative, to create a custom browser extension... which is being active on the one site, where the JS interaction is required (this can be defined in the extension's manifest). the GNOME Desktop has in every case little to do with what is happening on some remote site, except telling the web-browser which URL to visit. the search term "Browser Automation" also turns up a few Chrome plugins ...in general, one can use an actual web-browser or emulate the behavior of a web-browser (to obtain a session cookie and to stuff it into the local cookie jar, which equals being "logged in").

there is a slight difference, in between "logging in order to obtain some value and then store it" (where server-side automation makes perfect sense) or just automating the web-browser to perform certain interaction (eg. logging in and the handing over the ongoing session to the user). each site is different, so there won't be any default recipe; most web-sites not even adhere to standard auto-complete attributes.


Proper laptop temperature for warmer enviroment

Repeadetly high temperatures are never really healthy for the machine. In the long run this can lead for instance to cracked solderjoints on the processor/GPU because of the difference in thermal expansion of board and chip, but it can take a few years before you get into trouble with that.

Yes, your chips are okay with high temperature...your mainboard, however, is not really happy with it.

Normally, the main reason that the laptop runs 15  degrees hotter on ubuntu than on windows is the open source radeon videodriver.

When you install the (proprietary) fglrx driver from the ubuntu repository you will see a drop of 10 to 20 degrees in temperature on your laptop.

If you are already on fglrx, and the temperatures are still above what you desire:

avoid unneeded 3D eyecandy.
Install powertop to tweak your hardware for low energy consumption and to reveal the biggest CPU resource-hogs on your system.
You might prefer a lightweight desktopmanager like LXDE, that will free up to (or over) 50% of your system resources

When I'm running HD video on my netbook with GPU acceleration I have a CPU load of 90% to 100% on Ubuntu but a load of 20%-25% on Lubuntu (same netbook, same kernel, same drivers, same movie).


Additional drivers page shows nothing at all. (Not an nVidia problem)

I'm having the same issue trying to fix a graphics driver problem causing Ubuntu to crash upon login. Solved it by accident! I attempted to install some language updates, then went to the Software and Updates tab and tried to click X to close out of frustration. It then asked me to update, I accepted and upon reentering the list appeared. Try installing and update in general and try closing the tab to see if it asks you. Good luck


problem with Shift, Ctrl and Alt button with integrated keyboard

There is a known bug for this issue, that appears to be specific to HP, possibly specific to the HP 15.  See https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1532746 and add any information you have.


From the comments...

cat /etc/apt/sources.list.d/brave-browser-release-bionic.list

Output is...

 $ sudo apt update $ sudo apt install brave-browser brave-keyring

So do this...

Delete the /etc/apt/sources.list.d/brave-browser-release-bionic.list file, as its contents are completely invalid.

sudo rm -i /etc/apt/sources.list.d/brave-browser-release-bionic.list


Boot in whatever mode won't work for 12.04

As jet commented, the nomodeset boot option might help. If not, you'll have to add some more details to your question. Specifically, the make and model of your machine (or, if inapplicable, then of your motherboard) and the make and model of your video card. If you can tell us what kernel versions appear in the boot menu and whether or not any of them work,  that might help, too.


How to run a Desktop graphical application just once under sudo?

You can run the software from the command-line/terminal with gksudo prefixed to the command,  which will present the prompt for your sudoer's password prior to launching.

gksudo file-roller

Though you mentioned you do not want to make this a permanent change - you could add a new Menu item into something like Applications -> System Tools via alacarte (System -> Preferences -> Main Menu) The command for which could be gksudo file-roller creating both a regular Archive Manager launcher and a "root" Archive Manager launcher - for convenience.


How to deactivate multitouch on a Thinkpad x220/x230 tablet?

You can achieve this by writing a small script to toggle "device enabled" property of the multi-touch input device. You can then bind this script to one of the keys for easy access or just execute it using any other method you prefer.

First you need to get the device name using xinput utility. Open a Terminal and type xinput list.

:~$ xinput list
⎡ Virtual core pointer                        id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                  id=4    [slave  pointer  (2)]
⎜   ↳ Wacom ISDv4 E6 Pen stylus                   id=10    [slave  pointer  (2)]
⎜   ↳ Wacom ISDv4 E6 Finger touch                 id=11    [slave  pointer  (2)]
⎜   ↳ TPPS/2 IBM TrackPoint                       id=14    [slave  pointer  (2)]
⎜   ↳ Wacom ISDv4 E6 Pen eraser                   id=16    [slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad                  id=13    [slave  pointer  (2)]
⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard                 id=5    [slave  keyboard (3)]
    ↳ Power Button                                id=6    [slave  keyboard (3)]
    ↳ Video Bus                                   id=7    [slave  keyboard (3)]
    ↳ Sleep Button                                id=8    [slave  keyboard (3)]
    ↳ Integrated Camera                           id=9    [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard                id=12    [slave  keyboard (3)]
    ↳ ThinkPad Extra Buttons                      id=15    [slave  keyboard (3)]

As you can see in this case the name of multi touch device is Wacom ISDv4 E6 Finger touch and its id is 11. Yours may be different. You can use the id as well, but I prefer the name since adding/removing devices could cause the id of some of the devices to change. Here is an example script that could get you started. All this does is toggle between two commands -- one to enable the multitouch device and one to disable it.

#!/bin/bash
#!/bin/sh
# This script can be used to toggle enable state of wacom multitouch screen for
# Thinkpad Tablet Series. You may need to change the name of multitouch device
# which can be found by running *xinput list* command

TOGGLE=$HOME/.multitouch_toggle

if [ ! -e $TOGGLE ]; then
    touch $TOGGLE
    xinput set-prop 'Wacom ISDv4 E6 Finger touch' 'Device Enabled' 0
else
    rm $TOGGLE
    xinput set-prop 'Wacom ISDv4 E6 Finger touch' 'Device Enabled' 1
fi

I hope this will help you get around the problem for now. If you need any help with customizing or running the script above feel free to ask.


I had to follow the steps given in  this answer
Basically run these two commands
sudo touch /etc/NetworkManager/conf.d/10-globally-managed-devices.conf
sudo systemctl restart NetworkManager


I had a similar problem, however I was able to solve it.  I cannot exactly remember how, but try using the code rfkill list all in the terminal.  I remember using that code, but I do not remember if I used any follow-up codes.  Hopefully that works, but if not the results you get from that might be able to help other, more experienced, ubuntu users to help solve your problem.


How to update Mozilla Firefox web browser on 64-bit Ubuntu 12.04 LTS in a safe, secure, reliable, efficient and easiest way?

You should find out what the latest packages available are, by first running:

sudo apt-get update

and then install the latest firefox:

sudo apt-get install firefox

Or you could install the latest "everything" with:

sudo apt-get upgrade

Ubuntu should have an updater (don't remember exact name) that checks for and asks you about installing (or optionally automatically installs) newer packages/software. Is yours not running or set to keep quiet?

And there's also apt-get dist-upgrade that upgrades Ubuntu to a newer release, but it's traditionally less reliable than a fresh install.


Debian (.deb) package not installing in Ubuntu 16.04

Looks like dependencies are not satisfied. You can either use gdebi package installer. It'll install deb package in a very user friendly way and it'll also resolve any unsatisfied dependencies. Install it using this command:

sudo apt-get install gdebi

Then open the deb file using gdebi and it'll install it. Make sure that you're connected to internet while installing the deb file using gdebi, because it needs dependencies to be downloaded.


making a triple boot pc win xp win 7 and ubuntu

I'd start by visiting the Windows Stack Exchange site for the setup of XP and Seven. Once those work OK, then install Ubuntu 12.04, which will prompt you for the kind of setup you want; instructions for that are at Ubuntu and here in AskUbuntu. They key is to get Windows set up first.


khotkey script calling bindings stop to work on switching to Quantal

Oh I solved it:

sudo apt-get install kdm kde-standard


desktop files and Ubuntu software Center

Because that is how Ubuntu was designed. When you install an app from Ubuntu Software Center, Ubuntu puts an icon for only the user who installed the app.


You need to use sort before uniq:

find . -type f -exec md5sum {} ';' | sort | uniq -w 33

uniq only removes repeated lines.  It does not re-order the lines looking for repeats.  sort does that part.

This is documented in man uniq:

  Note: 'uniq' does not detect repeated lines unless they are adjacent.  You may want to sort the input first, or use sort -u' withoutuniq'.


I found the answer just after setting up the bounty lol.

In Debian derivatives (like Ubuntu), you have to install the package console-data with the command sudo apt-get install console-data

Then you can switch to bepo using this : loadkeys dvorak-fr-bepo.


What Version of Ubuntu? because if it is a certain few all you have to do is scroll your mouse over where it was before click on settings and then appearance,behavior tab and last but not least the button for auto hide the launcher that says on or off.


Why does this set of apt commands work when run line by line, but not when run as a script?

As you confirmed in the comments, your script has been written on a Windows system and contains Windows-style (CR+LF) line endings instead of Unix-style (LF), which would be necessary.

To easily convert the line endings of text files between DOS/Windows and Unix style, install a package named dos2unix:

sudo apt install dos2unix

It comes with two commands, dos2unix to convert a Windows text file to Unix format, and unix2dos to convert a Unix text file to Windows format.

In your case, simply run

dos2unix FILENAME

replacing FILENAME with your actual script file name, and it should run fine after that.


swappiness is zero but swap is still used unnecessarily

swappiness set to zero does not mean the system does NOT use swap. It tells the kernel to not swap processes out of physical memory for as long as possible. And it also does not start swapping when RAM is used up totally.

  Is this normal? If so, why? If not, why is it happening?

The only answer to this is probably: default behaviour. The system decided it is the best action to take.

You probably first need to identify the process that is responsible. So this will show swap used per process (run as root or it will report only on processes run by your user):

for file in /proc/*/status ; do awk '/VmSwap|Name/{printf $2 " " $3}END{ print ""}' $file; done | sort -k 2 -n -r | less

There is a tool in the repos called smem (also run as root):

# smem -s swap -t -k -n
  PID User     Command                         Swap      USS      PSS      RSS
    1 0        /sbin/init splash                  0   872.0K     2.2M     5.6M
  285 0        /lib/systemd/systemd-journa        0     2.6M     2.6M     4.6M
  307 0        /lib/systemd/systemd-udevd         0     2.1M     2.2M     4.4M
  616 100      /lib/systemd/systemd-timesy        0   404.0K   435.0K     2.7M
  711 0        /lib/systemd/systemd-logind        0   960.0K   986.0K     3.0M
  715 104      /usr/sbin/rsyslogd -n              0     1.5M     1.5M     3.6M
  721 0        /usr/sbin/NetworkManager --        0     6.7M     7.3M    17.4M
  723 0        /sbin/cgmanager -m name=sys        0   364.0K   401.0K     2.6M
  735 0        /usr/sbin/thermald --no-dae        0     1.2M     1.4M     8.7M
  736 0        /usr/sbin/anacron -dsq             0   212.0K   238.0K     2.3M
  741 105      /usr/bin/dbus-daemon --syst        0     1.9M     2.1M     5.4M
  767 0        /usr/lib/x86_64-linux-gnu/u        0     1.0M     1.1M     5.7M
 ...

 5097 0        su                                 0   480.0K   675.0K     3.5M
 5098 0        bash                               0   520.0K     1.0M     3.8M
 5112 0        /usr/bin/python /usr/bin/sm        0    11.8M    11.8M    14.2M
-------------------------------------------------------------------------------
  134 12                                          0     1.3G     1.5G     3.3G

If you follow this and find out a specific program being responsible edit into your question. And I also believe it will be firefox. It is a resource hog so changing browsers might be something to consider.


Why aren't the drivers for Broadcom preinstalled?

Those "other things" aren't included on the CD. They're downloaded. Are you suggesting it downloads a network driver without a network driver? "What good is a phone call... if you're unable to speak?", etc.

But you've essentially answered your own question. They're not included because they're proprietary.


I want to install ubuntu-16.04-desktop-amd64 along with windows10 will it work and support 8gb RAM?

"is it possible to install both alongside"

Yes

"and will ubuntu support 8gb ram?"

Yes


I have seen this with many computers, it is not the grub install that actually fails but the update-grub that makes the first config file that fails. the problem is that the if/then statement in 30_uefi-firmware errors.

the easiest fix is after it error, choose the command line prompt at the bottom of the installer menu. and use nano to edit the file /etc/grub.d/30_uefi-firmware. I have changed mine to read:

gettext_printf "Adding boot menu entry for EFI firmware configuration\n" >&2
cat << EOF
menuentry 'uefi-firmware' {
fwsetup
}
EOF

after editing rerun install grub. note: on some systems the print command needs to be commented out temporarily for the installer

If you want to try and boot the installed Linux to make repairs from there.

there is a guide for booting an install from the grub command line here https://askubuntu.com/a/931327/694267

you will have to change the drive references as needed for your installation


The answer is Yes (for both questions), but before testing your code on the Nexus 7 (2013), you'll need to run Utopic (14.10) on your laptop/desktop to get access to the latest development tools.

Follow the installation steps (using the development channel to get a 14.10 image).
Install the required packages to manage your device:

sudo apt-get install ubuntu-device-flash phablet-tools

Install the SDK

sudo apt-get install ubuntu-sdk

Connect your device and enable read-write mode (using the SDK):

Push a sample code to your device (hello.c):

$ adb push hello.c /home/phablet
1 KB/s (82 bytes in 0.041s)

Start a phablet shell connection, install gcc and libc6-dev (root password is phablet) and compile your code on the target:

sylvain@sylvain-ThinkPad-T430s:~$ phablet-shell
start: Job is already running: ssh
/home/sylvain/.ssh/known_hosts updated.
Original contents retained as /home/sylvain/.ssh/known_hosts.old
4 KB/s (200 bytes in 0.040s)
Warning: Permanently added '[localhost]:2222' (RSA) to the list of known hosts.
Welcome to Ubuntu Utopic Unicorn (development branch) (GNU/Linux 3.4.0-3-flo armv7l)

 * Documentation:  https://help.ubuntu.com/
Last login: Wed Jul  9 21:29:20 2014 from localhost.localdomain
phablet@ubuntu-phablet:~$ sudo apt-get update
[sudo] password for phablet:

[...]

phablet@ubuntu-phablet:~$ sudo apt-get install gcc libc6-dev

[...]

phablet@ubuntu-phablet:~$ gcc -Wall hello.c -o hello
phablet@ubuntu-phablet:~$ ls
Documents  Downloads  hello  hello.c  Music  Pictures  Videos
phablet@ubuntu-phablet:~$ ./hello
Hello, world!
phablet@ubuntu-phablet:~$


As the error points to line 51, this one is not correct. I should be as follows.

deb https://dl.winehq.org/wine-builds/ubuntu bionic main

Please also note further needed steps from the WineHQ site.


You can try imagination from the repository.

sudo apt-get install imagination

Imagination is a lightweight and user-friendly DVD slide show maker with
a clean interface and few dependencies. It only requires the ffmpeg encoder
to produce a movie to be burned with another application.

It currently features over 50 transition effects. Exporting the slideshow in FLV format is supported as well.


Ignoring bad line starting with '“options'

Use the sed command to comment out the line or fix the issue
sudo sed -i 's/"options/options/' /etc/modprobe.d/iwlwifi.conf
Then reboot

I am guessing you put a double quote in a sudo tee -a you can check in terminal with history | grep echo


Dual system: win10 can connect to wireless but ubuntu 18.04 cannot and keep asking password

I own and use successfully two Intel wireless devices. I have honed a few techniques in several years and thousands of forum posts.
First, check the settings in the router. WPA2-AES is preferred; not any WPA and WPA2 mixed mode and certainly not TKIP. Second, if your router is capable of N speeds, you may have better connectivity with a channel width of 20 MHz in the 2.4 GHz band instead of automatic 20/40 MHz, although it may slightly affect N speeds. I recommend a fixed channel, either 1, 6 or 11, rather than automatic channel selection. Also, be certain the router is not set to use N speeds only; auto B, G and N is preferred. After making these changes, reboot the router.
Next, I recommend that your regulatory domain be set explicitly. Check yours:
sudo iw reg get

If you get 00, that is a one-size-maybe-fits-all setting. Find yours here: http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 Then set it temporarily:
sudo iw reg set IS

Of course, substitute your country code if not Iceland. Set it permanently:
sudo nano /etc/default/crda

Change the last line to read:
REGDOMAIN=IS

Proofread carefully, save and close the text editor.


How to cross-compile an existing deb package from 64bit to 32bit architecture

It is mostly not possible to cross-compile a 32bit package from a 64bit deb package if the package contains any source files or libraries.

You'll need to repackage using the 32bit libraries and recompile the source code.

My suggestion would be to split your compile and packaging - do your 32bit work in a separate 32bit Virtual Machine.

Perhaps better, would be to set up a LaunchPad PPA and let Launchpad do the compiling for both 64bit and 32bit architectures automatically.


how to upgrade to firefox 12 not 13 on ubuntu

First remove the firefox installed on your pc by typing in terminal
sudo apt-get remove --purge firefox

Then download these packages (from the official firefox ppa).
I have assumed that you have natty.

For 32 bit

firefox 12 main

firefox mozsymbols

firefox locale_en

firefox gnome support

firefox global menu

firefox branding

For 64 bit

firefox 12 main

firefox mozsymbols

firefox locale_en

firefox gnome support

firefox global menu

firefox branding


What are the possible commands to reset a wifi connection?

Please open a terminal and do:

sudo gedit  /etc/systemd/system/wifi-resume.service

Use nano or kate or leafpad if you don't have the text editor gedit. A new empty file will open. Add the following:

[Unit]
Description=Local system resume actions
After=suspend.target

[Service]
Type=oneshot
ExecStart=/bin/systemctl restart network-manager.service

[Install]
WantedBy=suspend.target

Proofread carefully twice, save and close the text editor. Now do:

sudo chmod +x  /etc/systemd/system/wifi-resume.service

And next:

sudo systemctl enable wifi-resume.service

Reboot and let us know if the problem is solved.


You are missing libXtst.so.6 file which come inside libXtst6 package. Try this,

sudo apt-get install libXtst6

That will make the file available. If that doesnt work post output of

sudo updatedb
locate libXtst.so.6


Run inkscape from the commandline and suspend it when the unwelcome extra windows were displayed. Then run ps -o command and observed which extra processes are launched, for example:

/usr/bin/python gimp_xcf.py --tab="Options" --guides=false --grid=false --background=false --dpi=96 /tmp/ink_ext_XXXXXX.svgPAIY3Y
/bin/sh -c gimp -i --batch-interpreter plug-in-script-fu-eval -b - > /tmp/tmp6qiytj/junk_from_gimp.txt 2>&1
gimp -i --batch-interpreter plug-in-script-fu-eval -b -

These are other output extensions that are causing the problem. They will only run one at a time. To find all output extensions, do grep -l '<output>' *.inx in the extensions directory. Removing the .inx files for those output extensions (or moving them to a different location) will fix this error.


To run every 3 hours, starting at 3:45

45  */3 * * * bin/run.sh job

If you're trying to skip the hours between midnight and 8:45,

45 8,11,14,17,20,23 * * * bin/run.sh job


Problem with updating libcap2 100:2.48-1

You have to disable the http://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_20.10 repository and then retry.


I've added empathy -h to my Startup Aplications and it works in my case. Give it a try.


mate-panel clock applet non monospace font causes wiggling in notification area

The property you are looking for is
min-width: value

This will stop the box from going below a set value in width.
Here you can see the documentation, box properties can be found in table 7.
To address your issue with the numbers still resizing, this is related to the font you chose. In the link you give you can see the number 1 is only half the width of the other numbers.
To edit the .ttf file of a font you can use some thing like fontforge from the repos, it should be a simple task.
sudo apt install fontforge


"Kernel panic - not syncing: Timeout synchronizing machine check over CPUs" Every time I boot from a live USB

Have you tried using different programs to make the Live USB? When I make a Live USB with the Startup Disk Creator application, I usually get this error (which is odd, since it's the default application). But when I make a Live USB with Unetbootin, it almost always works great.
EDIT
I just looked up your motherboard. The BIOS has had a bunch of updates over the past few months, which might suggest that there's been some bugs with it. You could try flashing a newer BIOS: http://us.msi.com/support/mb/Z97_MPOWER_MAX_AC.html#down-bios
EDIT2
Resetting the BIOS by clearing the CMOS RAM has helped me before; maybe it will help you too. Here's an image showing how to do this that I grabbed from the manual of your motherboard:

If that image is hard to read, it's on page 45 (or section 1-31) of the full manual here: http://dl.msi.com/download_files/mnu_exe/E7888v1.0.zip
I'm sure you already know this, but make sure you do this with the computer off and unplugged.


You need to add one more widget to the panel, it's called Window Selector. It usually appears at the end of the list of widgets.


How to install OpenvSwitch in Ubuntu 16.04

Direct installation

Run these commands

sudo apt update
sudo apt upgrade
sudo apt install openvswitch-switch

Then start the ovs deamon

sudo ovs-vswitchd

Manual installation

1. Download OpenvSwitch

Create a directory (folder) in your Desktop called ovs then download https://www.openvswitch.org/releases/openvswitch-2.5.6.tar.gz from OpenVSwitch website and save it in the ovs folder. This is important because of step 3 below.

Extract it by right clicking on it and selecting extract or run the commands below in the terminal one at a time:

cd ~/Desktop/ovs/
tar -xvf openvswitch-2.5.6.tar.gz

2. Install dependencies

OpenVSwitch requires some dependencies installed first. Run this command in the terminal:

sudo apt install build-essential fakeroot graphviz autoconf automake bzip2 debhelper dh-autoreconf libssl-dev libtool openssl procps python-all python-qt4 python-twisted-conch python-zopeinterface module-assistant dkms make libc6-dev python-argparse uuid-runtime netbase kmod python-twisted-web iproute2 ipsec-tools openvswitch-switch racoon

Confirm if all dependencies are installed. The command below should return nothing if all are installed. Otherwise it will tell you which ones are missing. This command should be run inside the openvswitch directory extracted above:

sudo dpkg-checkbuilddeps

3. Generated OpenVSwitch .deb files

You have two options, use either of the commands below depending on whether you want to run the unit tests or not.

a. Run the unit tests

sudo fakeroot debian/rules binary

b. Don't run the unit tests

sudo DEB_BUILD_OPTIONS='parallel=8 nocheck' fakeroot debian/rules binary

This will generate the following debs in the ~/Desktop

openvswitch-common_2.5.6-1_amd64.deb
openvswitch-datapath-dkms_2.5.6-1_all.deb
openvswitch-datapath-source_2.5.6-1_all.deb
openvswitch-dbg_2.5.6-1_amd64.deb
openvswitch-ipsec_2.5.6-1_amd64.deb
openvswitch-pki_2.5.6-1_all.deb
openvswitch-switch_2.5.6-1_amd64.deb
openvswitch-test_2.5.6-1_all.deb
openvswitch-testcontroller_2.5.6-1_amd64.deb
openvswitch-vtep_2.5.6-1_amd64.deb

4. Install the generated deb files

The most important ones are openvswitch-common and openvswitch-switch. The rest can be installed depending on your exact needs.

cd ~/Desktop
sudo dpkg -i ../openvswitch-common_2.5.6-1_amd64.deb
sudo dpkg -i ../openvswitch-switch_2.5.6-1_amd64.deb

The openvswitch daemon called ovs-vswitchd will run automatically. You can confirm using:

ps -ef | grep ovs

Which should return such an output

ovsdb-server: monitoring pid 24477 (healthy)
ovsdb-server /etc/openvswitch/conf.db -vconsole:emer -vsyslog:err -vfile:info --remote=punix:/var/run/openvswitch/db.sock --private-key=db:Open_vSwitch,SSL,private_key --certificate=db:Open_vSwitch,SSL,certificate --bootstrap-ca-cert=db:Open_vSwitch,SSL,ca_cert --no-chdir --log-file=/var/log/openvswitch/ovsdb-server.log --pidfile=/var/run/openvswitch/ovsdb-server.pid --detach --monitor
ovs-vswitchd: monitoring pid 24487 (healthy)
ovs-vswitchd unix:/var/run/openvswitch/db.sock -vconsole:emer -vsyslog:err -vfile:info --mlockall --no-chdir --log-file=/var/log/openvswitch/ovs-vswitchd.log --pidfile=/var/run/openvswitch/ovs-vswitchd.pid --detach --monitor

Unless it isn't running, you can manually start it using:

sudo ovs-vswitchd

5. Documentation

This information plus the documentation can be found at http://www.openvswitch.org/support/dist-docs-2.5/


Dual boot in ubuntu with pre-installd windows 8 in hpg6-2301ax

Variants of this question have been asked numerous times. See, for instance, Can I use wubi if I have a UEFI motherboard and Windows Vista?.


How do I install my new Canon MG5250 printer? (MG5200 series)

I googled and found the instructions included below.  The instructions worked:  I now have a fully working printer with color and duplex! For B&W printing, follow Dahzler's answer.

Unresolved:

How to get scanning to work! (I will put a link here to a solution when I figure it out! There seems to be at least one intimidating method for experts.)

The scanner seems to be recognized by Canon's scangearmp but not by Ubuntu's built-in simple scanner app that I much prefer. See further details in the scanner question linked above.

Instructions:
The below is copied from http://linuxdeal.com/Printer-PIXMA-MG5220 but I have adapted it slightly to be easier to follow.

OS: Xubuntu 11.04 Natty Narwhal
Date: Jul 25th, 2011
Recommended

          Printer  Scanner
USB       Perfect  Untested
Wireless  Perfect  Perfect

Driver instructions:

Download the driver files to Downloads folder:
Printer: http://support-my.canon-asia.com/contents/MY/EN/0100301702.html
Scanner: http://support-my.canon-asia.com/contents/MY/EN/0100303002.html
Unpack the tar.gz files by right clicking on them and selecting 'unpack here'
Install the printer .deb packages by going into the folder and double clicking on the right .deb file for your system

32-bit:
cnijfilter-common_3.40-1_i386.deb
cnijfilter-mg5200series_3.40-1_i386.deb
64-bit:
cnijfilter-common_3.40-1_amd64.deb
cnijfilter-mg5200series_3.40-1_amd64.deb
Go to Application Menu > Printing > and search for a MG5200 printer if it has not been automatically added by now.

Install the scanner .deb packages in the same way as the printer installers above:

32-bit:
scangearmp-common_1.60-1_i386.deb
scangearmp-mg5200series_1.60-1_i386.deb
64-bit:
scangearmp-common_1.60-1_amd64.deb
scangearmp-mg5200series_1.60-1_amd64.deb
If dpkg does not work then go into a command line and use the cd tool to change directory into the path were your unpacked files are, look for the install.sh file:
sudo sh install.sh

Enjoy! :)
Comments

I ran a test print that printed a test page with Grayscale, Red, Green, Blue, Cyan, Magenta, Yellow, and Black colors with an ubuntu header.


A masked service is used to prevent a unwanted start of this service. If you are sure that Apache2 shouldn't be masked, you can just unmask and then restart your service with:

sudo systemctl unmask apache2
sudo service apache2 restart


Minimum value disables mouse acceleration and leaves you with your mouse's dpi. To lower the mouse speed you have to slide the slider a bit to the right, just to make in non-minimum or if you can configure your mouse's dpi, you can do that, only some mice allow that and they often do it with on board buttons.


gdb 7.8 is currently not available in trusty repo. But you can install it from the source.

Open terminal and type following commands

wget http://ftp.gnu.org/gnu/gdb/gdb-7.8.tar.xz
tar -xf gdb-7.8.tar.xz
cd gdb-7.8/
./configure
make
sudo cp gdb/gdb /usr/local/bin/gdb

It will install gdb in /usr/local/bin/ directory. As /usr/local/bin/ is searched before /usr/bin/ whenever a command is executed, running gdb will execute gdb 7.8.

Once installed, you can check gdb version using

gdb --version

It should output

GNU gdb (GDB) 7.8
Copyright (C) 2014 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 "i686-pc-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".

If you want to uninstall it simply remove gdb from /usr/local/bin/ by executing

sudo rm /usr/local/bin/gdb


How to run software, that is not offered though package managers, that requires ia32-libs

It's mostly depends on the software and how it was written. In such cases I would go for the 32-bit Debian (if available) binary or the compiled 32-bits binary. This was already explained in my answer How do you run a 32-bit program on a 64-bit version of Ubuntu? and demonstrated even running a 64-bit version of a 32-bit system (which was impossible some years ago). It's actually easier to run 32-bits applications in 64-bits systems.

Normally when you run the binary it will inform you of missing libraries, which you can look in the repositories.

  Does 13.10 catch any calls to ia32libs libraries and translate the calls to the right code on amd64?

No. Developers should do this. The system only shows the libraries using the GNU Linker ld. If the software tries to use "hard-code" libraries, then you have to trick him and point them to the right libraries. Modern, well written software, do not need this.

  If it runs, does that mean that all required libraries have been loaded correctly, or is there a change of it crashing later on when a library that was needed is missing after all?

If it runs, is perfect. Through libraries are loaded at the start of the executable, and without them (ie some of them are missing) it will not start, but even if they are present, not all calls are called at start so maybe a certain call for a certain function changed the way it behaves and the application doesn't support this, leading to a crash. This are corner cases scenarios but they are possible
So you'll probably notice if it has incompatibilities with newer libraries. However, that's another issue altogether. To fix that you'll have to either adapt to the new libraries or downgrade the already installed.

  Is it necessary to do a workaround such as installing gcc?

gcc is a compiler. Only if you will compile code using C or C++ you need to install it. Other cases may need a workaround, but I haven't seen a "binary" (already compiled executable) in need of the gcc compiler to run.

  How do I find out what libraries I might need to run this software? (or any other piece of 32-bit software that isn't offered through a package manager)

Is a bit brutish, but if the instructions doesn't say exactly what libraries you need, or use the ld-linux.so --list command. Example:

$ /lib64/ld-linux-x86-64.so.2 --list /bin/bash
    linux-vdso.so.1 =>  (0x00007fffd479f000)
    libtinfo.so.5 => /lib/x86_64-linux-gnu/libtinfo.so.5 (0x00007f0d39138000)
    libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f0d38f34000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f0d38b6a000)
    /lib64/ld-linux-x86-64.so.2 (0x00007f0d3937f000

(the ldd binary provides the same output, thanks to @ubfan)

As you can see, bash uses linux-vdso, libtinfo.so, libdl.so and libc.so. If those libraries are correct then bash is happy with them. This is for dinamicaly linked binaries. You may use --verify instead to check if the binary is really dynamically linked.

Then you take the name of the libraries, lets say libtinfo.so.5, which it included in the packages:

File                                Packages
/lib/i386-linux-gnu/libtinfo.so.5   libtinfo5 [not amd64]
/lib/x86_64-linux-gnu/libtinfo.so.5 libtinfo5 [not i386]
/lib32/libtinfo.so.5                lib32tinfo5 [not i386]
/lib64/libtinfo.so.5                lib64tinfo5 [not amd64]
/usr/lib/debug/libtinfo.so.5        libtinfo5-dbg
/usr/libx32/libtinfo.so.5           libx32tinfo5

So, we just have to install the correct package for the architecture of the binary (if it's 32-bits, add :i386 to the name of the package, 64-bit :amd64) and we will be good to go.

Needles to say, to run 64-bits binaries in a 32-bit platform your CPU must be 64-bits capable (most of the systems from 2008 and later are) and most likely will require a 64-bits kernel installed.


Language Support has an unwanted Chinese language option

I had the same problem (Chinese showing up in lists and once even as the system language) and this command solved it:

sudo locale-gen --purge


Ubuntu 18.04 cloud image does not get DHCP IPv4 address

I've experienced the same problem on my RasPi 2 install of Ubuntu Server 18.04 LTS (armhf).

dhclient fixes the problem temporarily, but rebooting the system disables IPv4 again.

I will add this... I was able to enable a work-around by adding the following cronjob to start dhclient at boot:

@reboot /bin/sh dhclient


How to boot to root shell when GRUB recovery menu fails to load a shell?

u can manually edit ur grub file.
For example, when booting up, press Shift to get into grub2, and press e to edit
the commandline, change the commandline:
append init=/bin/sh

linux  init=/bin/sh

and if you are lucky, you can get in a shell.
How to boot GRUB2 into the simplest Linux shell ?


windows 10 is not loading after installing ubuntu 14.04?

In Ubuntu open a terminal and run sudo os-prober then sudo update-grub and finally reboot. If that doesn't resolve your issue you will want to boot Windows installation media in UEFI mode provided that Windows has been installed in UEFI not legacy mode then select repair your computer, troubleshoot and finally startup repair


I can no longer log into my Ubuntu server anymore

Passwords of other users are not available (easily) even to root. They are hashed in the /etc/passwd database and /etc/shadow as well.

Your best bet here is to reset the password of your user with passwd like Android Dev suggested in the comments:

sudo passwd <yourusername>

and follow the on-screen steps to set a new password.


How do I obtain log info from the installer?

The installer logs to /var/log/installer

I believe the mini.iso uses the debian-installer: See this page for more info on debugging the installer:

https://www.debian.org/releases/stable/i386/ch06s01.html.en
https://wiki.debian.org/DebianInstaller
https://wiki.ubuntu.com/DebuggingUbiquity


Ubuntu 14.04 not logging in after NVIDIA update

While Kali may load, press e and then go to Kali.

After the command, write:

nouveau.modeset=0

Then hit F10.

This might solve your problem.


How to use DRBD for entire system replication

Replicating the entire system in a high-availability scenario is probably not a good idea, for two reasons:

There are a few configuration parameters that are unique to each server: for example, the hostname and IP address, possibly the mapping of DRBD devices to disks.  Setting the system up so that it can choose the correct configuration based on some "environmental" parameter (e.g., CPU serial number) is definitely more trouble than it's worth.
One of the advantages that High-availability setups give you, is the ability to do system upgrades without service downtime: you upgrade the "backup" system, test that it works, exchange the "primary" and "backup" roles, upgrade the former primary system.  If something goes bad, you still have at least one system up and running. Setting up an automated entire system replication voids this procedure: if you upgrade one system, the other gets upgraded too: you likely cannot do that while the service is running, and you loose the "disaster-recovery" feature.

That said, it is possible to replicate exactly the parts of the system you need to have a "hot spare" for the production systems, ready to kick in in case the primary server goes down.

The exact details of how you do this depend on the service you want to run (www? mysql? nfs?), but the general idea is: replicate configuration and mutable data.  For example, assuming you want to have an highly-available NFS server, you can proceed like the following (on both servers):

Set up a replicated DRBD disk and mount it on /nfs on both servers (primary and backup).
Create directories /nfs/etc and /nfs/data
Symlink /etc/export to /nfs/etc/export and make it export the /nfs/data filesystem to clients.
Have the NFS service managed by heartbeat, instead of by the system init/upstart daemon, so that it goes up and down according to the server role (primary or backup) and the availability of the DRBD disk.

This is rather sketchy, but should be enough to get you started.


How is information passed between ipconfig and the init process at boot time

The configuration for your network interfaces is in /etc/network/interfaces, and IPv6 is fully supported. Here is an example from one of my systems:

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
    address xx.yy.zz.222
    netmask 28
    gateway xx.yy.zz.209

iface eth0 inet6 static
    address xxxx:yyyy:zzzz:1::222
    netmask 64
    gateway xxxx:yyyy:zzzz:1::1


Since I didn't get any answer I've found a solution. Maybe it'll help someone out.

I have reinstalled Python 3.6.4 to the system.

And then I have created the virtual env in this way:

    python3.6 -m venv myvenv

And it's worked for me. I didn't see such solution anywhere while googling. It was said everywhere that it's a bug of Ubuntu 14.04 LTS itself and several workarounds were suggested but nothing has worked for me except the above following.

Thanks.


Behind proxy, environment variable http_proxy should be set. This can be done in either of the two ways.
1.Create apt.conf file in /etc/apt directory if not present and add the following line to it.
Acquire::http::Proxy "http://user:password@server:port";
2.Simply set the environment variable using the following command from terminal.
export http_proxy=http://user:password@server:port
Finally a small tweak, add -E option to the command for the environment variables to be used as follows
sudo -E apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 58B98E87


How to modify waiting time of the dual boot menu

Open a terminal window, then back up the existing grub config file:

sudo cp /etc/default/grub /etc/default/grub-backup

Now (using sudo or gksudo depending on your editor of choice) edit /etc/default/grub and change the number in this line of the file

GRUB_TIMEOUT=10

to your desired waiting time in seconds.

Exit, saving the file, and then run

sudo update-grub

On your next  boot you should have the wait time you specified.


How do I associate native applications with file types in WINE

Here is how you associate native applications in wine:
From the Wine FAQ
You can associate winebrowser with any file types to achieve the result. winebrowser program uses xdg-open to find the native application for a file type.
You need to create a registry file with these contents to associate .pdf files. Save it as import.reg file in your home folder.
[HKEY_CLASSES_ROOT\.pdf]
@="PDFfile"
"Content Type"="application/pdf"
[HKEY_CLASSES_ROOT\PDFfile\Shell\Open\command]
@="winebrowser \"%1\""

Now import the registry file using this command
regedit $HOME/pdf.reg

This will open pdf files from Wine applications with the native application which is set as default for a pdf file.


The simplest way to get steam on the system is to download the .deb file from the valve developer community. You can get the download here.


How to install apps which is in downloads folder?

If you just want to install indicator-multiload you have done it wrong. You have downloaded the source code of the program, while you can use it to install it, you need to compile it, and this can be non-trivial for someone without programming training.

To install software in Ubuntu you should always look first in the Ubuntu Software Centre.

It the program is not available in it, or you want a newer version you should look for PPAs.

If there is no PPA avaliable or you want to just download one file, look for a .deb file. You should be able to install it just with a double-click.

There are more ways to install programs in Ubuntu, but if you are a novice you should probably avoid them for now.


Problems uploading package to launchpad due to "checksum mismatch" error

It seems the problem was in the untangle firewall that is between me and launchpad. I've uploaded the files by hand at home and sent them through FTP to launchpad.

I used the command line "ftp" client since I cannot use "dput" on OSX and ncftp did not worked (maybe because it didn't set the correct email as password of the anonymous user)?

Anyway this is the sequence to do to upload manually:

Connect with FTP to ppa.launchpad.net
Use anonymous as user
Use the mail address you used to register to launchpad as password
change directory to ~yourlaunchpadusername/yourppa/ubuntu
upload the files packagename_version.dsc, packagename_version.tar.gz, packagename_version_source.changes
exit FTP and wait for email confirmation.

If your build doesn't complete correctly (in my case the problem was an unmet dependency) you have to upload the files with a different version or you'll get an error (I changed ~ppa2 to ~ppa3 in the end).


Why would removing gnash also remove gnome-desktop-enviroment?

gnome-desktop-environment depends on swfdec-gnome, which in turn depends on gnash.

Fortunately gnome-desktop-environment is a metapackage (e.g. it doesn't install any files); removing it shouldn't cause problems.


Apparently the issue was not enough time. Solved after adding bootstrap-timeout: 1800 to .juju/environments.yaml file.


KVM/Spice/Remote-Viewer: Need assistance troubleshooting USB redirection

Although I've got a gentoo flavor maybe this gives you a hint.
Recompiling qemu and spice-gtk with usbredir USE flag did the job for me. Should be a ./configure parameter for you.


Your rules look fine for ssh, but I think you have some name resolution problems, as proven by it working if you use the IP address. You say that your hosts file, etc is set up correctly. is that on the target machine or the source? The source machine needs to be able to get the target machines name ... a good way of doing this is by enabling DHCP on your router. If you want to verify that this is the problem, manually put an entry in your hosts file on the source machine.

the strange part is that the log does say the port is blocked ... from what I can see (and from the output of my own UFW status) it should be fine.


It is now available in ubuntu-toolchain-r too:
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt update
sudo apt install gcc-9

If the add-apt-repository command cannot be found, run this:
sudo apt install software-properties-common


Is it possible to import a keyring to another from its binary files

I have asked the same question on superUser: https://superuser.com/questions/508916/is-it-possible-to-import-a-gnome-keyring-to-another-from-its-binary-files

In short, the answer is: for a recent enough version of seahorse, just copying the directory will work


Just use internal card ip addres

sudo iptables -t nat -A POSTROUTING -s 192.168.254.0/24 -j MASQUERADE

It works until reboot.

PS

/proc/sys/net/ipv4/ip_forward should be enabled

sysctl -w net.ipv4.conf.all.forwarding=1

You can uncomment in /etc/sysctl.conf to keep this after the system restart

net.ipv4.ip_forward=1


/usr/include contains data about your packages, which means that a fresh install wouldn't write anything to it. I'm afraid your system has suffered a great loss.

Maybe you could try an update for your packages, but from experience, I know this doesn't usually work with Ubuntu.

sudo apt-get update
sudo apt-get upgrade

If your lucky, the apt cache will still have information about packages that used /usr/include. You can find a list using dpkg -S /usr/include/*, and use sudo apt-get reinstall [package] to fix things.

Edit : Best solution found in the comments :

sudo apt-get install --reinstall $(dpkg -S /usr/include/*|cut -d':' -f1|tr -d ','|tr '\n' ' ')

In order to reinstall all packages that where corrupted.


This is not a Perl error. Perl would have said:

Can't find string terminator '"' anywhere before EOF

It seems the shell can produce similar error, though:

echo 'x="a' | sh
sh: 2: Syntax error: Unterminated quoted string

How do you run the script? Does it contain a shebang line? Try running it with explicit perl:

 perl script.pl


General Problem: No Sound, can't reduce Brightness. lspci attached

I could solve the sound problem in my compaq cq42-121la.

Adding the ppa (via command line):

sudo add-apt-repository ppa:ubuntu-audio-dev/ppa
sudo apt-get update

Install the linux-alsa-driver-modules package (via command line):

sudo apt-get install linux-alsa-driver-modules-$(uname -r)


Install the latest version of the (tested) proprietary driver for your grahics card via Additional drivers in Xubuntu.
Go to chrome://flags/ with the latest version of Google Chrome.
In this page, enable Override software rendering list and relaunch Google Chrome.
Go to chrome://gpu/ and see if WebGL is active.
Look if your problem is gone or not.


When that happens to me I usually right click the window tab on the task bar and click move from the context menu, after that just dragging the mouse (without clicking anything) to an active screen should work.


Problem changing default search engine in Firefox address bar

Enter yahoo in the search bar of about:config and check whether there is some value similar to the Yahoo search URL. Change this one to the Google search URL too.

BTW: This question doesn't seem to be related to Ubuntu


Edit 1.5 year later:

Actually I finally solved the issue by... moving my wi-fi adapter higher :) I.e. before that, the device was connected directly to a PC, in the back. I used a 1m USB extension cable to move it away from a computer. And in the same  time, put it higher. Now it seems obvious for me, it wasn't back then, when I asked the question :)

But the below answer did help too, just not in 100%.

Someone suggested doing the following. Create the following file:

 /etc/modprobe.d/8192eu.conf

And add the following line:

options 8192eu rtw_power_mgnt=0 rtw_enusbss=0 rtw_ips_mode=0

From what I have found, the meaning of the options is like this:

-Disable power management:

options 8192eu rtw_power_mgnt=0

-Disable USB autosuspend:

options 8192eu rtw_enusbss=0

-Disable power management:

options 8192eu rtw_ips_mode=0

This helped with entering the sleep mode repeatedly problem, which improved the overall situation, although not solved it in 100% percent. This is, however, a topic for another question.

One of the sources:
https://forum.manjaro.org/t/solved-rtl8192-wifi-performance-problem-after-last-stable-update/25481


Shell Script - How to run script after mysql is ready?

Finally I found the answer! :D

while !(mysqladmin ping)
do
   sleep 3
   echo "waiting for mysql ..."
done
echo "starting the main script"
#main script
#main script
#main script


No bootable device found after install on already non booting Toshiba C650

Did you install Ubuntu?  My Laptop never works with the 'desktop' installer (the preview livecd) but always works with the 'alternative' installer.  It has the same symptoms, grub simply won't work and no attempt at recovering it succeeds.  Try that and see if that works.


Try setting nomodeset when launching the Live CD/USB. See the following answer.


How to boot Ubuntu as third OS and how to configure 3-OS loader?

It sounds like your system still has FastBoot enabled. Can you enter the BIOS of your system? It is usually F2 or F12 or some other function key based on your computer make. Once in there, disable FastBoot and also you could change your boot priority so that Ubuntu is higher than Windows. If you can post screenshots (photos) of what you're seeing in BIOS, we can help you get Ubuntu to boot. Good luck!


How do I sync music to my Sony Walkman (Z Series) using Rhythmbox?

I found this really old article on how to work around the bug.

Creating an empty file called .is_audio_player in the root of the SD card  solves the problem, I can transfer and delete files from Rhythmbox now.


Ubuntu 18.04 Netflix Error F7701-1003 FireFox 59.0.2 DRM enabled

Go into Preferences » Privacy & Security » History.  If you have told Firefox to "Never remember history" then you will get the F7701-1003 error.  Change it to "Use custom settings for history" and then make sure all four of the check-boxes that appear underneath it are unchecked.  Netflix should now work.

Note:  You probably don't need to have all four of those checkboxes unchecked.  I suspect only the first two are essential.  I haven't, however, bothered to test the theory.  :)


How do I find out where Ubuntu created partitions on my laptop?

You can also use GParted for this; it will give you a nice graphical display of all partitions; you can also modify / delete / create partitions using it, if you want.

You can install it using the Software Center, or by typing sudo apt-get install gparted.


MX4 Pro Ubuntu Edition can't normal boot

Start your phone, connect it via usb to your ubuntu host, use ubuntu-device-flash touch --device arale --channel ubuntu-touch/stable/meizu.en
reboot the phone, apply a factory reset, reboot.
Be aware, you are doing a factory reset.


package 'libhtml-parser-perl': Is a directory E: Sub-process /usr/bin/dpkg returned an error code (2)

Run sudo dpkg --force-all -P libhtml-parser-perl


Apparently php5-json was removed from php5-common.

what happened to json_encode in 13.10 php?

This seems to fix it:

sudo apt-get install php5-json

Then restart apache:

sudo service apache2 restart


Can I run Wallpaper Engine (from Steam) in Ubuntu 16.04 LTS?

You can't run software designed to manipulate the Windows desktop with Ubuntu.

If that is an exlusive feature you need then you should not switch to Ubuntu.

However there are a lot of customizations of the GNOME desktop (Ubnutu default) available (see e.g. GNOME-Look), and of course there are many Ubuntu flavors that come with a variety of other desktop managers, each with a different look and feel.


How do I find out about the update history in Ubuntu distribution update channels?

I think I answered my own question. The following page shows the updates that landed in the focal package:
https://launchpad.net/ubuntu/focal/+source/pulseaudio/+changelog
This would also work for other packages by simply replacing pulseaudio with your package of choice.


Opening Spotify shows "Failed loading skin"

I do it like that

rm -rf ~/./.cache/spotify

rm -rf ~/./.local/share/spotify

rm -rf ~/././.config/spotify

than whereis spotify

than simply remove from those locations:

sudo rm -rf /usr/bin/spotify /usr/share/spotify

and than install spotify like it is described in http://howtoubuntu.org/how-to-install-spotify-in-ubuntu

it works but i have loose all my spotify configurations


By default, the latest ubuntu install (12.04.2, and few others behind) hides messages and shows a nice animated image (splash) in a fancy resolution.

To make sure to view the console and possibly see what's hanging behind that dark screen:

/etc/default/grub (edit & save):

# find line below and put a # in front of it
# GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
# and put this one:
GRUB_CMDLINE_LINUX_DEFAULT="nomodeset"

Now update grub boot entries with these new defaults:

you@yourmachine:~$ sudo update-grub

And at your next start/shutdown process, you should see message lines with [ OK ] or [ ERROR ] or something wrong following it's title:

* Starting network shares                   [ OK ]
* Starting mysql server                     [ OK ]
* ...later when shutting down...
* Stopping mysql server                     [ OK ]
* Not Stopping something like it should     [    ]

nomodeset: You usually can toggle between the splash screen and the console messages with Esc key, but some video cards or lack of drivers can't handle the mode/capacities the boot process is using. nomodeset ensures it's using basic common capacities and makes sure you see messages (provided you don't press ALT-F1 to F7 during boot/shutdown to view other terminals than the one used for services startup/shutdown).

Edit: You can also try without nomodeset if you run into troubles starting X. GRUB_CMDLINE_LINUX_DEFAULT=""


How do I do a complete BIND9 DNS Server Configuration with a hostname?

Complete DNS server in ubuntu server 12.

First of all change the ip address of your server form DHCP to STATIC for this use the following command

sudo nano /etc/network/interfaces

and add:

auto eth0
iface eth0 inet static
address 192.168.1.5
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
# dns-nameservers

Restart networking daemons

sudo /etc/init.d/networking restart

Before configuring a DNS server in linux Ubuntu you have to make domain name first and then you will proceed. First you will check your hostname command for this is

sudo nano /etc/hostname

 nefitari

(This is my Ubuntu server hostname yours might be different .You can change this according to your need)

Now after hostname, you have to make domain name for your server. Say servername.domain.com it is better practice that whenever you are configuring server for home use or so, do not use .com but .hom or .net or whatever you like. Give the below command

  sudo nano /etc/hosts

add if it does not have it:

  127.0.0.1   localhost

  192.168.1.5     nefitari.autun.hom    nefitari

In my file 127.0.0.1 is for localhost and I have changed the second IP address 127.0.1.1 with my server IP that is 192.168.1.5 now I enter my domain name having my hostname nefitari first then my domain name autun.hom and then alias nefitari. You can select of your own, hostname.abc.net or hostname.home.lan etc. but remember changing to this file need to restart your server and then login. Restart is must

Now install BIND9

 sudo apt-get install bind9

After installation just configure the below files step by step

Named.conf.options
Named.conf.local
/etc/resolv.conf

Now configure file named.conf.options
This file is use for DNS IPs It mean that your server must connect to some DNS outside. When you buy domain name from ISP’s they normally gives you their own DNS IPs. You can use open DNS IPs of google or so. In my case I am using my own ISP DNS IPs.

 sudo nano /etc/bind/named.conf.options
 forwarders {
 # Give here your ISP DNS IP’s
192.168.1.1;    # gateway or router
182.176.39.23;
182.176.18.13;
68.87.76.178;
  };

***Save the file and exit***using control x press y and overwrite the file

Now edit the file named.conf.local
This is the file in which we define forward zones and reverse zones. It means that when we enter domain name it will translate it into IP address and when we enter IP address it will simply convert it into name.

sudo nano /etc/bind/named.conf.local

will show:

# Our forward zone
zone "autun.hom" {
 type master;
 file "/etc/bind/zones/db.autun.hom";
 };

# Our reverse Zone
# Server IP 192.168.1.5
zone "1.168.192.in-addr.arpa" {
  type master;
  file "/etc/bind/zones/db.192";
 };

***Save the file and exit***using control x press y and overwrite the file

Now we will make these two database files db.autun.hom and db.192 in zones folder

First make the directory zones in /etc/bind/

  sudo mkdir /etc/bind/zones

Before making files let me clear you that I have different devices

Devices       IPs

Server itself    192.168.1.5
Gateway          192.168.1.1
Win7pc       192.168.1.50

Now in zones directory we will create two files first db.autun.hom. I am just copying the db.local already present in /etc/bind folder to zones folder by changing its name to db.autun.hom.
I will put these IP’s in my db.autun.hom file. Let’s start

sudo cp /etc/bind/db.local  /etc/bind/zones/db.autun.hom

Now use the command below to edit the file

sudo nano /etc/bind/zones/db.autun.hom

 ;
 ; BIND data file for local loopback interface
 ;
 $TTL    604800
 @       IN      SOA     nefitari.autun.hom. webuser.autun.hom. (
                          2         ; Serial
                     604800         ; Refresh
                      86400         ; Retry
                    2419200         ; Expire
                     604800 )       ; Negative Cache TTL
  ;
autun.hom.      IN  NS  nefitari.autun.hom.
autun.hom.      IN  A   192.168.1.5
   ;@               IN  A   127.0.0.1
   ;@               IN  AAAA    ::1
nefitari            IN  A   192.168.1.5
gateway         IN  A   192.168.1.1
win7pc          IN  A   192.168.1.50
www     IN  CNAME   autun.hom.

Save it and exit

Webuser.autun.hom. is the email who will access name server. You can
write any name instead webuser like admin, root or host master etc.
Autun.hom. is my NS means name server
Autun.hom.changing to IP 192.168.1.5
@ IN A 127.0.0.1 and AAAA  ::1 can be comment out you should not need
it because db.local is already present in /etc/bind it is just a copy
of that file. So no need you can delete it
Changing Nefitari to IP 192.168.1.5
Gateway to IP 192.168.1.1
Win7pc you can name your windows PCs or Linux Clients to any name but
remember IP of that client must correctly be inserted into file. In
my case I gave IP of windows PC 192.168.1.50
Last, I am using CNAME means canonical name it is just an alias to
nefitari. Means that you can access your server by entering
www.autun.hom instead nefitari.autun.hom . You can omit this or
comment it. It is just up to you.

Now create reverse lookup zone file

sudo cp /etc/bind/db.127    /etc/bind/zones/db.192

Now use the command below to edit the file

sudo nano /etc/bind/zones/db.192

   ;
   ; BIND reverse data file for local loopback interface
   ;
   $TTL    604800
   @       IN      SOA     nefitari.autun.hom. webuser.autun.hom. (
                          2         ; Serial
                     604800         ; Refresh
                      86400         ; Retry
                    2419200         ; Expire
                     604800 )       ; Negative Cache TTL
   ;
        IN  NS  nefitari.
1   IN  PTR gateway.autun.hom.
5   IN  PTR nefitari.autun.hom.
50  IN  PTR win7pc.autun.hom.

Save it and exit

Now when you are done with your zone file you have to check it whether it is working correctly or not by entering the command below for forward zone file

named-checkzone autun.hom /etc/bind/zones/db.autun.hom
zone autun.hom /IN: loaded serial   2
Ok

Now check the reverse zone file

named-checkzone autun.hom /etc/bind/zones/db.192
zone autun.hom /IN: loaded serial   2
Ok

If the output of your named-checkzone is same as above then it is working fine otherwise you made some mistake in file.

Now edit the file resolv.conf

sudo nano /etc/resolv.conf

nameserver      192.168.1.5
domain      autun.hom
search      autun.hom

Enter the following lines into to your resolv.conf file and save it

Restart the bind

sudo /etc/init.d/bind9 restart

After bind start check your setting in log file

tail -f /var/log/syslog

it must not have any error in the log

Checking forward zones

host –l autun.hom

Output should like this

 autun.hom name server nefitari.autun.hom.
 autun.hom has address 192.168.1.5
 gateway.autun.hom has address 192.168.1.1
 nefitari.autun.hom has address 192.168.1.5
 win7pc.autun.hom has address 192.168.1.50

Now use NSLOOKUP

nslookup autun.hom

OUTPUT

Server: 192.168.1.5
Address: 192.168.1.5#53

Name: autun.hom
Address: 192.168.1.5

Use DIG

 dig gateway.autun.hom

 ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 35612
 ;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 1, ADDITIONAL: 1

 ;; QUESTION SECTION:
 ;gateway.autun.hom         IN  A

 ;; ANSWER SECTION:
 gateway.autun.hom      604800  IN  A   192.168.1.1

 ;; AUTHORITY SECTION:
 Autun.hom.     604800  IN      NS  nefitari.autun.hom.

 ;; ADDITIONAL SECTION:
 Nefitari.autun.hom.    604800  IN      A   192.168.1.5

 ;; Query time: 12 msec
 ;; SERVER: 192.168.1.5#53(192.168.1.5)
 ;; WHEN: Thu Aug 8 01:56:25 2013
 ;; MSG SIZE  rcvd: 90

Output should similar to the above, check status: NOERROR means it is resolving check ANSWER SECTION: gateway.autun.hom is resolved into 192.168.1.1

Checking reverse zone

 host 192.168.1.1

Output

 1.1.168.192.in-addr.arpa domain name pointer gateway.autun.hom

If it gives you an error like below

 host 1.1.168.192.in-addr.arpa. not found: 3(NXDOMAIN)

This means that you made some mistake in /etc/bind/named.conf.local file in reverse zone
If your server IP is 192.168.1.5 then your reverse zone looks like this

zone "**1.168.192**.in-addr.arpa" {
 correct ip reversing
};

Sometime people made mistake in reversing the ip like (just an example)

zone "**0.168.192**.in-addr.arpa" {
incorrect ip reversing
};

Use NSLOOKUP

nslookup 192.168.1.1

Server: 192.168.1.5
Address: 192.168.1.5#53

1.1.168.192.in-addr.arpa    name=gateway.autun.hom

If you get NXDOMAIN or SERVFAIL like errors  it means that one of your zone file is not working correctly

Now you can ping ubuntu.com or dig ubuntu.com for the first time it will take several miliseconds to resolve the name ubuntu.com but when you run it second time it will take 1, 2 or 3 seconds normally form 1 to 10 mili seconds are normal and it means that your DNS is working properly

Configuring clients

windows side

open network connections
select change adapter settings
select properties
select internet protocol version IPv4

and here give the IP address (in my case it is 192.168.1.50 have you remember win7pc)

IP address 192.168.1.50
Subnet Mask 255.255.255.0
Default Gateway 192.168.1.1
primary DNS 192.168.1.5 (my new BIND DNS server ip)
in the same window select Advance
select DNS tab
Type in the text box below here In DNS Suffix for this
connection:autun.hom
click ok
click on validate setting upon exit
click ok

and you are done with it open CMD

ping gateway

it must gives you some replies

similarly

ping 192.168.1.1 or 5

it must gives you some replies

Test Your Server to Outside World

Now you can ping ubuntu.com or dig ubuntu.com for the first time it will take several miliseconds to resolve the name ubuntu.com but when you run it second time, it will take form 1 to 10 mili seconds, its normal time and it means that your DNS is working properly
Configuring clients

windows side

open network connections
select change adapter settings
select properties
select internet protocol version IPv4

and here give the IP address (in my case it is 192.168.1.50 have you remember win7pc)

IP address 192.168.1.50

Subnet Mask 255.255.255.0

Default Gateway 192.168.1.1

primary DNS 192.168.1.5 (my new BIND DNS server ip)

select Advance (in the same window)

select DNS tab

Type in the text box below here In DNS Suffix for this connection:autun.hom

click ok

click on validate setting upon exit

click ok

and you are done with it open CMD

Code:

 ping gateway

it must gives you some replies

similarly

Code:

 ping 192.168.1.1 or 5

it must gives you some replies
you can use NSLOOKUP
Code:

 nslookup gateway

LINUX CLIENTS

Code:

 sudo nano /etc/network/interfaces

type the following lines

Code:

 auto eth0
 iface eth0 inet dhcp

Now restart Network Deamons

Code:

 sudo /etc/init.d/networking restart

to force client renew IP command

Code:

 sudo dhclient -r

Now obtain fresh IP:

Code:

 sudo dhclient

If you are running DHCP server on your Network then enter the domain name and name server in dhcpd.conf file; for example I have DNS server named nefitari.autun.hom and IP address is 192.168.1.5 like as under

Code:

 option domain-name "nefitari.autun.hom";
 option domain-name-server  192.168.1.5;

source


How to build the mainline kernel source package?

Looks like you're brave enough :) you could try following these instructions to create your own .deb packages from the mainline kernel.

Try reading this general document first:

https://help.ubuntu.com/community/Kernel/Compile

Here are specific instructions on how to compile a kernel for 11.10 (although you'd be doing so from the 3.2 source tree, so some things may ebd up being different).

http://blog.avirtualhome.com/2011/10/28/how-to-compile-a-new-ubuntu-11-10-oneiric-kernel/

Now, the problem with these instructions is they assume a source tree with a debian/ directory, which is where the control files that let you build a package reside. It's not a big problem though; it's easy to get a packageable source tree:

Get the mainline kernel tree

git clone https://github.com/torvalds/linux.git

Look at the latest mainline kernel (as of today http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.2-rc6-precise/). There are three patch files (0001-base-packaging.patch, 0002-debian-changelog.patch, 0003-default-configs.patch). Download these three files.
Change to your fresh new linux source directory and apply all 3 patches in order:

patch -p1 <0001-base-packaging.patch

patch -p1 <0002-debian-changelog.patch

patch -p1 <0003-default-configs.patch

You'll now have a nice debian/ directory with packaging information. Then you can apply the instructions in the two URLs I mention above to configure and build packages from your kernel. Hopefully this will also create a kernel-source package.


The problem got solved by itself after some Ubuntu updates.

Currently my xorg.conf file looks like this:

Section "ServerLayout"
    Identifier "layout"
    Screen 0 "nvidia"
    Inactive "intel"
EndSection

Section "Device"
    Identifier "intel"
    Driver "intel"
    BusID "PCI:0@0:2:0"
    Option "AccelMethod" "SNA"
EndSection

Section "Screen"
    Identifier "intel"
    Device "intel"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "PCI:1@0:0:0"
    Option "ConstrainCursor" "off"
EndSection

Section "Screen"
    Identifier "nvidia"
    Device "nvidia"
    Option "AllowEmptyInitialConfiguration" "on"
    Option "IgnoreDisplayDevices" "CRT"
EndSection


You have to install the openjdk-8-jre:

sudo apt-get install openjdk-8-jre

Next switch to the jre-8 version:

$ sudo update-alternatives --config java
There are 2 choices for the alternative java (providing /usr/bin/java).

Selection    Path                                            Priority   Status

* 0            /usr/lib/jvm/java-9-openjdk-amd64/bin/java       1500      auto mode
  1            /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java   1500      manual mode
  2            /usr/lib/jvm/java-9-openjdk-amd64/bin/java       1500      manual mode

check java version:

$ java -version
openjdk version "1.8.0_151"
OpenJDK Runtime Environment (build 1.8.0_151-8u151-b12-0ubuntu0.17.10.2-b12)
OpenJDK 64-Bit Server VM (build 25.151-b12, mixed mode)

Same procedure for Oracle java.


First, create a directory to be accessible by user. Here user is just a local user. Replace it with whatever user you want

sudo mkdir -p /var/sftp/files

Change the ownership of the files directory to sftp user so that user can read and write on this directory.

sudo chown user:user/var/sftp/files

Set the owner and group owner of the /var/sftp to root. This will ensure that files can be uploaded only in one directory i.e. files and not in the parent directory.

sudo chown root:root /var/sftp
sudo chmod 755 /var/sftp

Now, edit the SSH config file

sudo nano /etc/ssh/sshd_config

Append these lines to the end of the file

Match User user
    ForceCommand internal-sftp
    PasswordAuthentication yes
    ChrootDirectory /var/sftp
    PermitTunnel no
    AllowAgentForwarding no
    AllowTcpForwarding no
    X11Forwarding no

Replace user with the username from above.
Finally, save the configuration and restart SSH service

sudo systemctl restart ssh


Wacom Cintiq Express Key Remote not responding - 16.04

There is a dongle but you might not have noticed it plugged in to a USB port on your Cintiq. It looks like this:

http://www.antcgi.com/Blog/wp-content/uploads/2015/09/27QHD_USBDongle.jpg

Since you don't have any serial numbers listed in your wacom_remote sysfs directory (

cd /sys; sudo find . -iname "wacom_remote" | xargs ls

), I can see that the pairing between your dongle and your remote has been broken. There is a way to unpair the remote from the command line (

sudo echo * > unpair_remote

in the wacom_remote directory), but it is unlikely that you did this. If you use multiple remotes, one remote could "pair over" the pairing of the first remote, but I don't know how the pairing gets lost other than these two methods. FYI the remote has the ability to pair with up to 5 remotes.

Anyway to repair your device follow the instructions at this link:

http://wacom.com/en/support/faqs/cintiq-27qhd-and-cintiq-27qhd-touch/how-do-i-pair-the-expresskey-remote

or use google's cache of those instructions:

http://webcache.googleusercontent.com/search?q=cache:DHL00PhaQQsJ:wacom.com/en/support/faqs/cintiq-27qhd-and-cintiq-27qhd-touch/how-do-i-pair-the-expresskey-remote&num=1&client=ubuntu&hl=en&gl=us&strip=1&vwsrc=0


Dualboot Asus n56v (ubuntu / win 7 x64) - ubuntu doesn't detect partition table made by windows

Before installing windows: it may not be necessary,:
a) start live-cd / stick and use gparted, create a GPT-partition table as followed:
leave some empty space for windows (~120GB), then create a possible swap and root partition for ubuntu. (maybe it will work without: in my case it didn't)
b) installing windows, using the free space: windows will automatically set the partitions (3 partitions: one UEFI, one windows boot, one windows data)
c) It did not work installing from the CD (bios was able to boot win7 in uefi, but was not able to boot ubuntu in uefi), however from usb-stick went fine.
ubuntu needed an 1MB partition with the "flag": bios_grub (when made with gparted), also possible if you set the partition type (using the installer): boot-partition from the installer partitioning program
d) I created my partition table: sda5: swap (8GB), sda6 (100GB), sda7 (1MB); I selected sda1 for the location of the bootloader (the selection below the partition table) (the efi-partition - sda1 in my case - can keep a lot of boot-loaders
The installer automatically set up an uefi bootloader (in my case) named "linuxmint"
e) open terminal: mount all partitions as before and try again the efibootmgr command (two bullets above) and continue: edit /etc/grub.d/40_custom adding and insert the following:

menuentry "Windows x86_64 UEFI-GPT" {       search --fs-uuid --no-floppy --set=root ###-####      chainloader (${root})/EFI/Microsoft/Boot/bootmgfw.efi      }

-#### is the UUID from sda1 (to find out use: 'ls -la /dev/disk/by-uuid/')
advice: use grub-customizer for easier handling
f) use: "update-grub" and restart: the correct bootloader (if you're looking into bios) is named: linuxmint (P0...), not GRUB2 (if avaible too)
FINISH


How to connect to Wifi Network with i3wm?

I use (and would recommend) nmtui, a curses based TUI that will allow you to edit and activate connections.

It should already be installed on your system, but if not, you can get it by running sudo apt install network-manager.


First off, you don't need to use commas.  Arrays in Bash are space-delimited; not comma-delimited as is the case in some languages, such as javascript.

So your code should look something like this:

arr=("a" "b" "c" "d")
team_one=("${arr[@]:0:2}")
echo "${arr[@]}"
# a b c d
echo "${team_one[@]}"
# a b

The problem with your code was that "sdf","sdf","sdf","sdf" in an array is treated as one big long string rather than as four instances of the string sdf.


Enlisted MAAS nodes will not PXE boot for commissioning

After analyzing /var/log/maas/pserv.log, which is the PXE/TFTP boot server log, I noticed that it was complaining that there were no PXE images, or ephemerals, found on the server. The log asked to run maas-import-pxe-files again, even though I had run it multiple times.

2013-05-06 08:02:40-0400 [HTTPPageGetter,client] Stopping factory <HTTPClientFactory: http://localhost/MAAS/api/1.0/pxeconfig/?cluster_uuid=91149761-d1
49-4396-86a0-a3a2a6b57c7d&local=192.168.60.10&mac=08-00-27-3c-7b-91&remote=192.168.60.106>
2013-05-06 08:02:40-0400 [HTTPPageGetter,client] Stopping factory <HTTPClientFactory: http://localhost/MAAS/api/1.0/pxeconfig/?cluster_uuid=91149761-d1
49-4396-86a0-a3a2a6b57c7d&local=192.168.60.10&mac=08-00-27-3c-7b-91&remote=192.168.60.106>
2013-05-06 08:02:40-0400 [HTTPPageGetter,client] Logged OOPS id OOPS-bdc099b3ed2983f2eb94d6096a811915: No exception type: No exception value
2013-05-06 08:02:40-0400 [HTTPPageGetter,client] Logged OOPS id OOPS-ac4bdf5b247f85d2cb53baf0aa4c2183: EphemeralImagesDirectoryNotFound: The directory
containing the ephemeral images/info is missing (u'/var/lib/maas/ephemeral/raring/ephemeral/amd64').  Make sure to run the script 'maas-import-pxe-file
s'.

Notice, that it's looking in a raring directory for ephemerals. This directory doesn't exist.

After running the command again, I noticed that the maas-import-pxe-files only downloads ephemerals for Precise and Quantal, not Raring.

irossi@maasjuju:~$ maas-import-pxe-files
This utility may only be run as root.
irossi@maasjuju:~$ sudo !!
sudo maas-import-pxe-files
Downloading to temporary location /tmp/tmp.uTLWpre2Uz.
/tmp/tmp.uTLWpre2Uz ~
2013-05-06 08:14:25 URL:http://archive.ubuntu.com/ubuntu//dists/precise/main/installer-amd64/current/images/netboot/ubuntu-installer/amd64//linux [4965840/4965840] -> "linux" [1]
2013-05-06 08:17:04 URL:http://archive.ubuntu.com/ubuntu//dists/precise/main/installer-amd64/current/images/netboot/ubuntu-installer/amd64//initrd.gz [17446386/17446386] -> "initrd.gz" [1]
2013-05-06 08:17:18 URL:http://archive.ubuntu.com/ubuntu//dists/quantal/main/installer-amd64/current/images/netboot/ubuntu-installer/amd64//linux [5130968/5130968] -> "linux" [1]
2013-05-06 08:18:28 URL:http://archive.ubuntu.com/ubuntu//dists/quantal/main/installer-amd64/current/images/netboot/ubuntu-installer/amd64//initrd.gz [18668122/18668122] -> "initrd.gz" [1]
2013-05-06 08:18:45 URL:http://archive.ubuntu.com/ubuntu//dists/precise/main/installer-i386/current/images/netboot/ubuntu-installer/i386//linux [5015840/5015840] -> "linux" [1]
2013-05-06 08:19:35 URL:http://archive.ubuntu.com/ubuntu//dists/precise/main/installer-i386/current/images/netboot/ubuntu-installer/i386//initrd.gz [15977428/15977428] -> "initrd.gz" [1]
2013-05-06 08:20:37 URL:http://archive.ubuntu.com/ubuntu//dists/quantal/main/installer-i386/current/images/netboot/ubuntu-installer/i386//linux [5171760/5171760] -> "linux" [1]

I checked in the MAAS Server settings page (the gray gear icon) and the default distro for nodes was set to Raring Ringtail 13.04. The nodes were looking for a boot image for Raring that wasn't there. As soon as I changed this setting to Precise 12.04 as the default distro, all of the nodes booted successfully and were commissioned. It's working now, but I'm still not sure if this is user error or a bug. If anyone thinks it's a bug, I'll be glad to file it in Launchpad.


Corrupted OS After Upgrade from 19.10 to 20.04

Thanks for your help!
I have successfully managed to upgrade to ubuntu 20.04 while keeping my files and packages.
I did it accidentally, I was trying to repair a package by using the command sudo apt-get update and then sudo apt-get upgrade and Ubuntu just started to upgrade to 20.04 even though I just wanted my packages upgraded. I checked /etc/os-release and it said VERSION="20.04 LTS (Focal Fossa)".
Now because I only upgraded some packages, software updator told me that the upgrade wasn't finished even though the command exited. So, I clicked upgrade.
Now, everything works fine.
I dont  know what the problem was, but I ran fsck from a live media, upgraded my packages and tried to find firmware for my gpu (I couldn't).
Thanks for your help and suggestions!


Lost Windows Frames, how to get them back?

Looks like xfwm4 is messed up..Try this rm -R ~/.cache/sessions/* and logout/login..