chroot_setup: replace any busy binary without error
commit1ac1ebc8f8c17dac5843abda119f0cd86ea58670
authorKyle J. McKay <mackyle@gmail.com>
Wed, 17 Sep 2014 02:34:11 +0000 (16 19:34 -0700)
committerKyle J. McKay <mackyle@gmail.com>
Wed, 17 Sep 2014 02:34:11 +0000 (16 19:34 -0700)
treef0ea9fea9d5d5ae4e3230a04b86ebd39769cccc0
parent877b57e868376e292a7e912966096e89a29b93de
chroot_setup: replace any busy binary without error

Attempting to replace an in-use binary with cp can result
in a "text file busy" error.  Avoid this by first copying
the binary to a temporary location in the jail and then
force moving it into place.

This avoids the caller of pull_in_bin needing to do anything
special for binaries that might be in use.
chrootsetup_freebsd.sh
chrootsetup_linux.sh