Archive for the 'Geeky Peawee' category
Note to self:
June 3, 2008 2:28 pmNext time I go to have emacs auto-indent a 12,000 line FORTRAN77 source code, do it before I leave for the evening. It’s now 3:30, and it’s been chugging with roughly 85% of one of my workstation’s two cores for the past half hour.
Categories: Geeky Peawee
2 Comments »
So long, Open Solaris!
April 25, 2008 8:54 amI’ve been running OpenSolaris Nevada on my file server for a while now. While ZFS makes administration of filesystems beautiful, I’ve been disappointed with the zpool functionality.
In addition, administering the rest of Solaris is a maze of twisty passages, all alike. Things like Perl’s CPAN, which is supposed to have a high level of “JustWorks”, fails hard in Solaris (which includes both 5.6 and 5.8). Things like libtorrent/rtorrent and FLAC with Ogg support, which compile just fine on Mac, Linux, Cygwin, and OpenBSD, fail it hard under Solaris. I’ve been frustrated with all the little quirks of the system that just don’t seem to appear under other platforms. I’m underwhelmed by the SunPRO compiler set, and the system just feels *slow* to use, as compared to Linux on the same hardware.
So, using my handy-dandy external backup drive, I backed everything up, and installed the brand-new Ubuntu 8.04 on it, and while it’s back to mdraid and lvm, the rest of the sanity more than makes up for it.
Categories: Geeky Peawee
1 Comment »
Life without iTunes
April 7, 2008 2:46 pmApple’s walled garden works well for most people. I, unfortunately, am not most people.
This is my story.
As I’ve already discussed previously, iTunes has a certain amount of suck involved.
So, I’ve discovered Play, which sucks less in some ways, and sucks more in others. As so far, the more suckage hasn’t been so much of a concern for me yet, and after checking out the source code, it don’t look too hard to create some patches against. One of my “post-graduation to-dos”.
My CD collection sits as FLACs on my server drive, and Play handles it quite nicely, updating its sqlite database of music every time it starts up. To rip, I use sbooth.org’s Max, which includes the very excellent cdparanoia ripper and pretty good support for tagging, album art, and all the formats I’ve grown to love, such as FLAC.
Currently, there are a couple of weak links. Play doesn’t export playlists to plain text files (otherwise known as .m3u), and the built-in “Convert with Max” option only lets you select 10 tracks at a time. How am I supposed to convert 200-250 FLAC files into Ogg or MP3 to put on a portable player to bring around? Solution: the music library database is simply a sqlite database, which means I can hook up a Perl script to it and extract playlists like that, and run it through conv. For use with my iPod, I can simply make a small library in iTunes, and simply import into iTunes to copy to the little machine. No biggie. If I felt like it, I could most likely write an AppleScript to automate it for me.
CD burning? Same as with the iPod; just use iTunes to make it easy.
So far, I really haven’t missed it. Huzzah!
Categories: Geeky Peawee
No Comments »
Ben Franklin was an internet junkie.
February 22, 2008 5:16 pmiTunes headaches
February 19, 2008 2:34 pmAs you may guess, I run a mac. On the Macintosh, there really is only one music player in town: iTunes. Granted, there’s plenty others that will play music, but none that will manage it. I have enough music to make this a real issue. On Windows, there’s WMP, WinAmp, Foobar2000, and others I’m sure I’m missing. On Mac, there’s… iTunes.
iTunes follows the traditional 90/10 rule of most things Apple: do 90% of everything perfectly, and utterly fail at the last 10%. In this case, it fails at complex library management. Perhaps I’m setting the bar too high here, but Apple’s software is unable to intelligently re-build its library, based on changes to the library directory. For instance: Chip finds some music licensed under Creative Commons, and uploads it to me, directly into my music directory. On just about all the other players I’ve seen, I’m able to either re-index the music directory automagically, or even cooler, the player detects a delta between the current library index and what it sees in the directory, and rebuilds (Hello, Amarok!). As far as I can tell, iTunes does not do this. To add to the mess, on trying to import my library into iTunes fresh, it actually makes iTunes seize up about halfway through. This is rather unacceptable.
Also, it appears that it doesn’t include music that it can play but lacks metadata on. The very excellent band Everybody Else’s CD is one that I ripped to FLAC. Now, when I want to listen to them, I have to load up VLC. It’s not that I mind VLC so much, but it leaves something to be desired when working through my media collection.
My solution: once I’ve the time, hopefully I can whip up something resembling a media player for MacOS. I might, if persuaded, make it work cross-platform, but I don’t care too much about Windows, and the perfect media player already exists under Linux.
Categories: Geeky Peawee
1 Comment »
Beautiful Fortran
February 6, 2008 9:33 pmOne of my more favored software development blogs is Beautiful Code. The concept is that code that is properly elegant is going to be readable, functional, and most of all, working correctly. There’s a lot of focusing on unit testing, proper OO design techniques, and how to squeeze an elegant solution out of the nastiest conditions.
Well, I believe I have a Nasty Condition.
I hack on FORTRAN and Fortran at work, after getting out of the IT support gig. What’s the difference between the capitalizations? Easy. FORTRAN references the language pre-1990 (1950’s through to 1990), and Fortran is the more modern Fortran 90/95/2003 standards.
Fortran 90/95/2003 isn’t that bad to work on, actually. For its primary purpose (running numerical computations on hideously expensive computers), it works really well, and makes me a happy hacker.
FORTRAN helps to create ugly code. Complex looping and branching statements are much more difficult than in other languages, and many FORTRAN coders cut their teeth on it when the language was still implemented via punchcards, and “eloquent” coding meant as few cards (aka lines of code) as possible. Goto statements scare me. Gotos with literally 5-6 arguments terrify me. Did I mention that there’s limitations on line length imposed upon the language from punchcards?
The code in specific I’m working on is worse. Those working on it use no version control, so it’s full of commented-out things every which way, and it definitely dates from the punchcard era, as it lacks things like blank lines in between logical blocks of code statements. It has terrible, nonsensical indenting, and it relies heavily on subroutines acting in highly non-documented ways on literally hundreds of different, poorly named and undocumented, global variables.
Oh, and there’s a function that simply wraps ACOS(), the cosine function in FORTRAN. This is what it does:
FUNCTION ARCOS(X)
ARCOS = ACOS(X)
RETURN
END
Lovely, yes? Waste of a function to have to keep track of, yes? I’ve seen it in three different versions of the model, and it troubles me the same.
I also saw references to MS-FORTRAN 4.0 for MS-DOS in the comments. Joy of Joys. In addition, it will only compile with Intel Fortran. Portland Group’s compilers break a little bit on it, but gfortran, g95, g77, f2c, and sunf77 compilers all fail with pretty pyrotechnic displays with it.
Hopefully this stuff won’t drive me completely batty before I can understand what it does “under the hood” enough to re-write what I need out of it in something better.
Categories: Geeky Peawee
No Comments »
ZFS v NFS, 1-0.
October 9, 2007 2:12 pmOn our SAN at work, we use ZFS across it from a single head node to provide storage virtualization services, which are then exported via NFS to the rest of our machines on the network. At first, performance was a dog, especially on writing many small files to disk. This was indicative of having synchronous disk I/O, where all data is written straight to disk immediately before the writing program can go on, instead of having the data written to a cache in ram (aka asynchronous disk I/O). Synch’ed disk IO can slow down disk speeds a lot, as software accessing the filesystem has to wait for the disk writes to finish before it can go on, and there’s a lot more overhead involved with small files than with big files.
Upon some study, I went and turned off two ZFS module options in /etc/system that had more than a twofold increase in speed, especially when dealing lots of small writes.
set zfs:zil_disable=1
set zfs:zfs_noforcecache=1
These two settings made untarring the Linux source code (dozens of megabytes of small files) go from over 15 minutes for just linux/Documentation, to about 25 seconds. While on the SAN head node it’s under 15 seconds for the same operation, there’s still NFS overhead to worry about.
I also know that using these settings really annoy the ZFS developers, as they rightly should, as it mucks about with internals that effectively neuter ZFS’s very ingenious and effective data protection schemes. One of them, the noforcecache option, is mitigated by our disk controller hardware having battery backups for their on-hardware disk cache. The zil_disable is only backed by the SAN running off of UPS systems, however. Hopefully the ZFS devs can make the ZIL (the ZFS Intent Log) work correctly with NFS in the future without essentially forcing sync’ed IO.
Categories: Geeky Peawee
2 Comments »
Mail Clients
August 30, 2007 6:10 pmI’ve been looking for a good mail client for Mac OS 10. Apple Mail is pretty close to what I’m looking for: it’s simple, it works, and it’s got a great spam filter. However, it hides a bit too much in the background, has no option to change from the default top-posting behavior to email replies, and makes it difficult to feed witty sayings into an email signature, either via a program or a fortune file.
So, thus began the Great Email Client Search.
I started with GNUMail.app. It’s based off of the same essential NextSTEP framework that Mac OS, and thus Apple Mail is based on. It’s rather nice in a hackish sense, to tell you the truth, and on Linux, I think it just may be the best-in-class GUI mail application. However, it lacks the Growl notification I’d prefer to use, so any incoming emails can be seen, and thought “I’ll take care of that now”, or “I’ll take care of that when I take care of email as a whole.” The mail program itself doesn’t come with a mail filter, but Eric Raymond’s bogofilter appears to do a fine job of filtering emails. Basically, an all-around winner, except for the lack of built-in growl support, and lack of a reply-all button (WTF?).
I also looked into Mulberry. No easy signature support. Dumped. The interface is… complex. It reminds me of AutoCAD. For me, an email client should be streamlined and let you do one thing very well: read email. This was cluttered, and if I wanted all sorts of extra doo-dads, I’d just pick another mail client.
There’s MS Entourage, which comes with Office:Mac 2004, and while it’s not terrible, it’s Big, and it’s a power-pc app, which means it’ll kill my battery life via Rosetta emulation on my Intel MacBook. It also won’t do the fancy signatures thing (Really, how hard can it be?).
So, I hauled out Thunderbird. It doesn’t sync with the OS X Address Book by default, doesn’t use Growl by default, and won’t do interesting signatures. I found a version with OS X Address Book support (It’s not the Blessed And Holy Thunderbird Release, so it doesn’t use any of the Mozilla trademarks), and found extensions to do the rest. It doesn’t have the nifty unified inbox like Apple Mail has, but in other respects, it seems alright in its latest rendition; it’s still my mail client of choice on Linux and Windows.
Categories: Geeky Peawee
No Comments »
Fedora: huh?
July 26, 2007 8:30 amWhy is it that after I accidentally remove system-config-users from my FC 6 box, when I go to reinstall it, it wants to install wireless-tools?
For those not in the know: to install the user management tool, I have to install wireless networking configuration tools.
Whumba?
Categories: Geeky Peawee
No Comments »
Super Suckage Double Feature!
July 16, 2007 9:13 pmOK, I have two three Special Someones tonight to discuss.
The first is Supermicro, because there’s the least to rant about. Namely, when I wrote my last post, it did not take very long at all for someone from an IP address that resolved to Supermicro to respond to my post; less than an hour. It typically takes a day for their tech support to respond to an actual request for help, and even then it’s generally a cryptic one-line answer that makes me more confused as to how their products (don’t) work. Especially when dealing with their terrible IPMI card for the PDSMA motherboard- what gets it working is completely different from what their tech support and documentation says. For a department of our size, we’re buying a lot of products from them. We may not be big customers, but we’ve been loyal customers, goddamnit, and now I would like to see about buying future needs from other vendors due to SuperMicro not just sucking, but rubbing it in my face how much they suck through my own website. If anyone wishes to elaborate on this, I will.
Next up is Seagate. We purchased 16 750 GB SATA-II drives from them. We expected them to work as SATA-II drives, yes? They come pre-installed with the little jumpers that force them to work as SATA-I drives. No big deal normally; the average home user wouldn’t ever tell the difference. However, when you’re trying to get them to work with a SAS backplane and controller that the hardware vendor says “Well, yeah, it kind of sucks, sorry you had to buy our product to find out” with, it’s a Big Deal. We’d be getting all sorts of data errors across the 16 drives, and things just Wouldn’t Work.
Why didn’t I remove the jumpers? Because I didn’t know they were there. These things measure about 1mm x 1mm x 2mm. They’re small. With my Wonderful Awesome depth perception under the harsh fluorescent glare of the machine room, I thought at first they were colored plastic bases for the pins, so you knew exactly which ones to jumper. Then, I noticed they were jumpers, but so small that either they were blocks to discourage random jumpering, or that they were configured like that for SATA-II from the factory.
Only after the “Storage Doctor” commented about SATA-II did I figure on forcing the drives to act as SATA-I. So, after spending too much time looking through crappy documentation, I realized those drives were jumpered. So I took out the jumpers, and found the only dead drive in the batch (you order lots of drives at once, you expect a lemon or two). The system is working more or less alright now.
And, finally, the Wheel Of Suck turns to the Portland Group. They make a set of really handy compilers for Fortran and C/C++. There is, however, a big problem. The model I’m hacking on won’t compile with the latest version (7.0). It didn’t compile under 6.2 either, leaving us stuck with 5.2. It’s not my problem- it throws an Internal Compiler Error, which means their compiler broke somewhere on the inside. I tried to get help. I’ve been sending them weekly emails since June 22nd. Until I get an answer, I’m going to start emailing them twice a week. Then three times a week. I might just set up a cron job to get their attention. Something has to be done.
Categories: Geeky Peawee
10 Comments »

