WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: chroot into 32bit environment from 64bit TC  (Read 2197 times)

Offline bencpeters

  • Newbie
  • *
  • Posts: 1
chroot into 32bit environment from 64bit TC
« on: January 21, 2015, 02:08:37 PM »
Hi all,
I'm attempting to chroot into a 32 bit system from a 64 bit TC kernel (running docker on OS X). Unfortunately, I'm getting "Exec format error" whenever I try to run anything inside the environment. From reading online, this seems to be because TinyCore doesn't have 32 bit support built into the kernel?

I was wondering:

- Is this actually the cause of my issue?
- Is there any reasonably easy way to add this support into the kernel? (without re-compiling the whole kernel - this kernel was installed by Docker)

Thanks!

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: chroot into 32bit environment from 64bit TC
« Reply #1 on: January 21, 2015, 04:15:11 PM »
Our 64-bit kernels have always had 32-bit support enabled, so probably something else. Many users run with the 64-bit kernel and 32-bit userspace.
The only barriers that can stop you are the ones you create yourself.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: chroot into 32bit environment from 64bit TC
« Reply #2 on: January 21, 2015, 05:35:08 PM »
You must chroot into a directory that has the 64 bit kernel modules and the 32 bit user space.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: chroot into 32bit environment from 64bit TC
« Reply #3 on: January 22, 2015, 03:43:43 AM »
I don't think modules are needed if all needed ones get loaded before chrooting?
The only barriers that can stop you are the ones you create yourself.

Offline CentralWare

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 764
Re: chroot into 32bit environment from 64bit TC
« Reply #4 on: January 29, 2015, 01:09:37 PM »
@ben: My understanding is that Pure64 does NOT have 32bit support, thus you'll want to make sure you picked up the kernel from version/x86/release/distribution_files/vmlinuz64 instead of from x86_64.  From there, you should, in theory, be able to run in 32bit user space but ONLY running 32bit extensions.  Again...  this is IF my understanding is valid.