chroot_dir set in two different places?
It was confusing earlier chroot functions and chroot.sh functions
about where the chroot was located