Monday, December 10, 2018

Time synchronization issues in Dual boot Linux Mint/Ubuntu and Windows

I have always used to have the network time in my Linux Mint 19 or Windows 8. However when I switch between Linux and Windows[or vice versa] the time gets modified and wrong time would show up. This Time synchronization issues in Linux Mint/Ubuntu which can be solved by the following simple task.

1. Use your favorite editor to edit the file as root [If file not found create a new one]. I am using xed here.

sudo xed /etc/adjtime

2. Make the file looks as below. For me, I had only the first line. I created the next two line and saved it.

0.0 0 0.0

3. Reboot!

The issues exactly what is happening in the background is very well explained in this reference article.


Install Latex Texmaker on Linux mint 19 / Ubuntu 18.04

Installing latex is pretty straight forward. We could get it from the official packages /repos througth command line. I wish to install a "full" latex support as I don't want to install any other packages to install later on. So, the Download size is ~2.5GB and installation space need is 4.5GB roughly. Texmaker is just 5-50MB where as the rest is fully occupied by LaTeX  or TeX or TeXLive.
sudo apt-get update
sudo apt-get install texlive-full texmaker
Next things is that spell check
When do a check spelling you will get an "Error can't open dictionary"
Go to Options>Configure>Editor tab
Change myspell to hunspell dictionary. I wanted British English so I selected the below:

Thanks to vijay!

Next thing is you may have to install Latexdraw for drawing pictures. It need Java SE/JDK. I installed JDK from official oracle site here. Click JDK download(I would need for java programming etc).  I used deb file. Clicking/opening it will install it automatically or based on deb file

"sudo dpkg -i jdk-11.0.1_linux-x64_bin.deb"

As oracle Jdk didn't registered in update-java-alternative or update-alternative --config java. I went to fix it manually. I was able to locate my installation at  "/usr/lib/jvm" called "jdk-11.0.1" folder.

Extract the downloaded from After extracting run the following.

sudo /usr/lib/jvm/jdk-11.0.1/bin/java -jar installer.jar
That's it. Bye for now.
I have disabled trigger email from comment. Contact me on twitter instead for any questions.

Sunday, November 25, 2018

Install CUDA 10 on Linux mint 19 or Ubuntu 18.04

Assuming that you have nvidia GPU with cuda compatibility.
These are the steps for installing CUDA 10 on Linux mint 19 or Ubuntu 18.04
  • Install Linux mint 19/Ubuntu 18.04 fresh
  • Use the ppa nvidia drivers repo from lauchpad here
    • sudo add-apt-repository ppa:graphics-drivers/ppa
      sudo apt-get update
  • The version 410 is the current long term version as on date
  • From "Driver Manager" install the current stable version


    • Reboot; verify the driver installed from terminal using "nvidia-smi" command

    • Install these packages
      • sudo apt-get install build-essential dkms
        sudo apt-get install freeglut3 freeglut3-dev libxi-dev libxmu-dev
    • Download the deb file and follow the below steps

    • sudo dpkg -i cuda-repo-ubuntu1804-10-0-local-10.0.130-410.48_1.0-1_amd64.deb
      sudo apt-key add /var/cuda-repo-10-0-local-10.0.130-410.48/
      sudo apt-get update
      sudo apt-get install cuda

    • That's it.
    • Default location of installation is /usr/local/cuda
    • " ~/install" installs sample files
    • cd into the folder "NVIDIA_CUDA-10.0_Samples"
    • make -j2
    • Add the "PATH=$PATH:/usr/local/cuda/bin"  to your "~/.bashrc" as a last line.
    • run "deviceQuery" to verify the cuda installation.  And do the post installation formalities
    • sudo apt-get install g++ freeglut3-dev build-essential libx11-dev \
          libxmu-dev libxi-dev libglu1-mesa libglu1-mesa-dev

Saturday, November 24, 2018

Challenges in installing Linux Mint 19 to dual boot along side windows

 WARNING: There is an updated Install notes. Check out  the recent post
Had a tough time setting/installing up Linux mint 19 on my existing dual boot machine to solve these 2 problems:
1. grub-efi-amd64-signed' package failed to install into /target
2. Hash Sum mismatch.
3. shim-signed and grub-efi-amd64-signed failure to configure.
Huh. Nearly 6 hours trying to figure out.

As it happened:

I had a Linux mint 18 and a rusted windows. So I wanted to refresh my machine. So I reset factory/recovery settings on windows. And wished to install Linux mint afresh. So, I have downloaded the ISO file named linuxmint-19-cinnamon-64bit-v2.iso from the official website and verified. I have made necessary partitions while installing and installation went smooth. However, right after installing and just before grub installation, this error came up.

"GRUB Installation Failed.
The 'grub-efi-amd64-signed' package failed to install into /target/. Without the GRUB boot loader, the installed system will not boot".

To rectify this.
1. install boot-repair
sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install boot-repair 

Open boot repair and run the recommended things. [it took 20mins; be patient] It will FAIL badly. Never mind go ahead and restart it. It worked. Because it has successfully reinstalled grub.

2. apt-get update would not completed it will show error like "Hash Sum mismatch"

E: Failed to fetch  Hash Sum mismatch
   Hashes of expected file:
    - Filesize:393124 [weak]
    - SHA256:a70a891ed73362c0a3966c9c6c790096f5aba663389ab578a6b991b698ae43c6
    - SHA1:4e0cfabaaf47b0cbf6ecc284e5281430bbe530d2 [weak]
    - MD5Sum:94742010fa630d152bbff1445f6369b4 [weak]
   Hashes of received file:
    - SHA256:ea9bf28ed7d57e5bd739fc63485459130475026c35a84f25e57d2f5ca0521ec7
    - SHA1:af7bad4e086d5e768c450c77032ee520d58afeda [weak]
    - MD5Sum:aa28e356c8a66b4838a83ab18e10e2d5 [weak]
    - Filesize:393124 [weak]
   Last modification reported: Fri, 23 Nov 2018 12:50:34 +0000
   Release file created at: Fri, 23 Nov 2018 13:51:10 +0000

To resolve this:

sudo apt-get clean
sudo rm -rf /var/lib/apt/lists/partial
sudo apt-get update -o Acquire::CompressionTypes::Order::=gz
sudo apt-get update

Resolve steps 2:
I am not sure above steps did resolve it completely. because I was still getting. Hash sum mismatch even after doing that.

Changing the main mirrors to different URL in Software source actually fixed in.

3. New problems:
Everytime I installed some pkg
It would try install some failed installed packages such as

Resolve steps

sudo rm /sys/firmware/efi/efivars/dump-*
sudo update-grub
sudo apt-get -f install

Linux mint and askubuntu forums.

Last Post !! Moved to new site

As I am getting old 😋, it seem like I can not remember many of my earlier tech encounters. This is the place I was logging so that I refer ...