Decided to buy a new desktop to use as a server, Fedora can be a pain.

Was googling to find a solution to an issue I had a few weeks ago, and on the first page of the google results was my own website… and no it didn’t have the answer I was looking for; although my site has the answer now :-). But I should probably make an attempt to keep my website online so decided to replace the really old hardware it was running on.

This origional webserver was a physical machine (over 10yrs old but still going); 32 bit with 512Mb ram, 1cpu, a 20Gb hard disk, and I had to plug in a usb external 1Tb disk for data overflow, an external drive that spins down when not in use so great for power but slow to spin up when needed. I had to keep it running F17 as I got sick of having it offline for days trying to get kickstart scripts working for later releases. It had no dvd drive so all ‘recovery’ from booting to single user through to complete re-install had to be done using network boot (which is no problem, really easy to setup, I think I documented on the website somewhere).

The new machine I have purchased is 8Gb ram, 8 cores, with a internal 1Tb hard disk, and 64 bit of course.

As the webserver doesn’t need all of that my plan is to put a copy of the webserver, upgraded to F20 as F17 is out of support, into a VM assigned 2Gb memory, 2 cpus and 120Gb hard disk; which should hold it for quite a while.

So, created a kickstart script for F20 to build the VM with, and the battle commenced, Fedora can be a pain. It took a couple of weeks to get F20 working (mostly) correctly, could never have taken the origional server offline for that long.

On the webserver migration battle

  • major changes in httpd config since f17 to f20, to be expected, eventually resolved
  • ssl certs valid under F17 are rejected by apache in f20, manually recreating ssl certs under F20 got that going
  • mysql (mariadb) will not start with SELinux in enforcing mode, using ‘setenforce 0’ it will start. I still have to create SELinux rules to allow mariadb to run
  • changes to ifup-xxx configuration files ???. Network startup assigns the correct ip-address to the interface but the ‘gateway0’ directive in the config script is apparently ignored in F20. Currently I have to manually add the route for the default gateway. Doing it as a rc startup script for now
  • length of password hashes changed in mysql a while ago (I was even using the old_passwords=1 flag on f17 to allow use of the old format). However the PHP version with F20 only allows the longer hashed passwords. Every database user referenced in PHP scripts had to be deleted, re-added, and the database grants recreated before PHP scripts could access the sql databases (not fedora specific, any site upgrading php will eventually hit this issue), just using mysql to change the password does not work, only by using an identify by on the user create command sets a usable password. Not an issue for my kickstart scripts (soon) as the webserver backups will be the F20 backups instead of the F17 backups (latest backups of old webserver) used in the initial install
  • lots of perl modules installed by default in F17 are not installed in F20, had to manually install them
  • likewise PHP modules (such as php-zip) are not installed as part of the core PHP package anymore; I had to hunt down quite a few php rpms needed to get the website working under F20
  • still to do, get the SELinux rules customised and switch back to enforcing

But the F20 based webserver is live now.

About mark

At work, been working on Tandems for around 30yrs (programming + sysadmin), plus AIX and Solaris sysadmin also thrown in during the last 20yrs; also about 5yrs on MVS (mainly operations and automation but also smp/e work). At home I have been using linux for decades. Programming background is commercially in TAL/COBOL/SCOBOL/C(Tandem); 370 assembler(MVS); C, perl and shell scripting in *nix; and Microsoft Macro Assembler(windows).
This entry was posted in Unix. Bookmark the permalink.