LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-05-2005, 02:01 PM   #1
jollyjoice
Member
 
Registered: Aug 2003
Location: UK
Distribution: Gentoo 64
Posts: 383

Rep: Reputation: 30
chroot "Permission denied"


KK, trying to install gentoo 64 from inside fedora 3 (32) when i try and chroot it throws this at me, yes i am root yes it is 777d and yes it does the same with nano instead of bash.

Code:
[root@C0bra christopher]# chroot /media/gentoo64 /bin/bash
chroot: cannot run command `/bin/bash': Permission denied
any ideas?
 
Old 02-05-2005, 02:13 PM   #2
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 67
Are you sure that the bash executable is in /bin and not /usr/bin or /usr/local/bin?

Do a whereis bash to find out where exactly it is.
 
Old 02-05-2005, 02:20 PM   #3
jollyjoice
Member
 
Registered: Aug 2003
Location: UK
Distribution: Gentoo 64
Posts: 383

Original Poster
Rep: Reputation: 30
[root@C0bra christopher]# whereis bash
bash: /bin/bash /usr/share/man/man1/bash.1.gz
 
Old 02-05-2005, 03:06 PM   #4
Dark_Helmet
Senior Member
 
Registered: Jan 2003
Posts: 2,786

Rep: Reputation: 374Reputation: 374Reputation: 374Reputation: 374
I'm no expert with chroot, but doesn't chroot try to run the executable from within the new root? In other words, wouldn't a copy of bash need to be in /media/gentoo64/bin?

EDIT: I honestly don't know... so I'm asking as well as suggesting...

Last edited by Dark_Helmet; 02-05-2005 at 03:08 PM.
 
Old 02-05-2005, 03:11 PM   #5
jollyjoice
Member
 
Registered: Aug 2003
Location: UK
Distribution: Gentoo 64
Posts: 383

Original Poster
Rep: Reputation: 30
Well... it is, ls /media/gentoo64/bin lists bash as being there.
 
Old 02-05-2005, 03:14 PM   #6
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 67
Dark_Hemlet... drrr, your totally right, god only knows what I was thinking....


Did you use the correct string of switches when you untared the stage file? Check the handbook but I'm sure you have to use -p and possibly some others.
 
Old 02-05-2005, 04:12 PM   #7
jollyjoice
Member
 
Registered: Aug 2003
Location: UK
Distribution: Gentoo 64
Posts: 383

Original Poster
Rep: Reputation: 30
yes i did, just gone thrugh the whole thing again.
 
Old 02-05-2005, 10:48 PM   #8
msl
LQ Newbie
 
Registered: Jan 2005
Posts: 4

Rep: Reputation: 0
Answer

I do believe you need to bind /proc and possibly /dev as shown in the alternative installation guide

mount -o bind /proc /mnt/gentoo/proc
and possibly mount -o bind /dev /mnt/gentoo/dev
 
Old 02-06-2005, 05:25 AM   #9
jollyjoice
Member
 
Registered: Aug 2003
Location: UK
Distribution: Gentoo 64
Posts: 383

Original Poster
Rep: Reputation: 30
still no luck, might go burn that ISO...
 
Old 03-02-2005, 09:58 AM   #10
s1ider
LQ Newbie
 
Registered: Jun 2003
Location: Oklahoma
Distribution: SUSE 9.2
Posts: 19

Rep: Reputation: 0
If you mount the intended filesystem with user option you will get this error... chrooted filesystems must be mounted root only.
 
Old 08-09-2013, 07:50 PM   #11
apink
LQ Newbie
 
Registered: Jan 2013
Posts: 14

Rep: Reputation: Disabled
I had the same problem. This fixed it for me (run as root):

# mount -o remount,dev,exec /chrootDirectory
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
can't execute c++ binaries, "permission denied"... even though permission is 777 SerfurJ Programming 14 02-20-2009 04:50 AM
Submount, "permission denied" when writing to floppy as normal user DaneM Linux - Software 5 02-22-2006 02:05 PM
"permission denied" error when cron job executes jillu Linux - Newbie 11 11-02-2004 01:19 PM
Eclipse SDK v3.0 running problem: "Permission denied" AlexDunnCpp Linux - Newbie 1 08-03-2004 11:45 AM
"permission denied" when I try to send raw data to the sound device. Travis86 Linux - Hardware 2 10-29-2003 09:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration