Web pages not displaying correctly/500 internal se

That’s good news that it’s working!

Regarding /var/www – remember that you really did solve a problem by moving things to /home. PHP scripts are going to be run by SuExec, making them run as the user who owns the file. And SuExec only will work on /home.

What I did on my box was to make a dir under /home for those sorts of things – along the lines of /home/apache. Then I set that up as the DocumentRoot for the default VirtualHost, rather than /var/www.

As to why the php.ini files are missing?

My best guess is that those are copied over when the users homedir is created. Since they didn’t exist at that point, it wasn’t able to copy them.

What I would do is this:

  • mkdir /home/USERNAME/etc/php5
  • cp /etc/php5/cgi/php.ini /home/USERNAME/etc/php5
  • chown USERNAME:GROUPNAME /home/USERNAME/etc/php5
  • chown USERNAME:GROUPNAME /home/USERNAME/etc/php5/php.ini

Where "USERNAME" and "GROUPNAME" are the user and group who owns that particular account / domain.

I was wondering if that was the case with /var/www not now the default doc root. So will now have to use /home as the web directory, thats nothing major. Will just have to copy over those apps which were there.
But those are minor changes, at least things seem to be working now.

I really appreciate all your help, thank you.

Getting loads and loads of,
Cron <xxxx@xxxxx> /etc/webmin/virtual-server/collectinfo.pl e-mails stating:
sh: line 1: 26161 Segmentation fault /usr/bin/php5-cgi -v 2>&1 </dev/null
all with different seg fault numbers

Would this be something to do with the problem I have had? And does it mean there is still something amiss?

I was getting loads of them awhile back, but ignored them, thinking them non important. But since my recent problems, i think I should have took heed earlier.

Alright, so, looking at the command that’s dieing above, it’s trying to run this:

/usr/bin/php5-cgi -v

So when I try to run that on your system, I get the same error. Same problem even while running /usr/bin/php.

Digging a little deeper, it looks like the problem was based around two PHP extensions:

php5 -v
PHP Warning: Cannot load module ‘PDO_ODBC’ because required module ‘pdo’ is not loaded in Unknown on line 0
PHP Warning: Cannot load module ‘pdo_pgsql’ because required module ‘pdo’ is not loaded in Unknown on line 0
PHP 5.2.0-8+etch11 (cli) (built: May 10 2008 10:46:24)
Copyright © 1997-2006 The PHP Group
Zend Engine v2.2.0, Copyright © 1998-2006 Zend Technologies
Segmentation fault

Also, in looking at the strace output, it died fairly quickly after attempting to load those two extensions.

I moved the ini files that loads them from /etc/php5/conf.d to /root/php-ini.

Now when I run php from the command line, it runs successfully, without the segmentation fault.

So I believe that’s working now!

Excellent, that will save all that mail coming thank you.
Still problems with final install of for instance gallery tho. It goes, or went to step 5, mysql php not installed. But it is cuz I have checked apt-get and it is installed. No listing in php modules in server config tho of php5-mysql. Strange.
As I have deleted all servers and started from scratch again to cancel out any misconfiguration, but some problems are still popping up.
Have noted some discrepencies in /etc/apache2/mods-available and /etc/apache2/mods-enabled.
Looks like not everything has installed or installed to the desired directories? Will missing or non loaded mods in this directory cause php to not fully function?
This is driving me potty, one problem solved, just leads to another. I suppose this is what real computing is all about :slight_smile:

Kev King

For whatever reason, some ini files are missing from /etc/php5/conf.d, it looks like.

I created 2 of those, gd.ini and mysql.ini, which should get your gallery install going. Those ini files simply load the mysql and gd extensions.

yeah just noticed, once again thank you Eric, excellent service. Far beyond what I have experienced elsewhere or expected.

Can not recommend Virtualmin highly enough.

Eric, just a quick update on the situation.

All 3 webs working and scripts have been installed on all 3 and are working properly.

Excellent, I am a happy bunny, and will celebrate with a few beers tonight.

Many thanks team for your efforts
Kev King