On this page:
  • Wireless wonders
  • Moved to Vaio!
  • Getting sound to work again
  • Using supervisord for Nginx+FastCGI+PHP

Wireless wonders

I struggled with installing the DWL-650 wireless LAN card on my
Microsoft Windows XP partition for half an hour before I gave up and
booted to Linux. I suppose that if the operating system hadn’t been in
Japanese, I might’ve had a shot. What do you expect from Sony recovery
CDs for a unit primarily for the Japanese market?

On the other hand, Linux was a breeze with Ubuntu Linux, a
slick Debian-based distribution backed by
Canonical. My copy came from
Jerome Gotangco, Ubuntu documentation guy
for the Philippines.

Setting up wireless was just a matter of plugging my DWL-650 in.
D-Link really screwed up with that card by using the same model number
for cards using completely different chipsets, but Ubuntu
automatically found and loaded the module I needed.

Because we don’t want the next-door Internet cafe to sponge off our
wireless access, we protect our router with a simple MAC address
filter list. I couldn’t figure out where to find my MAC address in the
graphical network configuration tool, but a quick whiz through dmesg
turned up the magic numbers I needed to add to my router’s filters.
After I plugged that into the router’s web-based configuration tool,
set the ESSID in Ubuntu’s friendly network admin interface, and
activated the device, I was off and running.

Great stuff, huh? Now if I can just get it to work under stock Debian…

コンピューターは、たちえ緩慢にせよ大きな変化を引き起こした。 Computers caused a great if gradual change.

On Technorati: ,

Moved to Vaio!

The power adapter on my Fujitsu Lifebook P1110 has just completely given up. Fortunately, my parents had given me the Sony Vaio U1 to use as a backup computer. After a day of upgrading it from Ubuntu Breezy Badger to Ubuntu Dapper Drake (that should teach me to deselect all of the GNOME packages before I dist-upgrade!) and another afternoon for getting my various CVS Emacs stuff compiled and put together, I’m now back on an approximately working system. I still need to get software suspend working, but everything else works beautifully.

The Sony Vaio U1 is actually a pretty sweet machine. It’s *tiny* – 8.9″ screen and a keyboard that even I find just a bit small. No Dvorak on this one; the combination of a Japanese keyboard and chiclet keys makes it too difficult for me to remember the proper keyboard mappings through muscle memory. I type with four fingers: the middle finger and index finger of my left hand and the thumb and index finger of my right.

When Simon saw me setting up the Vaio, he insisted that I borrow a proper-sized keyboard. Heh. ;)

So I’m on Ubuntu now. It’s certainly slicker than the Debian system I’ve just moved from, with a pretty bootup sequence and a lot of other things that Just Work. I’m no longer a poseur. The Ubuntu stickers on my skateboard actually mean something. ;) Sweet.

Now that that’s sorted out, maybe I can work on my writing backlog. I owe so many people e-mail and I owe Don Marti an article…

On Technorati:

Getting sound to work again

Things to remember when setting up sound in Ubuntu Linux on a Sony Vaio U1:

  • modprobe trident
  • modprobe snd_trident
  • Be very very thorough with alsamixer settings. For some brain-dead reason, all the important stuff is muted.

On Technorati: , ,

Using supervisord for Nginx+FastCGI+PHP

I was having problems with spawn-fcgi-standalone occasionally resulting in dead PHP processes, which caused 502 Bad Gateway errors on my site. Crontabbing an /etc/init.d/init-fastcgi start didn’t help much, so I looked for other ways to do it. Supervisord looked promising.

Here’s how to get Supervisord:

apt-get install python-setuptools
easy_install supervisor

 

Here’s what to add to /etc/supervisord.conf:

[fcgi-program:php5-cgi]
socket=tcp://127.0.0.1:9000
command=/usr/bin/php5-cgi
numprocs=5
priority=999
process_name=%(program_name)s_%(process_num)02d
user=www-data
autorestart=true
autostart=true
startsecs=1
startretries=3
stopsignal=QUIT
stopwaitsecs=10
redirect_stderr=true
stdout_logfile=/var/log/php5-cgi.log
stdout_logfile_maxbytes=10MB

So far, so good. When I kill the php process, supervisord starts it back up. Progress!

supervisord doesn’t come with an init.d script, but you can get one for Ubuntu.