- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- 'chroot'ing an apache environment.
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 03:37 AM
тАО11-20-2001 03:37 AM
Have installed apache 1.3.13 - into default /opt/apache - all appears ok.
Would like to 'chroot' the apache install into /web/chroot.
Have created the relevant structure. copied all the /opt/apache files into /web/chroot/opt/apache. But when attempting to start it witt #chroot /web/chroot /opt/apache/bin/apachectl start I get the following error:- httpd: bad user www
I am starting it from root login (the same as I do from the non chroot environment). Is there a file missing that allows apache to spawn the processess as www but is currently unable to under a chroot?
Please help me!!
Dan.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 03:45 AM
тАО11-20-2001 03:45 AM
Re: 'chroot'ing an apache environment.
Cheers,
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 04:03 AM
тАО11-20-2001 04:03 AM
Re: 'chroot'ing an apache environment.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 04:36 AM
тАО11-20-2001 04:36 AM
Re: 'chroot'ing an apache environment.
Regards,
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 04:39 AM
тАО11-20-2001 04:39 AM
Re: 'chroot'ing an apache environment.
live free or die
harry
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 05:12 AM
тАО11-20-2001 05:12 AM
Re: 'chroot'ing an apache environment.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 05:46 AM
тАО11-20-2001 05:46 AM
Re: 'chroot'ing an apache environment.
As Apache appears to run ok from it's initial non chrooted location (/opt/apache), surely the problem must be that I need to move a particular file into the chrooted environment?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 06:11 AM
тАО11-20-2001 06:11 AM
SolutionI've never done this with Apache, so the following is not a definitive list, but these are the files that I would think are necessary. If any aren't copied over then I wouldn't expect Apache to work.
Shared libraries (copy to {chroot}/usr/lib):
libc.2, libm.2, libpthread.1, libdld.2, dld.sl, libnss_files.1, libnss_nis.1, libnss_dns.1
Files from /etc:
passwd, group, nsswitch.conf, hosts, resolv.conf
Any common utility called by Apache's scripts (copy to {chroot}/usr/bin):
sh, cat ... (I'm sure there are others)
Before running apache I would also change the shared library binding of the httpd program to 'immediate'. This will cause httpd to fail on startup if there are any more missing libraries & symbols. Do this with the chatr command:
# chatr -B immediate httpd
Once you know if works you can change it back with:
# chatr -B deferred httpd
Cheers,
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2001 08:00 AM
тАО11-20-2001 08:00 AM
Re: 'chroot'ing an apache environment.
Once I'd copied libnss_files.1, libnss_nis.1 & libnss_dns.1 all was ok. I would think that, judging by the filenames, the library I required was libnss_files.1 as I don't use NIS or DNS.
Again, many thanks.
Dan.