View Single Post
  #3   (View Single Post)  
Old 1st February 2021
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,985
Default

  • If I understand what you've done, you have three empty filesystems. If that's true, you'll need to install the OS on them there before you can install any packages. A chroot(2) is not necessarily the best or easiest way to do this -- a virtual machine is likely to be easier. Yes, one can dump(8)/restore(8) and installboot(8) from your existing OS, but installing the OS in a guest is much, much easier. Depending on your hardware, you can use the built-in hypervisor, or you can do this using Qemu emulation if you need to.
  • A chroot(2) is a new root filesystem location. As currently mounted, /home/openbsd/a does not have access to any other filesystem, so you will not be able to chroot(8) it and then reach the contents of its intended /usr or /home. Instead of having the other filesystems mounted to /home/openbsd/{b,c}, they would need to be mounted as /home/openbsd/a/usr and /home/openbsd/a/home, respectively.
  • Your chroot will have access to your network stack, but it will need valid domain resolution via resolv.conf(5). You will need to copy your existing /etc/resolv.conf into /home/openbsd/a/etc to obtain correct domain resolution from a chroot(2).
  • You may get interference between shared libraries on your base system and inside your chroot(). If they have differences in their ABIs, you may not be able to run affected programs from the new root filesystem successfully.
Reply With Quote