Results 1 to 2 of 2
Awhile ago I made a backup of my /etc/apache2 folder, just cp apache2 apache2.bak, or something like that. I only have ssh access to my server, and one of the ...
- 10-27-2006 #1Just Joined!
- Join Date
- Oct 2006
- Posts
- 42
Does anybody have the contents of php4.load, php4.conf, perl.load, perl.conf?
Awhile ago I made a backup of my /etc/apache2 folder, just cp apache2 apache2.bak, or something like that. I only have ssh access to my server, and one of the things I have sometimes found easier is using my ftp client to navigate around and edit files etc. Well when I saw that apache2.bak folder, I thought, I guess I don't need that anymore, so I used my ftp client, FileZilla, to delete it. However, a couple of the folders wouldn't delete, so I ended up removing the directory in PuTTY.
I then proceeded to do something with Apache2, I can't remember what now, and when I ran /etc/init.d/apache2 force-reload, I got a bunch of errors saying that several files in mods-enabled didn't exist and Apache refused to start. All I can guess is that something went wrong when I deleted the apache2.bak folder using FileZilla, I won't make that mistake again, and I'm assuming it was because the folder had a .bak extension and FileZilla found that confusing and deleted some files in the apache2 folder.
Anyway, now my PHP is broken and I need to restore the php4.load and php4.conf files in the mods-enabled folder so I can get PHP working again. I do have the Perl module working again, but it would be good to know what was in the perl.load and perl.conf files as well. If someone can cut and paste those here, I would be grateful, or barring that, is there a way to restore configuration files using apt?
- 10-28-2006 #2Just Joined!
- Join Date
- Oct 2006
- Posts
- 42
Well, I'll answer my own post. I eventually ended up doing a apt-get --purge remove in the hopes that it would restore the default configuration, but for some reason it didn't. Maybe the php.load and php.conf files are part of the Apache2 package. I don't know. At any rate, I finally figured it out. Putting the following in the php4.conf file didn't do anything.
<IfModule mod_php4.c>
AddType application/x-httpd-php .php .phtml .php3
AddType application/x-httpd-php-source .phps
</IfModule>
I'm not sure if the technical name of the module has changed or not, but I ended up commenting out the above lines and uncommenting the equivalent lines in the apache2.conf file and that got it working again. The line for the php4.load file is as follows.
LoadModule php4_module /usr/lib/apache2/modules/libphp4.so
I'm pretty new to Linux, and I had just started writing a script to back up important files, such as my Apache configuration files. I guess I am going to have to make that a priority... When I say "new" I mean I have been running my Linux server now for a little less than a year, so it is well past time I got a good system for backing up my important files in place.


Reply With Quote
