26th March 2006

Technology- Apache and Hosting

posted in Technology |

Today was a pretty good day. I got my Apache logging working using cronolog to create a new log
every day. It took a bit since it was distributed source-only and I couldn’t get it to compile at
first. It has a “configure” command that you run that tests the environment and creates appropriate
makefiles. First step was realizing that I didn’t have gcc, but that was easy since the configure
command gave me a good error message to that effect.

But once GCC was installed it was still giving an error message that it wasn’t actually working.
I tried running the compiler and it gave up an error message that the linker was actually failing
to load glibc.o. A little research suggested this was the standard c library and a bit more research
suggested that it needed to be installed on its own. The package name wasn’t obvious- I think it was
libc6-dev. At this point everything compiled and it was only a few more steps to get the files
installed in the right place and update the apache configuration files to use the log rotation tool.

Of course there were no direct examples of the right syntax to use to configure Apache to use the
cronolog. And when I started Apache and it just didn’t have any error messages, it took a bit to
figure out how to tell what was wrong. I figured out how to shut down Apache in the “service settings” and
run it from the command line where I could read all the error messages and debug my configuration files. A
little while later and its running fine and I just finished up fixing some differences in the stuff I
built between IE6 and Firefox. The key one is that IE6 exposes any extra attributes you sprinkle in your
HTML directly in the object model and in Firefox you need to call .getAttribute() and .setAttribute() to
read and write them.

This linux stuff does feel like its just held together with duct-tape and bailing wire sometimes. I’m sure its mostly
that I’m not familiar with it, but finding things can be tough when they can be in /usr/bin, /var/bin, /usr/sbin, /usr/local/bin,
/usr/local/sbin, or who knows what other directories. On the one hand the way that individual pieces are really building blocks
for each other can be really powerful, but if you have some obscure configuration problem in one place on your system its really
easy for the whole thing to stop working correctly. I’m sure Windows has many similar situations.

The other thing I noticed today was that I really need to get this moved onto a hosting provider
if I’m going to put more sophisticated stuff up here. Running it off my home connection has worked fine
so far but earlier today while I was listening to the radio the media player suddenly stuttered. A little
research revealed it was someone looking at photo libraries on this site. Next step is researching the
different options- The main thing I’m looking for at the moment is someone with good PHP and MySQL support,
the ability to host multiple domain names/sites without paying individually, and reasonable monthly
transfer limits. Any recommendations?

]]>

Leave a Reply