Rebooting The Magic SysRq Way


[Cory Wright] shares a tip on how to reboot a system with a failed hard drive remotely. The magic SysRq key is a linux kernel feature that lets you perform a number of interesting operations. If you’re working on a remote system where the disk has failed, you won’t have access to the reboot or shutdown commands. You can issue keystrokes to the magic SysRq device in /proc though, so you can send a hard reboot directly to the kernel with no disk access required.

The Wikipedia entry includes a handy tip on how to properly restart a otherwise frozen machine. It should save you from having to fsck the next time around.

[photo: Joshua Davis]

Data Manipulation With Sprog


Linux Journal’s [Mike Diehl] pointed out an interesting tool for manipulating data: Sprog. Sprog lets you assemble machines to complete specific data processing tasks. You snap together gears that read input data, process the data in different ways, and then output the results. The input could be a file, URL, database query results, or even MIDI notes. For processing you could be matching patterns, selecting csv columns, converting to uppercase, or executing arbitrary Perl code amongst many other options. Finally the output could be shown in a text window, inserted into a database, written to a file, or sent to your spreadsheet application. Sprog’s site has a section for user uploaded gears and a recipe section for examples like this crossword puzzle solver. Everything Sprog does could be done with scripting, but this is a simple graphical tool that could help you solve a problem without having to know the gory machinery behind it.