?
Solved

chroot

Posted on 1997-05-02
2
Medium Priority
?
424 Views
Last Modified: 2013-12-26
when I try tu use the chroot command, I always have:
chroot: No such file or directory

The result of 'which chroot' is /etc/chroot and when I type 'chroot <enter>', I have:
usage: chroot rootdir command arg ...

I've tried to "configure" the new rootdir in the same way as I did for anonymous ftp (create a directory rootdir/dev and creating the special files with 'mknod') but it still doesn't work.

Thanks in advance for your help

Benoit.
0
Comment
Question by:bb021897
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 3

Expert Comment

by:dhm
ID: 1292755
I need to know what system you're using, and the exact chroot command line you're trying to run.  Also, an "ls" of the new root directory would be good.

Remember that the chroot happens before the command is executed, so if you give a full pathname to the program (which is a good idea) it has to be relative to the new root directory.  Also, as you've guessed, if the executable requires any shared libraries or anything, you have to provide copies in the chroot-ed environment.
0
 
LVL 2

Accepted Solution

by:
mlev earned 200 total points
ID: 1292756
Like it says, you need to specify a command to run.
Try for example, chroot <dir> /bin/sh
(You do have to create a mini-tree, and you have to be root).
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
Introduction: Dialogs (2) modeless dialog and a worker thread.  Handling data shared between threads.  Recursive functions. Continuing from the tenth article about sudoku.   Last article we worked with a modal dialog to help maintain informat…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question