Sunday, August 30, 2009

Anyone Else Worked on a Commodore 64?

I am listening to The Ultimate Commodore 64 Talk. It was a talk given at the 25th Chaos Communication Conference last year; it was 64 minutes long with 256 slides (which if you're a geek you already can see the in-humor of that).

What was so great about the C64? It was no doubt one of the most flexible, hackable systems created for home users. That's probably the single biggest driver in creating a fanbase for the machine that persists today (don't believe me? The thing was released in 1982, and if you click here you can go to a website that is reportedly hosted on a Commodore 64. Yes, hosted. It's a web server running on a Commodore 64.

My first personal computer was a Commodore 128. I remember typing in my own BASIC programs (the built-in ROM booted straight to a BASIC interpreter), loading applications from five and a quarter inch floppies, and with the right key combination, booting to a Commodore 64 mode. My first introduction to the early incarnation of the Internet was by connecting an external modem...which really is just a device for modulating a digital signal to an analog signal, not necessarily something that connects to a phone line even though that's the most common use...and connecting it to a 2-meter amateur radio transceiver so I could hop from node to node on the digital amateur radio network, exchanging messages with other amateur radio enthusiasts and using a terminal to "chat" with people. Messages could also be passed through special gateways into different wired networks of bulletin boards and what was back then the fledgling Internet! At the time this was pretty exciting!

Listening to this talk and watching the slides brought back some memories...

Commodore will always probably be known as the company that screwed up a great platform, the Amiga, which again was used beyond what most systems would have lasted in the industry. Anyone remember the show Babylon 5? Seaquest? Max Headroom? The computer effects were rendered on Commodore Amiga systems. It also was ahead of its time for giving home users advanced (but affordable) sound, graphics, and multitasking abilities; this was a continuation of the tradition started with the C64, except for the multitasking ability.

The talk itself is all about the C64; it's in-depth at times, other times humorous, and the information covers a variety of topics from bugs in the processor to comparisons of how graphics looked in the beginning (with a Christmas graphics demo released in '82) to what advanced graphics were appearing years later to a humorous dig at Microsoft's Bill Gates ("If he can program the 6502, so can you." Apparently Gates included an Easter Egg in the code for the version of BASIC encoded on the C64.)

Parts of it will go over the heads of the majority of people out there (you see some assembly code, some diagrams of chips used on the C64...) but other parts will appeal to anyone with fond memories of this old but venerable technology. If you have an hour to spend reminiscing then check out this video!

Friday, August 21, 2009

Windows 2008: I Hate You

I recently had the joy of installing Windows 2008 Server at work in preparation to migrate an older server application to it. I put off moving to or using the latest versions of Windows because I read of many of the headaches for sysadmins that lay in store (in case you want to relate a little, ever use Vista? Well, 2008 is Vista with server capabilities, and a few consumer interface items stripped out...but keeping most of the security problems).

In my two days using it, I ran into this short list of things that truly annoyed the bejebus out of me.

I ran a chkdsk (check disk) on the drives to repair any potential damage after a power outage that outlasted the UPS (I know, what were the odds?). Ordinarily, you run chkdsk at bootup, you can check the results by looking in the logs for messages from WinLogon. I searched for five minutes through the list without finding it...because now it was under something called WinInit. In a way this was funny, since I wondered "Wininit gonna work right for a change??"...say it out loud if you don't get it.
Almost every site, including Windows Updates, including innocuous sites that I've visited for years, including common sites for additional software...required me to add it to a "trusted sites" list. Sometimes it wouldn't even tell me it needed it, some redirect or addon simply wouldn't work. It's an additional step that I don't need when I'm under pressure to get the server working and get things configured.
VNC doesn't work. It's a neat program from www.realvnc.com (which has a free edition) that allows you to remotely view and control your desktop console. It's a convenient way to get to the console, whoever's logged in...we often use it for remote troubleshooting. It has its own password mechanism so it's not reliant on the password for a particular Windows user. "But Barry, why use that when you can use Remote Desktop? You get two client licenses included!"-easy. If Administrator is logged into the console downloading something, and then I RDP in and log in administrator, due to idiot licensing restrictions my login will kill the other session. So if something is being worked on at the same time...poof! Gone. VNC just brings up the remote console because it's remote control, not remote access. Anyway, VNC comes up with an error that Windows won't allow it to run because it's an interactive process. Nice. Really nice.
They changed the Management Console. I used to be able to right click on "my computer", go to manage, then from the top of the tree right click on the "local computer" and from there enter the address of another Windows system on our network so I could view services, system logs, etc...well, no more! Windows 2008 uses the "Server Management Console". And I can't connect to other systems from it! How handy is that?! Well, it's not. Thanks to some other people who were annoyed at this they already solved the problem...I just created a batch file on the desktop that contains the line, "start compmgmt.msc", launching the old fashioned management console from which I can actually manage other systems.
The system logs on the server like logging a message about licenses being validated by WinLogon. Um...who or what is it validating against? Why...? I'm always a bit skittish about software "phoning home". We are using a server, with potentially sensitive data on it. Maybe it's just validating against something on itself, maybe to one of our Active Directory servers, I don't know. But it's annoying me.
Creating a share seems to get more of a burden with each release of Windows. I had to use a wizard now to create a simple share; Wizards are supposed to be a good idea for helping new users with tasks that may be unfamiliar. But wow..."provision share"? I wasn't sure what it wanted me to do with that at first. The familiar route...right click the folder I want to share and select sharing...now takes you to a mini-wizard that would not let me change the name of the share, which I needed to do. I believe I ended up going through a submenu in the server manager to create the share I wanted...through a bigger wizard. All I would like is to right click the folder, have a list of tabbed options, and go from there. Why is that so !@#% difficult? This is Windows Server, sharing is a very basic and common task for server admins. Why must it be a topic for a wizard, without a choice to not suffer through a @#$$ wizard interface? Or worse, an inconsistent interface, since there is more than one wizard to go through for sharing?

Maybe these are just initial impressions and I have to adjust to it. But my first impression was that it was a pain in the arse. VNC didn't work on it. Security notifications keep popping up, even for Windows Update! And common tasks have to be relearned. This is progress? You must seriously have to love the Microsoft Kool-Aid to embrace newer versions of Windows. I find it to be an giant pain to deal with...

Anyone else have similar experiences? Or reasons I should love this version of Windows? Please?

Tuesday, August 18, 2009

Windows Security Identifiers

This is another edition of Fun With System Administration.

Of course, by "fun" I mean I want to choke myself with a SATA cable.

See, much of my day job involves interacting with Windows systems, and there is never any shortage of reasons for me to pull my hair out.

The latest issue involves the Security ID, or SID. See, Windows, unlike Linux, identifies users and machines with a really long string of numbers and letter called the SID. Even though you might have a friendly username (like, say, your name...) when you go to use the computer in the background Windows knows you by a really long string of numbers. Your human-readable name is an alias of sorts.

Remember, I said users and machines have a unique ID associated with them.

The problem is that we have situations where we have to clone machines to go out to different offices. We take a machine out of a batch of identical systems; we install Windows, configure special software options and printers and various drivers, then we create an image of that machine that we then can copy down to all the other machines in hopes of saving time not having to remember every Windows and Office update and special software package.

Part of that procedure involves running NewSID, a free utility that will change the name of the computer and the SID so the machine gets a unique ID associated with it.

In the Wikipedia article it said:
Now the truth is that when the computers are joined into a domain (Active Directory or NT domain for instance), each computer has a unique Domain SID which is recomputed each time a computer enters a domain. Thus there are usually no real problems with Duplicated SIDs when the computers are members of a domain, especially if local user accounts are not used. If local user accounts are used, there is a potential security issue that is the same as the one described above when the computers are members of a Workgroup but that affects only the files and resources protected by local users, not by domain users.

Now...our users are on a domain! Maybe we don't have to worry about it!

I made note of it and had cloned several machines before remembering to actually test it. The latest NewSID will tell you the current SID for the machine; I looked at two systems on the domain and they both matched. Joining the Active Directory domain doesn't alter the machine's identifier as I thought.

Apparently the Access Control List that controls file ownership and such is associated with the user's SID, and in theory there shouldn't be an issue with this. But on reflection I didn't want to risk it.

Nuts.

So it was my own fault for not testing more thoroughly but it is one more reason to hate Windows...Linux doesn't use machine-specific ID's on the network outside of their name. Windows lets you change names but hides the fact that the name is just a superficial shell over a long string of gibberish (okay, it actually means something as the article tells you, but still...) and it's that string of gibberish that is actually significant; plus you need a special tool to alter it.

Another annoyance with Windows...it doesn't include the tool to alter these sort of fundamental parts of the operating system that can cause problems. You can get NewSID for free but it was actually a third party tool written by Mark Russinovich, hired by Microsoft after he released a lot of useful tools for Windows.

The lessons to be learned?

  1. Don't assume. Test. Even if it takes more time which results in becoming less popular with your boss because you're taking that extra time...because it's going to save you the time it takes to fix your time-saving shortcut.
  2. With Windows, even though you'd think changing names and ID's and such would make the machine unique on the network, it might not. There are underlying functions that Microsoft actually had the brains to abstract away from the users since they didn't need to know about it...only they didn't put any obvious ways to check on or monitor those abstracted functions until it's too late and you have a new mess to try fixing.
  3. Don't assume that just because there's some fundamental part of Windows that needs administration you'll have the tools included to fix those fundamental parts. Find a tool and save it somewhere that you can access that tool later on.
  4. Windows is a major pain in the rear.
I think that pretty much covers it...

Saturday, August 15, 2009

I Love My Mac

I recently acquired an old PowerPC Powermac G5 slated for a scrapheap. I thought I'd use it for my son; he's four, but he loves playing little flash games and watching DVD's, so to keep our own systems intact I get old systems that are barely adequate for use but have enough oomph to still do the job. At this point he was using a secondhand eMac; an all-in-one unit that had the monitor/CPU in one gumdrop-shaped unit (actually it reminds me of the nose of the space shuttle) that had an 80 gig drive and 512 meg of RAM and a G4 processor.

This unit was a G5 with 512 meg of RAM and a slightly new OS as well as a DVD burner instead of just a reader. I stripped the RAM from the G4 and upped the Powermac to 1 Gig of RAM. I then spent some time doing updates and installing items like NeoOffice and FireFox, then fended my little guy off while running Carbon Copy Cloner to an external LaCIE 160 gig external drive with combination USB/Firewire interface.

He loved it. His games no longer stuttered! Sure, the thing was running on the now-largely-unsupported PowerPC platform, but as long as his web stuff ran he was in heaven.

I was reminded of just why I loved the Mac for home users. I created an account for my son with the "simplified" Finder interface and limited the applications on the menus to just a few of the necessities, as well as creating an account for my daughter to use when she needed a desktop instead of her EEE PC for schoolwork (or more likely her iPod Nano). Simple for him to use, very very few exploits for the Mac, and far fewer worries on my part that he'd get into something he shouldn't.

Today I saw my wife had been doing something on it and left it logged in as the administrator user (I'm not really locking this down, just trying to keep it running for my little guy, so it's the only computer that everyone but my son has the admin password for in case it needed updates and to install a printer). At logoff it locked up tight.

Weird, I thought to myself. I hard-killed the CPU with the power switch and booted it back up. After sitting for quite awhile the dreaded folder icon appeared mid-screen. It couldn't find the Finder folder.

Crap.

Reboot with the mouse button down, opening the CD tray. Insert an old OS X CD, power up holding the C key to boot from that drive. Exit the installer and run Disk Utility. It found several errors before telling me it couldn't fix the drive.

I did some research and found that holding the option key will bring up a boot disk selection manager. Plugging in the external drive via firewire, I booted with option held down...must waiting yielded just the CD ROM drive to boot from.

Power down, plug in the drive via USB, try again. Same result.

I found some information on zapping PRAM and resetting NVRAM and OpenFirmware to get the external drive to appear. I didn't feel like trying that one next...I decided to try my favorite tool, Firewire Target Disk Mode. I love that ability of the Macintosh! It's saved my bacon on a couple occasions. If you're unfamiliar with that ability, it allows the Mac to boot into a mode where it appears to be a Firewire hard drive, and you can hook it up to other computers like any other external hard disk. In that mode you can run repair utilities, copy files from one system to another, or install a newer version of OS X if, for example, you want to install on a system that doesn't have a working DVD drive but have another Mac that does.

I found the key to hold...T...and rebooted the Mac, hoping that the old PowerPC G5 wasn't too old to have that ability. A wave of hope hit me when on the monitor a giant Firewire icon started dancing around. It worked.

I took out an Intel Macbook and connected my LaCie external drive to the USB port, then my dual Firewire cable to the G5 and MacBook. Oddly enough just the DVD-ROM with the bootable install disk showed up on my MacBook (it was in the PowerMac). I opened Disk Utility on the MacBook, and after some chugging it showed the hard drive (and CD drive) on the PowerMac. At this point I was fairly certain that if the drive wasn't bad, hardwarewise, that the filesystem was toasted on it so I wiped the partition with a new one. Then I fired up Carbon Copy Cloner, set the source to the external LaCIE drive and the target to the new partition I created on the PowerMac, and let it go with a bit-by-bit copy.

As I type this it has been running for 35 minutes and copies 2.4 gig of data. It should restore most of the data from when I first got it, which wasn't that long ago.

Hopefully it will be done in a couple hours and I'll be able to try rebooting the PowerMac to see if it was successful. If not I'll probably end up trying to get a new SATA drive to install in the PowerMac.

Either way...this is a wonderful lesson in having a working backup. There are many cases where I have saved my own bacon using Linux but there are times I truly wish I could get a PC to boot into a "target disk mode" like the Mac, or even having easy to use drive utilities like CarbonCopyCloner. The closest I can come to it is a system requiring a bootable CD to image partitions to an external disk. Slightly easier is doing work in a virtual machine because then I just power down the machine and copy the virtual machine's disk drive file to another drive or directory. It's nice to have the ability built right into hardware.

But this approach does underscore a couple issues...similar to information rot on the Internet (as I posted about recently, see the archives or use search) I needed to know if the machine even supported these features. Some Macs use IDE drives, some use SATA, some support booting from external disks and some didn't. You can't just use a Mac and expect this to work.

Similarly, in order to really use these features you probably need at least two Macs handy, which is of course rather expensive. I haven't tested it but the Mac in Firewire Target Disk Mode should allow it to connect as a Firewire drive to any machine that supports external Firewire drives; but I doubt you could easily perform certain functions like actually installing OS X from the host to the target Mac or using the target Mac as a bootable disk. And of course the host has to understand the HFS+ filesystem in order to actually see the data on the drive.

On the other hand it is nice to be able to use an iPod as a backup drive (or bootable disk) for times like this when you're stuck in a bind.

I love my Mac. I have issues with it, but I can't recommend them enough for home users, and I certainly wouldn't balk at being forced to use them as my main machine. I can only hope that Linux eventually gets the user-friendly features OS X has now...or that OS X gains the flexibility and power of Linux tools.

Anyone out there have stories relating when they realized that they had a definite preference for a given platform, Linux, Windows, or OS X? Amiga? :-)

Edit: The drive is, indeed, toast. It's a hardware failure. I ordered a new SATA drive, but unfortunately it won't be here until Tuesday. Then I'll get it installed and start the re-clone from the backup drive so Matthew can have his machine back. On the plus side, I removed the existing drive to see how much of a problem it was going to be...can I say again that working on the PowerMac's hardware is a joy compared to so many other machines I've been sliced open on or had to fight with? I popped off a panel (no tools), removed an airflow panel of some lexan-like transparent plastic (no tools), disconnected the SATA power and drive cables from the drive, and slid it out on the rails. At first I thought it was stuck...turned out the rails have an innovative dual-rail system in it so that the front of the drive naturally slides at an angle as you remove the drive so it doesn't catch on the edge of the case or cables. I'll need the screwdriver only to screw in the screws that allow the drive to sit on the guiderails. I think the Mac is the first system I've had hardware failure and I'm actually consoled because the fix isn't quite as much of a pain in the arse that I thought it would be!

Edit 2: The new hard drive arrived...hooked up the backup drive via USB to the MacBook, then the MacBook to the PowerMac via FireWire cable, and fired up Carbon Copy Cloner to re-image again.

The MacBook first burped an error when connecting the PowerMac (with the new blank drive installed) saying that the disk wasn't usable; I opened Disk Utility and told it to partition the drive then erase it. Carbon Copy Cloner then saw the drive, and in about an hour (the previous attempt took around 5 hours as I recall...then it failed) the copy and verify were done.

Eject both drives, put everything away, crossed my fingers and rebooted the PowerMac. It booted, good as new! My boy is very happy to have his machine back again!

Sunday, August 9, 2009

Information Rot on the Webbertubes

One of the roughest parts of working on the Internet is dealing with information rot.

I've been recently digging through what it would take to create a high-availability cluster of Linux systems; essentially a way of taking two or more systems and configuring them to provide a service (like a web site, for example) that appears to be one computer but in reality when one computer fails...motherboard bursts into flames...the other computer takes over and continues to provide the service in a nearly uninterrupted manner, enough that most users aren't aware there's been a problem.

Putting it like that makes it sound simple but it's not.

Information rot is the name I coined for the issue I ran into when researching the task. I've come to see it as a reason for techies to be a little more understanding when they spew vitriol at newbies who don't RTFM or Google for a solution before asking mailing lists for the answer to an issue that has already been answered three times in the past two weeks (to be fair, though, it seems many still don't do that first).

Here's an example of what I ran into. Some people set up clusters and put information into what's called a HOWTO. Just as the name implies, it is a document that tells you HOW TO do what they did. A recipe for setting up a cluster similar to what they did, in this case.

In order for computer B to know that computer A has had a problem (and so computer B must take over A's role), there is a bit of software called Heartbeat whose job it is to periodically check the other machine's health by answering a network query.

Since the first heartbeat software was released for the project it has since had a series of changes made; there was a version one, then a major second version, then it became another program called Pacemaker.

Now when you're trying to create a cluster to meet your own set of needs it means finding information on bringing a lot of related-but-not-tied-togther programs to work towards a common goal (your project needs). It means going through a lot of HOWTOs and home pages and program man pages.

But clusters aren't found in everyone's basement; of all the people who do create a cluster only a fraction of them bother sharing their experiences and information as tutorials, and then they often don't update them anymore. Many of the documents...instructions, HOWTOs, mailing list anecdotes...will have instructions with disclaimers saying, "This is how you do it with version one...version two has this ability built in, so click on this link to see how to configure that. Note that with Pacemaker you should disregard these and go to this link telling you how to do it the "right" way with Pacemaker, unless you're running in compatibility mode with version one Heartbeat..."

That's if you're lucky.

Sometimes you find instructions that refer to software that is just plain out of date so the author doesn't put any notes about versions in it at all, leaving you scratching your head why the commands aren't working for you the way they worked for the author of the document.

It's not just with trying to configure a cluster that I've run into this. I had the same issues with setting up proxy servers (speeding up and filtering web browsing for a large site) and mail filtering for a large number of users (sending email through a filter that decided what was spam and what wasn't while blocking certain senders and blocking certain attachments). The technology behind filtering and even the mechanisms for rerouting networks in Linux changed over time and so I had to puzzle out what documentation was relevant to the version of software, and the mix of software, I was trying to use for the task! Part of the problem with working in technology is that this shift occurs constantly and we're expected to change with it.

It's gaining not just knowledge of what is available as an option but the need to gain an understanding of each component so you can truly apply that solution to meet the needs of the client, whether that client is yourself or another business or department. Often it seems as if users think that tech people just have a store of knowledge that can be tapped into like a human Google and it simply doesn't work like that.

Ever ask a tech person a question that seems very simple on the surface, but in reality is far more complicated? My favorite one is when someone asks me what computer they should get. Seems simple, like asking what their favorite color is. But I can't give them a simple answer if I'm being honest.

I'd need to know what you're going to use the computer for, what your experience level is, what kind of software you really think you absolutely have to use. Are you a gamer? Just an Internet browser? And your budget? All of those are factors in the decision. A Mac can't be beat for people doing audio and video editing at home or just web browsing and email. Windows systems are cheaper (in price and quality, usually). Would your use include a lot of travel? Or do you just like commuting from home to the local book shop with wifi? A netbook might fit...or do you need a true desktop replacement class notebook? Data redundancy or backup?

While this seems like veering away from the concept of information rot, it is related in that both reflect the difficulty in gaining in-depth comprehension of the solution you're seeking.

Google can only point you to knowledge. It's up to you to find wisdom.

Friday, August 7, 2009

I Go to the Movies Apparently to Watch TV

My wife and I went to see the movie Hangover a few weeks ago. It was a pretty good movie, by the way.

The problem is that we paid quite a bit of money to get in; anyone who has been to the theater lately knows what I'm talking about. We didn't see the matinee time. We went in at a late-night showing. It was a multi-cinema theater, not a small town 2-screen theater; a major name place who shares its name with an adjective for a monarchy.

We sat down around 8:00 in our seats. The lights dim.

We watched over 20 minutes of commercials and previews.

Previews I don't mind so much. I sometimes enjoy seeing peeks of what's coming up soon. But commercials?

This theater already shows a loop of some trivia and information before the movie starts...I don't count that since if you're ten minutes early, you're going to have 10 minutes of that loop. I do get slightly irked at the whole, "this movie trivia is brought to you by Coca-Cola" thing they have going on, but hey...I have some control over how much of that I'm exposed to.

But when the movie is supposed to start it would be nice if the movie started.

Worse, they're showing commercials. Actual commercials. For cars and trucks. And soda.

WHY?

I don't want any of that crap just because they're ticking me off when I came here to see a @#$ movie. I associate their products with being annoying crap now.

Because they're actual commercials. Like what I see on TV. As in the reason we're paying a big bundle of cash to sit in the theater and get away from them in the first place.

In a time when people are literally turning their living rooms into small theaters with surround sound and projectors or ginormous LCD televisions, why would theaters go out of their way to try turning their theaters into giant living rooms by creating a crappy viewing experience? I could pay a boatload of money to watch pay per view in my underwear at home. I'm paying a quite a bit more to sit in your theater and be forced to sit through you trying to push the same commercials on me that I get already at home.

Basically it's a reason I don't go to the theater unless it's a movie I really want to see. Otherwise I wait for it to come out on DVD. I am simply too irritated at the onslaught of ads that waste my time and worse, I'm paying them to irritate me. It's a personal pet peeve.

Incompetent fast food restaurants led me to simply stop going to them and tell other people how crappy they are. If I keep getting this from theaters I think I'm going to add them to my craplist as well. I'm very close to sending a letter to the CEO asking he or she to pull his or her head from his or her butt and stop showing me the same crap I already get on my TV at home.