On Thu, 16 Oct 2003, ed tharp wrote:

> is it possible to make a symlink (ln -s) across filesystems? can I make
> a link to a folder on a vfat partition (or CDrom for that matter) that
> will show up in my /var?

Yes. In fact, any link you make across a partition boundary *must*, by
definition, be a symlink, as this is not possible with hardlinks.

Bear in mind that permissions on symlinks are not honored, and both
permissions and ownership of all data on vfat patitions is set at mount
time (and then applies to the entire partition). The practical upshot of
this is that if your vfat partition is mounted as user and group "ed", and
you make a link called /var/ftp/pub/ that points to a subdir located
somewhere on that vfat partition, don't expect that merely changing the
ownership of the symlink to "ftp:ftp" will allow your ftp daemon to follow
the link and to access the data (without your username and password having
been used); the permissions on the partition itself will determine this
(i.e., whether or not the entire partition is mounted world-readable).

If giving such a daemon access to some portion of the partition is your
goal (I'm just guessing that it may be, based on your mention of /var),
and there is other data elsewhere on there that you'd prefer to not be
world-readable by any and all local users on the system, you might want to
consider editing your fstab to mount it with your "ed" UID, the GID for
the group that the daemon runs as ("ftp" for ftp, "apache" for http), and
a umask of 27 (allows full r/w access to you, r/o access for the daemon -
which you'd restrict to a certain top-level dir, presumably the link in
/var, by an entry in its config file - and no access at all to others).

Also , one nice thing about symlinks is that their targets need not exist, 
which can be handy when linking to files or dirs on removable media. :)

HTH!

-- 
Bill Mullen   [EMAIL PROTECTED]   MA, USA   RLU #270075   MDK 8.1 & 9.0
The engineer is neither optimist nor pessimist. He sees the proverbial
half-full/empty glass and says, "The glass is twice as big as there is
any need for it to be."

Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to