From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,5f38e5e28d081a6d X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-11-15 15:19:22 PST Newsgroups: comp.unix.osf.osf1 Path: nntp.gmd.de!newsserver.jvnc.net!howland.reston.ans.net!cs.utexas.edu!utnut!info.physics.utoronto.ca!sysmark From: sysmark@helios.physics.utoronto.ca (Mark Bartelt) Subject: SUMMARY: chroot(1) oddity Message-ID: Nntp-Posting-Host: helios.physics.utoronto.ca Sender: news@info.physics.utoronto.ca (System Administrator) Reply-To: mark@cita.toronto.edu Organization: Canadian Institute for Theoretical Astrophysics Date: Tue, 15 Nov 1994 20:02:26 GMT References: I've had a few replies to my query from earlier today re chroot(1). None of them were completely on-target, but one was close (see below). I had one suggestion that /etc/svc.conf was needed in the chrooted directory, but by the time that suggestion arrived, I'd already had a look at that possibility (a sensible one, since svc.conf has a "passwd=" entry, so who knows what might happen if svc.conf were missing?), but it turns out that it isn't needed. (One can actually infer this without checking, by doing an "ls -l" (from a non-chrooted environment, of courrse), and then doing a "ls -lu /etc/svc.conf", and noticing that its atime doesn't change.) The best suggestion came from Joseph McGuire (joe@alpha.vyne.com), who said I beleive that you need to create the (dir and) file CHROOTDIR/bin/sia/siainitgood. [ ... ] Actually, he meant /etc/sia/siainitgood. As it turns out, that's not quite enough (it's necessary but not sufficient). What you *really* need in the chrooted environment for "ls" to map numeric uids and gids to user and group names is the following: etc/group etc/passwd.dir etc/passwd.pag etc/sia/bsd_matrix.conf etc/sia/matrix.conf etc/sia/siainitgood I had the first three; Joe suggestd the last. But you also need those .conf files in the etc/sia directory (matrix.conf is a symlink to bsd_matrix.conf). By the way, in case anyone thinks that this is a pretty trivial problem to be worrying about, this isn't actually what prompted the original posting in the first place. The *real* problem is that we have an application which we want to run chroot'ed, and it couldn't run because calls to getpwuid() failed, and in the course of investigating *that* problem, I discovered that even things like the "ls" example failed. Anyway, all is now working happily. Thanks for the suggestions, everyone! Mark Bartelt 416/978-5619 Canadian Institute for mark@cita.toronto.edu Theoretical Astrophysics mark@cita.utoronto.ca "Sheep not busy being shorn are busy frying" - Dylan, at a NZ lamb barbecue [ singing "It's all right, ma (I'm only bleating)" ]