« April 2008 | Main

May 11, 2008

One Random Saturday

Five

Busy with on-call duties earlier this week, recovered Saturday.

May 09, 2008

Lack of Safety at Eastlake & Fuhrman

From: Jeremy Mates <jmates@sial.org>
Date: Fri, 9 May 2008 15:18:55 -0700
To: nick.licata@seattle.gov, sally.clark@seattle.gov,
        richard.conlin@seattle.gov, david.della@seattle.gov,
        richard.mciver@seattle.gov, tom.rasmussen@seattle.gov,
        peter.steinbrueck@seattle.gov, carbina.resendez@seattle.gov,
        m.j.kelly@cascadebicycleclub.org
Subject: Bicycle Safety Improvements at Eastlake & Fuhrman?

How many more bicyclists must die, or be injured, before the city
improves the safety of the Eastlake & Fuhrman intersection for
bicyclists and pedestrians?

http://www2.seattle.gov/fire/realTime911/getRecsForDatePub.asp?action=Today&incDate=&rad1=des

  5/9/2008 2:51:31 PM F080040691 E17 M16
  Eastlake Av E / Fuhrman Av E Medic Response

Thank you,
Jeremy Mates

Bryce Lewis died at this intersection on 9/7/2007:

The crash site, an intersection that sees 30,000 cars a day, is notoriously dangerous for cyclists ("scary as shit," one Point 83 poster called it). Although Seattle Department of Transportation (SDOT) spokesman Gregg Hirakawa says SDOT has no specific records indicating that the intersection of Eastlake and Fuhrman avenues is more dangerous than other trouble spots. (SDOT doesn't keep crash statistics by intersection.) "This is a major connection [for cyclists], and it needs improvement," says David Hiller, advocacy director for the Cascade Bicycle Club.

Update: Councilmember Jan Drago (chair, Transportation Committee) and Grace Crunican (Director of the Seattle Department of Transportation) are the most appropriate contacts to voice concern over this intersection.

Technorati Tags:

May 08, 2008

Seattle Chess Resource

Chess ConfusionNorthwest Chess: Chess News from Washington and Oregon. My chess playing appears to greatly suffer during Winter, perhaps related to the general lack of sunlight? Also very blunder prone when on-call…

May 06, 2008

System Debugging

Computer system debugging benefits from both experience with and knowledge of the system. It also benefits from many questions being asked, until a cause is known, or at least potential causes being eliminated. As an example, a junior admin may note that a filesystem fails to unmount, and eventually ask a senior admin for help.

(As an aside, learning how to ask smart questions can help avoid time wasted over an “it doesn’t work” exchange.)

Possible workflow for a filesystem failing to unmount:

A good admin will ask many questions, and try to answer all of them, either by asking, or if possible, running the commands. The exact order of steps is not important so much as checking a wide variety of symptoms. Another admin may check df to see if the filesystem is actually mounted before running sudo lsof | grep mountpoint for open files. These commands are (usually) quick to run, and (usually) additional terminals can be opened to continue should one command be slow or block.

Junior admins should spend as much time learning the system as possible. Books such as the UNIX System Administration Handbook should help, as will delving through the manuals or other available vendor documentation. Consider also reading Unix Debugging Tips.

Quick System Overview

Be aware that an error message may not be from the problem, but something affected by the real problem. This is why some initial time spent getting a feel for the system will almost always help:

  • How long has the system been running? Use the uptime command, which also shows the system load. (Old RedHat 7.2 systems, if left running long enough, would eventually show 100% CPU usage due to a procps bug.)

  • Abnormal CPU, disk, or memory use? top, free on Linux, vmstat 1 or iostat can all be consulted in a matter of seconds. Processes stuck in D state or high I/O wait times may indicate an overburdened disk system.

    Note: df and similar commands can hang on a broken NFS mount. With multiple SSH or a screen session, this probably is not a concern. If one only has a single console link, the blocked df process could hamper diagnostics.

  • Anything strange in the system logs? This is more relevant should the system have recently rebooted. Check dmesg, and wherever else the logging daemon sends this information.

  • RAID or SAN or LVM state? More relevant on database and file server systems than throwaway desktop or service nodes. Due to the plethora of different arrays and devices possible here, best to write a wrapper script that figures out what the system has, and emits appropriate diagnostics.

Monitoring can help collect and alarm on abnormal CPU, memory, or disk usage. However, these should not page, as a busy but perfectly operational system may show high CPU, and waking someone up for false alarms hurts their ability to work on real issues.

May 05, 2008

Lode Runner

Reaching level 150 in Lode Runner is possible; I never had the patience, nor time to leave the Apple //e running for the duration required. Thanks to a virtual machine, the game can be saved and resumed as necessary. Following level 150, the levels start over again, except the enemies are faster. This happens again at level 300.

Level 52 is tricky the second time through, and requires cutting corners to reach the falling enemy in time. The third time through, a different strategy is required, as the enemy is now too fast to reach in time. Instead, one must dig to get past the upper two enemies, then fall into the usual pattern.

Curtains fall at level 357, where the now twice sped enemy always intercepts one before crossing the first ladder (only eight bits were allocated for the level counter, as following level 256, it wraps, hence level 101 being displayed):

Lode Runner Level 357

Note: lode_runner1.po on the Asimov Apple //e archive is corrupt at level 130-something. I am using lode_runner.do.gz. If paranoid, advance through the levels with control+U or control+6 to confirm the levels look right.

Next, Championship Lode Runner.

May 04, 2008

Polaroid: Film & Company

The Film

Do not much like Polaroid film. To be fair, I am using a Holgaroid back to a Holga. Peeves: loading the film is tricky, though worse is extracting the film for exposure, as the paper pull tabs risk breaking, leaving the film stranded, and the ninth exposure usually pulls the tenth out along with it. Another problem: odd streaks down the film, which appear to line up with the pull tab paper: somehow this is getting compressed against the film through the rollers?

Dream

Film quality excellent, with a deep glossy black, though getting the exposure right was very tricky, as the Holgaroid metered nothing like my DSLR measured. A incident light meter should give better readings, but I do not own one.

Digital or regular film photography, combined with post processing and glossy printing, while slower, should produce similar effects. I could see using Polaroid to take test shots for medium or large format needs. However! Given that Polaroid is going the way of the Dodo, best to avoid the resulting high film prices until and if an instant film market emerges following 2009.

The Company

“Dire financial straits notwithstanding, Polaroid paid senior executives and directors a total of $6.3 million in bonuses, consulting fees, and lump-sum pension payouts in the months before the [bankruptcy] filing. Payments included $1.7 million in incentive comp to former CEO DiCamillo, while former CFO Judy Boynton got $300,000 in severance, a $510,000 stock award, and a $638,000 lump-sum pension payout. (Boynton, now the CFO of Royal Dutch/Shell Group, is listed as an unsecured creditor, for an additional severance of $600,000 she is still owed.)”

“Polaroid retirees had feared the results of a sale to OEP, and that fear was justified. After June 28, the company's cash balance plan was terminated and handed over to the federal Pension Benefit Guarantee Corp., meaning many retirees had their pension payments slashed. Employees on long-term disability received letters informing them that they would not be hired by the new company and that their benefits were being terminated. Indeed, the Massachusetts attorney general's office had difficulty convincing OEP, as owner of the new Polaroid, to sponsor the retirees' supplemental Medicare plan, even though that sponsorship costs nothing except time spent keeping the books.”

    — What’s Wrong with This Picture?

May 03, 2008

Reading

The Kindle from Amazon is now in stock. I’ve only seen one or two floating around work. The device looks interesting, though is not on my immediate to buy list, mainly due to the stacks of real books I need to read. Most recently:

Based on conversations with our Dublin staff, Dublin is very much so not the town James Joyce wrote about.

May 02, 2008

Big Blobs

Perl coding can evolve towards the use of a Big Blob—a large structure of deeply nested data—once perldsc and perllol are mastered. That is, input from various sources is assembled into the Big Blob, any required munging performed, and the data structure iterated over to emit some sort of output or change. This method does work, though suffers from a number of avoidable flaws.

if ( $line =~ m/^ { $/x ) { $rule_target[-1]->[-1]->{_subrules} = []; push @rule_target, $rule_target[-1]->[-1]->{_subrules}; }

First, consider instead providing an Object Oriented interface, thus hiding the Big Blob. However, this may defeat a “well, I’m just trying to mangle X into Y, not waste time with class struggles” coding effort. Whether OO makes sense depends on the project. A standalone data conversion script probably does not justify OO. Code that other code will use, or a service interface, especially one used by other groups or users, will likely benefit from OO.

Secondly, Big Blobs could be a solution looking for a problem. The coder knows how to parse data into the blob, then iterate over the mess, but never considers whether a blob should have been used.

my %big_blob = load_from_file($filename); upload_to_database(\%big_blob);

In many cases, the entirety of data need not be loaded into memory, and instead only the minimum necessary data retained in memory before acting on it:

while <$fh> { my %line_data; # ... parse line into line_data hash # upload line_data contents to database $db->... } continue { if ($. % 1000) { $db->commit(); } }

This method scales better, as it no longer is bound by memory, and will not require DB_File or refactoring should the data set exceed available memory. The question: “do I really need to parse all the data to memory, or is there a more efficient solution?” will help prevent inappropriate use of Big Blobs.

Technorati Tags:

May 01, 2008

Chart & Graph

Chart

Choice

No, not Visio. Visio drives me batty. I use OmniGraffle, except at work.

Graph

Graphjam.

Technorati Tags: