Showing posts with label Ubuntu. Show all posts
Showing posts with label Ubuntu. Show all posts

Ubuntu 18.04 customizations

Ubuntu comes with lots of good options to configure the system.

Few of the things which I like are mentioned below.

Enable Gnome Shell extensions and Windows like themes

https://www.howtogeek.com/353819/how-to-make-ubuntu-look-more-like-windows/


sudo apt install gnome-shell-extensions gnome-shell-extension-dash-to-panel 
auso apt install gnome-tweaks adwaita-icon-theme-full
 
Install few good extensions

https://itsfoss.com/things-to-do-after-installing-ubuntu-18-04/

To use Gnome shell enable the browser extension and also the host extension.

Once you do that, you will see the toggle button for any gnome extension, right inside the browser Window.

You can also congfigure that in Tweaks application
 
 

Clevo P570WM Ubuntu freeze problem

TL;DR

To get Ubuntu running on a Clevo laptop get kernel version 5.6.15+. Here are the steps to upgrade Kernel.

7 years back in 2013, I bought a P570WM laptop from Metabox, I did one big mistake that I invested money on something which was brand new in the market. My goal was to get some good Ubuntu laptop. I thought to go ahead with Clevo based laptop.

Below were the specs, they might not look impressive, but if you think these are 7 years old, then you will feel they were really good back then.

  • Screen type: 17.3" FHD 1920x1080 LED/LCD 
  • Graphics: Nvidia GTX 780M 4GB GDDR5 video graphics
  • Processor: i7-3970X 6-Core 3.5GHz - 4.0GHz 15MB Cache
  • RAM memory: 32GB DDR3 1600Mhz RAM 
  • Primary drive: 1TB 7200 rpm primary hard drive

I was very happy with the laptop arrived, but my nightmare began when I installed Ubuntu in it and it froze immediately on the boot.

Unfortunately, Metabox was of no help, they said they don't support Ubuntu and I was left alone with a massive waste of money of $5.5K machine of no use.

Fast forward 2020, that laptop was collecting dust in my cupboard and I thought to give it another shot and glad it worked. I am using Ubuntu 18.04 with Kernel 5.6.15 and no custom drivers for the Nvidia card.

The posts which gave me a hope to keep moving are mentioned below

https://edgcert.com/2019/06/03/ubuntu-on-clevo/
https://forum.manjaro.org/t/freezes-when-probing-system-on-clevo-n850hk1/60346
https://askubuntu.com/questions/1068161/clevo-n850el-crashes-freezes-ubuntu-18-04-1-frequently

Related Kernel bug
https://bugzilla.kernel.org/show_bug.cgi?id=109051








Screen commands cheat sheet

Screen allows you to keep the session running in background for your system

It just like having multiple workspace in Ubuntu and you can switch between them on command line.

Start the new screen session

screen

Exit ( detach ) from session

Control a + d

See the running screen sessions

screen -ls

Attach to running screen session

screen -r <id>

Kill permanently the specific screen session
From within the running session

Control A and then press :quit

Sync folder between Android Tablet or Phone and computer

 

Requirement

To synchronize the contents of one folder between my android tablet or phone with folder inside my computer

Softwares used

Computer

Some FTP server

In windows i used Filezilla server

See guide here

http://www.addictivetips.com/windows-tips/how-to-setup-personal-ftp-server-using-filezilla-step-by-step-guide/

Read about different sync modes

https://sites.google.com/a/sergey-bogdanov.info/pcfilesync/tutorial-1/syncmodes

In Android

Download the application

https://play.google.com/store/apps/details?id=org.pcfilesync&hl=en

I was able to setup FTP server and sync between the folder in 10 mins

Please follow the tutorial here

https://sites.google.com/a/sergey-bogdanov.info/pcfilesync/tutorial

Now i two folders synchronize each other every 20 seconds.

Making Intel Dual Band Wireless-AC 7260 work in Ubuntu or other Linux

Making Intel Dual Band Wireless-AC 7260 work in Ubuntu or other Linux

Before that some quick simple summary how it works.

The Linux drivers are part of the upstream Linux kernel. But some devices needs additional firmware to tell kernel what device is all about and how to operate it.

So we need to download the firmware from Intel website and place in

/lib/firmware of the system , simple

So head to

http://www.intel.com/support/wireless/wlan/sb/CS-034398.htm

Download the tar related to kernel you have and device you have
Extract it
Place it in /lib/firmware

Reboot your machine

Done!!

Additional notes.

All of these are also part of Linux community code

http://git.kernel.org/cgit/linux/kernel/git/firmware/linux-firmware.git/tree/

In Ubuntu, firmware comes from one of the following sources:

    The linux-image package (which contains the Linux kernel and licensed firmware)
    The linux-firmware package (which contains other licensed firmware)
    The linux-firmware-nonfree package in multiverse (which contains firmware that are missing redistribution licenses)
    A separate driver package
    Elsewhere (driver CD, email attachment, website)

The ideal scenario would have been some one back porting the latest firmeware in linux-firmware for saucy. But this not been done so we can just manually
drop the file.

A additional shortcut you can follow is just download Trusty (14.04) deb file and install it. The trusty already has the firmware for it.

http://packages.ubuntu.com/trusty/all/linux-firmware/download
   
https://wiki.ubuntu.com/Kernel/Firmware



Check nvidia driver version ubuntu

Check nvidia driver version ubuntu

jagat@nanak-P570WM:~$ grep -i "x driver" /var/log/Xorg.0.log
[    23.014] (II) NVIDIA dlloader X Driver  331.38  Wed Jan  8 18:51:00 PST 2014
jagat@nanak-P570WM:~$


OR

dpkg -l | grep nvidia

How to help Kernel developers to help you

I have been bugged with lots of errors in Kernel errors in syslog lately with my new machine.

This machine Clevo is not linux supported offically by Clevo so i cannot ask them manufacturer.

I found this interesting link on how to find which function is throwing error and how to contact maintainer of that Kernel code

http://lwn.net/Articles/395178/


Download Kernel code

git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git linux-git 

Depending on error you get ,try to search the code and find the package from where error statement is being thrown.

After that use Ubuntu bug reporting tool to file the bug or ask question.



Update Ubuntu Kernel to latest Kernel

Go here: http://kernel.ubuntu.com/~kernel-ppa/mainline/

Download 3 (maybe 4) debs to a folder somewhere:

linux-headers-VERSION-NUMBER_all.deb 

linux-headers-VERSION-NUMBER_amd64.deb 
linux-image-VERSION-NUMBER_amd64.deb 
linux-image-extra-VERSION-NUMBER_amd64.deb # if available



Install the debs with whatever package manager front-end you use (is gdebi still around?), or use these commands:

cd /path/to/folder/where/you/put/the/debs

sudo dpkg -i *.deb
sudo update-grub
sudo reboot now

Choose the deb files above depending on your i386 or amd64 bit OS version

References

http://askubuntu.com/questions/119080/how-to-update-kernel-to-the-latest-mainline-version-without-any-distro-upgrade

Failed to open/create the internal network (VERR_INTNET_FLT_IF_NOT_FOUND)

I got this error while using Virtual box on Ubuntu.

Due to this networking was not working properly

Its a bug in Virtualbox
4.2.16
and fixed in 4.1.18

This happens with 3.11 Kernel

http://aptosid.com/index.php?name=PNphpBB2&file=viewtopic&t=2665&view=previous

Failed to open/create the internal network (VERR_INTNET_FLT_IF_NOT_FOUND)

 

 


How to share packages with other ubuntu systems via apt-cacher-ng

I have a host Ubuntu 13.10 system in which I am installing packages via

apt-get install

Now there are many virtual machines which run on top of this host machine.

I want these virtual machines to install from already downloaded packages by the host machine and skip going to the internet first to save my time.

I want to share only which I need and I want to download only once in my host machine.

Solution:

apt-cacher-ng

This creates a proxy that packages are downloaded only once and all machines can quickly download from it.

Here are the install steps

On my base host machine where i want to create apt-cacher-ng proxy

sudo apt-get install apt-cacher-ng

Open the browser to see that its installed successfuly

http://myip:3142

For me its

http://nanak-p570wm:3142

Now i all client machines including the host machine tell them to use proxy to get the packages

touch /etc/apt/apt.conf.d/01proxy

cat > /etc/apt/apt.conf.d/01proxy <<EOF
Acquire::http { Proxy "http://nanak-P570WM:3142"; };
Acquire::ftp { Proxy "ftp://nanak-P570WM:3142"; };
EOF

Thats it , try to test by downloading few things and see the magic


References

http://linuxexpresso.wordpress.com/2011/02/13/howto-apt-cacher-ng-on-ubuntu/
http://www.ubuntugeek.com/apt-cacher-ng-http-download-proxy-for-software-packages.html

 

GPE storm detected , transactions will use polling mode

In my machine i have been experiencing frequent system hang behaviour which i have to stop by hard system boot

OS : Ubuntu 13.10
Hardware Clevo P570WM

CPU Intel(R) Core(TM) i7-3970X CPU @ 3.50GHz

Graphics card
GK104M [GeForce GTX 780M]
driver=nouveau

Wireless

Wireless Intel Corporation 7260
driver=iwlwifi driverversion=3.11.0-7-generic firmware=22.0.7.0

BIOS
American Megatrends Inc.
version: 4.6.5
date: 03/20/2013
capabilities: pci upgrade shadowing cdboot bootselect socketedrom edd



I am trying to diagnose whats in syslogs at time of hang

Here is my ongoing analysis

Till now i have not found solution and problem.

It can be hardware issue
It can be a software issue

I am grouping my syslogs messages at hang time in different posts here on blog and corresponding steps in took.



syslog messages

Sep 14 10:28:55 nanak-P570WM kernel: [ 4855.198902] ACPI: EC: GPE storm detected(9 GPEs), transactions will use polling mode

Read on net about what is GPE storm  , it can be a hardware issue. One of the solution suggested here was to add boot parameter which can tell apci that this is linux machine.

I did following

#Commented as per http://forums.linuxmint.com/viewtopic.php?f=42&t=56323
#GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux"

sudo gedit /etc/default/grub

sudo update-grub

Lets see how it goes

Update : It has been more than 24 hours since i had the same issue. Seems things are working with that grub conf change about acpi_osi
Last error i had on 13 Sept 2013 when i changed this setting.

Eclipse menu not working ubuntu 13.10

I downloaded eclipse on Ubuntu 13.10 and when i open eclipse you know that for all applications ubuntu show menu at top bar. Eclipse was also not exception.

However strange thing was i could not do anything with those links.

So i searched and found this bug

https://bugs.launchpad.net/ubuntu/+source/indicator-appmenu/+bug/659931

Read if you like

How to solve

Instead of clicking eclipse directly start it with following command

 UBUNTU_MENUPROXY= /home/jagat/development/tools/eclipse/eclipse

Where the path on right side is exact path where your eclipse is sitting.

This should bring menus back in eclipse like normal OS and it would work.

However i am still thinking why this did not work in Ubuntu




Ubuntu safe remove usb drive

To safely remove the usb disk drive from Ubuntu

Right click on USB Disk drive

Select

Safely remove parent drive


The following packages have been kept back

While updating packages on Ubuntu if you get this message

Use command

sudo apt-get dist-upgrade

This will update everything.

Which process is using port

$ netstat -lnp | grep portNo

Note the process id and process name

To see full path of process use the command , replace the processID below

ls -l /proc/processID/exe

Example

ls -l /proc/1222/exe

Ubuntu proxy switcher

A addon to quickly switch Ubuntu proxy

http://erasmusjam.wordpress.com/2011/07/08/a-proxy-switcher-application-indicator-for-ubuntu/

Edit file as root using gedit in Ubuntu

Often we see file as readonly if you are not allowed to edit it. Then we need to open it as sudo ( or root) user

The simple command to open any file using root , in graphical editor (e.g gedit) can be

# sudo gedit filename

This will open file in edit mode and as a root you can edit this. Once you are done click save and close the gedit window.

Done :)

Install SSH on Ubuntu 11.10

The default package for SSH in Ubuntu is openssh-server

To install in simple steps do this

#sudo apt-get update
#sudo apt-get install openssh-server

This would install the ssh server in your computer. If you want to change some default configuration settings in SSH then you can follow the below post. It describes the process to install SSH on Ubuntu 11.10 and how to change various settings.

http://www.jonathanmoeller.com/screed/?p=3328

Blogging client for Ubuntu

This post is part of my learnings towards movement from Windows to Ubuntu

I have been using Windows Live writer since long , so i was looking for similar kind of software for Ubuntu

After search i found the following alternatives

Blogilo
Drivel
Lekhonee

And one solution for browser based editor can be Scribefire

Similar blog posts

http://www.scaine.net/site/2010/07/blogilo/
http://askubuntu.com/questions/78593/what-blogging-clients-are-available

7 day Ubuntu Challenge for myself

I have been Windows user since pretty long , but not i want to change myself for better things.

So i have challenge for myself to use Ubuntu for one week continuously where ever i am using my own system. I would not be using Windows at all

Just trying to document my learnings as i convert myself from Windowish guy to Nix :P

I would be maintaining my daily learning log on issues which i faced and how i found answers with them.