jc blog - tales of a modern-day nomadic hunter-gatherer

Follow jcomeau_ictx on Twitter This is the weblog of Intrepid Wanderer. You never know what you might find here; graphic descriptions of bodily functions, computer programming secrets, proselytizing for the antichrist, miscellaneous ranting and kvetching, valuable information on living off the land... if you don't share my rather weird interests you may want to try slashdot instead.

You can consider my Del.icio.us links an extension to my blog, as are my LifeTango goals and my other to-do items. My to-buy list is also public, but only for sharing any useful ideas that might be there; I'm not requesting charity, neither do I offer it.

You can find me easily in google searches, as jcomeau, jcomeau_ictx, or jcomeauictx. There are lots of other jcomeaus, but AFAIK I'm the only jcomeau_ictx out there so far.

If you want to comment on anything you see here, try the new Facebook comments, reachable by clicking the "[comment]" link at the end of each post. If for some reason that isn't working, go ahead and email me, jc.unternet.net. You know what to do with the first dot. Make the 'subject' line something reasonably intelligent-looking or it goes plunk! into the spambasket unread.

This RSS feed may or may not work. Haven't fiddled with it in forever. RSS Feed


Winding down on my RAC job... about to break out the tequila bottle and call it a night. It wasn't all that hard, but I was trying to make it a learning experience, so I went through a lot of hair-pulling getting javascript to work reliably, and learning some finer points of sed to do stuff I would previously have relegated to Perl.

I didn't know before, for example, that you could set form variables via the script that you specify as your "onsubmit" code, and that you can tack on a question mark and parameters to a plain-old .htm URL and retrieve them via javascript to affect the behavior of the form on the page. For example, based on what the user entered into the form, you could set a hidden variable to any arbitrary variable:

if (myform.email.value == "jcomeau@nosuch.dom") myform.debug.value = true;

Not sure that's correct, nor illustrative of the concept even... but that's the idea. Those of you who use javascript regularly are saying "ho-hum", but hey, I almost never touch the stuff... to me it was a revelation. You have to already have put that element into the form, though, without a value, sic:

<INPUT TYPE="hidden" NAME="debug" VALUE="">

I'm trying to get my sedit sound editor script working again; invoking it gave me a strange error:

: bad interpreter: No such file or directory/python

That looked vaguely familiar. Futzing around with strace didn't help at all; invoking it with "python sedit.py" avoided the problem... aha! I wrote this when I was still running Cygwin; I bet it has embedded CRs... xxd sedit.py... sure enough! A quick perl -pi -e 's/\r//' sedit.py later and now I'm on to the real bugs. [comment]


Got a call to my jfax voicemail, and received it in my Yahoo! email inbox. How do I listen to it? I'd forgotten how; actually, not sure I ever figured it out under Linux. Turned out to be easy; the sox 'play' program knows how to play .gsm format perfectly. I set up firefox to do this by default from now on, as I had previously set up gimv to view the .jfx (tiff) faxes.

It was from Social Security, regarding the disability application I had filled out on the web. The guy wanted me to call him. No mention of email; email doesn't exist. Like hell it doesn't. I guessed at the spelling of his name, sent an email to firstname.lastname@ssa.gov asking what the call was about. Didn't really expect an answer. Ha! Got one a few minutes ago. He wasn't even curious as to how I found his email address; I guess he just takes it for granted that anyone can figure it out.

Got my biggest RAC job so far, $200. Let's hope I don't botch it up. [comment]


Well, I had downloaded the latest Java 1.4 SDK the other day, and tried to get the JRE plugin to work with Firefox. After googling and trying different things, I got Firefox to stop crashing by linking, as several articles mentioned -- however, I would still get the "plugin" icon (a puzzle piece) and no applets would work.

The problem was the way I made the symlink. I burned the SDK to a CDROM using this script, since I don't have enough room on my hard drive, and mounted it under /usr/src/j2sdk1.4.2_06; but to make it easier to remember, I symlinked that to /usr/src/j2sdk. And I made my plugin symlink like so:

cd /opt/firefox/plugins
ln -s /usr/src/j2sdk/jre/plugin/i386/ns610-gcc32/libjavaplugin_oji.so .

But out of desperation tonight, I decided to symlink it directly:

cd /opt/firefox/plugins
ln -sf /usr/src/j2sdk1.4.2_06/jre/plugin/i386/ns610-gcc32/libjavaplugin_oji.so .

Now applets work. So Firefox can follow symlinks only so far?

Slowly getting back everything I lost when the hard drive crashed. Now for Asterisk. [comment]


The hourglass.py script was definitely a timesaver, but its constant cycling was not allowing the monitors to go into "green" power-saving mode. Also, it was inflating my google-ads impressions counts, so I couldn't tell how often my pages were really being visited. So, I hacked up a quiescent module, which lets me check how long a computer has been without keyboard or mouse activity. I guess screensaver apps use a similar method, I never looked at any of Zawinski's code though... I came up with this by trial-and-error.

So anyway, now with all 3 monitors blacking out after 3 minutes, I'm saving 1.5 amps, which means my café draws 2.1 rather than 3.6 amps when nothing's happening. That's not counting the lamp, which is on a separate circuit, I'm using a clamp-on ammeter on the one duplex outlet; I just took off the cover and made a loop of the slack in the blue wire. Anyway, the lamp is one of those circular flourescents, nominally 22 Watts, which should mean about .2 amps (22 / 120 = .18333), for a total of 2.3 amps "quiescent" current. Much better. Saves the monitors from raster-burn too. [comment]


I've been working on this python program, hourglass.py, to time out my internet café customers. It works pretty well; I can have all 3 computers in use, and I login to the bootserver with my Clié to run addpesos, a symlink to the same script, whenever they give me more cash. It works out great, I don't have to write down the times and try to remember who prepaid and who didn't... it was becoming a drag, and this makes it bearable again.

This pssh software is great. I know I keep harping on the same theme, but dig this: you turn off the PDA while it's connected to the remote server, and when you turn it back on, all you need to do is hit <ENTER>, and it reconnects within seconds to your session, no need to login again. That way the batteries can last the whole day, particularly if you turn off the backlight -- that's the biggest power drain, not the wifi.

I've only gotten feedback from one online acquaintance on my disability decision so far, but it's the one person whose opinion I value the most -- a libertarian friend who's not afraid to express what she thinks. Yes, it's somewhat negative, in effect saying that she and all other payers into the SS system will be paying for my decision. I don't see it that way, obviously... I'm still hoping to persuade her and other libertarians that my way of seeing the problem, and its solution, is a valid one. We shall see. I have to keep trying, because I haven't yet really convinced myself on all levels.

That I'm disabled isn't really contestible any more. I became finally sure of that when I freaked out on a little $50 joblet on RAC a week or so ago. I had to admit it: the stress of even a small assignment gets me worked up to a fever pitch. I can't imagine committing myself to any job without going, as the Brits say, completely bonkers. How about a broom-pusher job? I don't know, I've been applying for such online with nary a response. My resumé doesn't help much in that regard. Besides, most jobs of that sort require use of toxic chemicals, which make me sick. I don't want that either... why should I suffer either mental or physical illness just to make money, when I've already put away over $100,000 towards (or so I thought) my retirement?

Now, on to a different subject: the paleolithic diet. It took me years to reach this point, of which Ray Audette in Neanderthin warned me: carb binges now consistently bring headaches, diarrhea, upset stomach, and an acid taste in the mouth that I "feel" throughout my system. Finally I'm able to go into the Waldo's dollar store and resist the 7-ounce chocolate bars, knowing that if I buy it I'll eat it and suffer the consequences. It's as bad as drinking a gallon of beer, except that the pleasure isn't nearly as great while the pain is the same. So the diet is self-enforcing, with a built-in feedback loop that helps to prevent lapses. It just takes longer to "kick in" with some people than with others. [comment]


Goddamn useless gummint offices. Went to SSA in Chula Vista today for my second attempt at getting a Social Security card sent to me at the San Diego address that collects my mail for me. They said they sent one a month ago. I said that's right, they should have, since that's when I was last there to request one. They said the Post Office must have failed to deliver. I admitted that was possible. They said they'll put in one more order for a card, and if I don't get it, it's not their fault, I'll have to deal with the Post Office. I said I get other mail at that address with no problem. She (let's drop the anonymous "they", OK?) then shook her head as if to emphasize "that's not my concern". I offered to have it FedEx'ed at my expense. She said "that's not necessary". Which means they don't give a flying fuck if I get my card or not, as long as their paperwork is done.

OK, I have an announcement to make. It's only tangentally related to the above, and it's something I've been thinking about long and hard for over a year. I'm going to file for disability and start collecting my Social Security now rather than 17 years from now.

My Dad will turn over in his grave. My hard-working brother and sister will probably disown me, as will my libertarian-minded friends and online acquaintances. I'll probably lose at least half my blog audience and the 2 cents a day I collect on average from my Google ads. My Mom will probably forgive me, only because she always cuts me more slack than I deserve and her love goes beyond all the horrible things I do.

Yes, it's horrible. I admit it. It's wrong, damned wrong, and I already regret the decision in advance. But I have my reasons. First, I never signed any goddamned "cross-generational contract", a term which I never heard until reading about it this year in a Social Security publication. The money I paid in Social Security taxes was, so I thought, for my retirement. Now we have this spendthrift in the White House, with his lackeys up the hill, burdening the future generations of Americans with a mortgage for which they can't possibly afford the payments. So what's going to happen to my retirement money? Will it be there in 2021? I have sufficient doubts to warrant the breach of faith I'm about to commit.

Another reason is in-line with that. I want to deprive this government of as much operating capital as possible. That's why I'm making this decision public, to encourage others to follow suit. Let's see John Galt's bet and raise him. Let's not only withdraw our brains and bodies from the labor force, let's take back everything we paid in to the machine, and maybe even more. Here's my offer to show my seriousness. The first 10 people who follow my example will, after proving it to my satisfaction, be entitled to 3 days of urban survival training, a $3000 value, by Yours Truly, as discussed at redpill.unternet.net. Don't wait forever, I'll change my mind eventually and post a retraction, at which point the offer is over.

I'm sure I can think of other reasons, if pressed. The point is, I've made up my mind, the wheels are in motion, and it's going to happen. Those who no longer wish to be associated with me, I understand and wish you well. [comment]


Finally, the toxins had pretty much left my system by yesterday evening. Today I felt great physically, including my neck which seemed to fall into place as soon as my stomach got back to normal and my headache disappeared. I'm still an emotional wreck but at least my body is back to normal...

My RentACoder.com rating is getting better with each completed job, though of course all it takes is one fuckup to permanently fall off the face of the earth in that regard. Enjoying it while it lasts. I'm hoping to make the top 10 before I do something stupid. [comment]


More adventures in the life of the internet café clerk. I finally got around to upgrading all the necessary packages so I could install Mozilla Firefox 1.0. And in a completely unrelated issue, I had switched USB support into a module instead of built-in to the kernel, to try and work out some problems with my webcam (not the JB1, a different one, which also doesn't work... grr...). Well, to keep a short story short, the troublesome workstation, codenamed billy, Oopsed and wouldn't come all the way up into Xwindows. What's funny is that alyce, workstation 1, had the same Oops and still came up all the way.

The message included this: "kernel BUG at slab.c:815". I googled that and got a bunch of hits. One recommended putting "noacpi" into the kernel boot options. I did. No help. So then I just disabled the hotplug startup script on the thin clients. Presto, billy is OK again. No Oops, not on alyce either.

In case you're curious, here's the latest revision of /etc/pxeclient.init:

exec </dev/console >/dev/console 2>/dev/console
ramfs() {
 number=$1; mb=$2; mountpoint=$3
 dd if=/dev/zero of=/dev/ram$number bs=$((1024 * 1024)) count=$mb &>/dev/null
 mke2fs -q -m0 -i1024 /dev/ram$number &>/dev/null
 mount -n -o rw /dev/ram$number $mountpoint &>/dev/null
echo Setting up ramdisks...
ramfs 0 4 /tmp
chmod 1777 /tmp
ramfs 1 8 /mnt/tmp/etc
ramfs 2 6 /mnt/tmp/var
ramfs 3 4 /mnt/tmp/home
ramfs 4 2 /mnt/tmp/dev
echo Ramdisks created, now populating with files...
mount -n -t proc proc /proc &>/dev/null
ifconfig lo up # didn't used to be necessary, but seems so now...
#echo Mount status: $(</proc/mounts) # FIXME debugging only
cp -a /etc /dev /mnt/tmp
#echo Home directories: /home/* # FIXME debugging only
cp -a /home/internet /mnt/tmp/home
# now overwrite necessary files with client configurations
cp -af /ref/client/* /mnt/tmp
echo Ramdisks populated, now unmounting...
umount /mnt/tmp/*
echo Remounting ramdisks at proper mountpoints...
mount -n -o rw /dev/ram1 /etc
mount -n -o rw /dev/ram2 /var
mount -n -o rw /dev/ram3 /home
mknod /tmp/ram4 b 1 4
mount -n -o rw /tmp/ram4 /dev
echo Creating /etc/mtab from /proc/mounts...
cp -f /proc/mounts /etc/mtab
echo Mounting /dev/pts, unix pty support...
mount -o rw,gid=5,mode=620 -t devpts devpts /dev/pts
# define bootserver
echo Setting environment variables from /proc/net/pnp...
for declaration in $(grep -v '^#' /proc/net/pnp | sed -e 's/ /=/'); do
 declare $declaration
netroot=$(echo $bootserver | cut -d '.' -f 1,2,3)
echo Mounting $bootserver:/opt as /opt...
mount -t nfs -o ro,nolock $bootserver:/opt /opt
echo Creating default route...
route add default gw $gateway
export bootserver gateway
#/bin/bash -l # FIXME debugging only
echo Passing control to /sbin/init...
exec /sbin/init

And /opt/bootlocal.sh:

# put other system startup command here

# if syslogd failed, try a restart [ -z "$(pidof syslogd)" ] && /etc/init.d/syslog restart [ -z "$(pidof syslogd)" ] && echo "System is not logging!" >&2

# if dhcpd3 didn't start yet, try again here [ -z "$(pidof dhcpd3)" ] && /etc/init.d/dhcp3-server restart [ -z "$(pidof dhcpd3)" ] && echo "Still no DHCP service running!" >&2

# if httpd isn't running, attempt to start it here [ -z "$(pidof httpd)" ] && /etc/init.d/httpd restart [ -z "$(pidof httpd)" ] && echo "Still no HTTP service running!" >&2

# find out who we are declare $(ifconfig eth0 | awk '$2 ~ "^addr:" {print $2}' | sed -e 's/:/=/') if [ "$addr" ]; then echo Determined address to be: $addr >&2 hostname=$(grep "^$addr\>" /etc/hosts | awk '{print $2}') if [ "$hostname" ]; then echo Setting hostname to $hostname >&2 hostname $hostname fi # did we lose our default route? if so, fix it if ! [ "$(awk '$2 ~ "00000000"' /proc/net/route)" ]; then net=$(echo $addr | cut -d '.' -f 1,2,3) gateway=$net.1 # not always true, but in my case it is echo Setting default gateway to $gateway >&2 route add default gw $gateway fi fi

# set up binfmt_misc for postFORTH binaries [ -d "/home/jcomeau" ] && make -f /home/jcomeau/src/postforth-2/Makefile \ /proc/sys/fs/binfmt_misc/forthcom # now we can (maybe) add other stuff to binfmt_misc if [ -f "/proc/sys/fs/binfmt_misc/register" ]; then echo ':DOSWin:M::MZ::/usr/local/bin/wine:' > /proc/sys/binfmt_misc/register fi

# fix MTU for funky router that steals 8 bytes out of the packet ifconfig eth0 mtu 1492

# make reboot "safe" for unattended shop ! grep -q '^x:' /etc/inittab && su - internet -c startx &



Got Wine successfully installed for the first time, thanks to the Debian apt-get utility, and am running the Wookie HC11 simulator thanks to the excellent instructions (with downloads) at www.cs.unb.ca. If my buyer from yesterday isn't too pissed of at me I might just get some more work... [comment]


Finally! All 3 systems are working. I knew it had to be something stupid. I'd forgotten to put the 'noapic' boot option in /tftpboot/pxelinux.cfg/default. That's why it worked on one Wal-mart system (the master workstation) and not the other, PXE-booted system. So if you have a system whose keyboard and mouse lockup (freeze) as soon as it attempts to read from the mouse port, getting that stupid APIC out of the picture may be what you need to do.

You'll find similar patches out on the net, but here you go if you're trying to rebuild the 2.4.22-pxe or other 2.4-series kernel and you bomb out on a redefined __cmpxchg.

--- ./drivers/char/drm/drmP.h.orig 2004-10-13 03:54:30.000000000 +0000
+++ ./drivers/char/drm/drmP.h 2004-10-15 12:45:48.000000000 +0000
@@ -927,6 +927,7 @@

 /* Missing cmpxchg implementation for i386 kernel, copied from old drmP.h -KK Mar 2003 */
 #if __i386__
+#if __missing_cmpxchg__ /* you'd think "#ifndef __cmpxchg" would work, but no */
 static inline unsigned long __cmpxchg(volatile void *ptr, unsigned long old,
        unsigned long new, int size
@@ -957,6 +958,7 @@
 #define cmpxchg(ptr,o,n) \
   ((__typeof__(*(ptr)))__cmpxchg((ptr),(unsigned long)(o), \
        (unsigned long)(n),sizeof(*(ptr))))
+#endif /* undefined __cmpxchg */
 #endif /* i386 */

 #endif /* __KERNEL__ */

Goddamn. I'm so burned out between that lockup problem and the stress from that RAC job today. Think I'll have a good hit of that Orendain Blanco I bought the other day. About $11 a liter here, compared to $6.50 in Palomas, but still a good deal. Better than Cuervo any old day. See you in la-la land. [comment]


Wow, what a bitch installing dosemu on Debian can be. Luckily I found this German site that gives the correct installation instructions.

So why am I installing dosemu? I took a job at RAC today for a small HC11 project... it was only supposed to be to help with wiring some LEDs to the microcontroller, but I had to prove my wiring instructions were correct, so I was trying to help with the programming too... and I don't know HC11 assembler. I told the buyer that from the get-go, but it was getting hairy there for a while. I tried this and that, things that should work weren't, Anyway, I wanted to install an emulator but couldn't find one for Linux, so am installing dosemu to install the HC11 emulator under that... convoluted, huh?

I keep making changes to my websites and losing them. Am I losing my mind or what? Plus, my back is out of whack and I can't turn my head without pain. And one of the computers still locks up when trying to read from the mouse; and this version of Linux, 2.4.22, doesn't allow for the PS2 mouse driver to be installed as a module. The goddamned SSA hasn't sent my SS card yet, so I can't get my programming income from RAC. Something has to give.

On the plus side: I'm still breathing. I've got money to eat for a while. My lady still hasn't given up on me. Bush is going to lose the election... well, he is, isn't he? [comment]


After a lot of futzing around back-and-forth, I am using an nfsroot of the server's own root, mounted read-only... and it works! Here's my new boot default in /tftpboot/pxelinux.cfg/default:

DEFAULT vmlinuz ip=dhcp root=/dev/nfs nfsroot=/ init=/etc/pxeclient.init panic=5

Here's /etc/pxeclient.init:

exec </dev/console >/dev/console 2>/dev/console
ramfs() {
 dd if=/dev/zero of=/dev/ram$1 bs=1024 count=8192 &>/dev/null
 mke2fs -q /dev/ram$1 &>/dev/null
 mount -n -o rw /dev/ram$1 $2 &>/dev/null
echo Setting up ramdisks...
ramfs 0 /tmp
chmod 1777 /tmp
ramfs 1 /mnt/tmp/etc
ramfs 2 /mnt/tmp/var
ramfs 3 /mnt/tmp/home
mount -n -t proc proc /proc &>/dev/null
#echo Mount status: $(</proc/mounts) # FIXME debugging only
cp -a /etc /mnt/tmp
#echo Home directories: /home/* # FIXME debugging only
cp -a /home/internet /mnt/tmp/home
# now overwrite necessary files with client configurations
cp -af /ref/client/* /mnt/tmp
umount /mnt/tmp/*
mount -n -o rw /dev/ram1 /etc
mount -n -o rw /dev/ram2 /var
mount -n -o rw /dev/ram3 /home
cp -f /proc/mounts /etc/mtab
mount -o rw,gid=5,mode=620 -t devpts devpts /dev/pts
# define bootserver
for declaration in $(grep -v '^#' /proc/net/pnp | sed -e 's/ /=/'); do
 declare $declaration
netroot=$(echo $bootserver | cut -d '.' -f 1,2,3)
mount -t nfs $bootserver:/opt /opt
route add default gw $gateway
export bootserver gateway
#/bin/bash -l # FIXME debugging only
exec /sbin/init

And /opt/bootlocal.sh, which is the same as rc.local on RH-style systems:

# put other system startup command here
[ -z "`pidof syslogd`" ] && /sbin/syslogd

# if dhcpd3 didn't start yet, try again here [ -z "`pidof dhcpd3`" ] && /etc/init.d/dhcp3-server restart [ -z "`pidof dhcpd3`" ] && echo "Still no DHCP service running!" >&2

# if httpd isn't running, attempt to start it here [ -z "`pidof httpd`" ] && /etc/init.d/httpd restart [ -z "`pidof httpd`" ] && echo "Still no HTTP service running!" >&2

# find out who we are declare $(ifconfig eth0 | awk '$2 ~ "^addr:" {print $2}' | sed -e 's/:/=/') if [ "$addr" ]; then echo Determined address to be: $addr >&2 hostname=$(grep "^$addr\>" /etc/hosts | awk '{print $2}') if [ "$hostname" ]; then echo Setting hostname to $hostname >&2 hostname $hostname fi # did we lose our default route? if so, fix it if ! [ "$(awk '$2 ~ "00000000"' /proc/net/route)" ]; then net=$(echo $addr | cut -d '.' -f 1,2,3) gateway=$net.1 # not always true, but in my case it is echo Setting default gateway to $gateway >&2 route add default gw $gateway fi fi

# make reboot "safe" for unattended shop su - internet -c startx &

Sloppy as it may look, you don't see a single hardcoded IP address, do you? Well, they're hardcoded somewhere, but not in those scripts, heheh... /etc/hosts and /etc/dhcp3/dhcpd.conf is where all the nasty hardcoding can be found.

I avoid having a completely separate filesystem for the nfsroot by having /ref/client/etc contain only files that have to be different than the server's, and overwriting the client's ramdisk with those files after copying all of /etc over. I was going to do the same with /var, but that tree can be unpredictably large, so I made a full copy under /ref/client and zeroed out most of the files.

The system still needs a lot of tweaking... and my third system freezes once anything tries to read from /dev/mouse (as in starting Xwindows), so I'm going to have to rebuild the kernel with the mouse as a module to see if I can solve that problem. Google shows many people having had that problem, but I haven't found a single good answer. What bugs me is that the system in question is identical to the master workstation, being one of those two Wal-mart.com specials I bought a couple of months or so ago. If it works on this one, why not on that?

In other news... as soon as I got my payment for that last job, I went to MelSobel.com and bought that used B&L I've had my eye on. I've given up on getting into the genetics engineering industry by any normal method; I got into electronics, and then into computer programming, by doing it on my own first and making a name for myself. That's the way I'm going to go about genetics too. We'll see how it works, won't we? [comment]


Toxifying my system with chocolate candy and peanuts again. A minor binge, but depressing that I can't keep this under control. My whole system "feels" acidic and bloated again. Bummer.

I enabled the soft watchdog in my pxeboot kernel, but found out it was useless when I accidentally exited from the bash shell that was my "init" process. For that I had to specify "panic=5" in the options in pxelinux.cfg/default. Now it reboots in 5 seconds.

I like this testing of new systems via the PXE boot mechanism. It only takes 22 seconds from ctrl-alt-del to a new command prompt! [comment]


How's this for a minimal nfsroot system:

I have no name!@box:/# du -b -s
5070848 .
I have no name!@box:/# echo $(find /) | fold -s
/ /bin /bin/bash /bin/dd /bin/mount /bin/cp /bin/ldd /bin/cat /bin/ls /bin/ps /bin/top /bin/strace /bin/ln /bin/chown /bin/mkdir /bin/more /bin/less /bin/lynx /bin/ping /bin/cut /bin/find /bin/fold /bin/du /boot /dev /dev/console /dev/null /dev/ram0 /dev/ram1 /dev/ram2 /dev/zero /dev/ram3 /dev/ram4 /dev/pts /lib /lib/libncurses.so.5 /lib/libdl.so.2 /lib/libc.so.6 /lib/ld-linux.so.2 /lib/libext2fs.so.2 /lib/libcom_err.so.2 /lib/libblkid.so.1 /lib/libuuid.so.1 /lib/libe2p.so.2 /lib/librt.so.1 /lib/libpthread.so.0 /lib/libproc.so.3.2.1 /lib/libz.so.1 /lib/libnss_files.so.2 /lib/libnss_nis.so.2 /lib/libnss_dns.so.2 /lib/libnss_compat.so.2 /lib/libresolv.so.2 /lib/libpopt.so.0 /opt /root /root/.bash_history /sbin /sbin/mke2fs /sbin/route /sbin/pump /sbin/ifconfig /sys /usr /usr/share /usr/share/terminfo /usr/share/terminfo/l /usr/share/terminfo/l/linux /usr/share/terminfo/x /usr/share/terminfo/x/xterm /usr/share/terminfo/r /usr/share/terminfo/r/rxvt /usr/share/terminfo/v /usr/share/terminfo/v/vt100 /home /mnt /proc /tmp /var /ref /ref/etc /ref/etc/init /ref/etc/lynx.cfg /ref/etc/protocols /ref/etc/services /ref/var /ref/home /ref/home/user /etc /etc/init /etc/services /etc/lynx.cfg /etc/protocols
I have no name!@box:/#

Don't sweat the "I have no name!" stuff, that's just because I was chrooted into the nfsroot system on the bootserver itself; you don't see that on the target boxen. So far they can only lynx around on the net, but that's a start! And I'm learning a lot building it bottom-up this way. Here's /etc/init:

exec </dev/console >/dev/console 2>/dev/console
ramfs() {
 dd if=/dev/zero of=/dev/ram$1 bs=1024 count=4096 &>/dev/null
 mke2fs -q /dev/ram$1 &>/dev/null
 mount -n /dev/ram$1 $2 &>/dev/null
echo Setting up ramdisks...
ramfs 0 /tmp
ramfs 1 /etc
ramfs 2 /var
ramfs 3 /home
mount -n -t proc proc /proc &>/dev/null
cp /proc/mounts /etc/mtab
# make sure ref has hardlinks to all necessary files
cp -a /ref/* /
mount -o rw,gid=5,mode=620 -t devpts devpts /dev/pts
# the following only works while host knows only its IP
netroot=$(echo $HOSTNAME | cut -d '.' -f 1,2,3)
cp /proc/net/pnp /etc/resolv.conf
route add default gw $netroot.1
echo Well, here you go... be aware that keyboard interrupts do NOT work...
exec /bin/bash -l

And /etc/exports:


And /tftpboot/pxelinux.cfg/default:

DEFAULT vmlinuz ip=dhcp root=/dev/nfs nfsroot=/opt/netboot init=/etc/init

The reason it seems I haven't progressed much since July is that I was getting those stale NFS file handles and didn't know how to solve it, so abandoned the nfsroot method at that time... it turned out, of course, that I wasn't specifying the right export options. Until my hard drive died a few days ago, I had been booting using an initrd, and mounting individual shares over NFS. Not much difference in the results, really, just another approach. [comment]


I keep having to relearn the same shit over and over. If using pxelinux, you can either use nfsroot, and do your setup with /sbin/init; or you can use an initrd, in which case the nfsroot won't be available for you (until the linuxrc script exits), so you have to have a real mount program, not just ash-knoppix, to mount your NFS shares from the initrd. There are, seemingly, exceptions to this, as I've found with google searches, but I don't really understand them, and if you want to keep things simple you'll do one or the other. Which, I am having to admit, makes the likelihood of modifying a Damn Small Linux distribution into a thin client image is probably more trouble than it's worth... I'm more likely better off continuing the work I was doing before, creating a pared-down custom image.

My body seems to be back to normal now, more or less, and has been since around noon today. Whatever toxins I ingested are working their way out of my system. I thought that near-death experience would scare me into sticking to my diet, but nope. Ate a healthy seafood soup for lunch -- with two beers and a stack of tostadas. Then went across the street to the panaderia for a donut. Hell, you only live once. WTF. [comment]


Not much luck getting PXE set back up; but I am learning how to use apt-get, and really liking it. Some things still won't install, due to package mismatches (the perl that came with DSL is too new for the apache package, for example), but I'm sure I'll learn the workarounds eventually. It's definitely lightyears ahead of rpm in terms of package dependency resolution, although I'm sure RedHat has come up with something better in the past few years. Maybe up2date is their answer to apt-get, I really don't know...

Anyway, I've got yp installed, but not yet configured, and some other stuff, like my dyndns script working again. I'm really thinking I should wait for my new disk to arrive before I put too much into this, but this is what I've got to work with at the moment so I might as well go ahead with it...

The general malaise I've felt over the past few days seems to be abating, but for a while there it didn't look good. I went upstairs to crash for a while yesterday afternoon, and felt that the life force was slipping out of my body, and didn't even care. That last is pretty scary. But I woke up anyway, so you'll have to put up with my blather for a little while longer, I guess... [comment]


As predicted, the hard drive died again. Strike 3, you're out... I closed up the shop, went down the street to the computer dealer and tried to get a good deal on a drive. He wanted 10 bucks for an old 1.2G drive. Now, I already have a 160GB on the way I bought online for little over $100. So I'm gonna pay $10 for 1GB? No way. I offered him $5 and he smirked. So I also needed a webcam; I lost my momentum with the JB1. He had a pretty good one for $25. So I offered him $30 for the two items; nope. $32? Yep. OK, so I still overpaid, but $7 for a drive is not a bad deal for Rosarito. It could be an old beat-up floppy drive and they'd want $10 for it. That's just the way it is down here.

Anyway, after some problems booting Damn Small Linux (it boots fine on the other machine, but on this one I had to specify "failsafe"), I installed it on my new old hard drive. And I'm gonna have to work like hell all night if I want to open the shop tomorrow; I never backed up my PXE config. We'll see what happens. [comment]


Got mentioned by Reid Goldsborough (requires registration) today, regarding the famous Sal Wise fraud. Sal is currently scraping together $1000 to pay back United Check Cashing, and indirectly to pay back Joe Balla, who just found out about a week ago that the stop payment he had placed on his check to Sal had not been honored by his bank. It's a complicated story, you can read about it at StopOnlineFraud.com. I learned something at Joe's expense; never put a stop payment on something if it's not guaranteed, and that means you get your money back right then and there. A non-guaranteed stop can be worse than just letting a bad deal go down. In the latter case, you have just one individual to deal with. But between Joe and his money are at least two banks and a check cashing store. [comment]


Yeeeeeeah! Got postFORTH version 2 finally underway. Decided on a magic number of RZ, which is on x86 machines push %edx; pop %edx, using this interpreter from binfmt_misc. Check out the Makefile for some neat hacks. I had to study the texinfo for make for hours to figure out how to do that stuff elegantly. Sure does look simple now, doesn't it?

Now I've just got to write the compiler itself, all downhill from here, yeah, right... Anyway I like the way this is looking. For now. If I run into problems, I can always go back and play with versions 0 or 1.

I've been feeling bloated the past couple of days, so bought some nopal and have been munching it this afternoon. Got to lay off the pastries for a while, I guess. [comment]


I carelessly ordered a 200GB hard drive for $120 -- I say carelessly because I didn't even notice it was Serial ATA -- from jazztechnology.com. They accept PayPal for payment, which is cool, and just after I paid that "Serial" caught my eye... did some googling, and sure enough, it's a different type of host adapter than the normal (parallel) ATA... and I don't have it on my mobo.

So, I go to jazztechnology's website. There's an option to cancel the order, which I did... go back to my account page and the order is still active. Boo. Hiss. Tried canceling again, and again it says it worked, and again it didn't really.

Fired off an email to sales@jazztechnology.com. Surely a company that is savvy enough to accept PayPal will answer its emails promptly, right? Nope.

I didn't worry too much. It was my fault after all, and if they didn't cancel my order and refund me I'd just pay another $40 or $50 on the host adapter, and I'd still be well under a buck a gig. But according to BizRate.com, jazztechnology was just getting started in online sales, and already had one very bad review out of only a handful of reviews. They needed a chance to make things right. I really want newcomers to web commerce to succeed if they're clueful and have good prices.

But as of today they still hadn't answered my email. So I send them another:

From:   jcomeau.jcomeau.com
To:	sales.jazztechnology.com
CC:	management.jazztechnology.com, ceo.jazztechnology.com
Subject: Re: Account Information

So I guess by ignoring my emails you figure you can take my money for something I can't use, rather than invest a few minutes in selling me something I _can_ use? Not a good strategy for staying in business on the web. You might want to get on the cluetrain.

--- John Comeau <jcomeau.jcomeau.com> wrote:

> I made a mistake! I don't have serial ATA. Do you have > any parallel drives for about the same price? I tried > to cancel the order twice, and each time it says it > was canceled, but the order status still shows it > active! Please help! -- jc > > --- sales@jazztechnology.com wrote: > > > Welcome! > > > > A password for your account has been automatically > > generated.

I got a notice from PayPal within minutes that my money had been refunded. But still not a peep from the jazzguys. Oh, well, another one bites the dust. I won't give them a bad review, but I won't give them a good one, either... they'll either clean up their act or fade away into obscurity. I couldn't care less, I won't ever trust them again.

Finished my RAC job, the customer gave me a 10 rating, which should boost my Top Coder rating next time they recalculate; that 2744 that shows as of this post is old news, and was good enough to put me in the top 1500 until recently, when other more industrious coders have passed me by and bumped me down to 1520.

Also, got a consulting job from another consultant back home in Florida, and it's always nice making real money for my efforts, for a change. Of course, then I have to guarantee my work, something that I don't do for my rentacoder clients. [comment]


I never knew there were so many goddamn places to put php configuration settings. I finally got the friggin' safe mode turned off by editing some files under the httpd2 config tree. Good news is I can now qualify myself as an expert in installing, configuring, and debugging tunez.

My hard drive wouldn't boot again this morning. That was strike two. I'd better buy a new drive, and a UPS to protect it, before the third strike occurs. Backing up my files as we speak...

Better consider rosarito.kicks-ass.net, my internet cafe, to be offline for a while. If you happen to come by and it's working, great, feel free to pull up a chair... but on the other hand if you drive all the way down and it's boarded up, don't say I didn't warn you. [comment]


I'm not too impressed with ev1's dedicated server division. It turns out it was rebooted within minutes, but it took them almost exactly 24 hours to get it back on the net. Anyway, I just about finished the job, despite my own router being on the blink for a while today, forcing me to go to a competitor's internet cafe and pay $11 pesos per hour for 2 hours. Apparently a long-term brownout, not uncommon here. It turns out the biggest problems were suexec being enabled, and PHP being built with safe mode enabled... apparently when it's configured like that at compile time it ignores any directive turning it off in php.ini. Bummer. Anyway I just made a directory /usr/local/php_safe_mode and linked to every executable I needed from there. I didn't want to build a new php module and break a bunch of other stuff. The app works now but has some warts; waiting for some feedback from the owner before I continue.

I'm making some progress with postforth-2. I think I'm on The Right Track this go-round, but time will tell. [comment]


Just thought of a very cheap way to make a compiler for Linux/ELF. Just make 3 or 4 no-op ELF programs with various .text sizes ranging from the smallest possible to the largest you'd conceivably use with your language; then just copy the object code into the binary template that fits most closely. Make each a fixed power-of-two size, like, let's say, 1024, 4096, 65536. This, of course, assumes you don't care about symbol tables or any of the other features of the ELF format.

Still waiting for my customer's server to come back online. This could be the end of my RAC career if it doesn't, whether or not I caused the problem. Well, maybe I'm being overdramatic. More precisely, it could well be the end of my Top Coder rating. [comment]


Unnerving. Got a RAC job, and after a few minutes of working on it, the damned server crashed. Hard. It's still not back up, hours later. Racking my brain to figure out what I might have done to cause the problem, but nothing seems to fit. I wonder if someone at the data center just happened to accidentally pull the power plug at that moment, or if there was a cracker in the machine and when he saw me su to root, panicked and wiped the box. Even if it wasn't my fault, the data center could pin the blame on me if it was their error, and I won't have any way to prove I wasn't culpable. Ditto if a cracker rm -rf /'d it.

It's a shame, because the job was going well; I might have been able to beat minimum wage on it. Which for RAC is amazing.

In other news: no progress with the PXE boot, due to my complexity threshold being reached. Gone back to postforth-2 for a while, trying different things to see if I can simplify it to the point where I can feel comfortable with it. I've thought of some kernel-hacking projects too. Maybe make a syscall for tftp, since it's already in there anyway. There are probably hundreds of usable routines in the kernel that could conceivably be accessed via syscall, rather than duplicate the code in userland. Of course there are voices in my head screaming "Baaaaadddd idea!!!!!", but I'm ignoring them. Also make a meta-syscall in which the first parameter is the name of the call you want, e.g. EAX=__NR_meta, EBX="READ", ECX=fd, EDX=*buffer, ESI=count. That way, I can significantly reduce the symbols that have to be in postFORTH. [comment]


Hot diggety-dog. I got cloop patched so it works on both V1 and V2 compressed images. I didn't include it inline this time because the long lines would break the oh-so-wonderful format of my blog.

Now to get back to the plan, which was to be able to fix my pxe-boot setup so it had a more capable kernel, including ALSA sound. Stay tuned. [comment]


Every now and then you might find me using the alternative spelling method I'm developing in apa_jc.txt. I finally found the spelling reform document attributed to Mark Twain, after my mentor Hipbone told me George Bernard Shaw was a big proponent of spelling reform. Naturally I haven't liked any of the systems I found, so I am stubbornly creating yet another.

mai sistem uil hev ye list inkansistinsiz posibl, end ye list uested efort. it wil bi posibl to iuz it uiy ol lenguedjiz, por ehemplo espaniol, oder doitx. signifai proper nemz or ekronimz satx ez John Comeau or GNU uiy aper kes or `back ticks`, uitx ken olso bi iuzd for eni netiv spelinz. ez iu ken si, ai hevint iet disaided on ye iusiz av 'w' end 'u'.

Anyway, I'll be experimenting with this from time to time; any comments appreciated. [comment]

view blog for 2024-06
view blog for 2024-05
view blog for 2024-04
view blog for 2024-03
view blog for 2024-02
view blog for 2023-10
view blog for 2023-09
view blog for 2023-08
view blog for 2023-07
view blog for 2023-06
view blog for 2023-05
view blog for 2023-03
view blog for 2023-02
view blog for 2023-01
view blog for 2022-12
view blog for 2022-11
view blog for 2022-10
view blog for 2022-09
view blog for 2022-08
view blog for 2022-07
view blog for 2022-06
view blog for 2022-05
view blog for 2022-04
view blog for 2022-03
view blog for 2022-02
view blog for 2022-01
view blog for 2021-12
view blog for 2021-11
view blog for 2021-10
view blog for 2021-08
view blog for 2021-07
view blog for 2021-06
view blog for 2021-05
view blog for 2021-04
view blog for 2021-03
view blog for 2021-02
view blog for 2021-01
view blog for 2020-12
view blog for 2020-11
view blog for 2020-10
view blog for 2020-09
view blog for 2020-08
view blog for 2020-07
view blog for 2020-06
view blog for 2020-05
view blog for 2020-04
view blog for 2020-03
view blog for 2020-02
view blog for 2020-01
view blog for 2019-12
view blog for 2019-11
view blog for 2019-10
view blog for 2019-09
view blog for 2019-08
view blog for 2019-07
view blog for 2019-06
view blog for 2019-05
view blog for 2019-04
view blog for 2019-03
view blog for 2019-02
view blog for 2019-01
view blog for 2018-12
view blog for 2018-11
view blog for 2018-10
view blog for 2018-09
view blog for 2018-08
view blog for 2018-07
view blog for 2018-06
view blog for 2018-05
view blog for 2018-04
view blog for 2018-03
view blog for 2018-02
view blog for 2018-01
view blog for 2017-12
view blog for 2017-11
view blog for 2017-10
view blog for 2017-09
view blog for 2017-08
view blog for 2017-07
view blog for 2017-06
view blog for 2017-05
view blog for 2017-04
view blog for 2017-03
view blog for 2017-02
view blog for 2017-01
view blog for 2016-12
view blog for 2016-11
view blog for 2016-10
view blog for 2016-09
view blog for 2016-08
view blog for 2016-07
view blog for 2016-06
view blog for 2016-05
view blog for 2016-04
view blog for 2016-03
view blog for 2016-02
view blog for 2016-01
view blog for 2015-12
view blog for 2015-11
view blog for 2015-10
view blog for 2015-09
view blog for 2015-08
view blog for 2015-07
view blog for 2015-06
view blog for 2015-05
view blog for 2015-04
view blog for 2015-03
view blog for 2015-02
view blog for 2015-01
view blog for 2014-12
view blog for 2014-11
view blog for 2014-10
view blog for 2014-09
view blog for 2014-08
view blog for 2014-07
view blog for 2014-06
view blog for 2014-05
view blog for 2014-04
view blog for 2014-03
view blog for 2014-02
view blog for 2014-01
view blog for 2013-12
view blog for 2013-11
view blog for 2013-10
view blog for 2013-09
view blog for 2013-08
view blog for 2013-07
view blog for 2013-06
view blog for 2013-05
view blog for 2013-04
view blog for 2013-03
view blog for 2013-02
view blog for 2013-01
view blog for 2012-12
view blog for 2012-11
view blog for 2012-10
view blog for 2012-09
view blog for 2012-08
view blog for 2012-07
view blog for 2012-06
view blog for 2012-05
view blog for 2012-04
view blog for 2012-03
view blog for 2012-02
view blog for 2012-01
view blog for 2011-12
view blog for 2011-11
view blog for 2011-10
view blog for 2011-09
view blog for 2011-08
view blog for 2011-07
view blog for 2011-06
view blog for 2011-05
view blog for 2011-04
view blog for 2011-03
view blog for 2011-02
view blog for 2011-01
view blog for 2010-12
view blog for 2010-11
view blog for 2010-10
view blog for 2010-09
view blog for 2010-08
view blog for 2010-07
view blog for 2010-06
view blog for 2010-05
view blog for 2010-04
view blog for 2010-03
view blog for 2010-02
view blog for 2010-01
view blog for 2009-12
view blog for 2009-11
view blog for 2009-10
view blog for 2009-09
view blog for 2009-08
view blog for 2009-07
view blog for 2009-06
view blog for 2009-05
view blog for 2009-04
view blog for 2009-03
view blog for 2009-02
view blog for 2009-01
view blog for 2008-12
view blog for 2008-11
view blog for 2008-10
view blog for 2008-09
view blog for 2008-08
view blog for 2008-07
view blog for 2008-06
view blog for 2008-05
view blog for 2008-04
view blog for 2008-03
view blog for 2008-02
view blog for 2008-01
view blog for 2007-12
view blog for 2007-11
view blog for 2007-10
view blog for 2007-09
view blog for 2007-08
view blog for 2007-07
view blog for 2007-06
view blog for 2007-05
view blog for 2007-04
view blog for 2007-03
view blog for 2007-02
view blog for 2007-01
view blog for 2006-12
view blog for 2006-11
view blog for 2006-10
view blog for 2006-09
view blog for 2006-08
view blog for 2006-07
view blog for 2006-06
view blog for 2006-05
view blog for 2006-04
view blog for 2006-03
view blog for 2006-02
view blog for 2006-01
view blog for 2005-12
view blog for 2005-11
view blog for 2005-10
view blog for 2005-09
view blog for 2005-08
view blog for 2005-07
view blog for 2005-06
view blog for 2005-05
view blog for 2005-04
view blog for 2005-03
view blog for 2005-02
view blog for 2005-01
view blog for 2004-12
view blog for 2004-11
view blog for 2004-09
view blog for 2004-08
view blog for 2004-07
view blog for 2004-06
view blog for 2004-05
view blog for 2004-04
view blog for 2004-03
view blog for 2004-02
view blog for 2004-01
view blog for 2003-12

Valid HTML 4.01 Transitional

Valid CSS!