From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,47c5786dc2552a5c,start X-Google-Attributes: gidfee84,public X-Google-Thread: f678f,47c5786dc2552a5c,start X-Google-Attributes: gidf678f,public X-Google-ArrivalTime: 1995-03-21 17:45:27 PST Newsgroups: comp.unix.osf.misc,comp.unix.osf.osf1 Path: nntp.gmd.de!dearn!blekul11!ccsdec1.ufsia.ac.be!reks.uia.ac.be!idefix.CS.kuleuven.ac.be! Belgium.EU.net!EU.net!howland.reston.ans.net!math.ohio-state.edu!scipio.cyberstore.ca!vanbc.wimsey.com!unixg.ubc.ca!news.bc.net!newsserver.sfu.ca!fornax!mcdonald From: mcdonald@cs.sfu.ca (Ken Mcdonald) Subject: How to get progs working under chroot in OSF1 Message-ID: <1995Mar21.195520.4378@cs.sfu.ca> Organization: Faculty of Applied Science, Simon Fraser University Date: Tue, 21 Mar 1995 19:55:20 GMT Xref: nntp.gmd.de comp.unix.osf.misc:2464 comp.unix.osf.osf1:8437 I'm trying to get httpd working in a chroot environment and encountering some problems. As an intermediate task, I'm trying simply to get "ls" working under chroot, and encountering similar problems. In a nutshell, here is the setup. a copy of ls is in the directory /chdir. Also in this directory are copies of the directories leading to, and the files, /usr/shlib/libc.so, /etc/group, /etc/passwd, /dev/zero, and probably a few others as well. So, for example, the file /chdir/usr/shlib/libc.so is a copy of the file /usr/shlib/libc.so. According to "odump -Dl", libc.so is the only shared library ls depends on. However, executing chroot /chdir /ls gives the message "/ls not found". Executing the same command, but with a command other than ls which does not make use of shared libraries (eg. chroot /chdir /hostid, with a copy of hostid in chdir) does work. Clearly, ls is missing something. However, I have no idea what it is missing, nor how to find out. (On a sun, this process was quite a bit easier--I would try to execute chroot, and it would tell me, "oh, I can't find file such-and-such". The error messages on the DEC are a little more cryptic :-) ) Oh, yes, as the last line implies, I'm doing this on a Dec Alpha. It's not my normal environment, so please feel free to point out even really obvious points. Thanks, Ken McDonald mcdonald@cs.sfu.ca