On 07/09/2011 9:21 AM, Balogh Péter wrote:
Hi Frank, I've just inserted the following line on the top of the apache2.conf ChrootDir /hosting I didn't do anything else, to make it work, and that's the only line I've removed, to fix the issue Best regards, Peter Balogh On 2011.09.07. 14:59, Frank Gingras wrote:On 07/09/11 06:40 AM, Balogh Péter wrote:Hi Frank, I can try a PHP list, but it's clearly an apache chroot related problem. Best regards, Peter Balogh On 2011.09.07. 4:00, Frank Gingras wrote:On 06/09/2011 3:17 PM, Balogh Péter wrote:Hi, I've tried searching the archives (the FAQ is 404 at the moment), but couldn't find any tread regarding my issue. I have an Ubuntu 11.04 server running 2.6.38-10-server I've a stock apache2 and php5 installed from apt. Nothing fancy, no extensions or patches. I've chrooted the apache to a directory, and moved a few sites to the server. The sites loads fine for the first few times, but after a few reloads, I get a strange PHP error. From the logs: [Tue Sep 06 00:41:57 2011] [error] [client 80.98.32.172] PHP Warning: Unknown: failed to open stream: No such file or directory in Unknown on line 0 [Tue Sep 06 00:41:57 2011] [error] [client 80.98.32.172] PHP Fatal error: Unknown: Failed opening required '/hosting/site1/index.php' (include_path='.:/usr/share/php:/usr/share/pear') in Unknown on line 0 Few minutes later, or after a restart, the sites are working OK again. If I disable the chroot, everything works fine. Does anybody have a clue, what did I do wrong, or how can I figure out the problem? My only idea, is that I don't have a required so file in the chroot path, when apache runs out of concurrent instances, but I have no idea, how to figure out, what's missing. root@c1:/etc# dpkg -l | grep apache ii apache2 2.2.17-1ubuntu1.2 Apache HTTP Server metapackage ii apache2-mpm-prefork 2.2.17-1ubuntu1.2 Apache HTTP Server - traditional non-threaded model ii apache2-utils 2.2.17-1ubuntu1.2 utility programs for webservers ii apache2.2-bin 2.2.17-1ubuntu1.2 Apache HTTP Server common binary files ii apache2.2-common 2.2.17-1ubuntu1.2 Apache HTTP Server common files ii libapache2-mod-php5 5.3.5-1ubuntu7.2 server-side, HTML-embedded scripting language (Apache 2 module) root@c1:/etc# dpkg -l | grep php ii libapache2-mod-php5 5.3.5-1ubuntu7.2 server-side, HTML-embedded scripting language (Apache 2 module) ii php5 5.3.5-1ubuntu7.2 server-side, HTML-embedded scripting language (metapackage) ii php5-cgi 5.3.5-1ubuntu7.2 server-side, HTML-embedded scripting language (CGI binary) ii php5-cli 5.3.5-1ubuntu7.2 command-line interpreter for the php5 scripting language ii php5-common 5.3.5-1ubuntu7.2 Common files for packages built from the php5 source ii php5-gd 5.3.5-1ubuntu7.2 GD module for php5 ii php5-mcrypt 5.3.5-0ubuntu1 MCrypt module for php5 ii php5-mysql 5.3.5-1ubuntu7.2 MySQL module for php5 ii php5-pgsql 5.3.5-1ubuntu7.2 PostgreSQL module for php5 ii phpmyadmin 4:3.3.10-1 MySQL web administration tool ii phppgadmin 4.2.3-1.1 web-based administration tool for PostgreSQL Thank you for your help, Best regards, Peter Balogh --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxxTry asking a php-oriented mailing list. Frank --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx--------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxxBalogh,How did you build your chroot? If you used apache httpd directives, pastebin them in here. If you used your OS to chroot, you're falling outside the scope of this list, definitely.Frank --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx--------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
Balogh,If you can reproduce the error reliably, you can strace the httpd -X process, and find out exactly where it fails.
--------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx