Hello.
Because I have a little space on the sd card of my jetson nano,I have installed the nfs server on Ubuntu 18.04 x64 bit and the nfs common client on ubuntu 18.04 for arm64 on the jetson nano. I have followed this tutorial :
I have issued the following commands :
on the server side :
sudo chown -R nobody:nogroup /home/loziomario/Scrivania/Nano/qemu-chroot-I9
chmod -R 777 /home/loziomario/Scrivania/Nano/qemu-chroot-I9
on the client / jetson nano side :
sudo chown -R nobody:nogroup /root/Scrivania/Work/qemu-chroot-I9
chmod -R 777 /root/Scrivania/Work/qemu-chroot-I9
and then I have created a script like this :
xhost +
sudo mount 192.168.1.6:/home/loziomario/Scrivania/Nano/qemu-chroot-I9 /root/Scrivania/Work/qemu-chroot-I9
sudo mount -t sysfs /sys/ /root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/sys/
sudo mount -t proc /proc/ /root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/proc/
sudo mount --bind /dev /root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/dev/
sudo mount --bind /dev/pts /root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/dev/pts/
sudo mount --bind /dev/shm /root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/dev/shm/
I’ve logged inside the chroot with this command :
sudo chroot /root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/ /bin/su -l root
Ok.
I tried to update and upgrade the packages of the i386 chroot and this is what happened :
apt update
.......
Run apt list --upgradable to see it.
W: chown to _apt:root of directory /var/lib/apt/lists/partial failed
- SetupAPTPartialDirectory (1: Operation not permitted)
W: chown to _apt:root of directory /var/lib/apt/lists/auxfiles failed -
SetupAPTPartialDirectory (1: Operation not permitted)
W: Not using locking for nfs mounted lock file /var/lib/apt/lists/lock
W: Download is performed unsandboxed as root as file /var/lib/apt/lists/partial/archive.ubuntu.com_ubuntu_dists_bionic_InRelease' couldn't be accessed by user '_apt'. -
pkgAcquire::Run (13: Permission denied)W: chown to root:root of file /var/lib/apt/lists/partial/it.archive.ubuntu.com_ubuntu_dists_bionic_InRelease failed - Operation not permitted)
root@ziomario-desktop:~# apt upgrade
Reading package lists... DoneBuilding dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded: teamviewer1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 15.6 MB of archives. After this operation, 0 B of additional disk space will be used.
W: Not using locking for nfs mounted lock file /var/lib/dpkg/lock-frontendW: Not using locking for nfs mounted lock file /var/lib/dpkg/lockW:
chown to _apt:root of directory /var/cache/apt/archives/partial failed
- SetupAPTPartialDirectory (1: Operation not permitted)
W: chown to _apt:root of directory /var/lib/apt/lists/auxfiles failed
- SetupAPTPartialDirectory (1: Operation not permitted)
W: Not using locking for nfs mounted lock file /var/cache/apt/archives/lock
Do you want to continue? [Y/n]
something is wrong with the permissions ?. I’m not able to understand what’s wrong.
This is how I have configured the NFS on the server side :
sudo nano /etc/exports
/home/loziomario/Scrivania/Nano/qemu-chroot-I9 192.168.1.3(rw,sync,no_subtree_check)
where :
192.168.1.3
: is the ip of the nano
/home/loziomario/Scrivania/Nano/qemu-chroot-I9
: the folder that I want to make available only to the ip number of the nano
on the client / nano side I did :
sudo mount 192.168.1.6:/home/loziomario/Scrivania/Nano/qemu-chroot-I9 /root/Scrivania/Work/qemu-chroot-I9
where :
192.168.1.6
: is the IP of the server,ubuntu 18.04 64 bit
/home/loziomario/Scrivania/Nano/qemu-chroot-I9
: is the folder of the server that I want to make available to client-nano
/root/Scrivania/work/qemu-chroot-I9
: is the folder where I want to mount the folder of the server
this is the mixed full (network) path where It is saved the chroot i386,that I want to access through the nano :
/root/Scrivania/Work/qemu-chroot-I9/chroot-bionic-i386/
on the server side :
root@loziomario-I9:/home/loziomario/Scrivania/Nano/qemu-chroot-I9# sudo chown -R nobody:nogroup chroot-bionic-x86_64
root@loziomario-I9:/home/loziomario/Scrivania/Nano/qemu-chroot-I9# chmod 777 -R chroot-bionic-x86_64
on the client side :
sudo chown -R nobody:nogroup chroot-bionic-x86_64
chown: changing ownership of 'chroot-bionic-x86_64/sys/kernel/config': Operation not permitted
chown: changing ownership of 'chroot-bionic-x86_64/sys/kernel/tracing': Operation not permitted
chown: changing ownership of 'chroot-bionic-x86_64/sys/kernel/debug': Operation not permitted
chown: changing ownership of 'chroot-bionic-x86_64/sys/fs/pstore': Operation not permitted
chown: changing ownership of 'chroot-bionic-x86_64/sys/fs/cgroup': Operation not permitted
chown: changing ownership of 'chroot-bionic-x86_64/sys/fs/fuse/connections': Operation not permitted
and so on…
chmod 777 -R chroot-bionic-x86_64
chmod: changing permissions of 'chroot-bionic-x86_64/sys/kernel/config': Operation not permitted
chmod: changing permissions of 'chroot-bionic-x86_64/sys/kernel/tracing': Operation not permitted
chmod: changing permissions of 'chroot-bionic-x86_64/sys/kernel/debug': Operation not permitted
and so on…
sudo chroot ./chroot-bionic-x86_64/ /debootstrap/debootstrap --second-stage
/bin/mknod: //test-dev-null: Operation not permitted
E: Cannot install into target '/' mounted with noexec or nodev
I have also tried to do :
on the server side :
sudo mount -o remount,exec,dev /
ok
on the client side :
sudo mount -o remount,exec,dev /
sudo chroot ./chroot-bionic-x86_64/ /debootstrap/debootstrap --second-stage
/bin/mknod: //test-dev-null: Operation not permitted
E: Cannot install into target '/' mounted with noexec or nodev
I hope that everything is clear and that someone can give me some good suggestion to fix the permission problems that I have. thanks.