On Wed, 10 Jul 2002, Peter Rundle wrote: > Sluggers, > > I've been asked to look at an "unreliable" sendmail system. > > One thing that I have seen is that the mailboxes in /var/spool/mail > are replaced by symbolic links to another directory on a different > partition. Ok so a bit different but nothing really weird, maybe they > need the space, but what is weird is the link points to for example > > /var/spool/mail/mymail --> /home/sites/site34/../../spool/mail/mymail > > Does anyone have any idea why the ../../ in the symbolic link. > Is this some cleverness that I haven't seen before, as the link is > in effect /home/spool/mail/mymail. Would this have any effect, I can't > think of any.
This monstrosity usually works as expected, and is usually a symptom of some very script to generate those links being run in /home/sites/site34. HOWEVER: there are a few circumstances where this does not do what you expect, although I assume it does not apply in this case... If any of the back-referenced directories is a symbolic link, those back-references will sometimes be used against the destination of those links, rather than the links themselves. An abbreviated example from the junk in my own home directory: -------------------------------------------------------------------- ~/projects/work: -rw-r--r-- dn_wd.csv -rw-r--r-- dn_we.csv lrwxrwxrwx inner_west -> ~/projects/timetables-new/2002/inner_west/ lrwxrwxrwx north -> ~/projects/timetables-new/2002/north/ lrwxrwxrwx north_shore -> ~/pojects/timetables-new/2002/north_shore/ -------------------------------------------------------------------- ~/projects/timetables-new/2002: -rw-r--r-- CityRailLogoSml.gif drwxr-xr-x hunter/ drwxr-xr-x inner_west/ drwxr-xr-x newcastle/ drwxr-xr-x north/ drwxr-xr-x north_shore/ -------------------------------------------------------------------- ~$ cd projects/work ~/projects/work$ ls -l inner_west/.. -rw-r--r-- CityRailLogoSml.gif drwxr-xr-x hunter/ drwxr-xr-x inner_west/ drwxr-xr-x newcastle/ drwxr-xr-x north/ drwxr-xr-x north_shore/ ~/projects/work$ _ As you can see, that's not my current directory, as you might've expected... I _hope_ this isn't afflicting you. linked directories are thankfully not commonly used, and usually only in places where full paths are the norm. -- Jessica Mayo. (Everything with a Grin :) -- SLUG - Sydney Linux User's Group - http://slug.org.au/ More Info: http://lists.slug.org.au/listinfo/slug
