So today I went ahead and did a yum update, which updated my system from CentOS 5.2 to CentOS 5.3. Most things appear to be working properly, except that virtualmin doesn’t seem to be used when doing a “yum update” anymore, nor does it appear that any of the virtual hosts are running with suexec any longer, despite the module is installed and loaded.
I’m guessing this may be caused by the update overwriting some things, but I’m wondering if there’s any easy way to fix this which wouldn’t involve me needing to totally reinstall virtualmin, setting up all the mail stuff, and re-importing the virtual hosts.
but I'm wondering if there's any easy way to fix this which wouldn't involve me needing to totally reinstall virtualmin
Egads! Don’t reinstall!
I’m sure this is all minor.
Suexec: What’s in the suexec_log in /var/log/httpd?
yum+Virtualmin: What do you mean “virtualmin doesn’t seem to be used”? Do you still have the virtualmin-release package installed? Is the /etc/yum.repos.d/virtualmin.repo file still existent?
What else is wrong? Those two seem really simple. Reinstalling should definitely not be your first instinct here.
It’s not my first instinct, more of a last resort.
What I mean is, before the update when I’d do a “yum update” it would actually say something about checking the virtualmin repository. Now the repo file is still in the /etc/yum.repos.d/ directory for virtualmin, but when I do an update it doesn’t appear to check it as it did before.
What I mean by suexec not appearing to work is that where things running in the users home directories would read/write as the user as well, it now appears to do so as “apache:apache” instead. Only thing I’ve really seen this in so far (all I’ve checked) has been PHP scripts. There’s no signs of errors within the apache error log for suexec, nor in the actual suexec log. However, in the apache config the module is loaded, the module exists, and as far as I can tell it’s not causing errors.
Ok I think I know why the repository isn’t working… probably because the servers release version is now 5.3 and there’s no existing virtualmin repository for centos 5.3 here:
OK, for yum, check to be sure the "enabled=" line for virtualmin and virtualmin-universal are both set to 1.
For suexec, check to be sure the execution mode for scripts in Virtualmin is set to one of the "Run CGI scripts as domain owner?" options (in Server Configuration->Website Options for the domain).
Just for grins, check to be sure you have a correct suexec:
suexec -V
It should have DOCROOT set to /home.
If those are true, then let us see the VirtualHost section of httpd.conf for one of the effected domains.
While you’re in httpd.conf, make sure the suexec module is being loaded.
Ok I think I know why the repository isn't working.. probably because the servers release version is now 5.3 and there's no existing virtualmin repository for centos 5.3 here:
That shouldn’t make any different. the rhel repo is a link to the centos repo. They are binary compatible systems, so the packages are exactly the same.
I suspect yum was caching the bum data from before the 5.3 repo existed. If you were to change back and do a yum clean metadata, I bet it would fix itself up. But it doesn’t matter. Pointing to centos or rhel is fine. You’ll get the same packages.
Still a bit weird, though.
Anyway, it seems to be working now, though, right?
Did some thinking on the suexec thing then started looking deeper into the users issues. Then it hit me that PHP doesn’t ever run under suexec unless you’re running it as a cgi through some special setup versus under mod_php normally.
Then I realized that they changed from a perl forum over to a php based one. Which explains why what is happening is happening. Though I’m surprised that virtualmin doesn’t seem to set up php as a cgi under suexec by default. Either that or whatever it did set up was removed on the system update.