LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   file permissions on usb drive (https://www.linuxquestions.org/questions/linux-newbie-8/file-permissions-on-usb-drive-395745/)

nodisk 12-22-2005 03:48 PM

file permissions on usb drive
 
i plugged in a usb thumb drive into an ubuntu machine and wrote a test file to it. then i changed permissions for the file so that no one could read, write, or execute it. however, when i unplugged the device and then plugged it in again, the permissions i had set were not there anymore. is there some way to retain permissions on files even when the usb drive has been unplugged? any suggestions on how permissions can be retained on other kinds of devices, such as floppy, zip, cd, etc?

DarkElf109 12-22-2005 04:01 PM

AFAIK, to retain permissions, you'll have to reformat the drive with a file system that supports permissioning. You could also tar the file(s) that you want to retain permissions to, and store the tar.* on the USB drive, but that gets to be more of a hassle.

tuxrules 12-22-2005 04:18 PM

the usb thumb drives mostly come with fat32 filesystem which does not have any concept of permissions. You could just save it as it...I have not tried creating another filesystem on the usb thumb drive. The same goes with tar. Although, you can easily maintain permissions on a CD.

Tux,

DarkElf109 12-22-2005 04:25 PM

Quote:

I have not tried creating another filesystem on the usb thumb drive.
One of the methods of installing DSL on a USB drive is to create a boot partition on the drive itself, using a separate filesystem, so I know it can be done. However, if you use Ext2/3, if you don't have the right system drivers in Windows (I know that there's at least one driver for Ext2), you won't be able to access the drive. I'm not sure about Macs, either. But if you work in a Linux-only environment, I don't see any problems.

nitinatindore 12-26-2005 10:42 PM

You could always create two partitions on the thumb drive, one with FAT & other with ext2/3. Your permissinos will be preserved on ext2/3 file system.


All times are GMT -5. The time now is 07:04 AM.