Archive for April, 2007

Moving from apache2 to nginx

Wednesday, April 25th, 2007

If you want to use nginx as a reverse proxy, be aware that the default log format is not the same as apache’s default combined log, so it might screw up any log analyzers (like awstats), which will show the incorrect log entries as corrupted records.

If you were not aware of this, use the following sed command:

cat FUBAR.log | sed -e ‘s/(.* – – [.*]) (.* .* .*) “(.*)” (.* “.*” “.*”) “.*”/1 “2” 3 4/’ > /tmp/not-FUBAR.log

nginx config the ubuntu way

Monday, April 23rd, 2007

./configure –sbin-path=/sbin/nginx –conf-path=/etc/nginx/nginx.conf –error-log-path=/var/log/nginx/error.log –pid-path=/var/run/nginx/nginx.pid –with-cpu-opt=athlon –http-log-path=/var/log/nginx/access.log –http-proxy-temp-path=/var/spool/nginx/proxy_temp –http-client-body-temp-path=/var/spool/nginx/client_body_temp –http-fastcgi-temp-path=/var/spool/nginx/fastcgi_temp –without-http_rewrite_module

feisty upgrade

Sunday, April 22nd, 2007

Note: ez majd folyamatosan fog frissulni, ahogy kiderulnek az ujabb es ujabb baromsagai.

[ 4.104000] scsi 0:0:0:0: Direct-Access ATA FUJITSU MHV2080A 0083 PQ: 0 ANSI: 5
[ 4.104000] scsi 0:0:1:0: CD-ROM MATSHITA DVD-RAM UJ-832S 1.02 PQ: 0 ANSI: 5
[ 4.116000] SCSI device sda: 156301488 512-byte hdwr sectors (80026 MB)

Furcsa dolgok ezek, edgy alatt meg hda-kent latta a diszkemet. Nem mintha zavarna, de nem tudtam, h ez csak SCSISZEMUVEG kerdese…

Amugy maga az upgrade csont nelkul lement – most azt ne szamoljuk bele, hogy elotte ket napig vakaroztam, hogy hogyan csinaljak eleg helyet a ketszer megpupozott 4g-s rootfs-en, hogy az 500akarhany meganyi dotdeb lejojjon, valamint hogy ebbe beletartozott nehany oranyi partition magic(tm) rugdosas, mert az a fospumpa nem volt hajlando egyaltalan elindulni, valamint hogy a vegen a gordiuszi csomot atvagva bedaraltam ket particiot es csinaltam egy uj /home-ot magamnak, hogy elferjen a szentem -, mindossze a gdm-et kellett nullara purgeolni, majd ujra felrakni, h elinduljon. Viszont megjavult a ‘greeting app’, most mar nem crashel el indulaskor, csak a human-theme-t hianyolta egy darabig. Megoldva. Eljen.

Erzesre amugy gyorsabb, Ugyanez volt edgy upgradenel is, ott is gyorsabbnak tunt, nem derult ki, h az ezereves libc6 upgradelese miatt, vagy csak mert az elvezeti ertek. miszerint ‘juhe, vegre megint frissebb a zdisztribem’, is beleszamitott…

UPDATE: arra meg nem jottek ra, hogy hogyan lehet egy docked app-ot figyelni, peldaul az amarok-ot (ne rohogjel, az egyetlen hasznalhato lejatszo, igaz h kde-s, en meg gnome-ot hasznalok, de a gtk-s cuccok lejaccok a fasorba sincsenek, az oskovulet xmms-t hagyjuk, az egauile-t, vagy hogyafaszomba irjak, szinten meghagyom masnak, egyszer eleg volt felrakni, kurvagyorsan le is kerult), szoval hogy csak egy peldanyban induljon el, es a vicces juzernek ne legyen otven amarok ikonja a taszkbarban. Majd a kovetkezo rilizben.

UPDATE: kopete persze beszart menetkozben, majd remove-purge-install komboval megoldom. Tiszta vindoz.

UPDATE: es telleg.

gericom az anyad

Tuesday, April 10th, 2007

23:29 @wigyori> bazmeg
23:29 @wigyori> gericom notebookot nekem tobbet az eletben ne merjen mutatni senki
23:30 @wigyori> mert porgorugassal fogom elkuldeni a retkes picsaba
23:32 andrej_> gericommal mi a baj epp?
23:32 @wigyori> szerelem szet tisztitas celjabol
23:33 @wigyori> es erosen ketes h sikerulni fog-e osszerakni
23:33 @wigyori> mert meg ot perc szereles es aprofat csinalok belole

How to migrate proxying from Apache2 to nginx

Monday, April 9th, 2007

# for i in `ls /store/chroot/proxy/etc/apache2/sites-available/`; do
hostname=`echo $i |cut -d – -f 2`;
count=`echo $i |cut -d – -f 1`;
cat template.conf |sed -e “s/{hostname}/${hostname}/” > vhosts/${count}-${hostname}.conf ;
echo “include conf/vhosts/${count}-${hostname}.conf” >> vhosts.conf;
done

The only thing left is to set the servername aliases in the config files by hand.

TMF Jaarmixes

Sunday, April 8th, 2007

Just found the TMF Jaarmix 2006 somewhere hidden on my disk, took a look into it. Half of the clips are unknown to me… It was far another story with the 2000-2001-2002-2003 compilations – am I getting older or WTF?

bcw(4) licensing issues?

Friday, April 6th, 2007

I think it’s fair enough for the whole subject to read a few mails, the following ones:

Michael Buesch’s initial mail

Reply to Theo’s reply 1

Reply to Theo’s reply 2

Theo’s seems to be frantically trying to defend the indefendable, by counter-attacking Michael and trying to undermine what a licensing issue is… /me laughes hard at their mad way to defend BSD licensing…

Finally Pavel Roskin about MadWifi and OpenBSD

You can read the whole thread here.

x4100 ilom upgrade

Friday, April 6th, 2007

Take care with upgrading ILOM 1.0 to 1.1.1, it does not keep the original settings – like its fixed IP address – resulting in the service processor to acquire its address via DHCP… Not so lucky in a co-location environment 😛

freedos netboot

Thursday, April 5th, 2007

The master plan’s reason was that I have some boxes in Moscow and in the country, and their BIOS and SAS/SCSI/lofasz controller firmware update was timely.

The master plan was to get freedos booting via pxeboot from a local gateway – or bring up its interface via a bridged openvpn to my notebook in a very perverse way -, then provide an environment containing the flasher tools, the firmware images, and so on.

The master plan succeeded.

Creating a PXE environment was an easy job, install a dhcp3-server and a tftpd. Add a similar entry into your dhcpd.conf:

host shg2pxe {
hardware ethernet 00:02:b3:51:15:82;
fixed-address 10.1.1.100;
next-server 10.1.1.254;
filename “pxelinux.0”;
}

hardware ethernet is self explanatory, fixed-address also, next-server is the IP address of your TFTP server, filename is the PXE stage 1 loader, which you have to put into your tftpboot directory (/tftpboot or /var/lib/tftpboot in most of the cases, I will use the first one now.)

Then put memdisk and freedos.img into /tftpboot , and create a /tftpboot/pxelinux.cfg/default with this content:

DEFAULT freedos
LABEL freedos
kernel /memdisk
append initrd=/freedos.img

The freedos.img is a gzipped VFAT image, into which you can add files (flasher tools, firmware images, just as the original idea required) after gunzipping and mounting it with:

mount -o loop /tmp/freedos.img /mnt

Don’t forget that this is currently a 1.44Mb floppy image, so you have to fit in that. Also don’t forget to gzip it after playing around with it.

You can create an autoexec.bat on the disk image also, to run the flasher tool immediately after boot, and also add some kind of a reboot tool, to allow the box to boot up after the update.

Pinky: What are we going to do tomorrow night, Brain?
Brain: The same thing we do every night, Pinky.
Pinky: What’s that?
Brain: …I have no idea.
Pinky: Poit.
Brain: Narf.

diamonds are forever

Monday, April 2nd, 2007

ezt
hallgasd

Amugy rajottem h miert nem gerjedtem ra eddig a nagybogore, mert nem volt normalis hangfalam – felevvel ezelottig -, amin kijott volna normalisan a hangja.