sudo mkdir -p /mnt/runimg pi@raspberry4:~ $ sudo mount --bind /media/netdir/raspbrreyPi/mnt_runimg /mnt/runimg pi@raspberry4:~ $ ls -l /mnt/runimg/ total 55043072 -rwxrwxrwx+ 1 99 99 4555014144 Jan 7 22:32 2019-04-08-raspbian-stretch_chroot.img -rwxrwxrwx+ 1 systemd-timesync 98 3481272320 Mar 23 22:09 2019-04-08-raspbian-stretch-make-new.img -rwxrwxrwx+ 1 root root 3481272320 Dec 30 09:55 2019-04-08-raspbian-stretch-make-old.img -rwx------+ 1 99 99 3829399552 Jan 26 21:38 2019-09-26-raspbian-buster_jin.img -rw-r--r--+ 1 root root 5934940160 Apr 13 22:23 2020-02-13-raspbian-buster_jin-make.img -rw-rw-rw-+ 1 root root 31180455936 Apr 13 23:19 aarch64.img drwxrwxrwx+ 1 root root 160 Dec 19 22:41 bak -rw-rw-rw-+ 1 99 99 1728053248 Mar 25 22:50 readynas_compile_tool2.img -rw-rw-rw-+ 1 99 99 2173698048 Jan 8 23:25 readynas_compile_tool.img pi@raspberry4:~ $ sudo mkdir -p ~/rpi_mnt pi@raspberry4:~ $ sudo losetup -f -P --show /mnt/runimg/aarch64.img /dev/loop0 pi@raspberry4:~ $ sudo mount /dev/loop0p2 -o rw ~/rpi_mnt pi@raspberry4:~ $ cd ~/rpi_mnt pi@raspberry4:~/rpi_mnt $ sudo mount /dev/loop0p1 -o rw ~/rpi_mnt/boot/ pi@raspberry4:~/rpi_mnt $ sudo mount --bind /dev ~/rpi_mnt/dev/ pi@raspberry4:~/rpi_mnt $ sudo mount --bind /sys ~/rpi_mnt/sys/ pi@raspberry4:~/rpi_mnt $ sudo mount --bind /proc ~/rpi_mnt/proc/ pi@raspberry4:~/rpi_mnt $ sudo mount --bind /dev/pts ~/rpi_mnt/dev/pts pi@raspberry4:~/rpi_mnt $ sudo mkdir -p /media/netdir/source/raspberrypi/4-08_new_raspi pi@raspberry4:~/rpi_mnt $ sudo mkdir -p ~/rpi_mnt/mnt/compile pi@raspberry4:~/rpi_mnt $ sudo mount --bind /media/netdir/source/raspberrypi/4-08_new_raspi ~/rpi_mnt/mnt/compile pi@raspberry4:~/rpi_mnt $ cd ~/rpi_mnt pi@raspberry4:~/rpi_mnt $ sudo chroot . bin/bash root@raspberry4:/# root@raspberry4:/# ls -l total 92 drwxr-xr-x 2 root root 4096 Feb 14 01:00 bin drwxr-xr-x 3 root root 3584 Jan 1 1970 boot drwxr-xr-x 3 root root 4096 Jan 1 1970 boot.bak drwxr-xr-x 18 root root 4140 Apr 13 23:22 dev drwxr-xr-x 117 root root 12288 Apr 13 21:14 etc drwxr-xr-x 3 root root 4096 Feb 14 00:55 home drwxr-xr-x 17 root root 4096 Apr 13 21:13 lib drwx------ 2 root root 16384 Feb 14 01:15 lost+found drwxr-xr-x 4 root root 4096 Mar 31 00:05 media drwxr-xr-x 6 root root 4096 Mar 30 23:33 mnt drwxr-xr-x 4 root root 4096 Feb 14 01:01 opt dr-xr-xr-x 198 root root 0 Jan 1 1970 proc drwx------ 6 root root 4096 Apr 13 21:21 root drwxr-xr-x 4 root root 4096 Feb 14 00:51 run drwxr-xr-x 2 root root 4096 Mar 30 23:34 sbin drwxr-xr-x 3 root root 4096 Mar 30 23:32 srv dr-xr-xr-x 12 root root 0 Apr 13 21:56 sys drwxrwxrwx 8 systemd-timesync 98 4096 Mar 31 00:02 tftpboot drwxrwxrwt 7 root root 4096 Apr 13 21:33 tmp drwxr-xr-x 11 root root 4096 Feb 14 01:01 usr drwxr-xr-x 11 root root 4096 Mar 31 00:36 var root@raspberry4:/# echo 00:00:00 00:00:00 root@raspberry4:/# date Mon 13 Apr 2020 11:22:52 PM JST root@raspberry4:/# root@raspberry4:/# root@raspberry4:/# df -hT Filesystem Type Size Used Avail Use% Mounted on /dev/loop0p2 ext4 13G 9.6G 2.4G 81% / /dev/loop0p1 vfat 253M 67M 186M 27% /boot udev devtmpfs 1.8G 0 1.8G 0% /dev nas-27-59-FD:/data/tmp/source/raspberrypi/4-08_new_raspi nfs 5.5T 3.4T 2.1T 62% /mnt/compile root@raspberry4:/# root@raspberry4:/# root@raspberry4:/# root@raspberry4:/# compile finish bash: compile: command not found root@raspberry4:/# exit exit pi@raspberry4:~/rpi_mnt $ cd pi@raspberry4:~ $ sudo umount ~/rpi_mnt/mnt/compile pi@raspberry4:~ $ sudo umount ~/rpi_mnt/dev/pts pi@raspberry4:~ $ sudo umount ~/rpi_mnt/proc pi@raspberry4:~ $ sudo umount ~/rpi_mnt/sys pi@raspberry4:~ $ sudo umount ~/rpi_mnt/dev pi@raspberry4:~ $ sudo umount ~/rpi_mnt/boot pi@raspberry4:~ $ sudo umount ~/rpi_mnt pi@raspberry4:~ $ sudo losetup -d /dev/loop0 pi@raspberry4:~ $