Wednesday, July 9, 2008

make: don't know how to make libgzip.. Stop

Solution found at
http://www.tequilafish.com/2005/11/04/apache-mod_gzip-no-rule-to-make-target-libgzip/

It turns out that there’s an entry in mod_gzip’s Makefile.tmpl file that confuses my system. The very first line of src/modules/gzip/Makefile.tmpl uses a variable named LIBEXT that’s not defined on my system, so it fails. It’s an easy fix, open up src/modules/gzip/Makefile.tmpl for editing and find:

LIB=libgzip.$(LIBEXT)

And replace with:

LIB=libgzip.a

Save & Exit, run make clean; make; make install in the Apache src dir and you should be good to go

Wednesday, July 2, 2008

How to restart natd remotely

Be careful, when you want to make changes to natd.conf, and then restart from a remote console. If you just kill -9 natd, then you will get locked out immediately, without chance to start it again. Needless to say, this would lead to jumping in a car and rushing down to the office.

So, first, let's have a backup plan.

ipfw add 10 allow all from [myIpAddress] to me

Second, run

kill -9 [natd_pid] && /sbin/natd -f /etc/natd.conf -a [natd_external_address]

Of course, your natd flags may vary.