self, camphone, eye

Ouij's Board

The immutable system engenders rot

eeeXubuntu on the eee 701
self, camphone, eye
[info]ouij
So I've installed eeeXubuntu on my eee 701. EeeXubuntu, as far as I can tell, is Xubuntu with a few eee pc tweaks---Tuxradar recently named it the best distribution to run on an eee 701.

Good luck getting a hold of it though---it seems to have been abandoned in favor of eeebuntu. But as much as eeebuntu appealed to me, recent versions ship with the awful ath5k wireless driver--which, I'm sure, will be great one day, but currently, is shit: latency measured in whole seconds and 75% packet loss make it unusable for all practical purposes. Fortunately, I was able to find a more recent build, based on Ubuntu 8.10 Intrepid Ibex, here.

True to form, this is essentially Ubuntu with a few extra shell scripts to configure all the ASUS-specific gubbins. There's a catch, though: the build I've linked to labels the shell scripts in Japanese, so it was a bit of a leap in the dark to get that configured right. Fortunately the rest of the OS was properly localized in English.

Once up and running, I was relieved to see that it uses the older madwifi driver, and Wi-Fi was running trouble-free. That's more like it.

If this is all fine and dandy, I think I'm going to run this until Ubuntu Intrepid gets EOL'd in April 2010--that'll be enough time for the ath5k driver to improve to where I can take a second look at it. And if that's true, then the next install will be probably use Fluxbox and be based off a usable eeebuntu core.

LaTeX for Lawyers--some thoughts
self, camphone, eye
[info]ouij
I've been looking into LaTeX for legal documents. I already use LaTeX for personal things, such as generating study outlines:

Screenshot-2
My 1L CivPro outline.

The best part about LaTeX is that it makes the structure of the documents trivially easy. I can forget about formatting, and concentrate on the content.

Of course, this is hardly WYSIWYG:

screenshot-20070221@024251

The green-and-black terminal window is what I see when I create a document in LaTeX--the finished product is shown up top.

Of course, TeX is generally a science, mathematics, & engineering thing; humanities types don't use it very much, and lawyers don't use it at all.

One problem is that we're already too wedded to our working methods. We rely on word processors to generate our documents--even though we could benefit from the more predictable behavior of a typesetting language like TeX.

Our citation style doesn't help, either. The Bluebook is needlessly complex, and its conventions are so idiosyncratic as to make it nearly impossible to use existing bibliographic styles and software to manage citations in a complex document.

That means that we're left fly-specking documents for stray commas or spaces. Not only is it annoying, I figure it's a waste of time.

Unfortunately, all the work implementing legal citation styles for TeX seems to be overseas. Jurabib was developed for German legal style--close, but not quite. biblatex doesn't quite do law. The most promising implementation, Camel, seems to have ceased development, and its lead developerhas dropped off the face of the Earth.

What I wish I had was the ability to bang out legal documents in TeX, and then specify my citations on the fly, in a way that's familiar to me as lawyer--something like LyX, with Camel support.

Sigh.

I suppose I shall have to make it myself, if I'm to have it--but I wish I had time to learn how to do that.

multibuntu
self, camphone, eye
[info]ouij

multibuntu, originally uploaded by Ouij.

How many Ubuntu flavors can I run at once?

This is Virtualbox-OSE running on top of Ubuntu Intrepid x64. Guest OSes are OpenGEU (a flavor of Ubuntu that uses the Enlightenment DR 17 window manager), eeebuntu (a flavor of ubuntu aimed at ASUS eee pc's), and Ubuntu Hardy Heron i386.

Next up: I need to find a legitimate Windows XP license to run XP in virtualbox's "seamless" mode.

Performance isn't too bad, actually.


Install Report: Ubuntu Hardy Heron on Sharp Actius MM20
self, camphone, eye
[info]ouij
I've been spending the last part of my vacation time sorting out various family IT projects. My dad's old laptop, a Sharp Actius MM20. The MM20 (and its predecessor, the MM10) was a couple of years ahead of the curve on what has since become the netbook trend-. It's thinner than a MacBook Air, has very humble hardware, and is meant to be a portable supplement to a more powerful "base" computer.

The Actius had one other thing in common with many of today's netbooks: it ran Linux pretty well-- well enough to be sold by Emperor Linux as their most portable system (the Meteor).

I had installed Ubuntu 6.10 "Edgy Eft" on it, and Dad had been using it as a Linux machine for a while now, dual-booting with Windows XP. He has a new XP laptop (amusingly, its' an ASUS eeePC 1000, running Windows XP). Since now he has a whole new box running Windows, he asked me to wipe his old PC to run Ubuntu exclusively.

I decided to take the opportunity to install a more up-to-date version of Ubuntu. An install of Ubuntu 8.10 "Intrepid Ibex" failed--well, the textmode installer ran, but then on first boot, the machine just went black and did nothing--I couldn't even bring up a text console.

I burned through a bunch of CDs before it occurred to me to try to boot into a recovery mode session and see what was up. Turns out that the Ubuntu installer wasn't configuring Xorg properly.

Fortunately, it seems that novalugger David Cafaro has already solved this problem. I edited /etc/X11/xorg.conf along his lines. The relevant stanzas go like this:


Section “Device”

Identifier “Videocard0″
Driver “radeon”
Option “AGPMode” “4″
Option “XAANoOffscreenPixmaps” “true”
Option “RenderAccel” “true”

EndSection

Section “Screen”

Identifier “Screen0″
Device “Videocard0″
DefaultDepth 24
SubSection “Display”

Viewport 0 0
Depth 24

EndSubSection

EndSection


Fix that, reboot, and X should start.

I ended up installing Ubuntu 8.04.1 LTS "Hardy Heron" instead--figuring that Dad should probably get a stabler Long-term support release rather than having to update every six months like I do.

Project Wintendo: Install Report
self, camphone, eye
[info]ouij
N.B.: Regular readers will know/remember that I'm an Ubuntu user. In the spirit of Linux install reports, I'm offering this post, trying to compare and contrast my experiences installing Ubuntu and Windows Vista Home Basic.

I am pleased to report that "Project Wintendo"--my Windows Vista Home Basic installation--was a success. A few impresions, scribbled down during the installation process:

This was my first "real" Windows installation. All my previous Windows machines were OEM preinstalled, and I never bothered wiping & reinstalling.

The first challenge was getting the goddamn box open. Microsoft's new "packaging system"--presumably designed to thwart thieves--was aggravating to open. Sure, not as vicious as those hated clamshell packages, but still plenty annyoing.

It occurred to me as I was opening the package that the package was the physical manifestation of the type of DRM: designed to protect the producer, and succeding mostly in annoying the consumer.

Once I'd managed to get the box open, I popped the installation DVD into sputnik and booted it up. I was pleasantly surprised to be greeted with an Ubuntu-type installation splash screen. The installer didn't pick the right video mode for my graphics card right off the bat, though. The result was pretty enough, but the bad graphics mode was a bit of a letdown, given that most modern Linux distributions manage to handle this sort of thing pretty well. White text, for isntance, looked terrible--I was reminded of an Apple ][ from the '80s.

I bothered to read the whole EULA through once. For someone accustomed to free software, it's quite an eye-opener. I'm not a big fan of software with remote killswitches--nor of a document that permits Microsoft, theoretically, to go rooting about my system.

Also, I was dismayed to discover that Windows still needs to reboot a few times before the installation is complete. When I install Ubuntu, I can carry on using the LiveCD as the system is installed in the background. Definite advantage to Ubuntu there.

Post-install housekeeping included an installation of a current version of Kaspersky's security suite--a step I nearly forgot. Luckly, my Dad's Kaspersky license was good for three concurrent installations, so he let me use an unused installation.

All told, however, the installation process was pretty drama-free. No BSODs, or RSODs, no major breakage. I'm guessing most Vista nightmare stories come from people attempting to upgrade. Here, I was installing onto a fresh hard drive-- so there really wasn't anything to go wrong.

There are a few downers, of course. My logitech mouse wasn't fully supported, so I don't get multibutton support or high mouse resolutions. Fooey. (For the record, Ubuntu gives me proper multibutton support on the live CD, even if high mouse resolutions seem to be broken in the current AMD64 kernel)

As far as performance? I'm not going to lie--I'm pleasantly surprised. I'd read that Vista was a complete resource pig. Officially, Vista Home Basic's system requirements are pretty reasonable: 1 GHz processor, 512 MB RAM, 20GB hard drive, a DirectX 9-compatible graphics card. sputnik Has an AMD Athlon 3800+ (the "Manchester" core) running at 2 GHz, 2GB RAM, gobs of hard drive space, and an appropriate video card.

The installed system actually runs pretty snappily. Granted, the only thing I've really been using it for has been playing Civ4, and it's been perfectly adequate for that purpose.

Home Basic doesn't come with any of spiffy Aero user interface effects. My guess is that the real resource pig in most "premium" Vista installs is really Aero. Home Basic--without Aero--actually runs just fine. Of course, it's not as pretty as the desktop effects that I can get on Linux or OSX--but I dont' really care about how my interface looks if I see so little of it anyway. (To tell you the truth, I'd really be happy if Microsoft let me use fluxbox as a user interface, but that's not gonna happen.)

Final verdict? I installed Vista and lived. In fact, I'm pretty pleased with the result. But I'm using that partition only as a glorified games console--so I don't much care if that OS install goes kaput, since I've got all the important stuff elsewhere.

If you're running Windows XP now, and can't or won't migrate to a more sane operating system, I'd recommend that you go to XP Service Pack 3 and not bother with a full Vista upgrade.

If you're running Linux or OSX and have no particular need of Windows-specific software, there's really no compelling reason to switch.

If you built your own computer like I did, and you would like to put a Microsoft OS on it, then you'd best be served getting a retail box of Vista Home Basic. The "System Builder" packages are cheaper, but the license is bound to only one set of hardware--so if you build a new machine and wipe the old one, you don't get to use the media you bought to install the OS onto the new hardware. Given the cost of the OS, going with the OEM "system builder" pack is a false economy.

It begins
self, camphone, eye
[info]ouij
I'm waiting for rsync to cook through another backup of my /home directory, then I'll power down and install Vista Home Basic.

Not gonna lie: I am filled with a great sense of foreboding.

2009: The Year of the Windows Desktop?
self, camphone, eye
[info]ouij
I never thought I would be writing this.

I think I'm going to install Windows Vista on sputnik, my current box.

I have been a pretty satisified Ubuntu user for four years now. I have gotten to the point where I don't feel particularly tied to Windows as an operating system--at least not for work.

So why go to Vista?

Simple. I love playing Civ 4. Some people have been able to get it running on Linux. But there are always all kinds of hiccups running in WINE. Fortunately, sputnik's hardware is good enough to run Civ4 quite capably.

Why Vista Home Basic? I don't really care for the visual chrome that is Microsoft's Aero desktop. Linux desktop chrome is nicer and more useful. Nor do I have any real need for the incremental-backup features that the "premium" flavors of Vista offer me--for a price. Since the Windows partition will be used mostly as a light-duty gaming rig, I don't anticipate any real problems in that department.

Does this mean I'm going to switch back to MSFT? Not really. I'm treating this like a gaming-console purchase.

Getting OpenOffice to Load Before the Heat Death of the Universe
self, camphone, eye
[info]ouij
OpenOffice 2.3 takes somewhere near forever to load for me. A bit of google-fu uncovered this guide to speeding up OpenOffice load times in Ubuntu.

I can say that this certainly did it. OpenOffice Writer starts almost instantly now. YAY.

End of an era
self, camphone, eye
[info]ouij
I have seen the end of 32-bit addressing, my friends, and let me tell you, it's not pretty.

My default e-mail client, Evolution, is great, but it keeps my incoming mail in a single mbox file. (for you *nix nerds, by default this is at ~/.evolution/mail/local/).

Over the years, as I've migrated from computer to computer, I have brought my archived e-mails with me in various mbox files. As of last night, that represented a little under six years' of e-mail correspondence. I'd simply folded the mbox files into each other, allowing me to have a single mbox file that I could search--not that I did all that much grepping through my old logs, but I do go poking into my old correspondence every so often.

But there was a problem lurking here. On IA32, the Linux kernel can only handle files smaller than two gigabytes. It simply can't address anything bigger. After years of folding mboxes into each other, my Inbox file finally got so huge that the kernel just couldn't deal with it any more--Evolution spat an error about the file being too large, and there I was.

Now I know what the Paleolithic inhabitants of the cave at Zhoukoudian/Choukoutien felt like, as they were slowly squeezed out by the ashes of their continuously-tended fires.

I spent most of late last night/early this morning installing the AMD64 build of Ubuntu. Just as expected, the 64-bit kernel addressed the huge 2 GB file with no problem, and I set to work moving older files in the mbox to a series of archives (by year).

Sadly, this hasn't yet shrunk the file by nearly enough to make it addressable by my 32-bit Ubuntu install. Evo spits out a "file too large for data type" error--and, sure enough, the software reports an mbox file over two gigabytes big.

Most of the prolbem comes from my ISP: about a year ago, their POP3 server started acting weird; occasionally resetting the "read" status on messages. Since I download local copies of all the data on the remote server, this could be bad news: every time the ISP hiccups, I'm obliged to download the past however many months of messages all at once. I've tried to deal with it as best I can, but I probably have a metric shitload of redundant copies in that mbox file alone. Thanks, guys. I'll need to install a plugin or run a script to get rid of the redundancies.

Or I could just bite the bullet and migrate to a 64-bit kernel. But I'm so dependent on WINE and various non-free codecs that are avalable only on IA32 that migrating to the new architecture would be a real pain in the ass.

Keep on Rockboxin' in the Free World
self, camphone, eye
[info]ouij
My iRiver H340 battery has been dying for a while now. So, as a birthday present, I went ahead and bought a replacement battery.

Fortunately, licketysplitauctions on ebay carries batteries for the H340. I ordered a 2200 mAh battery for the princely sum of $15.99, plus $4.49 shipping. The battery arrived quickly, but I only got around to installing it this weekend.

Happily, there are plenty of instructions available for DIY battery replacement on the H340. The whole process took maybe an hour--most of that was my fiddling around, afraid of breaking stuff. If I had to do it again, I could probably do the job in about twenty minutes. The Cameron Sino battery pack was a perfect fit--really a drop-in replacement. Added bonus: no need to do any nerd-fu on the Molex connectors, since the battery shipped with the wires the "right" way around for iRivers. (First-generation iPod batteries will also work, but the wires are reversed, and the 2200 mAh cells are juuuust a bit too thick for the case, which requires some sandpaper-fu on the interior--not something I wanted to do with my weekend).

The battery took about two hours to charge. I decided to let the player run constantly until it discharged so I could get a sense of how much battery life I can get out of the player. The thing kept going...and going....and going.... I measured a runtime of 19 hours, 54 minutes, 12 seconds--impressive, considering that the H340 used to give me 9 or 10 hours before the stock 1300 mAh battery went flat.

For those of you interested, here's a graph:

battchart
Voltage (mV) over Time (seconds): Cameron Sino 2200 mAh Battery, iRiver H340, Rockbox

Amazon MP3 Store for Linux Users
self, camphone, eye
[info]ouij
I might be the last person on the series of tubes to catch on to this. But as I was shopping for next semester's textbooks, I noticed that Amazon.com has begun offering mp3 downloads!.

OK, go ahead. Be smug. I know that you've all been using the iTunes Music Store for ages and ages. And you know that I've been resisting iTMS and similar services because of my opposition to Digital Restrictions Management (DRM).

Amazon at last has begun to compete with Apple--not just on price, but on the terms offered. The Amazon mp3 store gives me pretty much what I've been missing at much more favorable licensing terms than what Apple has been insisting on for iTMS. This vindicates Judge Easterbrook's opinion in ProCD, Inc. v. Zeidenberg:

Terms of use are no less a part of "the product" than are the size of the database and the speed with which the software compiles listings. Competition among vendors, not judicial revision of a package's contents, is how consumers are protected in a market economy

ProCD, Inc. v. Zeidenberg, 86 F.3d 1447, 1453 (7th Cir. 1996).

There is still one annoying hurdle. In order to complete your purchase, you must install Amazon's MP3 Downloader. All well and good if you run Windows or OSK--not so much for Linux. Linux users can still purchase individual tracks, but are shut out of purchasing albums at the "album discount" price--

Or at least they were, until mad-scientist took a crack at the problem. He has cleverly figured out a way of using the Amazon MP3 Downloader in Linux with WINE with the help of a bit of bash script-fu.

I've tried it out and it works. This is extremely useful--and possibly ruinous to my budget. But there you have it.
http://mad-scientist.us/amazon.html

I'm using this as a placeholder for something
self, camphone, eye
[info]ouij
find . -name "*Lectures.pdb" -print0 | xargs -i -0 txt2pdbdoc -d "{}" "{}".txt && mv *txt ~/foo


More on that line of cryptic bash later.

Facebook source leaked
self, camphone, eye
[info]ouij
If you're reading this blog, it's a pretty good bet that you're also a Facebook user. It appears that someone has somehow gotten a hold of Facebook's source code.

I don't know much about this sort of thing, but I am given to understand that Facebook seems to be nothing but a huge ass-piece of PHP code. Heaven only knows how these guys got hold of the source--all this would be executed on the server side.

TechCrunch has some commentary and analysis on what the code leak might mean:
There are a number of clear ramifications here. The first is that the code can be used by outsiders to better understand how the Facebook application works, for the purposes of finding further security holes or bugs that could be exploited. Since Facebook is a closed source application, without access to the code security holes are usually found through a process of black-box testing, whereby an external party will probe the application in an attempt to work out how the application behaves and to try and find potential race conditions. In closed source applications it is common that developers rely on the closed nature of the application to obfuscate poor design elements and the structure of the application. An attacker getting access to the source code more often than not leads to further security holes being discovered. It is for these reasons that it is often claimed that open source software is more secure than closed source software, since there are many more eyes auditing the code and obfuscation can’t be used as a security measure.

The second implication with this leak is that the source code reveals a lot about the structure of the application, and the practices that Facebook developers follow. From just this single page of source code a lot can be said and extrapolated about the rest of the Facebook application and platform. For instance, the structure doesn’t follow any object oriented development practices, and it seems that the application is one large PHP file with a large number of custom functions living in the same namespace (they also seem to be using the Smarty templating engine).


Not fun. Myspace has been target for Cross-site scripting exploits for a while now, and you can be pretty sure there are guys who are way more knowledgeable than I could ever be poring over the Facebook code, looking for similar vulnerabilities.

Kernel bloopers
self, camphone, eye
[info]ouij
After a bit of googling about, it seems that I'm affected by Ubuntu Bug #111375, which itself seems to be kernel bug #8423. According to kernel.org's bugzilla, this has been fixed, but a new Ubuntu kernel hasn't been compiled yet.

This puts me in a bit of a bind. I could, conceivably, apply the kernel patch myself--but then that would leave me up a creek with the nvidia drivers. Or I could just wait until the patched kernel shows up in the repos, and just live with the fact that I don't get speed-stepping. I'm opting for the latter. That way, I could probably just run a 32-bit kernel and not have to worry about the various workarounds for flash and java.

So, while I'm waiting--c'mon Ubuntu team!--here's some entertainment:


unforeseen glitches
self, camphone, eye
[info]ouij
While sputnik runs well enough on a 32-bit 'generic' kernel, I am tempted to try an AMD64 kernel to see if I can get CPUfreq to work properly. It's not that big a deal for me, since I haven't put anything on this host anyway.

Genesis, implemented in LISP
self, camphone, eye
[info]ouij
Thanks to the efforts of [info]mattsachs, who posted it in a recent discussion of this comic by [info]xkcd, I bring you Genesis 1, as implemented in LISP. I am not the author, merely the distributor.




;; God is the REPL

(defparameter *heaven* (make-instance 'heaven)) ; 1:1
(defparameter *earth* (make-instance 'earth ; 1:1
:form nil ; 1:2
:void nil ; 1:2
:water-face nil)) ; 1:2
(push *heaven* *CREATION*) ; 1:1
(push *earth* *CREATION*) ; 1:1

(defparameter *light* t) ; Needed later for 1:3
(defun dark-p (x) (not (eq *light* x))) ; Needed for 1:2
(assert (dark-p (slot-value *earth* 'water-face))) ; 1:2

(assert *light*) ; 1:3
(defun good-p (x) (eq x *light*)) ; Used in 1:4
(assert (good-p *light*)) ; 1:4

(defparameter *Night* (remove-if-not #'dark-p *CREATION*)) ; 1:4-5
(defparameter *Day* (remove-if #'dark-p *CREATION*)) ; 1:4-5
(let* ((first-day (car *Day*))
(evening (car first-day))
(morning (cdr first-day)))
...)

Hooptie
self, camphone, eye
[info]ouij

This is the first extensive post I will make from my old IBM Thinkpad
570e. New hostname: hooptie.


Prologue


I have decided, George Foreman-like, that I am not gonna spend
a lot on a laptop, and to that end, I bought this lappy cheap. This is
the first time in my life that I was able to get actual IBM hardware, so
I was pretty excited. Having been a little kid back in the day when
personal computers were still advertised as "IBM-compatible," IBM always
stood for hardware that was almost impossibly out of reach. Heavy-duty
clicky keyboards, thick steel cases with mottled battleship gray paint,
glowing phosphorous monochrome CRTs.


Getting hooptie up and running properly has been a bit of a
struggle.

This is a rather unconventional installation report; if
you want hard technical information, you might be disappointed. But if
you're at all interested in how Linux runs on a Thinkpad 570e in the era
after Debian Potato, well, read on, brave reader, read on.


Goals


The main goal for this project is a lightweight notebook. By
"lightweight," I mean both in terms of actual physical
mass--hooptie tips the scales at just under 2 kg when detached
from its docking station--and in terms of software setup.


This computer can and does (occasionally) run X, but I envision it as
mainly a text-mode computer. I'm reasonably comfortable operating in
the console, and with no fancy X server gobbling up system resources, I
figure I might be able to squeeze a few more seconds or minutes out of
my battery life. Moreover, I'm hoping that keeping my ugly 80-column
terminal look will deter any campus thieves.


From a purely aesthetic standpoint, running a minimal install is a
rebuke to the bling-is-king aesthetic that projects like beryl have brought to the desktop Linux
world lately. I am going against that. This laptop is about
keepin' it real.


Preliminary Setup


For hooptie to be a useful portable, it was going to need some
sort of power management. I already knew that this series of laptops
handled power-management using APM, and that hibernation (i.e.,
suspend-to-disk), was going to require a special hibernation partition.


While there is a Free Software hibernation-partition creation utility
(tphdisk, written by the redoubtable Andrew "Tridge" Tridgell),
I hadn't had much luck with it. Instead, I wimped out and went for the
disk
image provided by IBM
, which worked very well for me, as we'll see
later. This created a suitable hibernation partition at /dev/hda1.

Enter the Dapper Badger


Of course, there were a few quirks. . .


It's Not a Big Truck (or, how I get my internets)


I've been an enthusiastic Ubuntu
user since the Warty Warthog release back in 2004. The current version
of Ubuntu, in the standard year-month version number scheme, is 6.10,
"The Edgy Eft," while the current super-stable, long-term release
version is 6.06.1, "The Dapper Drake."


Any of these will work with the Thinkpad, but because my only network
connection for this computer is a Linksys WPC-11 v.3 PCMCIA wireless LAN
adaptor, I have a bit of a problem. See, the adaptor uses the
orinoco driver, which up until recently, was probably the
best-supported wireless device driver in all of Linux. Totally Free
Software, no pesky FCC-mandated closed-source firmware, plug-and-play in
the kernel. Enough to make Stallman absolutely ecstatic, right? Except
that as far as I was able to make out, orinoco seems to be
broken in all kernel versions greater tha 2.6.12; either it doesn't
work at all (wrong modules are loaded) or it loads the right modules but
works badly (DHCLIENT fails).


Hard and Soft Options


Consequently, I was forced to go to the Ubuntu release based on a
2.6.12 kernel-- version 5.10, "The Breezy Badger," released (as you
might have guessed from the name) in October 2005.


Naturally, since I wanted the barest minimum install, I went with the
'server' install option. Once it was all over, I was left with a
gloriously bare Linux install with a perfectly running 2.6.12 kernel.


I also wanted slightly more current applications than were available
for Breezy, though. So I executed an apt-get dist-upgrade to
the Dapper, while apt-pinning the kernel. Now I had Dapper's userland
on Breezy's kernel, making my own freakish Ubuntu, "The Dapper
Badger."


I wasn't done with kernel shenanigans, yet. I wanted APM, but
Debian (thus, Ubuntu) kernels tend not to enable APM by default. So to
the default kernel options in /boot/grub/menu.lst I had to
append acpi=off apm=on.


Mr. Pogi in Userspace


Time to aptitude install me some software. In keeping with
my goals for this project, installed a number of command-line programs:
irssi for IRC, mutt for mail, slrn for
usenet. . . as well as an X server and my favorite lightweight window
manager--fluxbox. All set, right?


Run Silent, Run Deep


Not quite yet. There is the matter of getting my power management up
and running. The crucial packages to get here are laptop-mode
and apmd. apmd allows me to interact with the apm
system to learn important things like how much time I have left on my
battery. laptop-mode is a series of scripts that allow me to
spin down my hard drive and system fan in an effort to reduce power
drain. In order to take advantage of both, I had to write a little
script:


#!/bin/bash
# A spindown script. Run this as root, foo!
hdparm -S 4 /dev/hda
laptop-mode start

Executing this script as root (or with sudo) will invoke laptop-mode,
which causes the computer to run silent. . . and deep. I'm not sure how
much power it actually saves me, but it sure as hell shuts the fan up,
and gives me a much quieter computer. I am pleased.


Pimp this Hooptie!


I know. I said at the beginning that this whole project was supposed
to be an antidote to the pimp-my-desktop beryl ricer aesthetic. But
there were a few things I needed to get to first.


A Font for Sore Eyes


I have lately become a fan of the terminus font family for console
work, so I installed the relevant terminus font packages from the
repositories with aptitude. Now the problem was, how to set it?


Debian (and thus Ubuntu) keep their default console settings in
/etc/console-tools. /etc/console-tools/config deals
with global console configuration issues. The last line sets the
default console font. All I had to do was edit it and replace it with
the appropriate font name from /usr/share/consolefonts.
Easy!


Keys to the Kingdom


So much for prettification. Now on to actual useful stuff.


I'm a vim user. I'm writing this on vim right now,
as it happens. And, while the 570e has an otherwise awesome keyboard
for a laptop, its Escape key is tiny and hard to reach. I needed
something different.



To remap keys on your keyboard in Ubuntu, you have to edit

/etc/console-tools/remap

which is nothing more than a script that runs sed on the output of
dumpkeys. The example script turns the capslock key into a control
key, which doubtless will bring great joy to all you dumb terminal guys
and emacs zealots out there. *I*, however, modified it
suitably to give me the escape key that I wanted there.


The config files in /etc/console-tools are called by the
init script at /etc/init.d/console-screen.sh, so to reflect any changes, we have to

sudo /etc/init.d/console-screen.sh restart

Ubuntu Dapper, for some reason, does not run
/etc/init.d/console-screen.sh at startup. So, we have to make it do so.
I ended up adding a line to /etc/rc.local to make it load on
startup.


In X, we have to run xmodmap at start. First, we create
~/.Xmodmap, filling it with the following:


! Esc on caps lock
remove Lock = Caps_Lock
keysym Caps_Lock = Escape
Now all we have to do is run xmodmap at a
suitable time, either by calling it in .xinitrc or by otherwise
executing it before the X session gets underway. I ended up adding a
line to ~/.fluxbox/startup that ran xmodmap. Now I
have my preferred key bindings in both console and graphical
environments.


Summa Total


I'm quite pleased at how this has all turned out. The laptop is lean
and mean. Battery life (even with 'new' batteries) is a bit
underwhelming, but then the original battery benchmarks didn't take into
account the (likely considerable) current draw of a PCMCIA device with a
radio transmitter. I'm sure I could lock this down and squeeze more
milliamperes out of it (especially for train commutes) but at the
moment, things are pretty much as I want them to be.


The next step will be for me to learn how to use LaTeX more
effectively, so I can take my notes in vim and use LaTeX to produce
beautiful study guides.


More fun from my new favorite Linux user
self, camphone, eye
[info]ouij
So finally, a substantive response! technical details snipped, but here's my response:


> But, since my flame was based on a fallacy, it would seem like I owe you
> an answer.

I'm glad that you have relented in your wrath and can condescend
actually to answer a straightforward question. I understand that you've
been using computers for longer than I've been using air, and as such,
your time on the planet is valuable and can't be wasted responding to
the likes of me.

I'll have a look at loadkeys.

I RTFMed already, you pompous jackass
self, camphone, eye
[info]ouij
This is why I hate the Linux community sometimes.


> If you want to do something like that....Figure It Out For Yourself!
>
> I will give you a hint. Look at the man pages for xmodmap and xev. The
> xmodmap man page give you an example about how to swap Caps Lock with
> Left Control; you should be able to figire out the rest. Put it in a
> shell script and run it from the program that starts up your X sessions
> or by hand.


This acknowledges my receipt of your wonderfully helpful RTFM for
Xmodmap, which I've already done.

The problem is that I'm not doing it for X; I would like to do it in a
regular, non-X terminal in Ubuntu Dapper.

I have tried editing /etc/console-tools/remap but have had no success
at remapping, even if I use the example line. . .


>
> Note that the key to the left of the A key should be a Control Key, not
> an escape.

. . . which is provided in the comments to /etc/console-tools/remap.
Not that you care, but I'd like to use vim rather than emacs, and the
esc key on my laptop keyboard is small and tough to reach. I'm sure
I've violated some taboo, but you know what? I'm not sure I really
care.

I would otherwise wish you a safe and warm evening, but I suspect the
burning fire of your Linux skills, so recently kindled by your skillful
use of an RTFM bomb on me, will keep you plenty warm.
>
>
>
>
> >OK Novaluggers:
> >
> >how does one change one's keymap so that "Capslock" becomes "escape" in the regular console?
> >
> >I know that keymaps are stored in /usr/share/keymaps/ as gzipped text files, but how are these read/loaded at startup? What files would I have to edit and what script would I have to execute?
> >
> >I know that in X sessions, I'd have to use an xmodmap script, but I'm really looking to change the keymapping globally--both in and out of X.
> >
> >Running Ubuntu Edgy (maybe feisty soon, when/if I sort out a wireless problem).

when the bugs come out to play
self, camphone, eye
[info]ouij
I should really kick back and listen to some Enya. Anything by Enya...except maybe "Orinoco Flow." Because if anything flows in post-Breezy kernels. . . Orinoco is not it.

For those of you who've been on #ubuntuforums lately, you've probably noticed that I've been irritable AND cynical in more than my usual measures lately. The ghettolappy--whose hostname is now being changed to hooptie--has no network connection other than my old 802.11b card (the "Orinoco" in question here).

Apparently, the kernel devs among others feel that since nobody uses Orinoco any more, we can be safely abandoned. From the Ubuntu bugtracker at Launchpad, there appears to be a metric shitload of bugs with Orinoco/hostap/prism2. Many of them are old--kernel 2.6.15, where Edgy's kernel is 2.6.17-11.

My problem seems to be related; DHCLIENT will fail 29 out of 30 boots. On the 30th boot, DHCLIENT will succeed, and I will have exactly zero idea why it did so, other than freaky voodoo. Edgy loads orinoco, orinoco_cs, hermes, hostap, and hostap_cs modules on boot--and from much nerd-fu in /etc/modprobe.d/blacklist and pccardctl ls I have determined that I really DO need to run orinoco rather than all the other crap.

When the thing doesn't work--which is most of the time--the wireless card associates with the access point just fine, but DHCLIENT keeps on failing.

I'd file a bug report myself--I spend last night methodically logging & testing everything with a bare Edgy install--but I'm not sure I'm not being duplicative. I can also confirm similar anguish with current feisty kernels, but I haven't yet had the chance to be as methodical in my testing.

Worse, it doesn't seem that I'll get any relief any time soon:
This is clearly an upstream bug in the hostap kernel module. So please make sure you have got a prism based card with this ID and send the pccardctl ident output to the linux-pcmcia list so the appropriate string based matches get extended.
I guess it's not that easy to make a generic fix for this as one has to determine if the card is hermes/prism based while probing.



I'm really grumpy about this--more than I should be. I mean, I could just go buy an atheros card and be done with it, but atheros uses madwifi and non-free firmware, and I was feeling quite chuffed that I would be able to run a totally-free-software laptop. Bad implementation hurts more than non-implementation, I guess. What hurts most of all is outright regression, which is what we seem to be seeing here with Orinoco in the kernel.

Home