[plt-scheme] Cross device link?

From: Paulo J. Matos (pocm at soton.ac.uk)
Date: Thu Mar 8 16:12:10 EST 2007

On 3/8/07, Eli Barzilay <eli at barzilay.org> wrote:
> On Mar  8, Richard Cobbe wrote:
> >
> > I tried it on my desktop and discovered that the error is coming
> > from the rename system call (q.v.).  This is consistent with the
> > documented behavior of rename: src and destination must be in the
> > same filesystem.
> Right -- and the reason `mv' works is that it's doing something
> different when the destination is on a different filesystem.  You can
> try using `mv' on a big file or directory and see that it's never
> taking any time on a local move vs moving to a different FS.  You can
> also try to use `mv -v' and see that after a move to a different FS it
> says that the original file is removed.

You're right. :-) I had already wondered about the internals of mv but
never got the chance to get into it.

> In other words -- to get the `mv' behavior you'll need to catch this
> error and use copy+delete instead.

Yes, I'll be doing that! :-)

Paulo Matos

> --
>           ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
>                   http://www.barzilay.org/                 Maze is Life!
> _________________________________________________
>   For list-related administrative tasks:
>   http://list.cs.brown.edu/mailman/listinfo/plt-scheme

Paulo Jorge Matos - pocm at soton.ac.uk
PhD Student @ ECS
University of Southampton, UK

Posted on the users mailing list.