sed -i "s|^\(eval.\+\)$|#\1|g" /home/pi/vdesktop/vdesktop pi@raspberry48:~ $ sed -i "s|^\(export DISPLAY.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberry48:~ $ sed -i "s|^\(eval.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberry48:~ $ sed -i "s|^\(sleep.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberry48:~ $ sed -i "s|^\(lxpanelctl.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberry48:~ $ ls -l /media/netdir/source/raspberrypi total 0 drwxrwxrwx+ 1 systemd-network users 18 Dec 6 19:53 3 drwxrwxrwx+ 1 99 99 18 Feb 9 21:53 4-01_rasp drwxrwxrwx+ 1 99 99 18 Feb 10 18:45 4-02_readynas drwxrwxrwx+ 1 root root 18 Mar 4 20:08 4-04_docker_readynas drwxrwxrwx+ 1 root root 18 Mar 4 21:58 4-05_chroot_readynas drwxrwxrwx+ 1 99 99 18 Dec 6 19:46 org pi@raspberry48:~ $ mkdir -p /media/netdir/source/raspberrypi/4-05_chroot_readynas pi@raspberry48:~ $ inset_line=`grep -n systemd-nspawn /home/pi/vdesktop/vdesktop | tail -1 | cut -f 1 -d:` pi@raspberry48:~ $ let inset_line2=inset_line+1 pi@raspberry48:~ $ sed -i "${inset_line2}iumount \${mntpnt}/mnt/compile" /home/pi/vdesktop/vdesktop pi@raspberry48:~ $ sed -i "${inset_line}imount --bind /media/netdir/source/raspberrypi/4-05_chroot_readynas \${mntpnt}/mnt/compile" /home/pi/vdesktop/vdesktop pi@raspberry48:~ $ sed -i "${inset_line}imkdir -p \${mntpnt}/mnt/compile" /home/pi/vdesktop/vdesktop pi@raspberry48:~ $ ls -l /mnt/runimg total 18797568 -rwxrwxrwx+ 1 99 99 4555014144 Jan 7 22:32 2019-04-08-raspbian-stretch_chroot.img -rwxrwxrwx+ 1 systemd-timesync 98 3481272320 Feb 9 23:45 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 drwxrwxrwx+ 1 root root 160 Dec 19 22:41 bak -rw-rw-rw-+ 1 99 99 1728053248 Mar 5 00:10 readynas_compile_tool2.img -rw-rw-rw-+ 1 99 99 2173698048 Jan 8 23:25 readynas_compile_tool.img pi@raspberry48:~ $ sudo /home/pi/vdesktop/vdesktop /mnt/runimg/2019-04-08-raspbian-stretch-make-new.img Message from Botspot: Questions or suggestions? https://www.raspberrypi.org/forums/viewtopic.php?&t=251757 OK, looks like you specified a disk image. /dev/loop0 mount: /media/pi/vdesktop: mount point does not exist. mount: /media/pi/vdesktop/boot: mount point does not exist. mount: /media/pi/vdesktop: mount point does not exist. diff: /media/pi/vdesktop/etc/machine-id: No such file or directory Your cursor color will be blue until the container is terminated. Booting in 5 seconds. Directory /media/pi/vdesktop doesn't look like an OS root directory (os-release file is missing). Refusing. The machine has exited, but you can still access the guest. Press Ctrl+C to unmount /media/pi/vdesktop ^C Preparing to exit... Unmounted and exiting... pi@raspberry48:~ $ pi@raspberry48:~ $ pi@raspberry48:~ $