Friday, March 23, 2007

The Madness of March (Part II)

If you write something that says Part I in the title, then you've got to do a “Part II”. Unless you're Mel Brooks, of course. So let's talk about last night's Kansas – Southern Illinois game:

God, it was ugly. I know, that's the way SIU plays, and I say “more power to you,” except when I actually have to watch the thing. There was no offensive flow on either side. Bodies flew frequently. No one was seriously hurt because, most likely, he was falling on someone who was already down on the floor.

The officiating contributed to this, I think. Off the ball the game was called very tightly. I don't think I've ever seen so many illegal screen calls in a major game. However, near the ball, you could practically assault people with a pipe wrench and not get a call. This helped SIU more than it hurt, but that's not their fault.

KU did just enough to win. They had a very few near-transition baskets. Several times they tried to score off transition in a 2-on-3 3-on-4 situation, and they'd inevitably get stuffed. SIU did everything that they needed to do to win, except get the ball in the basket two more times. KU was lucky, without a doubt. But just about every winning team needs a bit of luck, so they say.

Maybe this is the year?

Aaagh! I've violated the pessimism rule! We're doomed!

Sunday, March 18, 2007

The Madness of March (Part I)

Well, here I sit, watching the Kentucky-Kansas game on my computer. Currently it's 15-14 for the good guys.

Historically, of course, this series has not been a lot of fun for KU. However, the last two years have been OK. Of course, during the last two years the season ended before this weekend.

(19-19 at the 8 minute TV timeout.)

Anyway, I want to take this opportunity to continue to break all the basic rules of blogging, go completely off topic, and give you one of those bullet-lists of thoughts about the tournament:

  • The ACC, as even Billy “Duke University” Packer, admits today, was over-rated. Duke especially. Seven teams in, only one remains. Of course, if I had my druthers, no league would get more than four teams into the tournament. I mean, really, if you can't finish in the top three/four or win you conference tournament, why should we think you can win the Big Dance?
  • 28-25 KU at the four minute timeout
  • The other 3 number-one seeds had some nervous moments getting out of the second round. Eventually we'll see a number 16 seed beat a number one, and even get into the final four. Things are that balanced.
  • CBS's March Madness On Demand (MMOD) works well on the Linux box, using the mplayer plugin. Oddly, it doesn't work on the Mac, because OS X doesn't support Windows Media Player, and I'm not going to search around for the appropriate plugin. So I'm typing this stuff up on the Mac while I watch the game on Hal. This also allows me to avoid watching when it gets too tense: I just work on this entry.
  • Sports Illustrated picked KU to win it all. Well, I guess I won't have to worry then.
  • 36-30 KU at the half. Kentucky's basically keeping KU from running, and KU had some early frustration charging fouls. Nevertheless, KU isn't playing badly, and Billy thinks UK is getting tired. We'll see. Hopefully KU learned enough from the two Texas games so they don't fold (see the Texas A&M game) if the 'Cats make a run. If you asked me at the beginning if I'd take a 6 point lead at half, I'd have said “hell yes”, of course.
  • KU 54 UK 42 with 14:11 left in the half. No idea how. I spent halftime and the first few minutes of play vacuuming rabbit-droppings off the back porch — don't ask.
  • Irritatingly, the CBS live scoreboard and play-by-play are now about 80 seconds game-time ahead of the video. So I know what's about to happen. Actually, when I think about it, this is a good thing, since I know when not to look.
  • If I was going to really reform the NCAA tournament, I'd let everyone in. Make it like a state high-school tournament. It's almost that way now. Is there a conference that doesn't have a tournament? If not, then the only teams that don't have a final chance at the dance are independents. Even Notre Dame, the most famous independent of them all, plays in the Big East for the basketball tournament.
  • 56-43 at the 12 minute timeout.
  • Another thing I'd do is take the money out of the equation. Teams should only get expenses for the players (plus parents and siblings), coaches (ditto), cheerleaders, band, and a few VIPs (A.D., President, Governor, etc.). All the other money goes into the NCAA pot, and it's divided equally among all the teams in Division I. That way there's not as much pressure to cheat to win. Of course, this has about as much chance of happening as Arnold has of becoming President.
  • One of the irritating things about MMOD on the Linux box is that the mplayer-plugin doesn't play unless it's visible. So I can't move to another area of FVWM's virtual desktop, nor can I completely cover the video part of the browser window. Which is why I'm typing this on the Mac.
  • 64-51 at the 7:38 TO, but Kentucky's at the line. Still waiting for them to make a run.
  • In baseball, it's often the case that the winning team will score more runs in one inning than the losers score in the whole game. Basketball, too, is a game of streaks. I haven't seen a study of it, but I'd guess that in most games the winner has one or more runs where they score 8+ points in a row. It's partly talent, partly luck. The example is the Syracuse-KU title game in 2003, where KU was the superior team, but Carmelo and company kept running off streaks that force Kansas to keep coming back.
  • Scoreboard says that Kentucky only has 6 team fouls to KU's 8, which is a bit surprising, considering UK has so many players in foul trouble.
  • In other games, looks like Texas is going home, which means that Kevin Durant is playing his last college game. He's going to be a great one in the NBA if he gets on a team with some support.
  • 71-56 at 5:46. KU now has 10 team fouls, which Billy and Jim somehow haven't noticed. If Kentucky gets on a run, they get two shoots on all fouls. Of course, the 'Cats show no sign of making a run, but that doesn't mean they don't have one in them. KU hasn't exactly broken away, and a 15-point lead is only a five-possession game.
  • Speaking of Billy and Jim, who decided that Chicago was the prime site this weekend? Not that I don't think so, but doesn't Billy ACC really belongs in Carolina. They aren't really talking about the game, anyway, just the tradition of the teams. Which is fine, but there's a friggin' game going on, and it's not totally out of reach for UK, at least not yet: 76-61 at 4:12, and Randolph Morris has 18 points to go with his three fouls.
  • KU stops a 7-0 Kentucky run (see?) with a Collins FG. 78-63 with 2:52 left. Maybe? I keep flashing back to the 1978 game at Lexington, where KU was ahead by about 6 points with a minute to play, no three-point shot, no shot clock, clock keeps running after a basket — and lost anyway. 6 points/1 minute/old rules < 15 points/3 minutes/new rules. It's still a five possession game, and I don't like KU's historic freethrow shooting.
  • OTOH, now it's 81-66 with 1:50 left. KU basically blew a minute off the clock without losing ground. Not bad.
  • CBS, having learned nothing from the 2000 election, has put KU into the regional finals with 1:32 left. Of course, now it's 83-66.
  • The Chant is going through the crowd. Funny, when I was at KU we never did this during the game. I guess it's sort of like Red Auerbach's cigar.
  • Finally, it's over: KU 88, UK 76. And KU's now 6-19 in the series, with the last three in a row.
  • And they're waving the wheat. Nor more than four more nights of agony left this year.

Well, thanks to all of you that stayed through the whole entry. Sometime next week we'll get back to the Linux part of the blog.

Saturday, March 17, 2007

And We're Back

... from Denver. Actually, I've been back for a week, but I've had a bad cold for all of that time and just haven't been up to posting.

I want to talk about the NCAA tournament (KU plays Kentucky on Sunday, Joy.), but first I want to mention a few things about the trip, which, as you may recall, took me from DC to Denver to Holyrood (KS) back to Denver to DC.

  • The trip started out uneventfully, as I walked up to the United Counter at Former-Republican-President-Capital-City-National-Airport, where I was informed that my flight had been canceled and that I was a really bad boy because I was too late arriving to board the flight which left an hour before my scheduled flight. So they gave me a $58 cab voucher and sent me on my way to Dulles, where I got a direct flight to Denver, meaning I didn't have to stopover in Chicago. It also gave me time to have a leisurely breakfast at Dulles, rather than a quick lunch at O'Hare, so I was more than satisfied. United, I suspect, lost out on the deal.
  • Acre for acre, the flattest country in the world is in — Eastern Colorado. Denver, famously, is 5,280 feet above sea level. So, claims its sign, is a town 100 miles to the east on I-70. (Sorry, forgot the name.) On any 100 mile stretch of I-70 in Kansas you're going to change altitude by at least 1,000 feet. So don't give me any of this flatter than a pancake crap.
  • Nevertheless, I love the plains. When I picked up my rental car at DEN, the clerk looked at my driver's license, saw I was from Maryland, and said, “I lived there, once. Too many trees.” I agree. Between Denver and Salina, when you do get to the top of a hill, even an overpass, you can, indeed, see for miles and miles and miles and miles and miles.
  • Kansas was windy — how windy, you ask? So windy that everyone complained about it. I don't think the wind dropped below 30 mph from Thursday through Saturday. Sunday was a bit better, but I was driving back to Denver, then.
  • Just after you pass the “Denver 100” sign on I-70, you can see Pike's Peak. Impressive. It's only 50-60 miles away, but still. Then you get to see the whole front range all the way into the airport.
  • Denver's not a bad town. 16th Street is set up as a mile-long open mall, and it's reasonably easy to walk. The best restaurants, though, are off of 16th. Ask where they are at your hotel, because if you wander too far off of 16th you get into some pretty rough areas really quickly.
  • Denver has one of the greatest innovations in city planning I've ever seen: the caddycorner cross walk. At busy four-way intersections, once in every stoplight cycle all traffic lights turn red. Then, if you look across to the far street corner, you'll see one of those little white men shinning at you. You're then allowed to walk directly across the center of the intersection to that corner. This cuts down dramatically on jaywalking. I hope other cities adopt the practice.
  • The meeting went pretty well. The session where I gave my talk was populated by old friends, so we had a lot of friendly discussion, back-and-forth, and catfighting. A fun time was had by all, and we might even get a few papers out of the deal.
  • Flying back was surprisingly uneventful, except that I couldn't watch the movie (A Night at the Museum, I believe) because the headphone connection on my armrest didn't work. Oh well, it will be out on pay-per-view shortly, anyway.
  • Of course, the DST time change meant that I went through a 3-hour time change, meaning that I was totally jet-lagged. On top of that, a came down with the aforementioned cold, so I've been completely wiped out for the last week. I only revived about 10 minutes into the first half of the KU-Niagara game, when it became apparent that KU was actually going to get to play on a weekend in March for the first time in three years.

So that's what I've been doing lately. More on basketball tomorrow, and maybe we'll even get to computing sometime next week.

Tuesday, February 27, 2007

Hi, Rocky Mountains!

I'm off to Kansas to see the family and then to Denver for the American Physical Society March Meeting. I'll try to post something next week.

Sunday, February 25, 2007

Did Bono Approve This?

So the other day I went over to Staples and bought a 2GB SanDisk Cruzer Micro USB Flash Drive, for the pretty low price of $24.98 (including rebate, which Staples makes ridiculously easy). Really nice price, considering I once bought a 256 MB drive for $60.

I have no complaints with the drive. I deleted the junk software that SanDisk put on the drive, and it works just fine under Linux, and on the Mac. I love it. It fits on my keychain, has a retractable USB plug, and looks cute. It'll carry around just about anything I want.

On the Mac, though, two partitions show up. The first is just the partition I see in Linux. The second, however, is labeled U3 and contains the software I deleted off the main partition: the windows only U3 Launchpad and application software. In a partition that Linux doesn't see and Mac OS X won't touch.

Plug this into a Windows XP box and it autolaunches. OK, you can remove the software, but only under windows, and only if Launchpad is running. I'm scared to death to stick it into our one and only XP box to see if I can do it. Apparently one can reformat the drive under Linux, but if I screw it up, I've got a $25 bit of plastic and silicon that's not heavy enough to make a good paperweight.

So what's the problem? Leave it alone, right? But big pendrives are great for Sneakernet applications. Suppose I want to carry a big file to a friend's Windows box? Up pops Launchpad, which should at least freak him out, if it doesn't cause any other problems. I know U3 vets all the software it allows on the drive, but it's still running programs on a friend's computer that he didn't give me permission to run. And then there is our own XP box, Hal's evil twin, which has the nice printer attached to it. I'd really like to Sneaker my files onto it, but not with this drive as long as it has U3 on it.

So I ask my small community of readers: Anyone successfully reformat a 2GB Cruzer, removed the U3 stuff, and still have a drive that can be read under Linux, OS X, and Windows? Leave details in the comments.

Monday, February 19, 2007

Almost One Line Archiving

This is one of those “well, if I don't write it down, I'll forget it,” posts, but someone else may find it helpful as well.

I recently did a bunch of updates on my favorite website. I keep a duplicate copy of the site where I can work on it without making a big mess of the active site. All of the files are in a directory we'll call $HOME/website. So I'm going to modify the files in my local copy of $HOME/website, check to make sure I haven't frakked anything, and then upload everything to the hosting computer, pause, take a deep breath and pray I really haven't frakked anything, and update the real website.

So what I want to create is a tarball consisting of all the files I've changed in $HOME/website since the last time I did an update. This is an almost one-liner. I say that because you need to do one step before you make any changes at all:

$ touch $HOME/newupdates

This creates a zero-length file. The important thing is that it will be older than any of the files you are about to change, and younger than any of the files that remain unchanged. If you have another file like this around, then you don't need this step.

Now make all the changes you want, making sure you have valid spelling, HTML, physics, tax advice, etc.

Now do the archive:

cd $HOME ; tar cvzf updates.tar.gz \
`find $HOME/website -type f -newer newupdates \
| xargs`; touch newupdates

(That's really all one line, of course, though you should be able to enter it as is with the backslashes.)

This uses the find command to list all regular (-type f) files in the directory $HOME/website which are newer than newupdates, then uses xargs to put them into a single string, and creates a gzipped tarball file named updates.tar.gz. Then it again touches the newupdates file, so that the next time you do this you won't pick up the files you've already archived.

Then copy updates.tar.gz wherever you want it.

Tuesday, February 13, 2007

X-ing out Tabs

In Firefox/Swiftfox 2.0, by default the active tab has a big red "X" beside it. Click on the X and the tab disappears. The disadvantage of this is that one can't delete a tab without making it active. A more desirable behavior would be to have an X in each tab, so you can delete the tab without opening it.

This hack is not mine, so I'll reference Geek to Live, where I found it. What you do is:

  1. In the address bar of the browser enter about:config
  2. In the Filter box that appears, enter the string browser.tabs.closeButtons
  3. Right-click the string that appears, and select Modify
  4. Change the number to "1" if you want an X in each tab, or to "3" if you want the Firefox 1.5 default behavior (one X, all the way to the right on the tab bar). Experimenting, "0" is the default 2.0 behavior, and "2" is no Xs at all.

The change should take effect as soon as you hit enter.

Saturday, February 10, 2007

The Perils of Packratitis

Well, the day started out promising. I'd slept well, read the paper, had breakfast, and headed downstairs with a cup of coffee to read my email.

Turn on the computer, and I'm greeted with a text screen including the words

Uncompressing Linux ...  OK, booting the kernel
[17179570.784000] Kernel panic - not syncing:  VFS : Unable to mount rootfs on unknown-block (0,0)
[17179570.784000]

and other such unpleasantness.

I remembered that a kernel upgrade had pushed through last night, so I suspected that was the trouble. After all, it was a kernel upgrade of Fedora that without sound for nearly a week a couple of years ago.

The new kernel is 2.6.15-28. (2.6.15 is the actual kernel version, the 28 is the latest Ubuntu fix.) So I shut off the box, turned it on again, and hit the ESC key when the option was offered. This brings up the GRUB menu, from which I selected the 2.6.15-27 kernel. Booting continued normally.

But what went wrong? How do I fix it? Well, after searching many forums, it appears that kernel panics happen for a lot more reasons than you'd expect, and have different causes. Mine? Well, after much searching, I was prompted to look at the GRUB menu, which is controlled by the file /boot/grub/menu.lst (that's an "ell", not a "one"). In there, I found these lines:

## ## End Default Options ##

title           Ubuntu, kernel 2.6.15-28-686
root            (hd0,0)
kernel          /vmlinuz-2.6.15-28-686 root=/dev/hda2 ro quiet splash
savedefault
boot

title           Ubuntu, kernel 2.6.15-28-686 (recovery mode)
root            (hd0,0)
kernel          /vmlinuz-2.6.15-28-686 root=/dev/hda2 ro single
boot

title           Ubuntu, kernel 2.6.15-27-686 (recovery mode)
root            (hd0,0)
kernel          /vmlinuz-2.6.15-27-686 root=/dev/hda2 ro single
initrd          /initrd.img-2.6.15-27-686
boot

title           Ubuntu, kernel 2.6.15-27-386
root            (hd0,0)
kernel          /vmlinuz-2.6.15-27-386 root=/dev/hda2 ro quiet splash
initrd          /initrd.img-2.6.15-27-386
savedefault
boot

See what's missing? The 15-28 kernel entries don't have the "initrd" lines. Simple enough, huh? This kernel update had problems. Maybe this manifested itself here by not updating the menu.lst file properly. Easy enough to fix, right? Just edit (as root) the menu.lst file, adding the line

initrd          /initrd.img-2.6.15-28-686

in the appropriate place.

Wrong. I got an edit error, suggesting that the file system was full. Oops.

The /boot sector is a separate partition. So see how full it really is:

$ df /boot
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/hda1                97826     97862         0 100% /boot

Oh boy. What's going on?

Well, I suffer from packratitis — the inability to throw out something that might be useful. Turns out that I had several copies of the old kernel. Well, more then several. It looks like I had a copy of every kernel since I first started with Ubuntu. Both i686 and i386 versions — though the later are completely unnecessary.

Go back to the old kernel, reboot, then go into synaptic and delete a few old kernel modules. The relevant packages are linux-image-version_number and linux-restricted-modules-version_number, where "version_number is something like 2.6.15... This freed up enough space so I could successfully edit the menu.lst file.

This time, when I booted, I got the message that the 2.6.15-28 compressed kernel was corrupted — obviously the install hadn't completed. So I went back to synaptic, reinstalled linux-image-2.16.15-28-686 and linux-restricted-modules-2.16.15-28-686, and, once again, rebooted.

Success. Finally.

Lessons learned?

  • You don't need every version of the kernel that comes down the pike. The upgrade process leaves the old kernel lying around for good and sufficient reason, as we have seen, but if a kernel is working well you can delete most of the older ones.
  • I don't think we need any of the 386 kernels. A Celeron chip is equivalent to at least a Pentium 4, so the 686 kernel should be sufficient.
  • Every once in a while, you need to check all your partitions to see how full they are getting.
  • Don't blame the upgrade process — at least until you've checked out the possibility that you've fraked yourself.
  • You know, it's kind of fun working on a broken computer — just like the old days when we booted "alternative" OSes on an Apple //e.
  • During my (as opposed to the kernel's) panic, I downloaded Slackware (still reading, Pete?). I tried installing it on my alternative Linux box. I failed, but I think I know why. It's certainly a more hands-on distribution. I will get it installed on the alternative Linux box, and at some time in the future I may change over entirely.

So fun's over, and we're back to running regular, updated Ubuntu Dapper. Stay tuned for more adventures in Linux debugging.

Sun's ODF Plug-In for Office

Linux Insider reports that Sun will provide an ODF plug-in for Microsoft Office 2003. Which means that I'll be able to send my OpenOffice.org files in their native format to those poor souls stuck with MS-Office. When they say "I can't read this," I reply, "sure you can. Here's the plug-in."

And then I say, "you know, the sofware I use isn't just free as in freedom. It's free as in beer, too.

Friday, February 09, 2007

Vista Marketing

Here's a good one: the Washington Post's tech writer Rob Pegoraro recently got Gateway to loan him a Vista-loaded laptop for review. Guess what? Vista claimed it was an illegitimate copy!. Wonderful. So either one of Microsoft's biggest suppliers is shipping pirated copies of Vista (extremely doubtful), or Vista's piracy-protection mechanism is fraked. Which makes me wonder what would happen if I bought one of those fancy new boxes Best Buy and Office Depot keep pushing at me in the Sunday supplement. I mean, if Microsoft can't make sure that reviewers get a legit copy of Vista, what about ordinary users?

Oh, wait. The next computer I buy might come with Windows, but after I tear it out by its DOS roots and install Linux I won't have any problem with piracy-protection software.

Never mind.

Tuesday, February 06, 2007

Plus, If He Wins, Catherine Zeta-Jones Will Be First Lady

From The Onion:

Mysterious Congressman Announces Dark Horse Candidacy

New Presidential Candidate

Sunday, February 04, 2007

Super Bowl XLI

Just a few random thoughts on the game:

  • Chicago did a pretty good job with its "If Rex Grossman is off the field he can't hurt us offense," but they lost sight of it in the fourth quarter, leading to defeat.
  • While I'm happy Tony Dungy and Payton Manning won, phrases like "second Super Bowl win in Colts' franchise history" stick in my craw. It's the first win for Indianapolis, OK? The phrase "in the middle of the night" still only means one thing in Maryland.
  • So much for playing the game in nice-weather venues. New York (well, Jersey) or DC (I mean Landover) would have been a lot better this week. It was football weather — cold.
  • I was going to give best commercial award to K-Fed, because nothing else caught my attention — I don't remember what he was advertising, either. But the two minute warning NFL in-house with Brett Favre was better, and the only memorable one in the lot.
  • Next Super Bowl? Ravens and Redskins. (If you believe that, boy, have I got some penny stocks to sell you.)

This Is Why Linus Is Way Cooler Than Bill Or Steve

Linux Kernel 2.6.20 Release Announcement

Thanks to LWN

gnuplot 4.2

gnuplot is one of those programs I can't live without. It's fair to say that 70% of the graphics I've published in my work were created with gnuplot, and the only reason that figure isn't higher is that I wrote a lot of papers before I found out about gnuplot.

The version supplied with Dapper is 4.0, but I found from an email that 4.2.rc4 was recently released. Going to the project home page I found that this release included support for animated GIFs, something that I was trying to create more or less by hand for an upcoming talk. Now expecting the new version to be available in Dapper is a bit much, so I went to SourceForge and downloaded the tarball. (Click on "Download gnuplot development," then on "4.2.rc4." It's not obvious.)

After a bit of tweaking, I found that I had to fire up synaptic and install the libreadline5-dev and libgd2-dev packages. These let me compile in readline support, so I can do things like tab-complete file names, and support for gif and png files, for the aforesaid animated gifs.

From there it's straightforward, using the checkinstall to create the .deb file:

$ untar gnuplot-4.2.rc4.tar.gz
$ cd gnuplot-4.2.rc4
$ ./configure --with-readline=gnu --enable-history-file
$ make
$ sudo checkinstall -D make install-strip

This makes, and installs,

gnuplot-4.2.rc4_4.2.rc4-1_i386.deb

which works. Once I get the paper cleared and presented, I'll see about putting up one of the animated gifs as an example.

Friday, February 02, 2007

Deleting the Double Green Line

Many blogs and web sites have been displaying ads in what I find is an annoying fashion. Selected words are underlined twice in green. When you run your mouse over them, an annoying popup appears, advertising something. Here's a random example.

(My favorite was a blog which had a phrase something like "overall this method works well," where overall was underlined and offered to sell me blue jeans with bibs.)

There outta be ways to block these things, and there are in fact many. These popups all have the name IntelliTXT on them, someplace. They are so ubiquitous that Firefox 2.0's Google search offers 11 different versions of the string "IntelliTXT *", most of which have to do with blocking, removing, or disabling the things.

As it turns out, Wikipedia has a good "stub" article, which includes blocking information. In my case, the easiest way to block everything is to use the Adblock extension for Firefox. Just add the string "*Intellitxt*" to Adblock's filter, reload the offending page, and the double green lines are gone.

Wikipedia: It's not just for truthiness.