Solved

chroot

Posted on 1997-05-02
2
420 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 100 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

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
mixString challenge 36 134
Doc'in system (example?) BA 7 120
post4 challenge 28 113
Work with App store 7 96
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
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.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

726 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