Fixed mv issue by using rsync, added clean-up function
changed apache restart to graceful; set chown command to go one more level down to make it compatible with existing sftp chrooting