mvdir: where is it, how can I get it?

John B. Milton jbm at uncle.UUCP
Sat Sep 17 15:33:51 AEST 1988


In article <15911 at shemp.CS.UCLA.EDU> cc1 at CS.UCLA.EDU (Michael Gersten) writes:
...
>***** mvdir was NOT included on the 3b1 *****
>Why not? WHere can I get it?
>Now, its not the absolute end of the world. I can put in ~/bin the
>following little thing
>
>main(argc,argv) char **argv;
>{
>	link (argv[1], argv[2]);
>	unlink (argv[1]);
>}
>
>, add some checks, and make it 6777, owned by root, in a directory only

6777, now really!

You need to think about the . and .. entries. You need to think about
what happens to ANY process using any of the involved directories (open or
as PWD). It is not as trivial as it sounds. SYSV DOES NOT LIKE to have .
and .. out of whack ever. It may work for you and crash another system.

The safe way to move a directory tree in SYSV is to use:
find . -print|cpio -p dir
read up on the -p to get the flavor right



John

-- 
John Bly Milton IV, jbm at uncle.UUCP, n8emr!uncle!jbm at osu-cis.cis.ohio-state.edu
home: (614) 294-4823, work: (614) 459-7641; CP/M to MP/M, MS-DOS to OS/2



More information about the Comp.sys.att mailing list