[CentOS] CentOS x86_64 6.4

Fri Feb 21 16:53:23 UTC 2014
SilverTip257 <silvertip257 at gmail.com>

On Fri, Feb 21, 2014 at 11:09 AM, Steve Clark <sclark at netwolves.com> wrote:

> Hi List,
>
> Strange problem.
>

Interesting, no doubt.


>
> I am running off of CentOS x86_64 6.4 usb key that is sdb
>
> I have ssd disk that has a centos image on it. I have mounted
> the partitions /dev/sda3 as /mnt/sysimage
> and /dev/sda1 as /mnt/sysimage/boot
>
> I am trying to chroot to /mnt/sysimage dir but get the following error.
>
> [root at localhost root]# /usr/sbin/chroot /mnt/sysimage /bin/bash
> /usr/sbin/chroot: failed to run command `/bin/bash': No such file or
> directory
>

If you run chroot without the third item (the command), it will use
whatever value is in $SHELL
[manpage]
       If no command is given, run '${SHELL} -i' (default: '/bin/sh -i').
[/manpage]

`echo ${SHELL}` to find out what that might be.

You might check the shell variable and also see if you can chroot without
specifying a command as you have been doing.

I've chrooted a few cloned installs in the past week, but I didn't use the
CentOS media.
I have a copy of SystemRescueCD (default shell is zsh) on my PXE server and
go at it that way.


-- 
---~~.~~---
Mike
//  SilverTip257  //