chroot environment

Other talk about Salix
User avatar
jpg153
Donor
Posts: 417
Joined: 23. Oct 2009, 15:43
Location: Marl/NRW/BRD/EU

chroot environment

Post by jpg153 » 10. Dec 2015, 22:21

Hi all,

I am considering to setup a chroot environment for 32bit apps on my 64bit Salix.

There was already a solution provided by Shador quite some time ago. It requires some additional work but did its job.
However in sourcery there is salix-chroot-install and schroot - both designed to support a chroot environment.

Does anyone have experience with these tools?

However I think to install a full 32bit system bootable in parallel to be able to update it. Would that work in a chroot?

The chroot should allow some applications to run as well as virtual box (or was it vmware..). I want to avoid multilib.

Please let me know your thoughts.

Thanks.
Regards Gruß
jpg

elcore
Posts: 40
Joined: 4. Jul 2014, 05:07
Location: EU

Re: chroot environment

Post by elcore » 11. Dec 2015, 09:24

One can chroot into Salix32 from Salix64, but not the other way around.
Similar situation with vm host/guest, one needs 64 bit host to run 64 bit guest.
At least from my experience, I could not even boot a pre-installed 64 bit guest on 32 bit host.

User avatar
jpg153
Donor
Posts: 417
Joined: 23. Oct 2009, 15:43
Location: Marl/NRW/BRD/EU

Re: chroot environment

Post by jpg153 » 11. Dec 2015, 10:05

Hi,

maybe I put it somewhat unclear..

The host is 64bit and I want to chroot into a 32bit environment. Not the other way round ;)
Regards Gruß
jpg

User avatar
gapan
Salix Wizard
Posts: 5617
Joined: 6. Jun 2009, 17:40

Re: chroot environment

Post by gapan » 11. Dec 2015, 12:06

salix-chroot-installer can be used to set up the chroot and then use schroot to access it. It's mostly explained in this email from our mailing list:
https://sourceforge.net/p/salix/mailman ... /33182843/
Image
Image

User avatar
jpg153
Donor
Posts: 417
Joined: 23. Oct 2009, 15:43
Location: Marl/NRW/BRD/EU

Re: chroot environment

Post by jpg153 » 11. Dec 2015, 14:35

Thanks Gapan,

it reads almost exactly what I want.
Just one question: with Shadors solution I didnot need not take care about graphics drivers and printer setup in the 32bit environment.
I was running Textmaker (gui app) in the 32bit chroot and printing went simply on the 64bit system without having a printer configured
in the 32bit system. Does that work with Schroot as well? I guess it would...

thanks again.

coincidently, its around the same time just one year after :D
Regards Gruß
jpg

User avatar
gapan
Salix Wizard
Posts: 5617
Joined: 6. Jun 2009, 17:40

Re: chroot environment

Post by gapan » 11. Dec 2015, 16:51

Yes, printing should work without having to set it up in the chroot. After all, cups is just a server and can be accessed from anywhere in the network, let alone from localhost.
Image
Image

User avatar
jpg153
Donor
Posts: 417
Joined: 23. Oct 2009, 15:43
Location: Marl/NRW/BRD/EU

Re: chroot environment

Post by jpg153 » 13. Dec 2015, 23:00

Thanks.

Will let you know when all is up and running ;)
Regards Gruß
jpg

User avatar
gapan
Salix Wizard
Posts: 5617
Joined: 6. Jun 2009, 17:40

Re: chroot environment

Post by gapan » 13. Dec 2015, 23:13

Oh, I see I didn't answer the graphics drivers part in my previous post. You won't have to do that either. Everything is working within your host system anyway and Xorg is also a server.
Image
Image

User avatar
jpg153
Donor
Posts: 417
Joined: 23. Oct 2009, 15:43
Location: Marl/NRW/BRD/EU

Re: chroot environment

Post by jpg153 » 14. Dec 2015, 00:22

Hi Gapan,

I started as you suggested.
After that I engaged a schroot session and received following message:

Code: Select all

F: 15binfmt: which: no update-binfmts in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin)
(I receive same message when exiting the chroot).

I installed "softmaker office 2016":

Code: Select all

jpg@jpg153salix:~/Downloads/LinuxPakete$ sudo ./installsmoffice

./installsmoffice: line 994: bc: command not found

This script will install SoftMaker Office 2016.

Do you want to continue (y/n)? [y] y
while installing the screen shows

Code: Select all

Using existing xdg-utils
./installsmoffice: line 227: bc: command not found
./installsmoffice: line 488: bc: command not found
Create MIME
Adding document icons...
./installsmoffice: line 329: bc: command not found
and further:

Code: Select all

Registering MIME types...
sed: can't read /etc/mime.types: No such file or directory
Installing for user(s) 
./installsmoffice: line 28: bc: command not found
After successful installation, with starters not working on my desktop, I invoked
textmaker to get up:

Code: Select all

jpg[bin]$ textmaker
libGL error: failed to load driver: swrast
libGL error: Try again with LIBGL_DEBUG=verbose for more details.
I received a similar message within textmaker when it came up.
But only after the first start. on second start the messages are gone.

So far so good! Thanks. :D

Is there a way to create a starter on my 64bit-desktop which will start the app inside the chroot automatically
and...to create a mime type for that? :?:
Regards Gruß
jpg

User avatar
gapan
Salix Wizard
Posts: 5617
Joined: 6. Jun 2009, 17:40

Re: chroot environment

Post by gapan » 14. Dec 2015, 14:04

The "bc: command not found" messages were obviously because you didn't have bc installed and the installer needed it somehow. The "update-binfmts" message shouldn't be a problem, I think it's looking for some debian thing.
jpg153 wrote:Is there a way to create a starter on my 64bit-desktop which will start the app inside the chroot automatically
and...to create a mime type for that? :?:
You can create a .desktop file that will launch the command you want through schroot. That .desktop file can also include mimetypes. That should do it.
Image
Image

Post Reply