Share a file system mounted in /etc/fstab
Hi Friends. I mount a file system in /etc/fstab on boot so it's available when the machine is turned on. I'd like to share a directory within the FS but am finding I can't change the permissions of the file system or any of its subdirectories. Is there a flag or option I can add to the fstab line to make myself the owner of the directory? Or how can I share a directory in this file system on my local network?
The line I have in /etc/fstab is :
UUID=(the UUID) /media/NTFSTB ntfs relatime,errors=remount-ro 0 1
Thanks.
Oh maybe if I don't mount it to /media ... I'll try mounting to one of my own directories.
19:24: Tried it, and I'm still "not the owner so I can't change the permissions"
If you right click the directory and select Sharing Options, you can share it that way.
Thanks akirashinigami, but because root is the owner of the file system I can't change the permissions. I also can't change the permissions or owner when I am root.
Got it. Edited /etc/samba/smb.conf and added the line "usershare owner only = false" . Now I can share the directory.
Every (uncommented) line in /etc/fstab relates to a call of the 'mount' command. The fourth column of the file contains the options.
The options to set the permissions depend on on the filesystem that is mounted. Obviously, the file system you mount is of the type NTFS. According to 'man mount', you must use "uid=value" to set the owser, "gid=value" to set the group and "umask=value" (given in octal) to set the actual permissions.
The IDs of the owner and the group can be read in the advanced settings of "System/Administration/Users and groups" or directly in the /etc/passwd and /etc/group files. Are you familiar with the permissions in octal? Like 775 for "owner and group can do anything, whereas other can only read and execute (not write)". If you want to know everything about permissions:
$ info coreutils 'File permissions'
The subsection focusing on the octal numbers for permissions is directly accessible in this way:
$ info coreutils 'Numeric modes'
I am having difficulty pasting files of firmware into /lib/firmware. The 'Paste" is in grey i.e. not possible for me. When I try to drag it into the error is that '...cannot be copied because you do not have permission to create it in the destination'. Properties of this path indicates that I am not the owner, root is, so I have no permission. What can I do? If the above communications were clear then I am the newest of the new-bees here and am still in the dark.
Hi,
You should be able to run nautilus as root and copy into that window
from another. use:
"nagksu nautilus /lib/firmware", in the 'run' dialogue, to open the root
file manager.
-Dave H.
On 06/06/2012 11:20 AM, name at domain wrote:
> I am having difficulty pasting files of firmware into /lib/firmware. The
> 'Paste" is in grey i.e. not possible for me. When I try to drag it into
> the error is that '...cannot be copied because you do not have
> permission to create it in the destination'. Properties of this path
> indicates that I am not the owner, root is, so I have no permission.
> What can I do? If the above communications were clear then I am the
> newest of the new-bees here and am still in the dark.
The indications above have nothing to do with your problem. You are talking about an administration task. It *must* be done as root. In other words, it is perfectly normal that the system does not let you do that without entering your password and you do not want to change permissions so that it becomes possible.
Although you can indeed run a graphical file browser as root, it is not a good advice to do so (any security bug in the graphical application run by root let the attacker do anything to your system, like installing a rootkit). You want to copy the file from a terminal using sudo:
$ sudo cp PATH_TO_FIRMWARE /lib/firmware
Many thanks - that was swift as Trisquel..
I am very lost then - what is the run dialogue?
When you press 'alt+f2', you get a text entry box where you can enter a
single command line, for instance, the name of a program and its options.
HTH,
Dave H.
On 06/06/2012 11:48 AM, name at domain wrote:
> Many thanks - that was swift as Trisquel..
> I am very lost then - what is the run dialogue?
>