View previous topic :: View next topic |
Author |
Message |
remix l33t
Joined: 28 Apr 2004 Posts: 797 Location: hawaii
|
Posted: Tue Feb 02, 2010 6:25 am Post subject: chroot: failed to run command |
|
|
hi, i'm doing a remote install on a new amd64 machine. i think i'm using a x86 minimal cd, does this matter?
i'm on the chroot step and am getting this error.
Code: |
livecd ~ # chroot /mnt/gentoo/ /bin/bash
chroot: failed to run command `/bin/bash': Exec format error |
any ideas? _________________ help the needy |
|
Back to top |
|
|
EzInKy Veteran
Joined: 11 Oct 2002 Posts: 1742 Location: Kentucky
|
Posted: Tue Feb 02, 2010 6:37 am Post subject: |
|
|
You need a 64bit kernel to run 64bit code. I suggest you use http://www.sysresccd.org/Main_Page to install Gentoo instead. Besides containing both 32bit and 64bit kernels it has some nice built in tools also. _________________ Time is what keeps everything from happening all at once. |
|
Back to top |
|
|
xaviermiller Bodhisattva
Joined: 23 Jul 2004 Posts: 8708 Location: ~Brussels - Belgique
|
Posted: Tue Feb 02, 2010 6:51 am Post subject: |
|
|
and don't forget to enter "rescue64" at the boot prompt. _________________ Kind regards,
Xavier Miller |
|
Back to top |
|
|
remix l33t
Joined: 28 Apr 2004 Posts: 797 Location: hawaii
|
Posted: Tue Feb 02, 2010 7:03 am Post subject: |
|
|
awww, so i guess i have to be there physically to swap out the disk then right?
cause i'm away from it, it's locked away.
is there anyway to do it via ssh without rebooting?
or, if i get back to it, could i just use an amd64 livedvd ? _________________ help the needy |
|
Back to top |
|
|
xaviermiller Bodhisattva
Joined: 23 Jul 2004 Posts: 8708 Location: ~Brussels - Belgique
|
Posted: Tue Feb 02, 2010 7:07 am Post subject: |
|
|
Yes, you can use an AMD64 live cd. It will also work _________________ Kind regards,
Xavier Miller |
|
Back to top |
|
|
Bash Commando n00b
Joined: 14 Sep 2017 Posts: 2
|
Posted: Thu Sep 14, 2017 12:23 pm Post subject: |
|
|
I have an AMD64 gentoo live-cd and I'm experiencing the same error. Is there any other solution? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54220 Location: 56N 3W
|
Posted: Thu Sep 14, 2017 3:37 pm Post subject: |
|
|
Bash Commando,
Welcome to Gentoo.
What is the full name of the stage3 file you used? _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
Bash Commando n00b
Joined: 14 Sep 2017 Posts: 2
|
Posted: Thu Sep 14, 2017 4:02 pm Post subject: |
|
|
The stage3 tarball I downloaded (Via "links") is stage3-amd64-20170907.tar.bz2
And I've solved my part of the problem. While I couldn't "chroot" /bin/bash, I cd'd back to the /root directory and ran the following commands:
source /etc/profile
export PS1="(chroot) $PS1"
And I'm now using the terminal in a chroot environment. |
|
Back to top |
|
|
HungGarTiger Apprentice
Joined: 04 Feb 2014 Posts: 180 Location: /nz/auckland
|
Posted: Thu Sep 14, 2017 6:26 pm Post subject: |
|
|
Bash Commando wrote: | The stage3 tarball I downloaded (Via "links") is stage3-amd64-20170907.tar.bz2
And I've solved my part of the problem. While I couldn't "chroot" /bin/bash, I cd'd back to the /root directory and ran the following commands:
source /etc/profile
export PS1="(chroot) $PS1"
And I'm now using the terminal in a chroot environment. |
If the command Code: | chroot /mnt/gentoo /bin/bash | didn't work then the changes you are making will not be in the Linux system you are trying to install, you will be performing changes in the installation medium. This is an important point to understand in the chroot command. Code: | export PS1="(chroot) $PS1" | isn't changing your root directory, only the label of your terminal indicator. Trying Code: | export PS1="(not chroot) $PS1" | will show you what I mean. Please read up on the chroot command and get an understanding of how it affects the root directory as this is probably the most common way to fix borked systems and will make your life much easier in the future if you have an understanding of the concept.
Edit* phone auto correct
Last edited by HungGarTiger on Thu Sep 14, 2017 7:38 pm; edited 1 time in total |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54220 Location: 56N 3W
|
Posted: Thu Sep 14, 2017 6:33 pm Post subject: |
|
|
HungGarTiger,
Its a lower case 'g' in Code: | chroot /mnt/gentoo /bin/bash | just in case another reader wants to copy/paste from your post.
Everything else you said is spot on. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
|