Return to BSD News archive
Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!simtel!daffy!uwvax!uwm.edu!spool.mu.edu!howland.reston.ans.net!news-e1a.megaweb.com!newstf01.news.aol.com!uunet!in1.uu.net!anshar.shadow.net!anshar.shadow.net!nobody From: dwhite@anshar.shadow.net (Don Whiteside) Newsgroups: comp.unix.bsd.freebsd.misc Subject: Re: Moving directories across filesystems Date: 14 Jun 1995 11:07:44 -0400 Organization: Shadow Information Services, Inc. Lines: 23 Message-ID: <3rmu00$f6m@anshar.shadow.net> References: <3r7c0h$qn1@news.bu.edu> <3rhvhr$r2h@si-nic.hrz.uni-siegen.de> NNTP-Posting-Host: anshar.shadow.net X-Newsreader: TIN [version 1.2 PL2] Peter Merz (peter@netz.hrz.uni-siegen.de) wrote: : Mikhail Teterin (mi@cs.bu.edu) wrote: : : I tried to : : : mv /root /usr/home/root : : And it failed (/usr was mounted on another partition). Is this a correct : : behavior now? Files are moved just fine : That's the right behaviour. You cannot move dircetories across filesystems. Looking at mv.c, it indicated that "if the move fails because we're trying to cross devices and it's a regular file, do the copy internally, otherwise use cp and rm." So in a nutshell - if it can't just create another entry pointing to the inode and remove the old one, it will make a copy. Directories... not so much, as Paul Buchman would say. ========================================================================= Donald Alan Whiteside MDCC Wage Slave School of Computer Science Official Usenet Dork for the week of Jan 9-13, 1995 GCS d-- -p+(---) l u+(-) e+ m+ s !n h f g+ w+ t+(++) r- y++ "There's nothing wrong with you I can't fix with my hands..." FM's Batman =========================================================================