Second day on this, so I'm definitely doing something wrong.

Can mount a spare drive to user's home subdirectory mount point, with correct permissions for user to use it. Doing that with just simple mount [device] [mountpoint] Device is ext4 logical volume, which fscks clean.

If I tell automount/autofs do it, it's not usable at all. The subdirectory is created, but owned and only accessible by root. The automount itself fails with:

...wrong fs type, bad option, bad superblock on /dev/xvdi, missing codepage or helper program, or other error. mount(ext2): failed to mount /dev/xvdi (type ext4) on....

The current automap options I'm using are:

-fstype=auto,defaults,noatime,nodev,nosuid,uid=1000,gid=1000,file_mode=0660,dir_mode=0770 :/dev/xvdi

I've tried many - fstype=ext4, ext2, with an without ids and modes, and without any options.

I'm also using udev rules, because this drive is not always connected:

KERNEL="xvdi", OWNER="user", GROUP="user", MODE="0770"

Does anyone have something similar working? Is there something easier than autofs, which is not systemd based?

1 Answer 1


You can use --fstype=autofs instead of filesystem format. Please check the following example for your information:

-fstype=auto,defaults,noatime,gid=100,uid=1000,nls=utf8 :/dev/sdax
  • Thanks. Same error so far.
    – bigsy
    Dec 9, 2019 at 6:09
  • @bigsy Did you check through the format filesystem ? Dec 9, 2019 at 6:23
  • Not sure what you mean by format filesystem. The drive mounts with mount command, and fsck says it's clean. Only automount can't figure it out.
    – bigsy
    Dec 9, 2019 at 6:53
  • @bigsy Could you please provide df -h output ? Dec 9, 2019 at 8:10
  • @bigsy, Please mention the driver name like xvdi1 into autofs file. Dec 9, 2019 at 10:22

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.