How to Encrypt a Drive on Ubuntu 18.04

29/12/2020
Chưa phân loại
Encryption is the best way to ensure your security of your personal info and other credentials. In the current world, encryption is the final option that we can only trust. That being said, if you have a personal computer, encrypting it is also one of the best ways to tighten your security.

Today, let’s take a look on encrypting your drive on Ubuntu 18.04. Note that all the Ubuntu flavors and Ubuntu-based distros will support the guides. No need to worry about compatibility.

Understanding the pros and cons

Encrypting a drive has both its benefits and disadvantages. Let’s talk about them first.

The benefits are numerous.

  • Increased privacy protection.
  • No one can break the data, not with current technology. Even cracking a single file may take 1000+ years.

There are some disadvantages as well.

  • If you forget the key, the data is as good as lost.
  • Data recovery is impossible.
  • The partition won’t be accessible to other systems and may cause SERIOUS compatibility issues.

For the protection of the data, you must remember the pass phrase, no matter what.

Encrypting machine’s host drive

Well, let’s jump into the encryption part. Whenever you install Ubuntu, you can have an encrypted drive right away. If you don’t remember how to install Ubuntu, let’s check out installation procedure of Ubuntu 18.04.

Thanks to the power of VirtualBox, we’re right into the installation of Ubuntu 18.04!

As soon as you arrive at this stage, check the option to encrypt the new Ubuntu installation for security. Choosing the LVM option is optional but good if you go with that.

At the next step, you’ll have to choose the security key that you’ll have to enter each time your computer boots up.

Continue the installation normally. Note that you will have to configure another password for logging into your user account.

Complete the installation as usual and restart the system.

Once the system starts, you will have to enter the passkey for the encrypted drive. Without the pass key, system won’t boot either. There’s literally no way to bypass it, literally NO WAY!

Encrypting a USB flash drive

Do you have a personal USB flash drive? Want to encrypt it? Let’s do it!

At first, we need a tool – GNOME Disk Utility. Run the following commands to install it –

sudo apt update && sudo apt upgrade -y

sudo apt install gnome-disk-utility cryptsetup

Start the disk utility tool. It should be present with the name – Disks.

Now, connect the USB flash drive.

Unmount the drive’s partition.

After unmounting, time to format the drive. That’s why make sure that the drive doesn’t contain any important data beforehand.

Select to format with “Ext4” file system and LUKS enabled. You can choose to erase but it will take longer time depending on the size of the drive/partition.

Create a password for the new encrypted partition.

Confirm every details and format the drive. Wait until the process finishes.

Now, you can see that the drive has a protected partition. You can easily lock it down with one click.

Each time you access the drive, you’ll have to enter the passphrase.

Similarly, you can perform the lock any partition present in your system. Make sure to back up all the important data present as the formatting step will make them unavailable.

Voila! Happy encryption!

ONET IDC thành lập vào năm 2012, là công ty chuyên nghiệp tại Việt Nam trong lĩnh vực cung cấp dịch vụ Hosting, VPS, máy chủ vật lý, dịch vụ Firewall Anti DDoS, SSL… Với 10 năm xây dựng và phát triển, ứng dụng nhiều công nghệ hiện đại, ONET IDC đã giúp hàng ngàn khách hàng tin tưởng lựa chọn, mang lại sự ổn định tuyệt đối cho website của khách hàng để thúc đẩy việc kinh doanh đạt được hiệu quả và thành công.
Bài viết liên quan

What is Git?

What is Git? Today most software development projects are collaborative efforts. These projects can have hundreds or thousands...
28/12/2020

Skype for Arch Linux

It’s probably no exaggeration to say that no other application has saved more long-term relationships and helped close...
28/12/2020

Git Rebase Tutorial

Beginners of Git are warned against the rebase command. And rightfully so. With all the new things to learn, beginners are...
28/12/2020
Bài Viết

Bài Viết Mới Cập Nhật

Tìm Hiểu Về Thuê Proxy US – Lợi Ích và Cách Sử Dụng Hiệu Quả
11/12/2024

Mua Proxy V6 Nuôi Facebook Spam Hiệu Quả Tại Onetcomvn
03/06/2024

Hướng dẫn cách sử dụng ProxyDroid để duyệt web ẩn danh
03/06/2024

Mua proxy Onet uy tín tại Onet.com.vn
03/06/2024

Thuê mua IPv4 giá rẻ, tốc độ nhanh, uy tín #1
28/05/2024