How to make Gimp run as a single window? Gimp is nice, but the one thing that drives me nuts is that everything floats around in front of each other, often hiding the main window and forcing me to minimize all open windows until I find the one floating window that I am looking for.

I'd like to have the floating windows docked along the edges of that main window, the way practically every other application works. I know this floating thing is one of the things that make Gimp special, but it's not the kind of "special" that I like... I don't have a huge screen, so it quickly gets too cramped. And I often use Gimp briefly, multitasking with other apps, so the many Gimp windows are annoying.

How can I make Gimp run in one window, with everything else inside it?

This is Gimp 2.6.11 -- just because that's what came with my Ubuntu 11.10 installation.

Ubuntu 14.04 and higher

Open GIMP, and go to Windows > Single-Window Mode

Ubuntu 12.04

Single-Window Mode is only available since GIMP 2.8+. You will have to install GIMP 2.8 from a ppa if you want Single-Window Mode. Just follow the next instructions:

Add the GIMP PPA. Open the terminal and copy/paste the following command: sudo apt-add-repository ppa:otto-kesselgulasch/gimp && sudo apt-get update
Update GIMP using Update Manager or apt-get.
Open GIMP, and go to Windows > Single-Window Mode

Now you have a single window! For example, my GIMP main menu:

Gimp 2.8 is capable of doing what you want. You can grab the source from here: ftp://ftp.gimp.org/pub/gimp/v2.8/ and compile it on your own. This runs in single window mode.


How do I get a TP Link TL WN722N wireless card working? I recently built a barebones machine (shuttle SH67H3), installed Oneiric (64-bit) and everything was great (no wireless card but wired connection was fine).

Now our router has changed locations and I'm trying to get wireless to work. I purchased a TP-Link TL-WN722N because I saw this post and assumed it would be smooth sailing from the moment the wireless usb adapter arrived at my home. WRONG.

Has anyone had any experience setting this up? I've downloaded the compat-wireless-driver, compiled and run install (all successfully) but am unable to load it.

If there are any alternative devices that are known to work with my setup I would love to hear about them as well.

UPDATE

I've installed the linux backports modules successfully and rebooted several times. Still no wireless activity.

When I list the usb devices it can clearly see the wireless adapter (Bus 003 Device 003) plugged in:

user@ubuntu:~$ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 003 Device 003: ID 0cf3:9271 Atheros Communications, Inc. AR9271 802.11n
Bus 001 Device 003: ID 192f:0416 Avago Technologies, Pte.
Bus 001 Device 004: ID 413c:1003 Dell Computer Corp. Keyboard Hub
Bus 002 Device 003: ID 1058:1100 Western Digital Technologies, Inc.
Bus 001 Device 005: ID 413c:2010 Dell Computer Corp. Keyboard

I have tried installing linux-backports-modules-cw-3.1-oneiric-generic but that did not work. The wireless network does not appear under the connection settings.
I tried wrapping the Windows XP driver following this post using the ndisgtk and ndiswrapper packages. All of the driver .inf files failed to load properly except the Windows XP version. The XP version loaded and even recognized the hardware. Still no wireless network options after several reboots and unplugs/replugs.

Are there any other setup steps that I am missing? After installing linux-backports-modules-cw-3.1-oneric-generic and rebooting should the wireless network just show up under the network settings? Is there anything else I can check at this point?

I'm willing to settle my loses and buy a different wifi adapter if I could be certain it would work with my setup. Anyone using 11.10 + usb wifi adapter?

Run lsusb to make sure the machine recognizes the adapter and confirm the chipset. You should see the following on one of the lines:

0cf3:9271 Atheros Communications, Inc.

The machine needs both the proper firmware and driver to utilize the adapter. Get the htc_9271.fm firmware file from here (I used version 1.3, get whatever is most recent) and copy it to the lib/firmware/ directory. Next, download the compat-wireless drivers here. Unarchive it and build the ath9k_htc driver by running the following commands in order:

tar xvf compat-wireless-2.6.38.2-2.tar.bz2
cd compat-wireless-2.6.38.2-2
./scripts/driver-select ath9k_htc
make
sudo make install

Load the driver

sudo modprobe ath9k_htc

If this does not work (you should now see wireless networks available), try unplugging the adapter and reinserting it. Also, a reboot might help but could require reloading the driver with modprobe again.

I had the same problem...bought the wifi usb card, dead as a doorknob in ubuntu.  Without further details, I took the wifi card to a windows 7 laptop, and installed in there with the included mini cd.

Brought it back to my ubuntu laptop, and lo and behold! Green light, network manager sees it, etc., etc. A lot simpler and faster solution, if unorthodox.


Weird text shows on a billboard TV I've got a 14m2 digital billboard with a computer behind which is working on Xubuntu.

Everything works just fine when it's turned on, the ads are showing correctly and stuff like that, but I need to change those ads. When I used to turn the computer and the digital billboard on it starts and after the boot screen that says Xubuntu it goes straight to the ads (so the ads start playing automatically when the PC turns on).

After reading some things about Ubuntu I wanted to go and use the interface of the computer like in Windows, so I pressed Ctrl+Alt+F1-F7 and there goes my problem. The only thing that my monitor displays is some weird text which looks like the text isn't being decoded.

Managed to get in the computer by remote after connectin 2 computer with crossover cable. All i can do now is manage the ads by the tecnovision dlx player and server. I still cant open that computer like a normal computer working on linux.

ALT+F4 combination should close the app and display the XFCE desktop.


Ubuntu 14.04 Nvidia Optimus Bumblebee error I know that in Ubuntu 14.04 there exists nvidia-prime for Nvidia Optimus, but I don't like it and neither am I able to get it work. After upgrading from Ubuntu 12.04 everything crashed, and I made a clean install of Ubuntu 14.04 and Bumblebee, but now I have new troubles. After running optirun glxgears I get the following error:

**[ 4703.996785] [ERROR]Cannot access secondary GPU, secondary X is not active.**
**[ 4703.996910] [ERROR]Aborting because fallback start is disabled.**

Please help.

From: https://wiki.debian.org/Bumblebee#Common_issues

I had to edit the file '/etc/bumblebee/bumblebee.conf' and set the driver manually :

Driver=nvidia

You should have a corresponding [driver-nvidia] section in your file with the current version of your nvidia driver :

[driver-nvidia]
# KernelDriver=nvidia-current
KernelDriver=nvidia-331
# LibraryPath=/usr/lib/nvidia-current:/usr/lib32/nvidia-current
LibraryPath=/usr/lib/nvidia-331:/usr/lib32/nvidia-331
# XorgModulePath=/usr/lib/nvidia-current/xorg,/usr/lib/xorg/modules
XorgModulePath=/usr/lib/nvidia-331/xorg,/usr/lib/xorg/modules

then restart the bumblebee daemon :

sudo service bumblebeed restart

I believe that you need to set up a virtual server for your image output. I am not sure on 14.04, but I know this works for me on upgrading to 13.10 from 12.04. It is not specific to 14.04, but if you are stumped, this answer should provide some guidance:

External Monitor display on Thinkpad W520 with 12.04

Here is a quick summary of the answer on that link:

1) Install latest intel drivers, hope that intel-virtual-output, which is the integrated version of screenclone. If it's not packaged, compile that stuff from source.
2) In your xorg.conf.nvidia ensure the option preventing external screens is disabled.
3) Xrandr as usual :)


Can Windows and Ubuntu share a single swap partition? I am dual booting my system with Ubuntu 12.04 and Windows 7. I have created the special swap partition for Ubuntu while installing (as recommended).

Can Windows use this swap area/partition--as its own swap/page file--when I boot from Windows?

It's possible, but probably only as an experiment:

Note: This is a what-if answer and is not recommended, especially if you are using hibernate from Ubuntu!

In theory, yes, Windows should be able to use your swap partition for its page (swap) file with some clever scripting on the Linux side.

I'm not going to do a step-by-step because I haven't tried it and if you can't figure out how to implement this you shouldn't be trying it either :)

Format the partition as NTFS from within Windows and set up Windows to use that drive exclusively for its swap file (nothing on C:)

Have a startup/upstart script to format the partition as Linux swap on Ubuntu startup and enable swap (swapon).

Have a shutdown script to swapoff and reformat the partition as ntfs.

Alternative (still not recommended) option:
You can create a swap file by following this guide on the NTFS partition, provided the NTFS partition is large enough for both swap files.
However this alternative is not recommended because:

Swapping on an NTFS(3G) partition would be extremely CPU-heavy.
And to make things worse, since the file can/will be fragmented, that would also cause a performance hit.

The short answer is: No, it cannot.

Windows does not recognize Linux partitions, although the opposite is possible (linux recongnizes windows partitions).


What to do when Skype freezes silently? I start to use ubuntu rather recently at work.
Among colleagues we are used to be always available on skype.
Unfortunately, on my machine, skype sometimes freezes without making me aware of that.
So, I think I am online, but for the rest of the world I am off. What can I check/do?

Such behavior may show up 2/3 times a day.
To restart skype, it is necessary to kill the proccess form the terminal (ctrl-q does not work).

Thanks for your patience.

Tied of constantly and silently freezing Skype I've created simple wrapper for this - it's a python daemon which constantly checks it via DBUS skype API, and restart process when notifies it's frozen. Hope someone finds it useful.

https://github.com/kapliars/doctor-skype

Can you try running Skype from the command line ie

sudo skype

here you may see if any error messages come up. I also got around some sound issues a while ago by installing pavucontrol

sudo apt-get install pavucontrol

but since Ubuntu 11.04 was installed the sound control menu has been improved. Anyway  in 10.10 pavucontrol enabled me to sort my input/mic source correctly via pulseaudio by selecting the input source. In 10.10 this action helped me have a working skype in Ubuntu

Hope that may help you . Let us know what error messages if any you get.

ps I also always deselect the allow skype to adjust my audio controls as I show below in the options section as I find skype will quite happily mess up my sound!

(BTW depending on which version of Skype you are running you may not see the message about pulseaudio below)


Fix audio glitches with Intel HDA Realtek 887-VD I've just self-build a beefy new desktop, with a Gigabyte Z97P-D3 mobo, intel i7-4790K, 16GB RAM. I am using the on-board sound hardware intel HDA (Realtek ALC887-VD) for audio output. I'm running Ubuntu 14.04 LTS.

Every few minutes I can hear a short skip in audio playing, almost as though one frame is being dropped. It's incredibly annoying and happens regardless of the source (VLC / Spotify / Chromium browser). In the brief moment during a skip, the Sound Preferences > Output tab's list of devices gets greyed out, and the volume control indicator briefly flashes as though it is muted, before all flicking back to normal.

ALSAmixer also similarly glitches during the skips with the volume bars all disappearing for a fraction of a second.

I've tried the following workarounds (none of which work for me):

1) /etc/modprobe.d/alsa-base.conf: Position_fix setting

options snd-hda-intel model=generic position_fix=1

2) PulseAudio /etc/pulse/default.pa: Turning off tsched

load-module module-udev-detect use_ucm=0 tsched=0

3) PulseAudio /etc/pulse/default.pa: Adjusting defaults (all sorts of combinations and values of the below)

default-fragments = 2
default-fragment-size-msec = 250
default-sample-rate = 48000
realtime-scheduling = yes
realtime-priority = 5

4) Reinstalling PulseAudio

5) Upgrading the kernel to the latest stable (4.4.2)

6) Using Jack2 instead of PulseAudio

7) Buying a new sound card (SoundBlaster Live), which doesn't seem to work with various applications like Spotify.

Output of cat /proc/asound/card*/codec* | grep Codec:

  Codec: Intel Generic

  Codec: Realtek ALC887-VD

  Codec: Nvidia GPU 60 HDMI/DP

Output of cat /proc/asound/card*

  0 [HDMI           ]: HDA-Intel - HDA Intel HDMI
                        HDA Intel HDMI at 0xf7914000 irq 33

  1 [PCH            ]: HDA-Intel - HDA Intel PCH
                        HDA Intel PCH at 0xf7910000 irq 32

  2 [NVidia         ]: HDA-Intel - HDA NVidia
                        HDA NVidia at 0xf7080000 irq 17

It's card #1 that I'm using.

Output of uname -a:

  Linux alnitak 4.4.2-040402-generic #201602171633 SMP Wed Feb 17 21:35:10 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

I suspect this has something to do with the intel HDA drivers seeing as Pulse, ALSA and Jack are all affected.

Are there any fixes I'm missing?

The Linux device driver called snd-hda-intel has been apparently causing huge amounts of aggravation since at least November 2010 when one aggravated user wrote a PulseAudioMicrophoneGuide.pdf.

Here is what I have figured out so far: PulseAudio is a software layer that runs on top of Alsa. Alsa is a software layer that loads a large number of driver software packages. Alsa is not just drivers for the electronic signals. Alsa loads several different little pieces of software for each electrical signal, like a mixer and like the software that reads bytes from a microphone or writes bytes to a headphone amplifier.

My 2015 Lenovo S21e laptop has a "no sound from the built in microphone" problem and as a result neither Skype or GoogleHangouts Chat works with the built in microphone.

The short term fix for me is to plug in a Webcam with microphone or use a Plantonics USB headset.

Here is what I think needs to be done. I am not a C programmer (just Python, Perl and Arduino). Inside the device driver that is talking to the hardware find the location in the source code where the audio data is being copied from the microphone memory location. One of the output channels, Right or Left is being inverted somehow in the software. My guess is they did a signal inversion hoping to cancel out some kind of noise from the signal. So the trick is to figure out why the original programmer forced an inversion. If nothing else, remove the inversion and see if that makes the Right and Left Channels OK.

Ok, I've solved it... The answer was:

1) Buy a new sound card (in my case a Soundblaster Live)

2) Install Jack Audio (jackd)

sudo apt-get install jackd qjackctl

3) Install the Jack-Pulseaudio bridge (pulseaudio-module-jack)

sudo apt-get install pulseaudio-module-jack

4) Fire up jack (I used qJackctl) with Soundblaster-friendly settings:

  Driver: alsa

  Realtime

  Frames/Period: 2048

  Periods/Buffer: 2

  Input Device: hw:Live

  Output Device: hw:Live

5) Make sure the Jack connections are patching PulseAudio JACK Sink to System Playback

jack_connect 'PulseAudio JACK Sink:front-left' 'system:playback_1'
jack_connect 'PulseAudio JACK Sink:front-right' 'system:playback_2'

6) Make sure PulseAudio is using Jack Sink as it's output

pacmd set-default-sink "jack_out" && pacmd set-default-source "jack_in"

7) Restart Spotify / VLC or whatever you are using to play sound... it will work!

It's an absolute fudge of a workaround, but that's because the intel HDA audio drivers in Linux are shoddy as hell. The problem lies with the DMA Position Pointer reporting (a known problem: https://www.kernel.org/doc/Documentation/sound/alsa/HD-Audio.txt).

Linux audio is a mess. I've been using Ubuntu since 2010 and in the past 6 years it is the audio clusterf##k that has consistently given me the biggest headaches. PulseAudio might have a lovely desktop widget, but it causes so many problems. Jack is poorly documented and qjackctl doesn't give you much of a leg up. Only ALSA seems to behave, but alas, nobody has written a nice desktop widget nor an interface to control the programs that have binded to it.

The take-home messages are:

Don't use intel HDA on-board audio if running Linux.

Linux audio is a mess. If it's not working correctly out of the box, you're in for a whole world of pain!


Kile. Keyboard layout switching When working with text with Kile I use both Latin and Cyrillic keyboard layouts.

Shortcuts like Ctrl+C or Ctrl+Z do work if layout is Latin, and do not work if layout is switched to Cyrillic.

Is there any hints or tricks to make it work independently of keyboard layout?
Thanks

It is necessary to bind to this second values on cyrillic: Ctrl+C and Ctrl+Ч

KDE System Settings > Shortcuts and Gestures > Global Keyboard Shortcuts > KDE Component: KDE Activity Manager - Add custom shortcut


How to use "grep" command to find text including subdirectories I want to find all files which contain a specific string of text. The grep command works, but I don't know how to use it for every directory (I can only do it for my current directory). I tried reading man grep, but it didn't yield any help.

It would be better to use

grep -rl "string" /path

where

-r (or --recursive) option is used to traverse also all sub-directories of /path, whereas
-l (or --files-with-matches) option is used to only print filenames of matching files, and not the matching lines (this could also improve the speed, given that grep stop reading a file at first match with this option).

I know there are plenty of answers here, but here's an alternative if you'd like to add other restrictions when searching the files:

find . -type f -exec grep --quiet string_to_look_for {} ';' -print

This works because grep will return 0 if it found a result, 1 otherwise. For example you can find files 1 MB large and containing something:

find . -type f -exec grep --quiet string_to_look_for {} ';' -size 1M -print

For multiple requirements you probably want to use the optimizer flag -O that exists in GNU grep.


Prevent a program adding itself to startup programs automatically I find my dropbox auto adds itself to startup programs, even after I unchecked it from the startup prefrences. However, when I manually started dropbox sometime, it automatically added itself to startup. Here is the experiment I did. (Ubuntu 14 LTS)

Uncheck dropbox from startup.
Exit dropbox
Manually start dropbox
Then dropbox is checked in the startup.

How to disable a program (e.g., dropbox) adding itself to startup programs?

The startup preferences is stored at ~/.config/autostart/. Take dropbox for example, it auto adds itself to startup by adding/editing the ~/.config/autostart/dropbox.desktop file. So a simple solution change that file and make it root-editable only.

vim ~/.config/autostart/dropbox.desktop. Then change Exec=dropbox start -i to Exec=
chmod 600 ~/.config/autostart/dropbox.desktop. This makes the file only accessible by its user.
sudo chown root:root ~/.config/autostart/dropbox.desktop. This changes the user of the file to root.

Changing preferences to prevent dropbox changing login items is good.

Yet simpler is changing dropbox preferences and deselecting "Start dropbox on system startup".


LightDM Backgroud is a simple purple radiant It seems after I tried to change the login screen background with Ubuntu Tweak, the greeter's background stays a simple purple background with just the spots..

I tried using dconf-editor, rechanging the image from Ubuntu Tweak back to the default, it still does not work.

So In The End, everything for the lightdm points to  /usr/share/backgrounds/warty-final-ubuntu.png.

But it's still a purple solid color. How do I fix it?

It's possible the picture file you're trying to use does not have the proper permissions to be viewed by others. Since you are logging on in LightDM and not yet known, the system can not display files which are limited access.

To make a file accessible for the LightDM screen, right-click on the file in Nautilus and select Properties, then Permissions and make sure "Access" is not set to "None" for "Group" or "Others".

Also note that the LightDM background defaults to the background of whatever user is highlighted in the log in space.

try to restart X Display: Manager:

sudo -s
setsid service lightdm restart

,maybe it will make  the difference
to restart unity and compiz to default

Restart Unity: setsid unity
Restart Compiz: setsid compiz --replace


Gnome-shell, how to fix it? Possible Duplicate:
  Ati incompatible with Gnome-shell?

my gnome-shell display screen  is tilted/ skewed, how do I fix it? sometimes the screen flashes, how do I fix it? I've installed the ATI Catalyst 11.9

You need to remove the fglrx drivers, at the moment (fglrx 11.9) do not work with GNOME Shell.

You need to access a terminal (press Ctrl+Alt+F1) or boot in to recovery mode (press Shift key right before Ubuntu is supposed to load and keep it pressed until the Grub menu comes up).

Login and run:

sudo sh /usr/share/ati/fglrx-uninstall.sh

Follow this guide: http://wiki.cchtml.com/index.php/Ubuntu_Oneiric_Installation_Guide


How do i completely remove Avast Antivirus On Ubuntu At first i didn't have antivirus on my Ubuntu 14.04, but a day later my friend sent a email about the antivirus that works on Ubuntu. "Avast" He say, therefore I immediately installed it.

After seeing the results, I was not so happy. I thinks was not as good in Windows. I decided to remove it, but i dont know how?

How to remove it ?

EDIT

Using terminal to install it:

wget http://files.avast.com/files/linux/avast4workstation_1.0.6-2_i386.deb
sudo dpkg -i avast4workstation_1.0.6-2_i386.deb

(Thanks to Rinzwind for suggestion)

Uninstall from GUI:

Go to Ubuntu Software Center
Click the Installed icon
Type avast in the searchbox, which is in the upper right corner of the window
Click the listed item and click Remove

Uninstall from Terminal:

Press CtrlAltT to open Terminal
Type sudo dpkg -r avast4workstation_1.0.6-2_i386.deb ,  then press the Enter key.
If prompted, type your password then press Enter. Your password won't be displayed when you type. This is normal. Don't worry.


Headset audio in Microsoft Teams I am running Ubuntu 19.10 on Dell XPS 15 9570. Headset works fine for most of the apps, but not for Microsoft Teams. I tried both web version (Chrome) and official app. The device just doesn't show up in the Teams audio settings. The same problem happens with Zoom.

Calling someone on Facebook works and I can see the headset available in the audio settings.

How can I make the meetings system work with my headset?

P.S. It is not the headset related issue, cause I tried multiple different ones. And the built-in audio gives a horrible echo and a background noise.

I have the same issue... looking through this issue: https://docs.microsoft.com/en-us/answers/questions/3015/microphone-for-teams-on-linux-not-working.html I've come up with a strategy, if not a solution yet...

Connect headset, set as default audio device, set profile as Headset Unit (HSP/HFP)
Open teams meeting
Avoid opening device settings

As long as device settings stays closed, it seems to continue working for me.

The solution is:

deactivate in MS Teams - Settings ()Auto-start application and () on close, keep running
then verify in Linux if your device is ready
restart MS Teams

Your device is ready to use in Teams.


Screen Resolution Problem with Ubuntu 14.04 and VirtualBox Environment: Lenovo T530 running Windows 7.  Have installed Ubuntu 14.04 on a virtual machine using VM Virtual Box.  Have installed all the updates from both Virtual Box and Ubuntu.

Problem: While in Ubuntu's desktop and other Ubuntu initiated programs, the window is reduced to about 3x4 inches showing in the middle of the rest of my regular Virtual Box window.  I am seeing only the upper right hand of the screen output of what I would normally see.  Please help.

I've seen How do I install Guest Additions in a VirtualBox VM?

But, none of these answers works in 14.04.

You basically need the Guest additions, log into the Virtual Machine to install the following packages:

sudo apt-get install virtualbox-guest-dkms

Finally restart the VM to complete the installation.

To expand on what Sylvain Pineau said, typing the following command is much easier (wildcards are accepted with apt-get):

sudo apt-get install virtualbox*


Rackspace, heartbeat ip failover I have tested tomcat specific clustering with apache mod_jk and mod_proxy on ubuntu local VMs for our website high availability and load balancing. The real servers are hosted by Rackspace cloud server provider and I should implement this on cloud servers once completely done. I tested tomcat clustering with 1 load balancer and 2 web servers. As single load balancer is again a single point of failure, I'm trying to add one more LB as slave.

In Rackspace there is an option Load Balancers and here is the link which guides how setting up load balancer which I am not sure to setup because of some doubts as I never did this before anytime.

I heard Rackspace offers to share an ip between computers, is that so?, then I can use this option.

I am trying heartbeat configuration on the load balancers and the way I followed from the link seems to work for a site. I have the following doubts here:

I think I should use public ip address in the place of virtual/floating ip which is shared and also to which the site domain is pointed, is that so?.
How could I configure heartbeat for multiple web sites as we have more than one site hosting?.
I will specify public/shared ip as virtual ip by eth0:0 in the network interface file on both the load balancers. Do you really think it works flawless even if specified the public ip as virtual ip with eth0:0 interface without any interruption?

Again I just gave a glance of other links link1, link2 and got confused which one to follow to host multiple webistes with ip failover. Does anyone tell me which link suits best for my requirement?

Finally my goal is to have ip-failover(master slave) for load balancers and need help on configuring heartbeat for multiple websites(may be pointing site domains to shared ip does the work?).

If we successed, we can share the success just by telling you 'thank you very much'. Thanks in advance!

I work at Rackspace and would be happy to help out here! Email me at mw at Rackspace dot com any time.

mw @ Rackspace . com. Email any time!


How do I fix my locale issue? I am getting this message every time I do something like starting or stopping a service.

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
        LANGUAGE = "en_US:en",
        LC_ALL = (unset),
        LC_MESSAGES = "en_US.UTF-8",
        LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
(Reading database ... 21173 files and directories currently installed.)
Removing bind9 ...
 * Stopping domain name service... bind9                                        [ OK ]
Processing triggers for man-db ...
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory

How do I fix this error ?

First run locale to list what locales currently defined for the current user account:

$ locale
LANG=C
LANGUAGE=
LC_CTYPE=fi_FI.UTF-8
LC_NUMERIC="C"
LC_TIME="C"
LC_COLLATE=fi_FI.UTF-8
LC_MONETARY="C"
LC_MESSAGES=fi_FI.UTF-8
LC_PAPER="C"
LC_NAME="C"
LC_ADDRESS="C"
LC_TELEPHONE="C"
LC_MEASUREMENT="C"
LC_IDENTIFICATION="C"
LC_ALL=

Then generate the missing locale and reconfigure locales to take notice:

$ sudo locale-gen "en_US.UTF-8"
Generating locales...
  en_US.UTF-8... done
Generation complete.

$ sudo dpkg-reconfigure locales
Generating locales...
  en_US.UTF-8... up-to-date
Generation complete.

Now you will not see any errors anymore!

Source of the problem

I experienced this, logging in from one machine to another via ssh. The remote machine didn’t have the locale files, that I had on my local machine. You can either disable the forwarding of the locale from your local machine to the remote machine (in the file /etc/ssh/sshd_config remove the line AcceptEnv LANG LC_CTYPE …) or install the locale (changing it is not necessary in this case).

Installing

On Fedora, RHEL, Redhat, CentOS I used

sudo dnf install langpacks-de

for the german (de) language packs. Logged out and in and it worked.

Search for other langpacks with

dnf search langpacks-

Changing/Activating

To list available locales I used

localectl list-locales

And to set a new one

sudo localectl set-locale de_DE.utf8


Why does Grub report two items for Windows 7? I did a clean install of Windows 7 on the same hard drive. I followed the instructions at:

http://www.howtogeek.com/114884/how-to-repair-grub2-when-ubuntu-wont-boot/

I followed the terminal instructions to restore grub bootloader.

Whenever I reboot. I see two entries of Windows 7 on Grub. I don't recall seeing this the last time. I am aware that Windows creates a 'System Reserved' partition (which is currently on sda1).

When I select either of the two boot options, Windows 7 boots fine (so it seems).

This is what update-grub returns:

$ sudo update-grub | tee ~/update-grub.txt
[sudo] password for christian:
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.8.0-29-generic
Found initrd image: /boot/initrd.img-3.8.0-29-generic
Found linux image: /boot/vmlinuz-3.8.0-27-generic
Found initrd image: /boot/initrd.img-3.8.0-27-generic
Found linux image: /boot/vmlinuz-3.8.0-19-generic
Found initrd image: /boot/initrd.img-3.8.0-19-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Windows 7 (loader) on /dev/sda1
Found Windows 7 (loader) on /dev/sda2
done

Will booting from the System Reserved cause any issues on Windows?

Why are there two entries of Windows 7 instead of 1? Should I have installed Windows 7 without creating a system reserved partition? Is that even an option?

I am on Ubuntu 13.04. My other Ubuntu machines only list down 1 entry for Windows 7. Ideally, if it had to list down 2 entries. It would be better if it displayed as:

Found Windows 7 (System Reserved) on /dev/sda1
Found Windows 7 on /dev/sda2

Can this changes be made via a Grub configuration file somewhere?

This 2nd entry has been added by Boot-Repair as a security: from now, if you accidentally delete the sda1 partition, you will still be able to boot Windows via the 2nd entry.

If you want to hide or rename one one these entries, you can use GRUB-Customizer, that you can install via its PPA:

sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer

yes you can do it by type "sudo gedit" if your style gedit or "sudo nano" if your style is nano

so it will be sudo gedit /boot/grub/grub.cfg just find menu entry for your windows on /sda1 and rename that as you want

ex:

### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Windows 10 (loader) (on /dev/sda1)'

to

### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Windows 10 (System Reserved) (on /dev/sda1)'


How to use the new Keyboard Switcher The keyboard switcher no longer works for me; I used to switch between keyboard layouts (from English to other languages) the same way as I do on Windows, using Alt-Shift.

It no longer seems to accept this combination, and I can't figure out how to set this up.

Is this a known bug?

Use the keys combination: Super+Space to next keyboard layout or Super+Shift+Space to previous.


dpkg: error: unknown option --add-architecture. When I try to do

sudo dpkg --add-architecture i386
[sudo] password for shailendra:
dpkg: error: unknown option --add-architecture.

this happens while installing skype.

Did you try to install Skype this way?

Add repository via terminal

sudo sh -c 'echo "deb http://archive.canonical.com/ubuntu trusty partner" >> /etc/apt/sources.list.d/canonical_partner.list'

Tell your system to pull down the latest list of software from each archive it knows about via the terminal

sudo apt-get update

Install Skype via terminal

sudo apt-get install skype

Maybe this way of installation will help you.


How to find source for a line in $PATH? I've got a line in my $PATH that is invalid and want to delete it, but I'm not sure where it's coming from.  It's not being set in .bashrc, .profile, or /etc/environment.

Is there any way to figure out its source? Thanks!

Environment variables should be set in either /etc/environment or /etc/profile, or their equivalent per-user files ~/.pam_environment or ~/.profile. Since you've checked /etc/environment and ~/.profile, check /etc/profile (and note that it sources files in /etc/profile.d/). There's no ~/.pam_environment by default.

If the bad PATH gets set by bash, you can start bash as an interactive login shell, with xtrace enabled, bash -xil, to help pinpoint the place where it happens.

EDIT: With more useful output and pipe to less:

PS4='+ $BASH_SOURCE:$LINENO: ' bash -xilc '' 2>&1 | less

I got frustrated with the bloated ~/.bashrc that is installed! i deleted it and made a minimal version that sets the PATH and aliases ls, all that other stuff i dont need. perhaps you want to start from scratch?


How do I install the latest Nvidia drivers automatically? There are a bunch of nvidias-drivers-* packages that are for different versions

nvidia-driver-390/eoan 390.129-0ubuntu2 amd64
  NVIDIA driver metapackage

nvidia-driver-418/eoan 430.50-0ubuntu2 amd64
  Transitional package for nvidia-driver-430

nvidia-driver-430/eoan 430.50-0ubuntu2 amd64
  NVIDIA driver metapackage

nvidia-driver-435/eoan 435.21-0ubuntu2 amd64

How do I install just the latest one without having to look for the biggest number by hand?

You don't always want to install the latest proprietary graphics driver. You want to install the latest driver that is compatible with the computer's hardware. Ubuntu has a built-in ubuntu-drivers program that can decide automatically which graphics driver to install, and streamlines the installation of Nvidia drivers. Open the terminal and type:

sudo ubuntu-drivers autoinstall
sudo reboot

The autoinstall command of ubuntu-drivers installs drivers that are appropriate for automatic installation including their dependencies.

sudo apt install $(apt search nvidia | cut -d'/' -f 1 | grep -E ^nvidia-driver-[0-9]+$ | sort -V | tail -n 1)


How to switch a netbook desktop on 12.04? I just installed Ubuntu 12.04 on my laptop. My screen is quite small, and I think that the netbook desktop (something like this) would be better. Is it possible to switch to netbook desktop on Ubuntu 12.04? If so, how is that done? (Or have I understood it all wrong...?)

That desktop option is not available since Ubuntu 11.04.

The Ubuntu Netbook Edition was introduced in Ubuntu 8.04, since Ubuntu 10.10 started using Unity the Netbook interface was set aside as an option only and since Ubuntu 11.04 you cannot install it anymore.

Unity should adapt it self for your screen's resolution and most of the times it looks nice enough to use it. If you do not agree and you need something more sleek maybe Kubuntu with it's Netbook plasma desktop is something to consider

At least you will be running the latest Ubuntu has to offer.

For netbooks I'll better prefer on netbook usage, EasyPeasy Ubuntu flavor which supports cloud computing and less resources usage with a better and more reliable Desktop and great GUI. EasyPeasy is what really you need as netbook desktop.

Link to download page:
http://www.geteasypeasy.com/get-easypeasy/


ldd can't find one library, but links to the other ones in same directory I'm trying to deploy my application. I created a deb package. If I install it on the same machine that I built it, everything works. When I try to use a deb package generated by my CI setup on gitlab, I encounter problems.

After installing, here's the error:

$ NCATests
NCATests: error while loading shared libraries: libQt5Core.so.5: cannot open shared object file: No such file or directory

This is surprising, because I installed a conf file (/etc/ld.so.conf.d/nca.conf) with a path /usr/lib/nca and ran a post-install ldconfig. To make sure that this worked I ran:

$ ldconfig -v
(snip)
/usr/lib/nca:
        libpcre2-16.so.0 -> libpcre2-16.so.0.7.1
        libicuuc.so.63 -> libicuuc.so.63.1
        libicui18n.so.63 -> libicui18n.so.63.1
        libicudata.so.63 -> libicudata.so.63.1
        libdouble-conversion.so.1 -> libdouble-conversion.so.1.0
        libQt5Widgets.so.5 -> libQt5Widgets.so.5.11.3
        libQt5Test.so.5 -> libQt5Test.so.5.11.3
        libQt5Gui.so.5 -> libQt5Gui.so.5.11.3
        libQt5DBus.so.5 -> libQt5DBus.so.5.11.3
        libQt5Core.so.5 -> libQt5Core.so.5.11.3
        libNCACore.so.1 -> libNCACore.so.1.3.8
(snip)

And yet:

$ ldd /usr/bin/NCATests
        linux-vdso.so.1 (0x00007fffc1081000)
        libNCACore.so.1 => /usr/lib/nca/libNCACore.so.1 (0x00007f049a368000)
        libQt5Test.so.5 => /usr/lib/nca/libQt5Test.so.5 (0x00007f049a310000)
        libQt5Core.so.5 => not found
        libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f049a0f0000)
        libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f0499d60000)
        libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f04999c0000)
        libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f0499790000)
        libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f0499390000)
        /lib64/ld-linux-x86-64.so.2 (0x00007f049a600000)
        libQt5Core.so.5 => not found
        libQt5Core.so.5 => not found

The library is there:

$ ll /usr/lib/nca | grep 5Core
lrwxrwxrwx 1 root root       20 Mar 15 08:20 libQt5Core.so.5 -> libQt5Core.so.5.11.3
lrwxrwxrwx 1 root root       20 Mar 15 08:20 libQt5Core.so.5.11 -> libQt5Core.so.5.11.3
-rw-r--r-- 1 root root  5200168 Mar 15 08:20 libQt5Core.so.5.11.3

Both files are 64 bit:

$ file /usr/bin/NCATests
/usr/bin/NCATests: ELF 64-bit LSB shared object, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 3.2.0, BuildID[sha1]=8adef8969237a756f7d2743121f87791c8ceafc2, not stripped

$ file /usr/lib/nca/libQt5Core.so.5.11.3
/usr/lib/nca/libQt5Core.so.5.11.3: ELF 64-bit LSB shared object, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=b126d6e6aafc3d2d6e2b7904786b22e7e84e252e, for GNU/Linux 3.17.0, stripped

Ubuntu version 18.04. What is the problem here?

sudo apt install libqt5core5a

There is your missing libary


Empathy refusing to connect I have configured Empathy with Facebook and Gmail just after installing Ubuntu 12.04. It worked flawlessly for few days and one fine day it crashed. After that when ever I am opening Empathy it is failing to connect to Gmail and Facebook ( I have not checked any other IM services).
After the crash I removed my account configurations and added once again but still facing the same issue.

Any pointer to fix issue is appreciable.

The reasoning is you're trying to use your log in e-mail address. It requires you to use your assigned name. The quickest way to find this information out is to login to Facebook via a web browser and check out your own profile. It should the web url as facebook . com / YOURNAMEHERE.

Use that given name and your password you used to log in and it should work.


Unable to give permission through sudoers to a script accessing /dev/tty13 Here abc is the username and ak.sh is the file which I wish to get all the permissions. Have added the following line on the top of sudoers.tmp which I opened like sudo visudo:

abc ALL=NOPASSWD: /home/abc/ak.sh

ak.sh contains:

#!/bin/bash
sudo cat /dev/tty13

When I run the script file, it asks me for password.

You need to actually use sudo for a sudoers rule to be of use. Either:

Use the current sudoers rule and run sudo /home/abc/ak.sh
Use the other rule you mentioned, but with absolute path for cat like this:
abc ALL=NOPASSWD: /bin/cat /dev/tty13 and run sudo cat /dev/tty13 in the script.

Assuming your method of password exemption works the same way as changing sudoers, you need to call the SCRIPT with sudo, not the command IN the script. Or change sudoers. In other words:

sudo /home/abc/ak.sh

is what you exempted from requiring a password, not cat. You still have to use sudo but if you did it right, you won't be required to enter a pass.

@muru

# # # # # # # # # # # # # # # # # # # #

Why it seems to me to be better to password exempt the script CONTAINING a cat command rather than cat itself:

$ ls / | grep secrets
secrets_root_does_not_want_to_share_.txt
$ # hmmm, that looks interesting . . .
$ cat /secrets_root_does_not_want_to_share_.txt
cat: /secrets_root_does_not_want_to_share_.txt: Permission denied
$ # Curses! My evil plans are foiled because:
$ stat /secrets_root_does_not_want_to_share_.txt | grep 'Access: ('
Access: (0600/-rw-------)  Uid: (    0/    root)   Gid: (    0/    root)
$ # But wait! I'm pass exempted! So:
$ sudo cat /secrets_root_does_not_want_to_share_.txt
Oh, my. Sensitive stuff is exposed to ordinary users.

Password exempting sudo cat isn't as dangerous as, for instance, password exempting sudo echo but it does seem to me to be a fairly bad practice.

# # # # # # # # # # # # # # # # # # # #

Added later to address Muru's skepticism regarding the equivalence of sudo cat when the password has not expired from a previous use of sudo to sudo cat when cat has been password exempted:

I added a rule to the beginning of my pass exemption section in /etc/sudoers like so:

me THIS_LOCAL_SYS=(ALL)NOPASSWD:/bin/cat, . . . [many other rules, separated by commas]

Then in a fresh terminal:

$ # Demonstrating that password is not un-expired from previous use of sudo:
$ sudo ls /root
[sudo] password for j:
$ stat /secrets_root_does_not_want_to_share_.txt|grep 'Access: ('
Access: (0600/-rw-------)  Uid: (    0/    root)   Gid: (    0/    root)
$ cat /secrets_root_does_not_want_to_share_.txt
cat: /secrets_root_does_not_want_to_share_.txt: Permission denied
$ # And rightly so, but with pass exempted sudo:
$ sudo cat /secrets_root_does_not_want_to_share_.txt
Oh, my. Sensitive stuff is exposed to ordinary users.
$

So, yes, they ARE equivalent, just as they should be; yes, I DO understand how sudo works - I've only edited that file a few hundred times; and yes, password exempting plain /bin/cat, instead of a script containing cat, is an unsound practice from a security perspective. Again, not the disastrous stupidity that password exempting sudo echo or sudo vi would be, but still a bad idea.


How can I start RhythmBox minimized? Does anyone know how to start RhythmBox in quiet mode?

There is a plugin for this...

disclaimer - I'm the author for this plugin

Called rhythmbox_hide, this is a little applet that either starts rhythmbox hidden or minimized.

By default, when the plugin is enabled through the menu option Edit - Plugins, rhythmbox starts hidden on startup, but through the plugin preferences you can uncheck this option and rhythmbox will then start minimized.

This plugin is particularly useful in combination with another plugin called remember-the-rhythm.

When used with this plugin you can start rhythmbox via the startup applications option for your Desktop Environment and on login, your last track that was playing will be immediately start playing.

how to install

sudo apt-get install git
git clone https://github.com/fossfreedom/rhythmbox_hide
cd rhythmbox_hide
./install.sh

You will be prompted for your password which installs the dconf schema key used to remember your preferences option.

Alternatively, if you prefer a package installation method:

sudo add-apt-repository ppa:fossfreedom/rhythmbox-plugins
sudo apt-get update
sudo apt-get install rhythmbox-plugin-hide

Linked Question

How do I install third-party rhythmbox plugins?

Just click to volume icon in the top menu of your desktop, and then click to play icon.


Bumblebee applications running very slow My laptop has NVIDIA GT 520MX discrete graphics. I installed Bumblebee to take advantage of OPTIMUS technology. But applications are running slow with Bumblebee. Applications with small memory footprint like Mines game and gedit are running fine(ran them with Bumblebee just for testing). But video playback with Totem is very laggy. Frame rate is too low. Firefox is also comparatively slow. What should I do?

Yeah. Linux driver support sucks. This is why Linux will never be a Desktop platform for people who value their own personal time. Hardware / chip manufacturers don't write quality drivers for their hardware targeting Linux, so Linux users are out of luck. The only option is to buy hardware that is qualified by Canoncial / Ubuntu / etc to run on certain releases. But this leaves out a lot of the hardware we want to use.


Installing matplotlib on Ubuntu 14.04 after installing Python 3 with pyenv I am using Ubuntu 14.04 with Python 2.7.6. I have installed matplotlib for Python 2. Now, I just installed Python 3.4.2 using pyenv install 3.4.2. I then ran pip install matplotlib to install matplotlib for Python 3. I later discovered the package python3-matplotlib for Ubuntu 14.04. I wonder: should I have used sudo apt-get install python3-matplotlib instead? What is the preferred way of installing matplotlib for Python 3 side-by- side with the Python 2 matplotlib?

I dont have Ubuntu system right now with me. but still I can help you I think.

open your terminal and type as

apt-cache search python3-matplotlib

If you find it like its available then you can install it from

sudo apt-get install python3-matplotlib

that is the most preferred way.

Now how to use matplotlib with python 3. I have posted a question also in here about how to use python2 and python3 side by side.

Simple , use python3 <filename.py> while executing your program with python3-matplotlib

and similarly if you  use python2 then it will load python 2.

hope that helps.

It is a problem with the development files of libgeos. I have the same problem and it was resolved by installing those libraries. Hope it helps.


7zip: How to exclude file types? I want to exclude the following file types:

epub
pdf
html (upper case too)
azw3
mobi
opf
txt

I have this so far which doesn't seem to work, i get an error saying "Incorrect Command Line".

7z e "-x!*.epub" "-x!*.pdf" "-x!*.html" "-x!*.azw3" "-x!*.mobi" "-x!*.txt" "-x!*.HTML" "-x!*.opf" *

I also tried the above command without double quotes.

I created the above command using info from here (for windows) but it doesn't seem to work under Linux.

From man 7z:

-x[r[-|0]]]{@listfile|!wildcard}
              Exclude filenames

To exclude file (or types) you can use the following command:

  7z a -xr@exclude.txt backup.7z /whatever/dirs/or/files

Notice -xr instead of -x. The r indicates recursive so it can match excluded files in deep folder hierarchies

The file exclude.txt is a list separated by carriage returns like this:

*.epub
*.pdf
*.html
*.HTML
*.azw3
*.mobi
*.opf
*.txt

If you want to exclude the full directory (you may have this extension file separated in directory)

 7z a -t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on ~/bkpFile_$(date +"%d_%b_%Y").1.7z /home/ubuntu/projectfile -mx0 '-xr!vendor' '-xr!view' '-xr!documents'

Here, vendor , view, and documents directory has been excluded.


Is there any way to use Windows Live Messenger in Ubuntu? I know there are many alternatives to Windows Live Messenger like Empathy, Pidgin, emesene or aMSN. However, I usually use the 'Photo Sharing' feature with my friends that is not in any chat client.

I need to use my MSN Messenger account. So how to use Windows Live Messenger in Ubuntu? Or can I connect to WLM and use 'Photo Sharing' with any chat client for Linux?

Would you recommend to use a virtual machine?

You may need a VM for photo-sharing.

Why not Wine?

While running in Wine is an option, the newer versions are reported as Garbage, which means they didn't install, or didn't work. You can try running version 8.5 if it still is available, but it also has issues, as it is rated Bronze. Even rated Bronze, it is very difficult to use and can cause Unity or Compiz crashes as documented here.

What can I use?

Emesene appears to have a great outlook1 but it is unable to perform photo-sharing tasks.

For a VM, you should use virtualbox . It is lightweight and works with many systems. Ensure you have a license to use Windows. VirtualBox has a Seamless mode which makes applications integrate with the host OS, but I have not tested such functionality yet.
 The info about Seamless mode is courtesy of this comment by Brendan Long.

Ref:

https://help.ubuntu.com/community/WindowsLiveMessenger
https://apps.ubuntu.com/cat/applications/emesene/
http://appdb.winehq.org/objectManager.php?sClass=application&iId=127

1 No Microsoft-related pun intended.

If you want to use the original Messenger by Microsoft you should install it using wine. A lot of windows programs run under wine but not all of them. Just try it.


How to boot from an Ubuntu USB? My laptop is running windows 10, build 9926. I would like to install Ubuntu or Kubuntu over windows 10. I have USB drives formatted and ready with the ISO files of Ubuntu and Kubuntu. (each drive has one ISO). For some reason, my laptop doesn't recognize an available USB to boot the computer from. I don't have a CD to boot from either. I am at a loss, is there a way that I can install Ubuntu without using a CD or a USB?

May be your BIOS do not support booting from USB in which case nobody can help you. You will have to use a VD/DVD. Another possible way that uses Unetbootin is described in this post: Install Ubuntu without CD and USB , how? Check it out.

You can't install it with just the ISO file. Use Unetbootin (downloadable tool, not command) to install Ubuntu on the USB, then reboot into said USB. Select the option to install Ubuntu.

At this point, install it normally like you would for a dual boot by allocating some of your disk space to the Ubuntu partition. Pay attention to the amounts; you'll use them later. Then boot into the live USB again and select "Try Ubuntu" to boot into a live session.

Now that you are in the live session, open the application GParted. It is a partition manager. From this partition manager, you will see several partitions. You can tell which they are by the amounts of disk space they take up. Identify the one that has your Windows system on it (usually /dev/sda1), unlock it (if necessary), and delete/format it. It should now be labeled as empty space. Then, unlock your Ubuntu partition and resize it so it fills your whole disk. Then wait for GParted to finish working, relock your partition, and reboot into your regular system.

You should now have only Ubuntu installed, with your whole disk available to it.


How to mount synology SMB2 share on ubuntu I'm having a hard time mount a SMB2 share from my synology to ubuntu server 16.04.

mount.cifs //NAMEOFNAS.domainname.local/Backup /mnt/NAS/ -U USERNAME

results in following error:

mount error(95): Operation not supported

So checking the network share with smbclient results in another error:

 smbclient //NAMEOFNAS.domainname.local/Backup -U username
WARNING: The "syslog" option is deprecated
Enter username's password:
protocol negotiation failed: NT_STATUS_INVALID_NETWORK_RESPONSE

When doing the same but with a share on Windows server, I have no problem whatsoever. Is there something I have to configure in Synology NAS (i noticed it's configured to only use SMB2)?

Here is the output of testparm (only thing I changed was domain and security=user)

   # Global parameters
[global]
        workgroup = AVR
        server string = %h server (Samba, Ubuntu)
        server role = standalone server
        security = USER
        map to guest = Bad User
        obey pam restrictions = Yes
        pam password change = Yes
        passwd program = /usr/bin/passwd %u
        passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
        unix password sync = Yes
        syslog = 0
        log file = /var/log/samba/log.%m
        max log size = 1000
        server max protocol = SMB2
        max protocol = SMB2
        protocol = SMB2
        server min protocol = SMB2
        min protocol = SMB2
        dns proxy = No
        usershare allow guests = Yes
        panic action = /usr/share/samba/panic-action %d
        idmap config * : backend = tdb

[printers]
        comment = All Printers
        path = /var/spool/samba
        create mask = 0700
        printable = Yes
        browseable = No

[print$]
        comment = Printer Drivers
        path = /var/lib/samba/printers

What can I do to mount this share please?

kr,
wouter

I use a PI to mount a DS Share into my nextcloud instance. For that reason I use the following mounting command:
sudo mount.cifs -o username=ds-user,password=pw-of-ds-user,uid=33,gid=33,file_mode=0660,dir_mode=0770,vers=2.1  //IP-of-NAS/share /mountpoint/where/to/mount

I will explain the command

username and password should be clear I hope
uid gid are the values for www-date to get it working under nextcloud
file_mode set the permission for the mounting point
dir_mode do the same for folders
vers=2.1 that was the most important to get it working, the version 2.0 was not working for my DS in combination with my Linux
and of course the the source and destination

So you cannot copy and paste my command you must edit it to your needs, but I think the structure should be clear now.

edit /etc/samba/smb.conf，change smb client version
[global]

# SMB protocol
client min protocol = SMB2
client max protocol = SMB3

restart or reboot
# restart smb service
sudo systemctl restart smbd.service

# or reboot
sudo reboot

try to link your NAS server
smb://<nas-ip>


How do I remove PHP 7 Completely? I have upgraded PHP old version to latest php7 but unable to start its services.

systemctl restart apache2.service

Job for apache2.service failed. See "systemctl status apache2.service" and "journalctl -xe" for details.

Status Detail:

systemctl status apache2.service

● apache2.service - LSB: Apache2 web server
Loaded: loaded (/etc/init.d/apache2)
Active: failed (Result: exit-code) since Mon 2016-01-04 13:58:17 IST; 5s ago
 Docs: man:systemd-sysv-generator(8)
 Process: 16666 ExecStart=/etc/init.d/apache2 start (code=exited,       status=1/FAILURE)

Jan 04 13:58:17 GCT022 apache2[16666]: *
Jan 04 13:58:17 GCT022 apache2[16666]: * The apache2 configtest failed.
Jan 04 13:58:17 GCT022 apache2[16666]: Output of config test was:
Jan 04 13:58:17 GCT022 apache2[16666]: apache2: Syntax error on line 140 of /etc/apache2...
Jan 04 13:58:17 GCT022 apache2[16666]: Action 'configtest' failed.
Jan 04 13:58:17 GCT022 apache2[16666]: The Apache error log may have more information.
Jan 04 13:58:17 GCT022 systemd[1]: apache2.service: control process exited, code=exit...s=1
Jan 04 13:58:17 GCT022 systemd[1]: Failed to start LSB: Apache2 web server.
Jan 04 13:58:17 GCT022 systemd[1]: Unit apache2.service entered failed state.
Jan 04 13:58:17 GCT022 systemd[1]: apache2.service failed.
Hint: Some lines were ellipsized, use -l to show in full.
root@client022:/home/user22$ ^C

Now I want to revert back or remove php7 that i can do the user machine active with the old version.

To remove php7.0 use

sudo apt-get purge php7.0-common

After doing a:

sudo apt-get purge php7.*

to remove all versions of php7, you still need to run some extra steps to completely and utterly remove php7:

sudo apt-get autoremove --purge

Then do a:

whereis php

and then remove all directories in the output of the last command, E.G.:

sudo rm -rf /etc/php


Wifi problem rtl8723be I have tried a lot of ways to make my WiFi connection stable and it is okay now for an hour. Solutions that I already tried:

Dedoimedo: Fix for the Realtek RTL8723BE driver in Ubuntu Trusty
Ask Ubuntu: Wifi problems with rtl8723be in Ubuntu 14.04
UbuntuForums: RTL8723BE wifi dropping connection on Ubuntu 14.04

The 2nd link helped me to install the drivers, options rtl8723be fwlps=N ips=N
helped to make the connection stable.

Problem: I can't access the internet through WiFi on the laptop, but it works on any other device. And I don't have any idea why.

If you need some additional information, please tell me.
Thank you!

I had the same problem. somewhere I found that we need to edit wifi network we are connected to and add 8.8.8.8 as dns. After that I was able to get Internet access.


problem installing make command, x11rdp and libxcb1-dev package I installed x11rdp using the tip here How to install and configure X11RDP?, its a script that download, build, install and configure x11rdp, I ran once the sudo bash setup.sh, it didn't work because I didn't have the command make so I installed it, the make command ran without trouble except by the package libxcb1-dev, who seems broken, I tried ran apt-get -f install, it didn't work again, I tried update by the update manager, same problem again, I tried use synaptic and didn't work again, any idea to solve that problem or any idea if is something that I have done wrong or that script has done wrong or if its a problem in the package??
by the way, even with the broken package I could install x11rdp with the script and I am using without trouble.

here the LOG:

The following packages have unmet dependencies:
 libxcb1-dev: Depends: libxcb1 (= 1.8.1-1) but 1.8.1-1ubuntu0.1 is installed
Depends: libxau-dev (>= 1:1.0.0-1) but 1:1.0.6-4 is installed
Depends: libxdmcp-dev (>= 1:1.0.0-1) but 1:1.1.0-4 is installed
 ldconfig deferred processing now taking place
and log into the `apt-get -f install`
 Errors were encountered while processing:
  libxcb1-dev
  libx11-dev
  libxfixes-dev
 E: Sub-process /usr/bin/dpkg returned an error code (1)

 A package failed to install.  Trying to recover:

 dpkg: dependency problems prevent configuration of libxcb1-dev:
  libxcb1-dev depends on libxcb1 (= 1.8.1-1); however:
   Version of libxcb1 on system is 1.8.1-1ubuntu0.1.
 dpkg: error processing libxcb1-dev (--configure):
  dependency problems - leaving unconfigured
 dpkg: dependency problems prevent configuration of libx11-dev:
  libx11-dev depends on libxcb1-dev; however:
   Package libxcb1-dev is not configured yet.
 dpkg: error processing libx11-dev (--configure):
  dependency problems - leaving unconfigured
 dpkg: dependency problems prevent configuration of libxfixes-dev:
  libxfixes-dev depends on libx11-dev; however:
   Package libx11-dev is not configured yet.
 dpkg: error processing libxfixes-dev (--configure):
  dependency problems - leaving unconfigured
 Errors were encountered while processing:
  libxcb1-dev
  libx11-dev
  libxfixes-dev

Install build-essential  if you have not done so already. This provides various packages useful for building software in Ubuntu. It can be installed in the Software Center or by running:

sudo apt-get update && sudo apt-get install build-essential


Crontab entry not running as expected I have setup crontab e with the following line and it is not running every hour on the 14th minute as I expect it should.

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

First, is this code correct?

Secondly, If so why is it not running at all and what do I have to do to get it to do so. I just want to clear the trash hourly is all. I go this code from a best answer here on askabuntu.

thanks

Why don't you just install Autotrash? Here's the instructions:

First, add the repo:

sudo add-apt-repository ppa:bneijt/ppa

Then do the update

sudo apt-get update

Then install Autotrash

sudo apt-get install autotrash

Sample uses of autotrash:

To purge any file in the trash for more than 30 days being stored, enter the following line in a Terminal window

autotrash -d 30


How to run a .sh file in terminal on login so I have a simple sh file I want to run whenever someone logs in. I tried adding it to startup applications. This didn't work. I tried editing the .desktop file for the startup application to set Terminal=true. This made it open temporarily but shut it down.
I tried editing .bashrc by adding the command bash /path/to/my/file.sh and it had the same effect. This seems like it should be really simple to do, even in linux, but I have tried lots of ways and had no success. I am on Ubuntu 14.something.

When you set Terminal=true in the desktop file, the terminal window by default closes after the "the job has finished".  An easy solution is to change your (terminal-) profile settings:

open a terminal window, choose Profile Preferences
choose "Title & Command" (at least that is what it is in Dutch, the second tab)
in the section "when the command has finished" choose "keep terminal window open"

And of course, like you did, in the desktop file, set Terminal=true

Solution for Question --> "so I have a simple sh file I want to run whenever someone logs in. I tried adding it to startup applications."

Suppose path of your file is /home/foster/Desktop/script.sh

First make it executable by :

$ chmod +x /home/foster/Desktop/script.sh

Now just Add path of the script to file "/etc/rc.local" :

sh /home/foster/Desktop/script.sh
exit 0


Changing screen brightness I have a hp pavilion dv6 with xubuntu installed. however there isn't a way to change the screen brightness, i tried the fn plus scroll keys to no avail, any ideas?

Package name is xfce4-power-manager-plugins. Solved my brightness problem in xubuntu 10.04.2.

You can use xgamma. The default value is 1.0, higher is brighter, lower is darker.

Example xgamma -gamma 0.9.


Touchpad and wireless adapter not recoginsed Acer Aspire V3-372-53UE I have installed the offical Ubuntu 14.04 OS. After booting I have realized that my touchpad and wifi are not working. I connected usb mouse and usb wifi adapter and they are both working so I think I am having troubles with drivers. Can anyone help? Btw everything is working on Windows 10.

Thanks in advance!

02:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 15)
    Subsystem: Acer Incorporated [ALI] Device [1025:104c]
    Kernel driver in use: r8169
03:00.0 Network controller [0280]: Qualcomm Atheros QCA6174 802.11ac Wireless Network Adapter [168c:003e] (rev 32)
    Subsystem: Lite-On Communications Inc Device [11ad:0807]
    Kernel driver in use: ath10k_pci

I don't know why are you having problems with the touchpad, but the thing with the wifi is very normal for the newest pc on the market,  so for that problem you can try this :
https://help.ubuntu.com/community/WifiDocs/Driver/Ndiswrapper

that's gonna install the wifi drivers of windows on Ubuntu or something like that, btw I'm not a english speaker (?) so my redaction have a lot of mistakes , but I want to help you
saludos :)


how to count the result How to count the result? when you write a command and some result appears. any way to
count them. For example If I want how many result I have for applications which have python word .

dpkg -l | grep python

In the case of grep, you can simply use the -c option

dpkg -l | grep -c python

From man grep

   -c, --count
          Suppress normal output; instead print a count of matching  lines
          for  each  input  file.  With the -v, --invert-match option (see
          below), count non-matching lines.  (-c is specified by POSIX.)

More generally, you can pipe command output to the wc command e.g.

 dpkg -l | grep python | wc -l

A simple way is to use a for loop and a variable that counts the elements:

for i in `dpkg -l | grep python`; do let elements=elements+1; done; echo $elements

You can change the text inside the `` to adapt it to other commands.


After doing chmod 400 on /usr the sudo command is not working I changed the permission of the /usr to 400 and now I am not able to use sudo. How do I revert this and fix it?

Well - so you made /usr readable only to root, I guess (if no further changes). More over - you removed "x" by that which made the folder pretty much not accessible. Hence you can't now - as regular user - run sudo, which, if I remember correctly, is in /usr/bin/.

The best idea for now would be to start a system from LiveCD, mount your disk/filesystem and change the permissions back to 755.

And next time to be more careful with this kind of changes ;)

I remember that I got a similar problem a few years ago, and the solution was not trivial. You can always recover the sudo command, but, if you changed the permission of all the /usr/ sub-files, since you don't know the exact permission of all the files you changed, you may choose bad/dangerous configuration which would lead you to an unstable system. Maybe doing a re-installation would be better... But if you really want to try to recover your system, or if you didn't recursively changed the /usr permision, you have the following option.

Try #1: Connect as root if the account is enabled (quick to test, but likely to fail)

If you have the root password enabled, you are lucky, just log as root

su root
<enter root password>
chmod 755 /usr

and if all sub files have bad permission (it's may lead to an unstable system) :

chmod -R 755 /usr

Try #2: Boot in recovery mode (do not need USB Key, but likely to fail)

You may want to try to boot in recovery mode, just hit "Escape" or "Shift" when you reboot, and you will get a root. You will be then able to type

chmod 755 /usr

However this method does not always work, depending on how you configured the passwords...

Try #3: Use a LiveUSB (always work)

Take an empty USB key, download a live ubuntu system, copy the system on it by using Unebootin for example, or if you know what you are doing with dd if=<fichier>.iso of=/dev/sdX bs=4M. Boot on the USB key, and then run

sudo mkdir /mnt/drive
sudo mount /sdXn /mnt/drive
cd /mnt/drive
ls   # Check that you see usr...
sudo chmod 755 /usr/


Problem detecting Wifi on Asus A74A with Ubuntu 13.04 I have successfully installed Ubuntu 13.04 as double boot with Windows 8 into my new Asus X74A. Everything works fine, expect the Wifi! although it recognizes the ESSID (see below), it does not switch it ON. Note that under Windows 8 it works fine.

eth0     no wireless extensions.

lo       no wireless extensions.

wlan0    IEEE 802.11bgn  ESSID:off/any
              Mode:Managed  Access Point: Not-Associated   Tx-Power=off
              Retry  long limit:7   RTS thr=2347 B   Fragment thr:off
              Power Management:of

Any help!

prgenevo@prgenevo-X75A1:~$ sudo lshw -class NETWORK
*-network DÉSACTIVÉ
   description: Interface réseau sans fil
   produit: RTL8188CE 802.11b/g/n WiFi Adapter
   fabriquant: Realtek Semiconductor Co., Ltd.
   identifiant matériel: 0
   information bus: pci@0000:02:00.0
   nom logique: wlan0
   version: 01
   numéro de série: 20:68:9d:98:4d:55
   bits: 64 bits
   horloge: 33MHz
   fonctionnalités: pm msi pciexpress bus_master cap_list ethernet physical wireless
   configuration: broadcast=yes driver=rtl8192ce driverversion=3.8.0-19-generic firmware=N/A latency=0 link=no multicast=yes wireless=IEEE 802.11bgn
   ressources: irq:17 portE/S:e000(taille=256) mémoire:f7d00000-f7d03fff
*-network
   description: Ethernet interface
   produit: AR8161 Gigabit Ethernet
   fabriquant: Qualcomm Atheros
   identifiant matériel: 0
   information bus: pci@0000:03:00.0
   nom logique: eth0
   version: 10
   numéro de série: 08:60:6e:95:8d:9a
   taille: 100Mbit/s
   capacité: 1Gbit/s
   bits: 64 bits
   horloge: 33MHz
   fonctionnalités: pm pciexpress msi msix bus_master cap_list ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
   configuration: autonegotiation=on broadcast=yes driver=alx driverversion=1.2.3 duplex=full firmware=N/A ip=192.168.0.18 latency=0 link=yes multicast=yes port=twisted pair speed=100Mbit/s
   ressources: irq:19 mémoire:f7c00000-f7c3ffff portE/S:d000(taille=128)

You have the correct driver loaded for your device but it is problematic in ubuntu sometimes adding driver parameters help if not compiling the latest driver is usually the only way to get it to work.

Please do:

echo "options rtl8192ce swenc=1 ips=0" | sudo tee /etc/modprobe.d/rtl8192ce.conf
sudo modprobe -rfv rtl8192ce
sudo modprobe -v rtl8192ce

Edit:

sudo modprobe -r rtl8192ce
sudo rfkill unblock all
sudo modprobe rtl8192ce

Edit:
If you have windows installed make sure wireless is on in window before you boot ubuntu.

Also go into bios and make sure wireless is enabled if you have that option in the bios if not reset the bios.

Edit:

sudo gedit /etc/rc.local

add the following three lines:

rmmod -f rtl8192ce
rfkill unblock all
modprobe rtl8192ce

Proofread carefully, save and close gedit.
Reboot

Just try to activate the interface:

sudo ifconfig wlan0 up

and

sudo iwconfig wlan0 txpower on

EDIT:
According to the output you should be using a Realtek RTL8188CE.

You can try using that driver (you can find the driver here: http://www.realtek.com.tw/downloads/downloadsView.aspx?Langid=1&PNid=48&PFid=48&Level=5&Conn=4&DownTypeID=3&GetDown=false&Downloads=true#RTL8188CE ) you have to download the "Linux kernel 2.6.24 or later".

So do this:

Download the driver
Uncompress the archive: tar -jxvf linux_mac80211_0012.0207.2013.tar.bz2
Install build-essential and kernel headers (or you won't be able to compile): sudo apt-get install build-essential linux-headers-$(uname -r)
Use the README file inside the archive to compile & install the driver

Anyway the installation process should be:
    su -
    cd *DRIVER_DIRECTORY* (it should be "rtl_92ce_92se_92de_8723ae_88ee_linux_mac80211_0012.0207.2013"
    make
    make install
    reboot

But as I said, read the README file inside the driver archive to being sure.


No internet after upgrade from 16.04 to 18.04 After the upgrade I noticed that I don't have internet access. The wired network and the wifi settings looked good, but it didn't work. After the login the system always switched itself into airplane mode.
I tethered the network via USB and Bluetooth by my mobile but they also didn't work.

Update 2: the bugreport was refused because I couldn't reproduce it on the already upgraded system and couldn't provide data for the developers.

Update 1: I reported the bug on launchpad. You can subscribe if you are involved:
https://bugs.launchpad.net/ubuntu/+bug/1816530

the ORIGIN of the solution

if the /etc/resolv.conf is empty but you can ping 8.8.8.8

$ echo "nameserver 8.8.8.8" | sudo tee /etc/resolv.conf > /dev/null

if the /etc/resolvconf/resolv.conf.d/head is empty then you have to repeat the command above after every restart except you do this:

$ echo "nameserver 8.8.8.8" | sudo tee -a /etc/resolvconf/resolv.conf.d/head > /dev/null

then you have to restart the resolvconf and the networking

$ sudo systemctl enable resolvconf
$ sudo systemctl start resolvconf
$ sudo /etc/init.d/networking restart

I solved a connection failure after an upgrade by using a wireless connection using a USB-attached network adapter, then changing to the preferred wired connection directly to the router.


Updated from Ubuntu 12.04 LTS Wubi to 13.10, won't boot now Yesterday night, I have installed Ubuntu 12.04 LTS through Wubi, since I don't want it to be on a CD or a USB. Later that night, I have updated the version from 12.04 LTS to 13.10. It asked me to reboot to complete the installation of the update, so I did that.

Afterwards, like normal booting, it asked me which OS do I want to open. Windows 7 or Ubuntu, so I chose Ubuntu, of course, but, after I clicked on the Ubuntu button, the Ubuntu start up screen shows (the Ubuntu logo which has five grey loading dots under it) and then it disappears and turns into a black screen with a white line. The white line isn't even moving. What's going on? Please help.

What I always do in a problem is to reinstall whatever version of Ubuntu I am using. That usually fixes the problem (Do not get into any partitioning or any complicated stuff while installing. That may cause problems while booting). Cheers! :)


How to reinstall gnome classic clock in 16.04 I had a problem with my menu-bar clock and date after some wrong fiddling the clock disappeared. I couldn't figure out how to reinstall it.
I did see receive some suggestions, but none of them worked and after I tried them it got worse: the menu-bar disappeared completely!

One of the suggestions is "You need to reset the per-user configuration of the notification area." by  David Foerster. I would like to know how to do it. BTW, I am using Gnome Classic.

Check clock settings and make sure you mark up show a clock in the menu bar option.

If it not editable or responsive then follow this steps .

First make sure your Ubuntu is Upgraded

sudo apt-get update && sudo apt-get upgrade

then reinstall gnome-control-center

sudo apt-get install --reinstall gnome-control-center

then restart the task bar service by

sudo killall unity-panel-service


What do the different colors mean in ls? What do the different colours in Ubuntu's ls command mean? For example, when I type the ls command in one of my folders, I get one of the files in light green, the other (which is a folder) in blue with green highlighting.

What do those colours mean, and there is any manual about all the colours?

Blue: Directory
Green: Executable or recognized data file
Cyan (Sky Blue): Symbolic link file
Yellow with black background: Device
Magenta (Pink): Graphic image file
Red: Archive file
Red with black background: Broken link

For your information:

To turn the color off, you have to comment out the following lines in .bashrc.
# enable color support of ls and also add handy aliases
#if [ -x /usr/bin/dircolors ]; then
#    test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
#    alias ls='ls --color=auto'
#    #alias dir='dir --color=auto'
#    #alias vdir='vdir --color=auto'
#
#    alias grep='grep --color=auto'
#    alias fgrep='fgrep --color=auto'
#    alias egrep='egrep --color=auto'
#fi

Also if you want to see your own bash color meanings,then copy/paste the following codes in your terminal.
eval $(echo "no:global default;fi:normal file;di:directory;ln:symbolic link;pi:named pipe;so:socket;do:door;bd:block device;cd:character device;or:orphan symlink;mi:missing file;su:set uid;sg:set gid;tw:sticky other writable;ow:other writable;st:sticky;ex:executable;"|sed -e 's/:/="/g; s/\;/"\n/g')
{
  IFS=:
  for i in $LS_COLORS
  do
    echo -e "\e[${i#*=}m$( x=${i%=*}; [ "${!x}" ] && echo "${!x}" || echo "$x" )\e[m"
  done
}

Output:

Note:

For more information, type man dir_colors in terminal.

None of the answers here include the 256 color options in the latest versions of Ubuntu. I'm color deficient (some colors give me trouble near each other) so the default blue directory on black is real hard for me to read. What follows is my research to change that.

Type dircolors -p |less to see your current color code.

The default .bashrc should already be configured not only to take advantage of the system color code, but also one in ~/.dircolors so dump the dircolors output to .dircolor so you can start with that using this command.
dircolors -p > ~/.dircolors

Alternative: pick up a very similar 256 color dircolors from seebi's solarized project.

Grab this colortest script and run it with the command colortest -w so you can see all the colors at once. Choose a color. I like the orange #208. I want that to be the text color so using this info on extended color codes, I can apply that.

So you have a color, now what. First we have to create the string.

The first number will be an attribute code, most likely 00, but if you want it to blink go with 05:

  Pick an attribute code: 00=none 01=bold 04=underscore 05=blink 07=reverse 08=concealed

Next pick append ;38;5; to that attribute code to indicate your text color to get 00;38;5; and then append your color. I picked 208 so I get 00;38;5;208.

If you want to also put a background on it, pick another color (let's say 56) with the colortest script and the append ;48;5; for the background and 56 for the color to get a total string of 00;38;5;208;48;5;56.

So now you have it, what do you do with it?

vim ~/.dircolors and find the section you want to change (for me that is DIR) to the string we determined above "00;38;5;208".

This won't apply immediately, you'll need to load the config. Use dircolors ~/.dircolors to the get code to set your LS_COLORS variable. You could just paste that into your terminal session or you can close your terminal and reopen it. You could also pipe that into a file and run it as a shell script.

You can do this same procedure with 16 colors. You don't need the special ;38;5 or ;48;5 stuff. Just toss the numbers into the string and enjoy the simplicity.

Thanks to Dan and seebi for their notes and code on this.


Desktop Search Tool with Lotus Notes Integration Hey Fellow Ubuntu lovers,

I switched a while ago from Win. to Ubuntu and I am loving it! The only thing I miss is the desktop search integration with Lotus Notes. I've been searching the web for quite some while now but without any luck. To bad Google stopped because it seemed to be the only on supporting Lotus notes in Unix based environments.

Anyone got a hint or a tip?

IBM says Desktop Search for Linux is provided by Beagle Desktop and Tracker Desktop software

http://publib.boulder.ibm.com/infocenter/domhelp/v8r0/index.jsp?topic=%2Fcom.ibm.workplace.search85.googledesktop.doc%2Fp_search_m_ovr_srch_center.html

There's a text search package called recoll available in the software center. It comes with Qt based gui.  If you also install the recoll-lens package you can do full text searches of docs directly from the Unity Dash.

Here's the recoll website: http://www.lesbonscomptes.com/recoll/index.html
and here's a little article on the lens: http://www.webupd8.org/2012/03/recoll-lens-full-text-search-unity-lens.html

EDIT: Note that the recoll-lens is available through a separate ppa. To add it, type from the command line:

sudo apt-add-repository ppa:recoll-backports/recoll-1.15-on
sudo apt-get update && sudo apt-get install recoll recoll-lens


How do you make Ubuntu accept files sent over bluetooth I have a problem when I send my files from phone to ubuntu 12.04 via bluetooth as the phone prompts with the message "the file not sent"! I can send any files from ubuntu 12.04 to my android phone.

Go to Dash Home search for personal file sharing. If you don't have Unity installed, you can open the program from a terminal with typing gnome-file-share-properties in it.

At the bottom of the box enable Receive files in downloads folder over bluetooth also enable Notify about received file then you're good to go :)

go to bluetooth sittings and pair your device and choose the device that you want to send or connect audio speaker set shown and put sign on ( use your phone as, and send or play music


How do I activate a conda environment in my .bashrc? I use Conda for package management in Python. I have a basic environment which I use almost all of the time, and I want it to be loaded by default when I open a terminal. How do I set up my .bashrc to load the environment?

So far, I tried source activate myenv, but my understanding is that I need to provide an actual path within the .bashrc file. I then tried source ~/anaconda3/envs/myenv/bin/activate. Although this doesn't throw an error, it also doesn't activate the environment. I'm running Ubuntu 16.04.

It looks like the accepted answers might be out of date. From the docs:

  If your shell is Bash or a Bourne variant, enable conda for the
  current user with

$ echo ". /home/<user>/miniconda3/etc/profile.d/conda.sh" >> ~/.bashrc

  or, for all users, enable conda with

$ sudo ln -s /home/<user>/miniconda3/etc/profile.d/conda.sh /etc/profile.d/conda.sh

  The options above will permanently enable the 'conda' command, but
  they do NOT put conda's base (root) environment on PATH.  To do so,
  run

$ conda activate

  in your terminal, or to put the base environment on PATH permanently,
  run

$ echo "conda activate" >> ~/.bashrc

  Previous to conda 4.4, the recommended way to activate conda was to
  modify PATH in your ~/.bashrc file.  You should manually remove the
  line that looks like

export PATH="/home/<user>/miniconda3/bin:$PATH"

  ^^^ The above line should NO LONGER be in your ~/.bashrc file! ^^^

To activate conda environment simply put this at the end of your .bashrc file
to open .bashrc open terminal, go to home directory.
Run/type nano .bashrc, at the prompt put the following at the end of the file:

conda activate my_environment_name

now save the .bashrc file (Ctrl+Shift+o)
press enter.


Desktop background will not load after performing aticonfig --adapter=all --ovt=opengl I am trying to get Eagle to work on ubuntu 14.04 LTS. When I run Eagle and open a schematic the display is not refreshing/redrawing correctly. One solution that I found was to install the flgrx drivers and do the aticonfig command to use opengl... So I did and rebooted. Now when I turn on my laptop I get all the way to the login screen, login, and then nothing happens, it just goes to the background image with no icons or anything... I tried deleting and copying the original xorg.conf file and no results... What do I do other than reinstalling Ubuntu? is there anyway to force the original driver?

Sorry dude my first try was wrong. I had it and then removed it again. Now I have the correct settings again.

This helped me:

http://www.securethelock.com/2014/04/20/installing-configuring-amdati-drivers-ubuntu-14-04-trusty-tahr/

try this here. I just did it myself 1 h ago. I dont have the right drivers right now but i can use my system.

sudo apt-get purge fglrx*


How do I resume video play from the point it was stopped with VLC? How can I play a video starting from the point it was stopped last time?

This is useful for watching long videos.

I am using Ubuntu 12.04 LTS and VLC media player.

Note: In recent versions of Totem below feature sadly was removed.

Totem
The default Ubuntu movie player Totem has an option to resume playback too. This is accessible from the "Edit -> Preferences -> General" menu. Just tick "Start playing files from last posititon":

Creating a bookmark only saves it if the video is part of a playlist first.  So add the video to a playlist, create your bookmark and then exit.  When you relaunch your playlist you will be able to utilize the bookmark in the playback menu.


Hybrid graphics Intel/Radeon HD 6630M I bought a Dell Vostro 3450 with hybrid GPU and I don't know how to configure properly, I think the fan is running at full speed, also I'm really new in this OS, so I would appreciate all the help you can give me.

Thanks a lot!.

Hardware

2nd generation Intel®Core™ i5-2450M 2.50GHz
6 GB2 Dos canales SDRAM DDR3 a 1333 MHz
AMD Radeon™ HD 6630M (128-bit) 1GB VRAM

since I'm new, i can't post images :(

follow the instructions here:

https://help.ubuntu.com/community/BinaryDriverHowto/ATI

under
Manually installing Catalyst 12.1

do everything there step by step until

"sudo amdcccle

To read more about the AMD/ATI Catalyst Control Center click here. Keep in mind that all configuration options for the ATI Catalyst Control Center mentioned there may not be available for your Ubuntu system. "

works with hybrid graphics card (intel / radeon)

you might have to change the filename of the .run file to the filename of the more recent file you downloaded.  (when typing in the terminal, you can use the tab key on your keyboard to autocomplete)

tested in Xubuntu 11.10

Making procedures for the link
https://help.ubuntu.com/community/BinaryDriverHowto/ATI
the cooler is still in full swing.


How to launch Anbox? I understand, that Anbox is in super alpha, but I need help. I cannot launch it. There is terminal entries:

$ anbox launch
[EE 2017-04-27 16:03:20] [launch.cpp:76@operator()] Anbox session manager     service isn't running!
$ anbox session-manager
[EE 2017-04-27 16:03:44] [session_manager.cpp:119@operator()] Failed to start     as either binder or ashmem kernel drivers are not loaded

You probably need to load the kernel modules ashmem and binder by running

sudo modprobe ashmem_linux
sudo modprobe binder_linux

For Ubuntu, just click on the Anbox icon in the dash.

It's supposed to automatically launch the 'anbox session-manager' and then the gui application window.

Currently it's broken for me and doesn't work in Ubuntu (bitten by bug https://github.com/anbox/anbox/issues/367) :(


UEFI dual-boot, how to load recovery partition (Windows 8) after installing Ubuntu I've installed Ubuntu (~EFI mode) in a ASUS Zenbook UX32VD, which has Windows 8 pre-installed. It had Security Boot disabled. I installed grub in the same partition I put the root directory (sda7 in my case).

After installation Ubuntu loaded and worked, great.

But there were 2 other partitions in grub that didn't run:

Windows Recovery Enviroment (loaer) (on /dev/sda2)
Windows 8 (loader) (on /dev/sda4)

Whenever I try to load any of the above i got:

error: can't find command <<drivemap>>.
error: invalid EFI file path.

I found in Internet multiple people having similar issues: https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1024383

I tried using Boot-repair (recommended repair) utility from Ubuntu, and I've got 2 new entries in grub called:

Windows UEFI bootmgfw.efi
Windows Boot UEFI Loader

They load Windows 8, but the recovery partition is missing. I've tried using Boot-repair more times with different parameters which could make the bootmgfw.efi fail but none added a recovery partition entry:

http://paste.ubuntu.com/1690668/    (this is the last one Boot repair I did. EDIT: This Boot-Repair was using Recommended Repair)

I'd like to know how can I add an entry to grub that loads the recovery one. Any help to make my recovery partition to load would be greatly appreciated.

The Windows RE cannot be loaded directly from GRUB, as it requires bootmgfw.efi to call it.  The only way to get to it is through Windows 8 because it relies on the underlying framework of Windows to be loaded.  As long as you did not move the original partitions (Windows RE and Windows 8) around, you should be able to get into through Windows.  Otherwise, you will need to rebuild the BCD, which is outside the scope of this question.

I had almost the same problem (see here) (same machine!), adding/changing the normal start entry (Windows 8 (loader) (on /dev/sda4)) to

setparams 'Win8'
set root='(hd0,gpt1)'
chainloader /EFI/microsoft/BOOT/bootmgfw.efi

fixed that one. Still, I could not get the recovery-one to work. I really do need that one. Did anyone find any solution to that yet?

EDIT:

Here is one attempt which seemes to have worked for fixing the recovery mode:

setparams 'Win Recover - Recovered'
set root='(hd0,gpt2)'
chainloader (${root})/EFI/Microsoft/Boot/bootmgfw.efi

It boots, then I get a bluescreen. I don't know if this is because this entry is wrong or my win8 is broken...
If someone could verify that it is working - that would be great!


Installing Ubuntu 14.10 (64-bit) on a Windows 8 bay trail atom tablet "How can I install 64-bit Ubuntu on my 32-bit UEFI Bay Trail atom tablet?"

To those of you who marked this question as off-topic, because it is related to a no longer supported version of Ubuntu... This was posted in May, before Ubuntu 14.10 had reached it's End of Life. reference below:

  Ubuntu announced its 14.10 (Utopic Unicorn) release almost 9 months
  ago, on October 23, 2014. As a non-LTS release, 14.10 has a 9-month
  month support cycle and, as such, the support period is now nearing
  its end and Ubuntu 14.10 will reach end of life on Thursday, July 23rd

This post can be found here

Note: As of right now, Ubuntu 15.04 will BOOT on a bay trail tablet, but it will not install correctly.

My guide is based mostly on this one, but with minor adjustments, and easier to follow instructions. This guide is tested and working on the Winbook Tw100 Windows 8 tablet (by Microcenter).

You may require:

USB OTG (on the go) cable, for connecting the USB drive/keyboard/mouse
A 4GB or more USB flash drive
Any downloads mentioned below
You will need to disable Secure Boot and change the boot order in your tablet's BIOS settings

Problem 1: Booting a 64-bit OS with a 32-bit UEFI BIOS on a 64-bit CPU (it's like a jigsaw puzzle)

Download the latest Ubuntu 14.10 (64-bit) ISO file
Download Universal USB Installer
Use Universal USB Installer to create a bootable Ubuntu 14.10 USB drive
Download this bootia32.efi file from GitHub
Place the bootia32.efi file you just downloaded into the EFI/BOOT/ folder of the bootable Ubuntu 14.10 USB drive you just created
Download these two .deb files, and place at the ROOT of the USB drive
NOTE: due to broken links, files have been moved to Google Drive for permanent storage.

https://drive.google.com/file/d/0BxPvhHHEJKxNTzZqX0VBdFNfZ2M/view?usp=sharing

https://drive.google.com/file/d/0BxPvhHHEJKxNY25ZdW5KcEhLeG8/view?usp=sharing

Connect the USB drive to your tablet and power it on

You should be presented with a screen like this, choose "Try Ubuntu without installing"

Problem 2: Installing, and making the installation stick!

After Ubuntu has finished booting, manually partition your tablet's internal storage

1.5.  If you want to Dual-boot Ubuntu and Windows 8, you'll have to do all your partitioning using Windows disk management
After you have finished manually partitioning your tablet's internal storage, install Ubuntu like normal
When the installation has finished, leave the USB drive connected to your tablet, and restart
When you are presented with the GRUB screen again, hit the "C" key, and enter these lines of code...

you might need to change the "(hd0,gpt5)" and "/dev/mmcblk0p3" sections of code to suit your specific needs

  linux (hd0,gpt5)/boot/vmlinuz-3.16.0-23-generic root=/dev/mmcblk0p3

  initrd (hd0,gpt5)/boot/initrd-3.16.0-23-generic

Now enter the "boot" command. If you were successful, you should not have received any error messages, and booted into your freshly installed Ubuntu 14.10 installation. If you receive any error messages, try the last two steps again.

Open a terminal, and enter "sudo apt-get remove grub-efi-amd64"
after that has finished, open the USB drive, and install these two .deb packages in the order that they are listed

grub-efi-ia32-bin_2.02~beta2-15_amd64.deb
grub-efi-ia32_2.02~beta2-15_amd64.deb

Open a terminal, and type "sudo update-grub"
Restart

And you're done!!! If you followed these steps very carefully, and to the letter, then you have a (not-so) fully functioning 64-bit Ubuntu 14.10 (and possibly Windows 8 dual-boot) bay trail tablet.

What doesn't work (this is a list for the Tw100, your tablet may be different)

Sound
Touchscreen
Battery (ACPI)
Accelerometer (tilting, screen rotation)

Check out this guide I did on how to boot Ubuntu 15.04 on bay trail tablets.

You should install the 32-bit version of Ubuntu, which will install the required 32-bit EFI without additional work. However, Canonical does not currently provide the correct install media, so you will have to create it yourself. Instructions here: https://askubuntu.com/a/715843/463546

As of Ubuntu 15.10 and kernel 4.4.0rc7, a lot of things still do not work. However, a certain group of people are trying valiantly to get Ubuntu to work on various flavors of the ASUS T100. In particular, Kirill Belyaev posts kernels and firmwares that get a lot of things to work. Although the hardware in each Bay Trail computer is frustratingly varied, it may help with your device as well.


Installing Cuda 10 and TensorFlow 2.0 Ubuntu 19.10 I've been trying to install Cuda 10.0 and tensrflow 2.0 in Ubuntu 19.10 (the same goes for the previous versions of Ubuntu), but there is no use. It says that the package 418 (althouh I ask explicitly for 410) is not configured and the insalling crashes. I also tried to purge the 418 version and reinstall it, but it doesn't work either.

I already tried several resouces such this and this one but no success. Any idea on how to solve this?

Installing Cuda 10 from the repositories, I had problems with unmet dependencies. After a lot of troubleshooting the sequence that worked for me was:

sudo apt install nvidia-driver-435
sudo apt install nvidia-cuda-toolkit

Then I had Cuda 10 installed. I don't know if this solves your problems with tensorflow.

for installation of cuda 10.0 on ubuntu 18.04/19.10:

see github link: install cuda on ubuntu 18.04

and tensorflow :

 pip3 install tensorflow tensorflow-gpu


How do I get resolvconf to regenerate resolv.conf after I change /etc/network/interfaces? After updating /etc/network/interfaces with something very similar to below, how do I get /etc/resolv.conf to update?  I tried (as root) resolver -u, service networking restart but they didn't work. I also fixed the symlink for resolv.conf and tried resolver -u again. Finally in frustration I rebooted, which did fix the problem by rebuilding /etc/resolv.conf.

Ubuntu 12.04, 64bit server, all the latest patches installed.

Example /etc/network/interfaces:

iface eth0 inet static
    address 192.168.3.3
    netmask 255.255.255.0
    gateway 192.168.3.1
    dns-search example.com
    dns-nameservers 192.168.3.45 192.168.8.10

service networking restart is not always a reliable way of down-upping all interfaces.

The resolvconf -u command only updates resolv.conf from resolvconf's own database. You need to update the database.

To update the database you have to call resolvconf with the -a or -d option. That happens behind the scenes when you run ifup or ifdown. So, normally, as with any other change to /etc/network/interfaces, to activate changes to the dns-* options you have to ifdown the interface in question and ifup it again. Or you can reboot.

If you want to make changes to an interface without ifdownupping it (perhaps because you are administering the machine remotely and happen to be connected via that interface, natch) then you can achieve the same result by running resolvconf directly from the command line. This requires a bit more knowledge of resolvconf's semantics. Assume the relevant /e/n/i stanza is

iface IIII FFFF static
    address ...
    ...
    dns-nameservers X.X.X.X Y.Y.Y.Y
    dns-search SSSS

where FFFF is an address family ("inet" or "inet6").

To activate these dns-* options you run resolvconf as follows (yes, with newlines in the string piped to resolvconf).

echo "nameserver X.X.X.X
nameserver Y.Y.Y.Y
search SSSS" | sudo resolvconf -a IIII.FFFF

For the stanza given in the question this would be the following.

echo "nameserver 192.168.3.45
nameserver 192.168.8.10
search example.com" | sudo resolvconf -a eth0.inet

Consult the resolvconf(8) manual page and the resolvconf package README file (/usr/share/doc/resolvconf/README.gz) for more information.

Also you can try this command:

cat /etc/network/interfaces |sed 's/#.*$//'|grep dns-|sed 's/dns-//g'|sudo resolvconf -a eth0.inet


How to get the boot time of Ubuntu? I am trying to find the boot time of Ubuntu.

The following tells me that my last reboot took 1 minutes 39 second.

$ last reboot
reboot   system boot  3.8.0-29-generic Wed Jan  8 14:55 - 16:35  (01:39)
reboot   system boot  3.8.0-29-generic Wed Jan  8 14:38 - 14:55  (00:16)
reboot   system boot  3.8.0-29-generic Wed Jan  8 14:27 - 14:38  (00:10)
reboot   system boot  3.8.0-29-generic Wed Jan  8 11:07 - 14:27  (03:19)
reboot   system boot  3.8.0-29-generic Wed Jan  8 00:03 - 00:31  (00:27)
reboot   system boot  3.8.0-29-generic Tue Jan  7 10:39 - 14:22  (03:43)
reboot   system boot  3.8.0-29-generic Mon Jan  6 10:51 - 18:42  (07:50)
reboot   system boot  3.8.0-29-generic Sun Jan  5 22:08 - 00:19  (02:11)
reboot   system boot  3.8.0-29-generic Sat Jan  4 11:34 - 15:47  (04:12)

While when I looked at dmesg:

[   14.707210] type=1400 audit(1389173157.301:11): apparmor="STATUS" operation="profile_replace" name="/usr/lib/NetworkManager/nm-dhcp-client.action" pid=1018 comm="apparmor_parser"

This shows that the total boot time is 14.707210. So as per the above two methods which is the actual boot time?

The first command, last reboot, does not tell you the boot time. It tells you at what times your system was running. For example, the first entry tells you that your system has been running from 14:55 to 16:35 on Wed 8. That's 1 hour and 39 minutes. It did not take your system 1 hour and 39 minutes to boot - hopefully ;)

The second command, dmesg, brings you closer to what you want to know, but since dmesg will continually output more system events while your system is running, it's not the tool of choice to measure boot time either.

If you really want to reliably measure your system boot time, I would recommend a tool such as bootchart.

See here:
https://wiki.ubuntu.com/BootCharting

I don't know what the values mean, if you want faster loading times update to Ubuntu 13.10, you will see a nice speedup on your machine and all your apps updated to the latest stable versions.

Remember to run in the terminal:

sudo apt-get autoremove

(this erases packages you don't need)

You can also speed up your system by:

sudo apt-get install bleachbit

and then

sudo bleachbit

This program will delete many unused temporary files, you will also see a nice boost on the loading times, please try it and post the new results so that we can all know the real speedup. Thank you, hope it works!

PS: your phone has a stopwatch function :)