Other debootstrap and linux compatibility

Hello All,

I am using FreeBSD 13.1 (amd64).

I am following the handbook (https://docs.freebsd.org/en/books/handbook/linuxemu/) and trying to use linux compatability.

I installed debian (with "deboostrap bullseye /compat/debian") and setup mount points as per (https://wiki.freebsd.org/LinuxJails). Did not do the /tmp and /home mounts though.

I also added [compat.linux.emul_path="/compat/debian"] to the /etc/sysctl.conf file. When I try to run "/compat/debian/bin/ls" it complains with this.

% /compat/debian/bin/ls
ELF interpreter /lib64/ld-linux-x86-64.so.2 not found, error 2
Abort trap

But if I am in chroot in /compat/debian I can use these.

And there is a /lib64/ld-linux-x86-64.so.2 file in the compat/debian directory.

Is it possible to use the debian (or linux) binaries without chroot?
 
See sysctl compat.linux.emul_path. What's configured here is the prefix of a Linux userland that overlays your filesystem.
I also added [compat.linux.emul_path="/compat/debian"] to the /etc/sysctl.conf file.
This is only applied on boot. Either reboot or apply it manually with sysctl(8).
 
For that error I also had to replace the absolute link to a relative one.
See 1. in this thread for an example:
 
See sysctl compat.linux.emul_path. What's configured here is the prefix of a Linux userland that overlays your filesystem.

This is only applied on boot. Either reboot or apply it manually with sysctl(8).
I already had rebooted. And this particular sysctl variable returned the correct path /compat/debian
 
For that error I also had to replace the absolute link to a relative one.
See 1. in this thread for an example:
Yep that was it. Thank a lot. Now I can run /compat/debian/ls.
 
  • Thanks
Reactions: grz
Back
Top