I want to check out Nitrux, which can be "deployed" using znx (how-to here).

znx does not seem to open correctly in Fedora, so I would like to deploy it using the terminal. The how-to says that I should install it on a partition with at least 4 GB.

I have one big free partition on my computer, about 200 GB. Do you know if Nitrux will use the entire partition if I deploy it on that partition? Or will znx assign 4 GB of that partition and let me use the rest?

  • 1
    If you give a -1, please also give an answer Dec 9 '18 at 22:46

No, the entire partition will not be used by Nitrux:

The first thing you have to do in order to use znx is to initialize the device. znx will wipe the device and create a new GPT partition table on it, with two partitions. One of those partitions stores the bootloader data, while the other stores user data (including the images). Those partitions are then formatted with the FAT32 and the BTRFS filesystems respectively. After that, znx creates some directories on both partitions, as well as copying some files to the boot partition. Once those things are done, the device is considered initialized.


Images are stored on the /boot_images directory of the data partition. Inside that directory, a hierarchy of subdirectories that match the name of the image are created. So, when you, for example, deploy your_distro/rolling, a directory /boot_images/your_distro/rolling is created in the data partition. Then, the image is stored in that directory.

The 4G recommendation by Nitrux is not for the partition but for the entire device; This is very important. znx essentially takes over an entire disk, as described in the first quotation above. Maybe you can get it to work with with your 200GB partition, but that's not how the znx documentation describes it.

You can read the nitty-gritty in the znx Wiki.


Note: The information below is exclusively for the ISO images that include or support znx and does not pertain to the ISO files that use a traditional installer such as Calamares.

I want to check out Nitrux, which you can deploy using znx (how to here).

You can go about this in different ways. You can either use the entire disk or reuse an existing root partition (as long as the filesystem is Btrfs). It doesn't matter if the partition is empty or already in use for the latter.

Suppose you decide to use the entire disk. In that case, you can download the ISO, flash it to a USB (don't burn it to optical media), boot the Live USB, and use znx to initialize and deploy the distribution to an internal or external device. The ISO already includes znx.

If you decide to reuse an existing partition, you can check our tutorial "Integrating znx with your existing OS" for detailed steps. In this case, you need to download znx.

However, I'd emphasize that you read the FAQ to understand the distribution goals overall. And for information about znx specifically, you can read these articles on our blog.

Since you already have a distribution installed on your computer, in your case, Fedora, you need to download the znx AppImage file and follow the steps in the integration tutorial.

We distribute znx as an AppImage, so there's no installation involved (i.e., using a package manager). There's also no "installation" involved with Nitrux either (the correct term in this context is deployment; we explain the difference in the FAQ).

To quote the FAQ:

Deploying the operating system in our case means that you are copying the ISO file to the storage device as a single file and enabling persistence on the storage device using OverlayFS instead of extracting its contents and creating the standard directory tree on the storage device; this is why we prefer to say that Nitrux does not do a standard install.

In other words, Nitrux does a frugal installation (the operating system files are stored in just a couple of files in a directory, rather than spread out over a drive partition).

“A frugal installation only occupies one folder in a partition, and the rest of the partition can be used for anything else. Other Linux distributions, for example.” Meanwhile, traditional Linux distributions do a full installation, “A full installation is where Linux occupies an entire partition, and in that partition you will see the folders /bin, /sbin, /opt, /etc/, /sys, /proc, /tmp, /dev, /usr, /run, /lib, and more.”

An installer such as Ubiquity, Calamares (KPM Core), Anaconda, and every other installer [...] extract the contents of the SquashFS file inside the ISO and place the contents on a partition of the storage device.

That is why we don’t refer to znx “installing” an OS; instead, we use the word deploy. Because znx isn’t extracting the SquashFS file from the ISO, it’s booting the ISO directly, and data is preserved on the storage device using OverlayFS.

After downloading the AppImage, you have to make it executable; then, you can execute the AppImage in the Terminal using sudo.

sudo chmod +x znx.AppImage
  • Optionally, you can move it to /usr/bin/ so you don't have to type ./ to execute the AppImage, and you can use it anywhere.
sudo mv znx.AppImage /usr/bin/znx

It's important to understand that znx is a CLI program; it does not have a graphical interface so clicking the AppImage file will not open a window.

  • Once it's made executable, you can use sudo znx --help to display the help.
  • You need to type the commands and arguments for znx with the correct syntax, like the examples in the help show.
Usage: znx [options] <command> [command_args]


  -h, --help        Print this help.
  -v, --version     Print the commit hash that generated this binary.
  -d, --debug       Enable debugging messages.
  -y, --no-confirm  Autoconfirm dangerous operations.


  A block device file name. e.g.: /dev/sdxN, /dev/sdb.

  Must match the regular expression: '^\w+/\w+$'. This means that letters, numbers and underscores
  are allowed on both sides of a slash. No other characters are allowed.

  Can be a URL or a path pointing to an ISO image, or a directory path. The latter may be useful
  for deploying images from within a live session.


  init <device>                          Initialize <device>.
  fix-esp <device>                       Restore the ESP (EFI System Partition) of <device>.
  deploy [-k] <device> <image> <origin>  Deploy <image> on <device> from <origin>.
                                         The '-k' flag serves to bypass SSL certificate checking.
  rename <device> <old_name> <new_name>  Rename image <old_name> to <new_name>.
  update <device> <image>                Update <image>.
  check-update <device> <image>          Check if an update for <image> is available.
  rollback <device> <image>              Revert an update.
  reset <device> <image>                 Delete all user data on <image>.
  clean <device> <image>                 Remove the backup that is created during an update.
  remove <device> <image>                Remove <image> and all associated data from <device>.
  status <device> <image>                Show information about <image>.
  list <device>                          List the deployed images on <device>.

The gist of the integration tutorial is the following.

  • You need to download and extract the znx AppImage.

  • You need to install the package that contains the file /usr/lib/grub/x86_64-efi/btrfs.mod in Fedora that is grub2-efi-x64-modules.

  • You need to create or delete the contents of the directory /boot/efi/boot/grub.

  • You need to copy the file grub.cfg and the directory themes from the AppImage to /boot/efi/boot/grub.

  • You need to rename the directory /boot/efi/EFI/BOOT to /boot/efi/EFI/boot and delete its contents.

  • You need to copy the file bootx64.efi from the AppImage to /boot/efi/EFI/boot.

  • You need to add an EFI boot entry (not a GRUB boot entry) to load the znx boot loader file.

    • Replace /dev/sdx with the device with your ESP partition (e.g. /dev/sdc).
      • efibootmgr -c -d /dev/sdx -p 1 -L "znx" -l "\EFI\boot\bootx64.efi"
  • You need to change the partition labels for the ESP and the root partition. You can do this from the Terminal or using GParted (or similar).

    • Replace /dev/sdxN with your partition (e.g. /dev/sdc1).
      • fatlabel /dev/sdxN ZNX_BOOT
      • btrfs filesystem label /dev/sdxN ZNX_DATA
  • You can deploy an ISO and test the functionality of znx. znx supports both local and remote files, and we will use a remote file.

    • Replace /dev/sdx with the device with your root partition (e.g. /dev/sdc).
    • [deployment_name] can be any combination of alphanumeric characters, i.e., abc/123, ABC/123, 123/ABC, 1A2B/3C4D, etc. Please make sure not to use spaces or hyphens.
sudo znx /dev/sdx [deployment_name] http://updates.nxos.org/nitrux-OTA-latest-amd64.iso

As mentioned in the tutorial, to boot into the ISOs deployed with znx, you have to use the EFI boot menu not the GRUB menu. It's essential to understand the difference.

On the other hand, follow the steps below to use the entire disk.

  • Whether you choose to flash the ISO to a USB or run znx from another distribution (installed or not) and want to use another disk, the steps are the same.

First, you initialize the device. This will wipe the device as znx will create a new partition table and partitions. The syntax of the command for this task, in this case, is znx [command] [path_to_target_device].

  • Replace /dev/sdx with the device (e.g. /dev/sda).
    • Note: SATA and USB storage devices are named /dev/sdx, and NVME devices are named /dev/nvmeXnY, where X is the port and Y is the device.
sudo znx init /dev/sdx

Then, proceed to deploy Nitrux. The syntax of the command for this task, in this case, is znx [command] [path_to_target_device] [deployment_name] [path_to_file]. znx supports both local and remote files. We will use a remote file.

  • [deployment_name] can be any combination of alphanumeric characters, i.e., abc/123, ABC/123, 123/ABC, 1A2B/3C4D, etc. Please make sure not to use spaces or hyphens.
sudo znx deploy /dev/sdx nitrux/release http://updates.nxos.org/nitrux-OTA-latest-amd64.iso

And that's it. Reboot and select the drive to boot into Nitrux.

  • One of the features of znx is that you can deploy multiple operating systems at once without the need to create multiple partitions. - given that the installation procedure involves a command (sudo ./znx init /dev/sdx) that will wipe out the device sdx, how will the second OS be installed next to the first on the same device? can Nitrux be installed along a preexisting OS on the same device sdx? Am I expected to simply wipe out all my data in order to install Nitrux Linux?
    – cipricus
    Mar 13 '19 at 18:31
  • With znx, you only need two partitions: in other Linux I need only one; and can I keep my old partition (60% of my drive, with no OS on it, meant to stay accessible from both Linux and Windows) that I don't want touched by newly installed OSes?
    – cipricus
    Mar 13 '19 at 18:41
  • @cipricus There's plenty of information about znx, and how it works. Given that this is a Q&A website you could, instead, ask a question where we can provide you with a full-length answer. Mar 14 '19 at 7:48
  • @MXMLLN I've updated the answer. Feb 26 '21 at 22:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.