Friday, May 23, 2025

How to setup encrypted external hdd/sdd in linux

It is pretty much required to save your files in a encrypted way for security and privacy reason. IT infrastructure should offer this in the most easiest way. Though all hard disk vendors provide this kind of encryption, it would involve the use of a software distributed by the vendor and moreover, it would work only with Windows systems. I was on the lookout for a pretty robust and straight forward method to used it in an external hard disk. I got all the methods from this link below. 

https://linux.fernandocejas.com/docs/how-to/encrypt-an-external-hard-drive

lsblk

lsblk - lists block devices

RECOMMENDED: Wipe all file systems and data from the hard drive

sudo wipefs -a /dev/sda

Run cryptsetup to create the encrypted partition (it would be mostly installed, otherwise install it)

sudo cryptsetup --verbose --verify-passphrase luksFormat /dev/sda

Open the encrypted partition

sudo cryptsetup luksOpen /dev/sda sda

Create a new filesystem on the encrypted partition

I chose F2FS which is Flash-Friendly File System developed by Samsung. 

F2FS stands for Flash-Friendly File System. As the name suggests, F2FS is designed for flash-based storage, such as SD cards, eMMC modules, and flash drives. F2FS will achieve better performance and extend the lifetime of flash-based storage in many cases compared to other traditional file systems, such as ext4 or XFS. The F2FS format is especially useful on single-board devices (like Raspberry Pi, RockPro64, etc.) that boot from an SD card or an eMMC module. Many Android devices use F2FS too.

Install f2fs-tools

sudo apt-get install f2fs-tools

Format in f2fs

sudo mkfs.f2fs /dev/mapper/sda

Make a label for the hdd, I call it samsung

sudo mkfs.f2fs -l samsung /dev/mapper/sda

By default, some space has been reserved, but if you don’t intend to run a system from the hard drive, you can remove it to have slightly more space on the hard drive.

sudo tune2fs -m 0 /dev/mapper/sda

Now make the partition writable 

sudo chmod +Rv /media/sid/3cd11ec2-a30d-4eb8-a24f-ddce6d1ef5f3/

Now you can write anything with the file explorer

sudo cryptsetup luksClose sda

Eject and remove the hdd

To open again 

sudo cryptsetup luksOpen /dev/sda sda

Or while mounting your GUI will open a dialog box to enter your encryption password to open the folder. Using open source tools to encrypt the hard disk can be reliable. 

In case you want to change your password for the external hard-disk encryption,  you can use

sudo cryptsetup luksChangeKey /dev/sda 

It will ask for old password and allow you to enter a new password which you can use later. 


Friday, April 18, 2025

Kubuntu 25.04 Plucky Puffin review

A blog post after almost 8 years, in my Linux Experimentation Blog. The latest release of Plucky Puffin made me so elated to write this Blog Post as a review of the Kubuntu 25.04 which is codenamed Plucky Puffin. A longtime Linux user and a KDE fan, I have mostly used Kubuntu or Debian KDE. 

Of late, I have been using Kubuntu as my daily driver for almost two years on my Asus Zenbook UX3402ZA. I am an adventurous Linux distro user, not hesitating to use beta versions, but my age and focus in life currently, prevents me to do so. However, the youth in was ailing to test the latest KDE 6 iteration. However, I had to wait till the latest Ubuntu release 25.04 which would allow me to use the polished KDE 6.3 version which I was longing for. I was waiting for the 17th of April to arrive in my calendar, often checking the news for the release of 25.04 version of Ubuntu. I live in India and I got the version update notification at around 9.30 pm on my laptop. I had my hard disk to the brim,  so had to delete a few large video files to allow space for the upgrade. 

The GUI upgrade tool had some glitches and threw up a few errors. So I took the command line route for the install. The updater showed an upgrade of around 2400 packages to be upgraded, some additional packages to be added and a few packages to be removed. I started with "Y" and waited anxiously. Despite my fast home broadband, the in.archive.ubuntu.com servers were probably a bit slow and it took a lot of time downloading packages. The downloads lasted for about an hour and then the unpacking and installing took about 45 minutes. I booted in to my new system, but I was shocked to enter a non-responsive system. The window manager was lightdm or something. I had to login to the cli, install Kubuntu system and then set the windowing system to sddm and then to Plasma X11. With my Linux expertise and web searching I fix all the glitches and enter in to the shiny new KDE system.

After login and first install, I was taken aback but the aesthetics of the system. I felt so proud and happy to use such a sweet OS. In today's age of Apps and AI, the operating system is no longer a matter. And, Linux has come a long way, its a highly mature and stable and user-friendly system. But I am proud to  Linux which gives me the freedom and a lot of choices. I am not tied to a corporate OS like Windows or Mac which decides what's good for you and changes its policies at its whims. Their decisions are mostly dumb in my opinion. On the contrary, the Linux desktop has reached such a maturity, stability, beauty and ease of use and Kubuntu 25.04 is a testimony to it. In my opinion, it's the most beautiful desktop in the world and I feel elated to use it. The Breeze icons look gorgeous, the font rendering is so good. There are no glitches whatsoever. My favourite desktop enviroment, KDE has reached its pinnacle and I wonder what more would be there to improve. However, as any human endeavour, computing never ceases to evolve. Computing has changed a lot in the long years since I have been using it. My daughter who is 7, is a different a kind of user, she has started her computing in the age of tablets and apps. Her understanding and her vision of the computing platform would be much different.  I am still wondering, how the open source platform and KDE in particular will handle AI and VR and the ever changing forms of computing in the years to come. 



The KDE 6.3 desktop with its default wallpaper. 
 



The KDE 6.3 control center in the Breeze Dark Theme


Kubuntu 25.04 Plucky Puffin with KDE Plasma version and Linux version details 




Tuesday, May 16, 2017

Thoughts on my Google Chromebook Pixel 2013

I jumped in joy when Google released the Chrome browser. It is a piece of software that changed the computing world rapidly. It had maximized screen viewing area, it set new standards in HTML, it set limits for browsing speeds, brought new video codecs to usage and finally became a trojan horse in the Microsoft Empire. Believe it or not, people live more time in the Chrome world than in the actual operating system world. Soon, the browser became OS agnostic, and lots of people migrated into the MAC OS world. Chrome terminated the dominance of IE in a short time. It is so popular and successful like its original project leader who is now the CEO of Google.

When it was released I had a major gripe that it was not released for Linux operating systems. It was the heyday of netbooks and Chrome was needed in them. Sensing the obvious, Google released a netbook with just Chrome in it and called it Chromebook. I had even applied for the Chromebook testing program in which Google gave away a Samsung Chromebook to initial users. I wasn’t the lucky few who got one. Later, in 2013 Google released a Chromebook with the highest imaginable specs, that it can hardly be called a netbook. Chromebook Pixel was born in Menlo Park which would soon become a toy of rich geeks. Even Linus loved it. Even now, I think, its screen in unrivalled in terms of pixel density and colour reproduction. I simply fell in love with this machine and waited till I could afford one. And 3 years after its release I could lay my hands on a 2013 (Ist gen. model). The screen needs just one word to describe it: Gorgeous

The concept of the Chromebook is brilliant, a lightweight computer which just the minimalistic body of computing while the soul lives somewhere in the cloud. The “Chrome” is this link between this body and soul. It's beautiful in that the body is never important, and guardian angel “Chrome” updates itself in Google’s command, keeping the system safe and snappy. I love the concept of having a computer in which you never have to really install programs in the classical sense, no .exes, no Photoshop, no MS Word. The moment you switch on, a secure browser is ready to serve you web services and your soul comes alive with your documents, photos, music and videos. Google has created a new paradigm in computing rather than competing with MS for market share.

Now to my experiences as a loyal Google fanboy. Chromebook Pixel was great, I loved seeing it, touching it, and not so much using it. Like many bloggers and tech enthusiasts have already put it, it's really hard to find a 100% usage of your Chromebook (Pixel in my case). Its biggest advantage is also its disadvantage, there are no programs that live in the computer for simple tasks. For simple tasks like editing an MP3 tag, there was no tool, I had to upload all my music to Google Play Music, rename and then download. For a minor photo edit, I had to upload the photo to a cloud photo editor and then download it. Remote desktops worked fine and I could connect my laptop running Elementary OS with ease. Google docs and Google productivity suite was the main reason for me buying this laptop. Google docs was impressive in the Chromebook Pixel as it should be. I could create offline documents, work on documents offline and sync once connected. The audio quality was simply gorgeous as its screen(this is the first gen. Chromebook Pixel), rich in bass, clear and loud. The screen had nothing else to compare. The touchscreen which is obviously a fingerprint magnet is still a pleasure to use especially for scrolling. The screen form factor of 2:3 is the most sensible choice for using the web for reading and being productive.

I had very little hate over the abundant love I had for my Chromebook Pixel. I tried every possible use for my Chromebook and the experience was positively very different. Finally, I had to give up my Chromebook Pixel not because of my hate but because of a hardware failure in the gorgeous screen. The most beautiful part the Chromebook Pixel had some horizontal lines, a rare manufacturing defect. Since I had bought it in Hong Kong where this piece of hardware is not sold legally, I could not get it fixed by Google. I could have tried third party services to replace my the panel, but I decided to let it go, to avoid many hassles.

Given my first experience with the Chromebook Pixel, I still would like to go for the newer versions. The Pixel C is an evolution in this lineage where the Chrome meets Android. I would love to try this beauty sooner or later. I believe in the marvellous innovation in technology by Google despite it not being "not evil” anymore. I have to admit, I am a simple stupid Google fanboy.



Monday, January 16, 2017

No Times New Roman in Google Docs



A self confessed Google fan boy, I own a Pixel Chromebook 2013. I planned to use it for all my office work,  to replace Microsoft Office products. I am amazed by the vision of Google to have everything tied to the cloud. It makes good sense to move your work to something independent of any OS or even a physical storage. It feels really cool that you you don't have to install any program but still get all your work done with your browser. 

It was quite a revelation to me when I read two write-ups (the other one) today of how Google fooled people in thinking that what they use as Times New Roman (in Google Docs) as Times New Roman. When you use Times New Roman to type something in Google Docs, it actually displays "Tinos" a font which Google says is metric compatible with Times New Roman and released under Apache license. To the untrained eye, it is hard to believe. So I set to test it with comparison with Times New Roman, as produced by Microsoft Word.  To me Tinos looks much closer to Liberation Serif which is mostly used in Libreoffice. I also compared Tinos with Liberation Serif. 

Times New Roman vs. Tinos




















Times New Roman vs. Liberation Serif
















Liberation Serif vs. Tinos

















Comparing all three in Lorem ispum dolor sit amet





Google has remedied the situation somehow probably by a font licence agreement with Microsoft such that if you download a PDF, it comes out to be Times New Roman.  It makes sense because when you want to print from Google Docs, it automatically downloads the document as PDF. But what you see while typing with Google Docs is actually Tinos and Google doesn't tell you that. If you download the document in docx, and forward it to your supervisor or colleague, they wouldn't get Times New Roman as how this student had to get less grades because he could not use Times New Roman as per his school rules. Google is to be blamed than anyone else in this case. Another case of loosing grades here. Mighty Google are you willing to help students using Chromebooks?

In my opinion, Tinos which is a part of Croscore fonts  (Chrome OS core) is very much similar to Liberation Serif fonts (see comparison above). So people working with Liberatoin Serif under Libreoffice under Linux systems get similar looking fonts as Tinos in Google Docs.

I goes without saying that what you see you as "Arial" in Google Docs is nothing but "Arimo". I will do a comparison between Arial and Arimo in the next article. However, I am guessing the difference would be hard to detect because they are 'Sans serif' fonts. 

Here is a PDF version for printing of the fonts.

Wednesday, October 12, 2016

How to install system load indicator / monitor to Elementary OS 0.4 Loki

Elementary OS 0.4 codenamed Loki is a Linux distribution worthy of much praise. It is lightweight, stable and based on Ubuntu 16.04 LTS release, meaning the repositories would host of a lot of updated packages. However, the GUI of Elemantary OS, Pantheon Desktop Environment, does not have a system monitor included. You can install Gnome system monitor, but it doesn't look good on the Pantheon user interface.

A simple way is to install, the system load indicator called indicator-multiload which is lightweight and meets most of the requirements of a system monitor. Most importantly It blends well with the Pantheon wing panel on the top of the desktop. To install it we need to add the PPA (Personal Package Archive) called indicator-multiload.

For ease of use, just follow the commands below.

sudo add-apt-repository -y ppa:indicator-multiload/stable-daily


sudo apt-get update


sudo apt install indicator-multiload




Wednesday, May 27, 2015

How to install Latex typesetting package in Ubuntu 14.04 / Debian Jessie

Latex is the probably the best typesetting package available. Though the learning curve is high, the benefits of using Latex outweighs several other programs. First of all its free, available on all platforms. The way it handles whitespaces is logical. There are lots of graphical backends for actually typing and creating Latex documents.


Latex is packaged as texlive packages for Ubuntu and Debian.


The barebone packages used for installing and using Latex in Ubuntu/Debian systems are: texlive-latex-base, texlive-latex-extra, texlive-fonts-recommended (for special font packages such as marvosym.sty etc)


sudo apt-get install texlive-latex-base texlive-latex-extra texlive-fonts-recommended



For creating documents you need can also install a good Integrated Development Environment (IDE) for Latex. The options are lots such as Texmaker, Texworks and Kile. My personal favourite is Texworks for its simplicity and lightweightedness. Kile is also a very good Latex editor for KDE.



sudo apt-get install texworks



If you want to use beamer for presentations:




sudo apt-get install latex-beamer



Sunday, December 14, 2014

How to install Adobe flashplayer from .tar.gz from adobe website

Though Adobe flash is getting less and less popular with the rise of HTML5 for online video content, it is still an integral part of the web. Adobe pushes security updates to its 11.2.202.XXX version of flashplayer even though it has pledged not to update it to newer version numbers.

Popular Linux distros offer easy ways to install and update the non-free Adobe flash plugin. For example Ubuntu lets you install Flash through a package called 'flashplugin-installer'. Similarly Linux Mint offers 'mint-flashplugin'. The problem with these install scripts is that they don't work well when you are behind a company or university's proxy settings (sometimes even after you set your proxy environment according to this blog). The way to setup proxy to your wget is given here and here. But even after trying those, my mintupdate-flash was not able to fetch the latest flash though it informed me of an update that is available (on my Linuxmint Debian Edition install).

So I had to resort to installing it manually by downloading the binary from Adobe's website. The method I followed was pretty much based on this thread as per user IgnitE's post. This blogpost also tells us how to install flashplayer for Debian based distros.

I'll summarize what I did to install Adobe flashplayer from Adobe's website and it works for an update as well as a fresh install of flashplayer from Adobe directly.

First go to Abode flash download page, choose the updated version as .tar.gz version. Make sure you choose the 64-bit version or 32-bit version according to the Linux installation you have. The download usually goes to the Downloads folder in your home directory(~).


Make a directory under ~/Downloads to place the untarred files

mkdir adobeflash

Untar the contents into it

tar -xzf install_flash_player_11_linux*.tar.gz -C adobeflash/

Change to the directory where the files are untarred

cd adobeflash

Now there would be: /usr, libflashplayer.so and readme.txt files in the untarred folder. We have to copy the /usr and libflashplayer.so to the appropriate directories for the install process.

First,

sudo cp -r usr/* /usr


If you are in Debian or Ubuntu prior to 14.04 i.e., 13.10 and below follow the below command (Yes, it works for both Firefox and Iceweasel).

sudo cp libflashplayer.so /usr/lib/mozilla/plugins/

IF you are in Ubuntu 14.04 or above, then use the following command

sudo cp libflashplayer.so /usr/lib/firefox/browser/plugins

Restart the browser and you have the latest flash installed, check it by right clicking flash content or by clicking here.

Apart from this you can get the Google updated Pepper flash by installing Google Chrome. But for now, I would prefer to use the flashplugin provided by Adobe in Firefox and Chromium.


PS.: The problem of mintupdate for flash was not due to wget proxy problem, but due to the fact that linux mint software repository mirror has been clogged due to heavy usage. When I changed the software update repositories from the mint update manager (Software updates - Edit - Preferences - Update sources; change the mirrors to something else than the default) and refreshed the cache, I was able to install mintflash update properly even under my proxy settings. So it is better to check your repo mirrors before trying the method mentioned above. Otherwise the update manager would still be showing an update unless you unistall the mint-flashplugin package.