Linux Block I/O Scheduler Interview

linux, software engineering No Comments »

Kernel Trap has a great interview with the maintainer of the Linux Block IO layer. He discusses some of the limitations in the current I/O schedulers, and how they can be swapped out dynamically at runtime.

I found the following particularly informative:

“Splice has a host of applications. It can completely replace the bad hack that is sendfile(), which is an extremely limited zero copy interface for sending a file over the network. The neat thing about using pipes as the buffers, is that you have a known interface to work with and a way to tie things together intuitively. A good and easy to understand example is a live TV setup, where you have a driver for your TV encoder (lets call that /dev/tvcapture) and a driver for your TV decoder (lets call that /dev/tvout. Say you want to watch live TV while storing the contents to a file for pausing or rewind purposes, you could describe that as easy as:”

$ splice-in /dev/tvcapture | splice-tee out.mpg | splice-out /dev/tvout

“The first step will open /dev/tvcapture and splice that file descriptor to STDOUT. The second will duplicate the page references from the STDIN pipe, splicing the first to the output file and splicing the second to STDOUT. Finally, the last step will splice STDIN to a file descriptor for /dev/tvout. The data never needs to be copied around, we simply move page references around inside the kernel. It’s like building with Lego blocks :-)”

Entertaining like a Canadian Diplomat

humor, random 1 Comment »

I recently ran across some rather amusing Amazon reviews from some madman genius. Here is a sample:

Margaret Dickenson is the wife of a Canadian diplomat. I learned from her book the hierarchical placement of guests around the dinner table that diplomats use. The most important sits to the right of the host, the second most important to the left. I have used this dinner table tactic to divide and conquer my guests, making them jealous of each other for my attention. I had Jeremy Saltmaven over for vermouth the other day and made him sit to my left, leaving a vacancy to the right. With this subtle trick I suspect I probably let Jeremy Saltmaven know he needs to give me more finery to secure my favour. Margaret Dickenson also explores dinner party themes, but this is where I went soft on the book. For my Hieronymus Bosch themed party, I assembled a nice costume from one of Bosch’s panels. I heard the first knock at the door, and hurriedly threw on my bird mask, mounted a copper cauldron on my head, and leapt up onto my stilts. In the process of taking my first step I spilled headfirst into the front door, misjudging the weight imbalance of the cauldron on my neck. My guests later told me they first heard some shuffling, the single sonorous knell as of a large bell, and then nothing. After waiting patiently on the porch for 5 minutes, it took them a few moments longer than normal to open the front door, heaving it, unwittingly shifting my dumped motionless body across the vestibule floor.

So, Margaret Dickenson, that’s why I can’t give this book anything higher than 3 stars.

Oracle Install Buttons Don’t Work

oracle, troubleshooting 2 Comments »

Today, I was attempting to uninstall/upgrade Oracle Enterprise Manager 10g on a Solaris 8 Sparc server, and spent well over an hour trying to get the display exported properly to my MacBook Pro. First, the OSX X11 component doesn’t seem to play nicely with the Oracle ‘Universal’ Installer, so I booted up Red Hat Enterprise Linux in a Parallels Desktop and used ssh to export the display.

Then, everything came up fine, but I couldn’t click any of ‘Next’, ‘Installed Products’, or even ‘Help’. It makes me wonder about the rest of Oracle when the installer buttons don’t work right, I mean that’s so hard to test and all….

Anyway, after searching the web the only recommendations I could find for this problem (going back at least 6 years) were:

  • Turn off your numlock key (no, seriously)
  • Try a different window manager
  • Type: export LANG=C at the shell prompt before launching runInstaller

After trying all of these, including booting into Ubuntu, nothing was working. Out of desperation, I booted into Knoppix, exported the display and everything worked the first try. Ubuntu and RHEL both use Gnome and Knoppix uses KDE, so I guess the ‘try a different window manager’ is the solution.

Die Oracle, Die. Hope this helps someone Googling out there.

Cyclomatic complexity of Django

python, software engineering No Comments »

Gary Wilson has written up a post detailing the cyclomatic complexity of Django (the Python web dev framework).

Wikipedia defines cyclomatic complexity as:

Cyclomatic complexity is a software metric (measurement) in computational complexity theory. It was developed by Thomas McCabe and is used to measure the complexity of a program. It directly measures the number of linearly independent paths through a program’s source code.

The concept, although not the method, is somewhat similar to that of general text complexity measured by the Flesch-Kincaid Readability Test.

Cyclomatic complexity is computed using a graph that describes the control flow of the program. The nodes of the graph correspond to the commands of a program. A directed edge connects two nodes if the second command might be executed immediately after the first command.

It isn’t often that you see software engineering metrics applied to open source projects. I wonder why that is?

Snow in Seattle (again)

seattle No Comments »

Seattle Snow!

Yes, it is snowing in Seattle, again. People are already freaking out. Should be fun tomorrow.

I wonder if we can adopt him

random No Comments »

Hello Everyone,

This morning a crazy man wearing tan pants, tan shirt, baseball cap, and sneakers bolted through security and managed to get up the elevators before anyone could stop him. He has been raiding the first aid kits mounted in the hallways, and pulling the blue phones off the walls. If you see this man please contact security and let me know about it.

If you are going to be the last person to leave of the day please check your room to insure that you really are the last person, then double check the lock.

Thank you

WP Theme & Icons by N.Design Studio
Entries RSS Comments RSS Log in