Limitations of cp and mv?

john.urban urban at cbnewsl.att.com
Fri May 17 22:54:35 AEST 1991


In article <2570004 at hpcc01.HP.COM> maryhc at hpcc01.HP.COM (Mary Hsia-Coron) writes:
>
>I read in the AT&T System V release 4 manual pages that:
>
>    - cp and mv cannot transfer DIRECTORIES across
>      different file systems.
>
>I'm writing some documentation and cannot verify this limitation
>of cp and mv on a wide range of UNIX systems.
>
>Questions:
>----------
>
>2) Does this limitation exist on System V systems PRIOR to release 4?
	Yes
>
>3) Does this limitation exist on your system? Please include info on:
>    * What flavor of UNIX you have (ULTRIX, SUN, ZENIX, HP-UX, etc.)
>    * Whether your UNIX system is based on AT&T system V, BSD 4.3, or a hybrid.

	Yes.  I'm running AT&T UNIX System V/x86 Release 4.0 Version 2.1

mv(1) has changed between 3.2 and 4.0.   Prior to 4.0, you could not even
mv directories within a filesystem!  This is why the mvdir(1M) command existed
prior to 4.0.  Now in 4.0 you can mv directories around on the same filesystem
but you still cannot move them across filesystem.

i.e:
$ mount
/ on /dev/root read/write/setuid on Tue May  7 15:31:27 1991
/home on /dev/dsk/0s4 setuid/read/write/noquota on Tue  7 15:35:49 1991
$ mkdir /tmp/T
$ cp /etc/passwd /tmp/T/P
$ pwd
/home/install
$ mv /tmp/T /home/install
mv: can't mv directories across file systems
$ mv /tmp/T /tmp/apples
$

Sincerely,

John Ben Urban



More information about the Comp.unix.questions mailing list