Install Mageia 1 on an encrypted btrfs file system

Mageia is a new Linux distribution forked from Mandriva. The first release was just last month and it has since been reviewed on this website. (See Mageia 1 review.) Btrfs is a relatively new file system in the Linux kernel, It is a copy-on-write file system with built-in support for, amongst other features, subvolumes (the same functionality provided by LVM, the Linux Logical volume Manager), filesystem-based RAID 0, 1 and 10, online resizing and several other enterprise-grade features.

It is still under heavy development, and not yet recommended for use in a production environment. The man page for btrfs utilities specifically warns that it “… is currently under heavy development, and not suitable for uses other than for benchmarking and review.” It is, however, the default file system on MeeGo, and is slated to be the default on Fedora 16. What that points to is it will also be the default on other Linux distributions before very long. This then is a good time, if your favorite distribution supports it, to start getting used to it.

This tutorial offers the simple steps needed to install Mageia 1 on an encrypted btrfs file system. You do not have to encrypt it, but disk encryption is one of several methods that you may use to boost the physical security profile of your computer.

To start, download an installation image of Mageia from here. You may download any image, Live, Network-install, or a DVD image. Boot the system from the CD or DVD you made from the downloaded image and click until you get to the disk partitioning step. This is a standalone installation, but it is possible to install a btrfs-based Mageia alongside another distribution or operating system in dual-boot fashion.

The images used in this tutorial were taken from an installation in a virtual environment. The first step is to delete existing partitions, so unless your disk is a brand new one, select each partition and click Delete.
Mageia Btrfs

Now that we have a “clean” disk, time to start creating partitions. Before you start, click Toggle to expert mode. Btrfs is not an option in normal mode, so you need to be in expert mode to be able to complete this tutorial. Once in expert mode, select the disk, then click Create.

Note: When setting up a btrfs-based system, three partitions are recommended. These are for /boot, Swap, and /, the btrfs root.
Mageia Btrfs 1

For the boot partition, a size of 500 MB should be more than enough and the mount point should, of course, be /boot. In this example, I set the file system type to btrfs, but you do not have to use btrfs for /boot. So you may want to ignore my choice here and select Linux native (ext2). If this is the first partition on the disk, the installer will create it as a primary partition, even if you do not specify it here. OK.
Mageia Btrfs 2

With the boot partition created, select the free space and click Create.
Mageia Btrfs 3

The second partition will be for Swap, disk space that the system may use as virtual memory. 2 GB is usually enough for Swap. Set the “Preference” to “Primary” and set the “Filesystem type” to “Linux swap.” For added security, encrypt this partition. OK.
Mageia Btrfs 6

There should be no reason to check for bad blocks, so click OK. If you are curious, it wont hurt to check. Note that this step and the next one will be repeated when you configure the last partition.
Mageia Btrfs 5

The right choice here is OK.
Mageia Btrfs 7

The third and last partition will be for the btrfs root. If Mageia is the only distribution or operating system you are going to install on the disk, assign all available disk space to it. To prevent the installer from creating this as a logical partition, set the “Preference” to “Primary.” Enable encryption and specify and confirm an encryption passphrase. OK.
Mageia Btrfs 8

Partitioning is completed. Click Done to continue with the rest of the installation.
Mageia Btrfs 9

The partitions sans Swap will need to be formatted. Next. Complete the installation and when you reboot, the passphrase you specified for the root partition will be needed to boot into the system. Note that if you wish to add another layer of physical security to the system, you can password-protect the boot loader. The step to do that, if you are installing from a DVD or Network-Install image, is at the Summary step, just before your settings are written to disk.
Mageia Btrfs 10

You can have quality articles like this delivered automatically to your Feed Reader or Inbox by subscribing via RSS or email. This website now has a Question and Answer section. Use the commenting system for simple comments, but for more involved assistance, please use the Question & Answers section.

Related Posts

How to customize Mandriva 2011 Mandriva 2011, the latest desktop edition of the popular Linux distribution, was released yesterday. If you have just installed it, you would have not...
Install NetworkManager on Hymera Open The network manager application that comes pre-installed on Hymera Open, a Debian-based, desktop-oriented GNU/Linux operating system, is Wicd. While ...
Windows 7 disk partitioning annoyance Today I made an attempt to dual-boot Windows 7 and BackTrack 5 R3 on a single hard disk drive (HDD), but on a computer with two internal HDDs. From th...
Triple-boot Windows 7, Ubuntu 12.10 and Fedora 18 on one HDD To Triple-boot Windows 7, Ubuntu 12.10 and Fedora 18 on a single hard disk drive (HDD) presents a different set of challenges than dual-booting any tw...
The Benefits of Microcaching with NGINX NGINX and NGINX Plus are commonly used as web content caches, ranging from individual websites to some of the largest content delivery networks (CDNs)...
How to enable the btrfs Anaconda option on Fedora 13 Fedora 13 is one of a handful of Linux distributions with support for btrfs, the B-tree File System, one of the newest file systems in the Linux kerne...

We Recommend These Vendors and Free Offers

ContainerizeThis 2016 is a free, 2-day conference for all things containers and big data. Featured, will be presentations and free, hands-on workshops. Learn more at

Launch an SSD VPS in Europe, USA, Asia & Australia on Vultr's KVM-based Cloud platform starting at $5:00/month (15 GB SSD, 768 MB of RAM).

Deploy an SSD Cloud server in 55 seconds on DigitalOcean. Built for developers and starting at $5:00/month (20 GB SSD, 512 MB of RAM).

Want to become an expert ethical hacker and penetration tester? Request your free video training course of Online Penetration Testing and Ethical Hacking

Whether you're new to Linux or are a Linux guru, you can learn a lot more about the Linux kernel by requesting your free ebook of Linux Kernel In A Nutshell.


  1. Pingback: Install Mageia on encrypted btfs « 0ddn1x: tricks with *nix

  2. Pingback: Links 23/6/2011: Red Hat’s Record Financial Performance, Scientific Linux 5.6 is Out | Techrights

Leave a Comment

Your email address will not be published. Required fields are marked *