I think what was intended was
ln -s foo bar
mv bar bar
and see what happens, bar will seem to disappear when it was really moved to
mv follows / resolves the link before executing - proper order :o)
Business Systems Development
Merrill Lynch Capital Markets Bank, Treasury Building, Lower Grand Canal
St., Dublin 2
Tel: + 353 (0)1 6058532
> -----Original Message-----
> From: Mike Knell [SMTP:mike.knell at cs.tcd.ie]
> Sent: Friday, June 11, 1999 3:00 PM
> To: ilug at linux.ie> Subject: Re: [ILUG] bug in mv and/or ln
>>>> > Try this in Linux:
> > create a soft link to a directory,
> > ln -s directory link
> > now, do the following:
> > mv directory directory
> > Watch what happens. The "directory" link disappears. A bug?
>> What exactly do you mean here?
>> If you rename a directory, any symbolic links (as opposed to hard links)
> to it will, I believe, be broken, but the links will remain there
> pointing to the old name.
>> I've tried replicating the above, but haven't noticed any vanishing
> links - just symlinks with nothing left to point at, poor things.
>> For clarity, I tried
>> mkdir foo
> ln -s foo bar
> mv foo baz
>> and ended up with
>> lrwxrwxrwx 1 mknell mknell 3 Jun 11 14:59 bar -> foo
> drwxr-xr-x 2 mknell mknell 1024 Jun 11 14:59 baz
>> which is correct behaviour.
> Computer Science System Administrator, Trinity College, Dublin, Ireland
>mike.knell at cs.tcd.ie -=- http://www.cs.tcd.ie/Mike.Knell/>> --
> Irish Linux Users' Group: ilug at linux.ie>http://www.linux.ie/mailman/listinfo/ilug for (un)subscription
> List maintainer: listmaster at linux.ie
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!