I am trying to mount a ext4 fs and keep the ownership to a user with
uid=1001 and it is failing

Here is the mount point

root@splunk:~# ls -ld /opt/splunk
drwxr-xr-x 2 splunk splunk 4096 2011-01-31 11:19 /opt/splunk

I am going to mount /dev/sdc1

root@splunk:~# fdisk -l /dev/sdc

Disk /dev/sdc: 31.0 GB, 30999052288 bytes
255 heads, 63 sectors/track, 3768 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0006456c

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1               1        3768    30266428+  83  Linux


root@splunk:~# mount -o uid=1001 /dev/sdc1 /opt/splunk
mount: wrong fs type, bad option, bad superblock on /dev/sdc1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

[ 5320.532242] EXT4-fs (sdc1): Unrecognized mount option "uid=1001" or
missing value

root@splunk:~# mount -o uid=splunk /dev/sdc1 /opt/splunk
mount: wrong fs type, bad option, bad superblock on /dev/sdc1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

[ 5353.380091] EXT4-fs (sdc1): Unrecognized mount option "uid=1001" or
missing value

mount as root works just fine, but the ownership changes to root

root@splunk:~# mount /dev/sdc1 /opt/splunk
root@splunk:~# ls -ld /opt/splunk
drwxr-xr-x 3 root root 4096 2011-01-31 11:12 /opt/splunk

so the fs is OK.

any idea how to mount it with ownership to a user instead of root

-- 
Asif Iqbal
PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

-- 
ubuntu-server mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
More info: https://wiki.ubuntu.com/ServerTeam

Reply via email to