1

I'm trying to run some graphical i386 apps on ARM64 / xfce4 / jetson nano. I have configured the I386 / bionic chroot environment following and adapting a little bit this tutorial :

https://www.youtube.com/watch?v=dzAoaFOJy7U&t=161s&ab_channel=NovaspiritTech

I've created the chroot-i386 on ubuntu x64 with foreign i386 with the command :

debootstrap --foreign --arch i386 bionic ./chroot-bionic-i386/

and I copied the directory to the jetson nano, then I copied the qemu-i386-static from jetson nano to the i386 chroot with this command :

cp /usr/bin/qemu-i386-static /root/Scrivania/work/qemu-x86/chroot-bionic-i386

Now,Instead of running :

chroot ./chroot-bionic-i386/ /debootstrap/debootstrap --second-stage

outside of the chroot folder,inside the chroot I did :

chroot ./chroot-bionic-i386 /bin/bash

I changed the PS1 to see that I'm inside the chroot with :

PS1="(chroot i386) $PS1"

and I have launched the debootstrap second stage :

/debootstrap/debootstrap --second-stage

It worked. I don't know why for the author of the tutorial it worked in a different way than me. Now I'm trying to understand how to run Teamviewer from within the chroot.

below u can see the final result that he's got and that I wanna reach,also :

enter image description here

unfortunately this is what I get :

enter image description here

there is something that's missing on my side and that he has omitted. I did the same as him,including adding this line inside the file /root/.bashrc

export DISPLAY=:0

so,what else can be missing ? What I would like to reach is to see the teamviewer window appears inside the terminal that u see on the picture. Anyway I wanna save your time showing the commands that he issued,so you can avoid watching the full tutorial. From within the chroot he wrote :

apt install xterm
cd opt
mkdir chrootscript
cd chrootscript

sudo nano chrootmount

!/bin/bash

sudo mount -t sysfs /sys/ /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/sys/

sudo mount -t proc /proc/ /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/proc/

sudo mount --bind /dev /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/dev/

sudo mount --bind /dev/pts /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/dev/pts/

sudo mount --bind /dev/shm /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/dev/shm/


sudo chmod +x chrootmount


sudo nano /etc/systemd/system/chrootmount.service


[Unit]

Description= mounts chroot on boot

[Service]

Type=one-shot

ExecStart=/opt/chrootmount/chrootmount

[Install]

WantedBy=multi-user.target


sudo systemctl enable chrootmount.service


sudo nano /opt/chrootscript/start_x86_user


!/bin/sh

/usr/sbin/chroot /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/ /bin/su -l ziomario

sudo nano /opt/chrootscript/start_x86_root#

!/bin/sh

/usr/sbin/chroot /root/Scrivania/Work/qemu-x86/chroot-bionic-i386/ /bin/su -l root


chmod +x start_x86_user

chmod +x start_x86_root

Instead,on the desktop of ubuntu 18.04 installed on the nano,I did :

nano /root/Scrivania/x86_user.desktop


[Desktop Entry]

Type=Application

Comment=Start x86 user

Name=x86 User

Exec=lxterminal -e sudo /opt/chrootscript/start_x86_user

Icon=

Terminal=false

Categories=Utility

StartupNotify=True

and :

nano /root/Scrivania/x86_root.desktop


[Desktop Entry]

Type=Application

Comment=Start x86 root

Name=x86 root

Exec=lxterminal -e sudo /opt/chrootscript/start_x86_root

Icon=

Terminal=false

Categories=Utility

StartupNotify=True

at this point I have copied the folder chrootscript from the /opt folder of the chroot into the /opt folder of the ubuntu 18.04 / jetson nano and I ran the x86_user and the x86_root icon on the desktop of the nano and I got the error : "cannot open display".

NB : I haven't created any xorg.conf file,since he didn't do that.

can u realize where is the error ? thanks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.