sed -i "s|^\(eval.\+\)$|#\1|g" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ sed -i "s|^\(export DISPLAY.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "s|^\(eval.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "s|^\(sleep.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "s|^\(lxpanelctl.\+\)$|#\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ ls -l /media/netdir/source/raspberrypi total 0 drwxrwxrwx+ 1 systemd-network users 18 Dec 6 19:53 3 drwxrwxrwx+ 1 pi pi 18 Dec 30 09:59 4-01 drwxrwxrwx+ 1 pi pi 18 Dec 30 15:26 4-02 drwxrwxrwx+ 1 pi pi 18 Dec 30 20:46 4-03 drwxrwxrwx+ 1 systemd-timesync 98 18 Dec 31 15:39 4-04 drwxrwxrwx+ 1 99 99 18 Jan 1 21:05 4-05 drwxrwxrwx+ 1 99 99 18 Jan 2 08:03 4-06 drwxrwxrwx+ 1 99 99 18 Dec 29 09:27 4-10 drwxrwxrwx+ 1 pi pi 18 Dec 29 18:21 4-11 drwxrwxrwx+ 1 pi pi 18 Dec 29 19:19 4-12 drwxrwxrwx+ 1 pi pi 18 Dec 29 22:21 4-13 drwxrwxrwx+ 1 pi pi 18 Dec 29 22:30 4-14 drwxrwxrwx+ 1 pi pi 18 Dec 20 18:51 4-8 drwxrwxrwx+ 1 pi pi 18 Dec 21 21:14 4-9 drwxrwxrwx+ 1 99 99 18 Dec 6 19:46 org pi@raspberrypi4:~ $ mkdir -p /media/netdir/source/raspberrypi/4-06 pi@raspberrypi4:~ $ inset_line=`grep -n systemd-nspawn /home/pi/vdesktop/vdesktop | tail -1 | cut -f 1 -d:` pi@raspberrypi4:~ $ let inset_line2=inset_line+1 pi@raspberrypi4:~ $ sed -i "${inset_line2}iumount \${mntpnt}/mnt/compile" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ sed -i "${inset_line}imount --bind /media/netdir/source/raspberrypi/4-06 \${mntpnt}/mnt/compile" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ sed -i "${inset_line}imkdir -p \${mntpnt}/mnt/compile" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ ls -l /mnt/runimg total 47171444 -rwxrwxrwx+ 1 systemd-network users 1939865600 Dec 21 22:50 2012-07-15-wheezy-raspbian.img -rwxrwxrwx+ 1 systemd-network users 1939865600 Dec 21 00:08 2013-02-09-wheezy-raspbian.img -rwxrwxrwx+ 1 systemd-network users 2962227200 Dec 20 23:26 2013-12-20-wheezy-raspbian.img -rwx------+ 1 99 99 8956451117 Jan 1 23:29 2017-07-05-raspbian-jessie_compile-armel.img -rwxrwxrwx+ 1 99 99 4555014144 Dec 31 22:50 2019-04-08-raspbian-stretch_chroot.img -rwxrwxrwx+ 1 systemd-timesync 98 3481272320 Dec 30 11:47 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 drwxrwxrwx+ 1 root root 160 Dec 19 22:41 bak -rw-r--r--+ 1 systemd-timesync 98 867172352 Dec 27 22:23 Debian-testing-armmp_2019-12-27T221219.img -rw-r--r--+ 1 99 99 764411904 Dec 23 10:06 Raspbian-stretch-rpix_2019-12-22T225115.img -rw-rw-rw-+ 1 99 99 8589934592 Jan 1 19:02 raspi-test-armel.img -rw-rw-rw-+ 1 99 99 2173698048 Jan 2 09:59 test2.img -rw-rw-rw-+ 1 99 99 8589934592 Jan 1 23:45 test.img pi@raspberrypi4:~ $ sudo /home/pi/vdesktop/vdesktop /mnt/runimg/2019-04-08-raspbian-stretch-make-new.img OK, looks like you specified an .img file. e2fsck 1.44.5 (15-Dec-2018) Pass 1: Checking inodes, blocks, and sizes Pass 2: Checking directory structure Pass 3: Checking directory connectivity Pass 4: Checking reference counts Pass 5: Checking group summary information rootfs: 94973/209664 files (0.2% non-contiguous), 760999/837632 blocks /mnt/runimg/2019-04-08-raspbian-stretch-make-new.img mounted on /mnt/virtualdesktop Your cursor color will be blue until the container is terminated. Booting in 5 seconds. Spawning container virtualdesktop on /mnt/virtualdesktop. Press ^] three times within 1s to kill container. systemd 232 running in system mode. (+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD +IDN) Detected virtualization systemd-nspawn. Detected architecture arm. Welcome to Raspbian GNU/Linux 9 (stretch)! Set hostname to . Failed to install release agent, ignoring: No such file or directory [ OK ] Created slice User and Session Slice. [ OK ] Created slice System Slice. [ OK ] Reached target Slices. [ OK ] Listening on Journal Socket (/dev/log). [ OK ] Listening on Journal Socket. Starting Restore / save the current clock... Starting Set the console keyboard layout... [UNSUPP] Starting of dev-serial1.device not supported. [DEPEND] Dependency failed for Configure Bluetooth Modems connected by UART. hciuart.service: Job hciuart.service/start failed with result 'dependency'. Starting Remount Root and Kernel File Systems... [ OK ] Listening on Syslog Socket. [ OK ] Listening on /dev/initctl Compatibility Named Pipe. [ OK ] Started Forward Password Requests to Wall Directory Watch. Starting Journal Service... Mounting RPC Pipe File System... [ OK ] Reached target Swap. [ OK ] Created slice system-autologin.slice. Mounting FUSE Control File System... [ OK ] Started Journal Service. [ OK ] Mounted FUSE Control File System. [ OK ] Mounted RPC Pipe File System. [FAILED] Failed to start Remount Root and Kernel File Systems. See 'systemctl status systemd-remount-fs.service' for details. Starting Flush Journal to Persistent Storage... [ OK ] Started Restore / save the current clock. [ OK ] Started Flush Journal to Persistent Storage. [ OK ] Started Set the console keyboard layout. [ OK ] Reached target Local File Systems (Pre). [ OK ] Reached target Local File Systems. Starting Create Volatile Files and Directories... Starting Preprocess NFS configuration... Starting Raise network interfaces... Starting Set console font and keymap... Starting Tell Plymouth To Write Out Runtime Data... Starting Show Plymouth Boot Screen... [ OK ] Started Preprocess NFS configuration. [ OK ] Started Set console font and keymap. [ OK ] Reached target NFS client services. [ OK ] Reached target Remote File Systems (Pre). [ OK ] Reached target Remote File Systems. [ OK ] Started Tell Plymouth To Write Out Runtime Data. [ OK ] Started Create Volatile Files and Directories. [ OK ] Reached target System Time Synchronized. Starting Update UTMP about System Boot/Shutdown... [ OK ] Started Show Plymouth Boot Screen. [ OK ] Started Forward Password Requests to Plymouth Directory Watch. [ OK ] Reached target Paths. [ OK ] Reached target Encrypted Volumes. [ OK ] Started Update UTMP about System Boot/Shutdown. [ OK ] Reached target System Initialization. [ OK ] Listening on triggerhappy.socket. [ OK ] Started Daily Cleanup of Temporary Directories. [ OK ] Listening on D-Bus System Message Bus Socket. [ OK ] Listening on Avahi mDNS/DNS-SD Stack Activation Socket. [ OK ] Reached target Sockets. [ OK ] Reached target Basic System. Starting rng-tools.service... Starting triggerhappy global hotkey daemon... Starting System Logging Service... Starting LSB: Resize the root filesystem to fill partition... Starting Login Service... Starting Check for v3d driver... [ OK ] Started Regular background program processing daemon. Starting Avahi mDNS/DNS-SD Stack... Starting Disable WiFi if country not set... Starting dhcpcd on all interfaces... Starting LSB: Autogenerate and use a swap file... [ OK ] Started D-Bus System Message Bus. Starting WPA supplicant... Starting LSB: Switch to ondemand cpu governor (unless shift key is pressed)... [ OK ] Started Daily apt download activities. [ OK ] Started Daily apt upgrade and clean activities. [ OK ] Reached target Timers. [ OK ] Started triggerhappy global hotkey daemon. [ OK ] Started System Logging Service. [FAILED] Failed to start rng-tools.service. See 'systemctl status rng-tools.service' for details. [ OK ] Started Check for v3d driver. [FAILED] Failed to start Avahi mDNS/DNS-SD Stack. See 'systemctl status avahi-daemon.service' for details. [ OK ] Started Disable WiFi if country not set. [ OK ] Started dhcpcd on all interfaces. [ OK ] Started Login Service. [ OK ] Started LSB: Switch to ondemand cpu governor (unless shift key is pressed). [ OK ] Started WPA supplicant. [FAILED] Failed to start LSB: Resize the root filesystem to fill partition. See 'systemctl status resize2fs_once.service' for details. [ OK ] Started Raise network interfaces. [ OK ] Reached target Network. Starting Permit User Sessions... [ OK ] Reached target Network is Online. Starting Daily apt download activities... Starting /etc/rc.local Compatibility... My IP address is 192.168.1.254 [ OK ] Started LSB: Autogenerate and use a swap file. [ OK ] Started Permit User Sessions. Starting Light Display Manager... Message from virtualdesktop: Log in as user pi using the guest's password. (default is raspberry) Once you login, the graphical desktop will load automatically. Raspbian GNU/Linux 9 raspberrypi console raspberrypi login: pi Password: Login incorrect raspberrypi login: pi Password: Last login: Fri Dec 27 23:37:35 JST 2019 on console Linux raspberrypi 4.19.75-v7l+ #1270 SMP Tue Sep 24 18:51:41 BST 2019 armv7l The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. pi@raspberrypi:~ $ ls -l total 8 drwx------ 2 pi pi 4096 Dec 27 23:37 Desktop drwxr-xr-x 2 pi pi 4096 Apr 8 2019 MagPi pi@raspberrypi:~ $ echo 00:00:00 00:00:00 pi@raspberrypi:~ $ date Thu 2 Jan 10:13:06 JST 2020 pi@raspberrypi:~ $ uname -a Linux raspberrypi 4.19.75-v7l+ #1270 SMP Tue Sep 24 18:51:41 BST 2019 armv7l GNU/Linux pi@raspberrypi:~ $ su - root Password: root@raspberrypi:~# root@raspberrypi:~# compile finish -su: compile: command not found root@raspberrypi:~# shutdown -h now Session terminated, terminating shell...Sending SIGTERM to remaining processes... Sending SIGKILL to remaining processes... Process 361 (plymouthd) has been marked to be excluded from killing. It is running from the root file system, and thus likely to block re-mounting of the root file system to read-only. Please consider moving it into an initrd file system instead. Powering off. Container virtualdesktop has been shut down. pi@raspberrypi4:~ $ sed -i "s|^#\+\(eval.\+\)$|\1|g" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ sed -i "s|^#\+\(export DISPLAY.\+\)$|\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "s|^#\+\(eval.\+\)$|\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "s|^#\+\(sleep.\+\)$|\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "s|^#\+\(lxpanelctl.\+\)$|\1|g" /home/pi/vdesktop/profile pi@raspberrypi4:~ $ sed -i "${inset_line}d" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ sed -i "${inset_line}d" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $ sed -i "${inset_line2}d" /home/pi/vdesktop/vdesktop pi@raspberrypi4:~ $