Re: chroot and hostname resolution problem [was : Re: [syslog-ng]centralized
Gregor Binder wrote :
Msg from Guillaume LACHENAL:
Hi Guillaume,
and I suppose those libs are needed by the resolver ...
most likely :)
Why 'ldd syslog-ng' does not reported this two files ? (nor ldd on the libs returned by the previous commands)
You might find them if you continue to search recursively through the results.
This is what I've done ! : G> nor ldd on the libs returned by the previous command
How could I 'guessed' that I need to copy this files into the jail ?
I've set up quite a few chroots for all kinds of services. Experience says, that guessing (i.e. trying to figure out in advance) will usually only save you the first few trace-sessions but almost never make the chrooted service work 100% right away.
Ok
Althougt my $JAIL/etc/nsswitch.conf contains "hosts dns", hostnames are only resolved if they are in $JAIL/etc/hosts ! Amazing ...
As you seem to start having fun with process tracing, try to find out where resolving fails, or if it is attempted at all.
I'm on this way !
Regards, Gregor.
Msg from Guillaume LACHENAL: Guillaume,
You might find them if you continue to search recursively through the results.
This is what I've done ! : G> nor ldd on the libs returned by the previous command
that's why I said "might" and not "will" :) ldd's capability in searching shared libraries for dependencies is (maybe depending on the platform in use) not always reliable.
I've set up quite a few chroots for all kinds of services. Experience says, that guessing (i.e. trying to figure out in advance) will usually only save you the first few trace-sessions but almost never make the chrooted service work 100% right away.
Ok
Even though this does not necessarily apply to syslog-ng, also make sure that you test the chrooted service properly. Some software might fail at a later date, when somebody tries to access rarely used functionality, or the software does something automatically (such as a proxy purging its cache or similar things). Cheers, Gregor.
participants (2)
-
Gregor Binder
-
Guillaume LACHENAL