While following this guide to installing Arch Linux the reader is instructed to execute the following command:

genfstab -U -p /mnt >> /mnt/etc/fstab

It is stated the the -U option uses UUID's over labels, but what does the -p option do? I have Googled it and can only find a page on fstab itself, not its generator. Arch includes no manpage on the subject... if anyone knows where docs on genfstab are, can they please provide a link? If not, can someone tell me what the options are or what the options do (primarily the -p switch)?

  • 2
    genfstab --help – strugee Apr 14 '14 at 17:51

As stated in the "usage" section, -p will skip pseudo-FS mounts (tmpfs, AutoFS and others):

usage: genfstab [options] root

 -L       Use labels for source identifiers (shortcut for -t LABEL)
 -p       Avoid printing pseudofs mounts (default behavior)
 -t TAG      Use TAG for source identifiers
 -U       Use UUIDs for source identifiers (shortcut for -t UUID)

 -h       Print this help message

genfstab generates output suitable for addition to an fstab file based on the devices mounted under the mountpoint specified by the given root.

You can check the details in its source code: genfstab.in - arch-install-scripts.git | Official arch-install-scripts repository

  • is that a man page? is the problem simply that arch doesnt include the man for this command? or was this obtained from the provided link? – Konner Rasmussen Apr 14 '14 at 17:38
  • 2
    Yes, Arch doesn't provide man-page for genfstab. And you can get this if you run genfstab without parameters or genfstab -h. It's quite common for short scripts to contains full usage explanation (because there is too few options to bother with man). – anlar Apr 14 '14 at 17:43

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.