How to add user with encrypted home folder in Xubuntu 18.04 LTS or Ubuntu 18.10

After a long while, upgraded from Xubuntu 16.04 LTS to Xubuntu 18.04 LTS and was in for a surprise. No encrypted home folder. Support for this was dropped as ecryptfs-utils was no more maintained by it’s maintainer.

However, fret not. Encrypted home folders can still be created as below. Make sure you take a backup of your system first.

Open a Linux Terminal window.

Install the ecryptfs-utils and cryptsetup packages, or whatever is available of them at this time:
$ sudo apt-get install ecryptfs-utils cryptsetup <enter>

Add user1 with encrypted home folder:
$ sudo adduser --encrypt-home user1 <enter>

Add user1 to the sudo group, so that it is able to perform administrative tasks:
$ sudo usermod -aG sudo user1 <enter>

Lastly, if you do not want the original user0 you created, you can remove it by:
$ sudo deluser user0 sudo <enter>
$ sudo userdel -r user0 <enter>
$ sudo find / -user0 1000 -print <enter>

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s