On Tue, Dec 31, 2013 at 09:06:38AM -0700, Joseph wrote:
> 
> Thank you for the hints, here is the output of: tail -f /var/log/messages
> My line if fstab is: 
> /dev/sdb1             /media/stick    auto            noauto,rw,user
> and this USB below file are mounted as root:root (not joseph:users)
> 
> Dec 31 09:02:16 syscon7 kernel: [231771.029376] usb 8-1: new high-speed USB 
> device number 33 using xhci_hcd
> Dec 31 09:02:16 syscon7 kernel: [231771.042189] usb 8-1: default language 
> 0x0409
> Dec 31 09:02:16 syscon7 kernel: [231771.043442] usb 8-1: udev 33, busnum 8, 
> minor = 928
> Dec 31 09:02:16 syscon7 kernel: [231771.043445] usb 8-1: New USB device 
> found, idVendor=058f, idProduct=6366
> Dec 31 09:02:16 syscon7 kernel: [231771.043447] usb 8-1: New USB device 
> strings: Mfr=1, Product=2, SerialNumber=3
> Dec 31 09:02:16 syscon7 kernel: [231771.043448] usb 8-1: Product: Mass 
> Storage Device
> Dec 31 09:02:16 syscon7 kernel: [231771.043450] usb 8-1: Manufacturer: Generic
> Dec 31 09:02:16 syscon7 kernel: [231771.043451] usb 8-1: SerialNumber: 
> 058F63666433
> Dec 31 09:02:16 syscon7 kernel: [231771.043515] usb 8-1: usb_probe_device
> Dec 31 09:02:16 syscon7 kernel: [231771.043517] usb 8-1: configuration #1 
> chosen from 1 choice
> Dec 31 09:02:16 syscon7 kernel: [231771.043614] usb 8-1: Successful Endpoint 
> Configure command
> Dec 31 09:02:16 syscon7 kernel: [231771.043689] usb 8-1: adding 8-1:1.0 
> (config #1, interface 0)
> Dec 31 09:02:16 syscon7 kernel: [231771.043722] usb-storage 8-1:1.0: 
> usb_probe_interface
> Dec 31 09:02:16 syscon7 kernel: [231771.043726] usb-storage 8-1:1.0: 
> usb_probe_interface - got id
> Dec 31 09:02:16 syscon7 kernel: [231771.043728] usb-storage 8-1:1.0: USB Mass 
> Storage device detected
> Dec 31 09:02:16 syscon7 kernel: [231771.043787] scsi41 : usb-storage 8-1:1.0
> Dec 31 09:02:17 syscon7 kernel: [231772.175846] scsi 41:0:0:0: Direct-Access  
>    Multiple Card  Reader     1.00 PQ: 0 ANSI: 0
> Dec 31 09:02:17 syscon7 kernel: [231772.176055] sd 41:0:0:0: Attached scsi 
> generic sg2 type 0
> Dec 31 09:02:18 syscon7 kernel: [231772.836523] sd 41:0:0:0: [sdb] 62333952 
> 512-byte logical blocks: (31.9 GB/29.7 GiB)
> Dec 31 09:02:18 syscon7 kernel: [231772.836932] sd 41:0:0:0: [sdb] Write 
> Protect is off
> Dec 31 09:02:18 syscon7 kernel: [231772.836934] sd 41:0:0:0: [sdb] Mode 
> Sense: 03 00 00 00
> Dec 31 09:02:18 syscon7 kernel: [231772.837316] sd 41:0:0:0: [sdb] No Caching 
> mode page present
> Dec 31 09:02:18 syscon7 kernel: [231772.837318] sd 41:0:0:0: [sdb] Assuming 
> drive cache: write through
> Dec 31 09:02:18 syscon7 kernel: [231772.838812] sd 41:0:0:0: [sdb] No Caching 
> mode page present
> Dec 31 09:02:18 syscon7 kernel: [231772.838815] sd 41:0:0:0: [sdb] Assuming 
> drive cache: write through
> Dec 31 09:02:18 syscon7 kernel: [231772.846512]  sdb: sdb1
> Dec 31 09:02:18 syscon7 kernel: [231772.848062] sd 41:0:0:0: [sdb] No Caching 
> mode page present
> Dec 31 09:02:18 syscon7 kernel: [231772.848065] sd 41:0:0:0: [sdb] Assuming 
> drive cache: write through
> Dec 31 09:02:18 syscon7 kernel: [231772.848067] sd 41:0:0:0: [sdb] Attached 
> SCSI removable disk
> Dec 31 09:02:25 syscon7 udisksd[3624]: Mounted /dev/sdb1 (system) at 
> /media/stick on behalf of uid 1000
> 
> -- 
> Joseph

The blkid output would have shown this device, it's UUID, and filesystem.

At any rate, for my flash drives I want them mounted with perms for rw for
user mingdao, so I put something like this in /etc/fstab:

baruch ~ # blkid /dev/sdc1
/dev/sdc1: LABEL="AMD" UUID="CA00-9136" TYPE="vfat" 
baruch ~ # grep CA00-9136 /etc/fstab
UUID=CA00-9136                                  /AMD    vfat    
noauto,users,rw,gid=1000,dmask=0002,fmask=0113  0 0

Different for NTFS, of course. And btw, I don't automount anything anything
that is plugged in. Just my preference.

As Alan mentioned, "man mount" would be a good read; as well as "man fstab".
And, did I give you a link to an article on file permissions?

The difference between user and users mean simply that with "user" only the
user who mounted the device can unmount it; with "users" any user can unmount
it, not just the user who mounted it.

Cheers,
Bruce
-- 
List replies preferred.

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?

Don't top-post: http://en.wikipedia.org/wiki/Top_post#Top-posting

Reply via email to