Tell me more ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I know there are similar questions but I get some specific problem I can't overcome.

I have:

  • HDD split into two partitions. /dev/sdb1 and /dev/sdb2. sdb1 is NTFS and I don't need it. I need sdb2 which is fat32.
  • Ubuntu 12.04.1 LTS (server)

I want:

Ultimately I need a perma-mount /dev/sdb2 to /home/storage with access right (rw) for the user media.

Problems I'm facing:

1) Using manual mount from command line.

If I just use

server# sudo mount /dev/sdb2 /home/storage

It mounts but the /home/storage receives root as owner and group and doesn't allow media user to write there.

If i use mount command without sudo as the user media - i'm not allowed. Says only root can use mount.

If I use mount with options: server# sudo mount /dev/sdb2 /home/storage -o umask=000 I get what I need. A bit overdone of course, since the storage folder becomes writable for everyone. BUT - that is manually mounted - now i need it to remount on every reboot.

2) Remounting on reboot - using fstab

So I thought I'll be fine if I use fstab to mount this partition (/dev/sdb2) every time i reboot. The fstab line I added:

UUID=8C52-C1CD /home/storage auto user,umask=000,utf8,noauto 0 0

got uuid with blkid. The fs type auto i changed few times...tried vfat too, but always on the reboot ubuntu stops when processing fstab (as i think) with the message (took from the log):

fsck from util-linux 2.20.1 /dev/sda5: clean, 120559/10969088 files, 19960144/43861504 blocks mount: unknown filesystem type 'static' mountall: mount /etc/fstab: [772] terminated with status 32 mountall: Filesystem could not be mounted: /etc/fstab: Skipping /etc/fstab: at user request

And also - sudo mount -a never really does anything.

What am I doing wrong? I do suspect I messed up something:)

UPDATE:

As it seems - fstab should hold only mounts for static drives, not any sort of usb stuff. I'm puzzled how then this works with all the people posting on the net their success stories...

however..if this is not possible - i would like to know how to remount my usb after every reboot...if not with fstab - than how?:)

share|improve this question
I think you should post all of fstab for review, and not just one line. As for the right permissions, run id media and use uid= and gid= and umask=027options. – mikewhatever Feb 4 at 15:35
Is there some reason you need to use FAT ? If not, I would back up the data and use a linux native file system. You can then set ownership and permissions. – bodhi.zazen Feb 4 at 18:27
@mikewhatever thanks but it's working strangely actually... well..not really:) – Yura Antonov Feb 4 at 22:28
@bodhi.zazen did more reading... seams like on ubuntu 12 fstab should have only mounts for static drives. not any usb... – Yura Antonov Feb 4 at 22:29

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.