Documents

Archives

Search

BLOGical Thoughts Archive

September 2007

Friday, 28 September 2007

I have 21 more episodes of the original Star Trek to go through, then I will be done. It's been interesting rewatching a series I first saw in my teens. Most of it holds up very well, but some has been hopelessly outstripped by current technology.


I will start replacing and adding parts to my '52 Plymouth from the '51 Plymouth this weekend. I need to add emergency brake, choke, heater, front bumper, radio and grill and glove box at the very least. When I find more I will add it. The goal is to have something working well enough to take it down to a local restorer who can do all the major work.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Thursday, 27 September 2007

I have solved all the major problems with the program I wrote at work. The last one was a bug where the program was using old logs instead of creating new ones or using the latest one. Hopefully, I will have more time to do other things now.

I have written a configuration program for the Windows service, and I was asked yesterday to add some start, stop and restart buttons to the config program, that would start, stop or restart the service. By a remarkable coincidence, I had read how to do that the night before, and I had brought that book to work. So it took about a half hour to implement.


It looks like we will have a North Idaho Linux Users Group meeting next month after all. A member has donated the use of his church meeting room in Post Falls. That's very nice of him.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Wednesday, 26 September 2007

I now have some adequate reference books for programming in C# and .Net. I'm not sure they will make me any happier about programming for Windows, though.

At least C# programs have less tendency to completely crash the operating system. Well, I think they have. They tend to crash only themselves, just like Linux programs.


I tried a couple of Xara Xtreme tutorials the other day and it was obvious that they were oriented towards the Windows version of the program. There were things the tutorials asked us to do that were not present in the Linux version. So I guess I may have to modify my approval of the program, to just "it works ok".


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Tuesday, 25 September 2007

I keep sending Book Mooch mooched books out, and books I want never show up in their database. I can now mooch up to 18 books, but none from my wishlist. Come on people, let go of some of those books. I'm looking for mysteries, science fiction and technical books.

Maybe my tastes are not in the mainstream. That's probably good for me (I'm not a reality-show robot), but bad for my booklist. If it's on the best seller list, I probably wouldn't be interested in it.


Here are words to live by: Never trust Microsoft to do anything right. Especially programming interfaces.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Monday, 24 September 2007

If you are thinking of trashing your old Pentium III, you might want to think again. I wanted to use KAudioCreator to rip some CDs, so I loaded the program on my workstation, which is an AMD 64 3200+ with 1GB of memory. When the program ran, it was like using a Pentium II with 64MB of memory - painfully slow.

I figured that I have so much running on the workstation, that the processes were interfering with the ripping process. So I started up the HP toaster (Pentium III, 256MB) and installed KAudioCreator on it. The program ran like it used to on my Athlon XP 1800+ machine. I'm a happy camper.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Friday, 21 September 2007

I spent last night at the meeting of the North Idaho Mineral Club. I haven't done any lapidary in 33 years, and I thought it would be interesting to see what is happening today. It was interesting. I turns out there are more places to hunt for material in the Pacific Northwest than I had thought. I may join this group, as hunting for rocks to cut and polish could go well with the teardrop trailer.


I will be cooking tomorrow, from about 10 until 3 or 4, at the Lions Club in Rathdrum. It's part of the 2007 Heritage Days Festival, as I mentioned before. If you don't have anything to do and want some good free food, come on over. As you can probably tell, this means I won't be working the weekend, like I have the last two.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Thursday, 20 September 2007

I am cleaning up the small things that go wrong in my program at work. The latest is an exception that gets thrown when I attempt to stop the program (Windows service). It appears that when I abort the threads that are using my logging object, they abort and also dispose of the logging object. Then, when the program shuts down, it attempts to dispose of the logging object, too. And I get an aborted dispose exception. Isn't Microsoft software wonderful? They 'take care of it themselves' instead of letting you take care of object disposal.

My current line of investigation into this is to increase the object reference count, so the object isn't destroyed by the thread. And M$ won't even let you do that in a straightforward way!


I brought my Plymouth home from the shop yesterday morning. I had a hard time starting the car, due to the fact the manual choke is disconnected. So that goes on my list, too. I also need to lubricate the speedometer cable. When you are only traveling about 35 and the speedometer bounces around and finally tells you you are going over 120 and makes a godawful racket, you know it needs lubrication.


Web site of the day: Perpetual Kid - Entertain Your Inner Child


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Wednesday, 19 September 2007

It took me a day and a half to decide what to do with the program I am working on. I created a class whose sole job is to write the log file. I passed the same instance of that class to all the threads, so they all use the same WriteToLog method. Finally, I locked that method, so only one thread at a time could use it. This all works when I have only one thread. I am going to try it with two threads today.

I still have to figure out why the program can't monitor remote servers, but that is a low priority.


The brakes on my '52 Plymouth now work, and it also has a new fuel pump. I will pick it up from the mechanic this morning. Next up is bodywork around the windshield and some interior work.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Tuesday, 18 September 2007

I googled for some help with passing data between program threads, and there are as many (complex) solutions out there as there are gallons of water in the ocean. I haven't found a suggestion that completely fits my situation, which is many retrieval threads feeding data to one logging thread, with no action from the main program thread. I'll keep looking.

In the meantime, I am fixing some minor bugs in the program and its configuration program. One is not so minor: I have a memory leak in the program. The question is, how do I track it down? It's extremely tough to debug Windows services.


The last gasp of summer is this Saturday. I will be participating in a Dutch oven cooking demo at the Lion's Club in Rathdrum. It's part of the 2007 Fall Heritage Festival, and the festivities start at 8:30. Dutch oven samples start coming out of the ovens at about 10:00.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Monday, 17 September 2007

I worked again this weekend. I removed SQL authentication and encryption from the program I am creating, then I completely rebuilt the associated configuration program. This sounds like a lot of work, but it was fairly simple.

I also added some things to the configuration program that makes it easier for users to configure for their particular network. Never let it be said that a program I create is hard for a user to use.


I will install SUSE Linux 10.2 on one of my boxes and begin serious work on the coaching program. I know I've said that in the past, but I really have to do it this time. That means I will be dragged into the Ruby and Rails deveolpment community.


I could post a bunch more links about the SCO bankruptcy filing, but they're done: let's take them out of the frying pan.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Friday, 14 September 2007

In the Windows service I am writing, I had a problem with stopping the service when I needed to. The problem was not exactly mine. I am using a Microsoft trace server class to monitor SQL Server events, and the class is, to put it delicately, 'poorly written'. There is no way for me to determine if there is data present unless I go out and actually read the data. When I do that, the program thread hangs up waiting for a response.

This means that when I tell the thread to kill itself, it won't respond until there is data from the SQL Server. So the Windows service manager eventually times out and tells me the service could not be shut down.

I related this in our status meeting yesterday, bemoaning the fact that I couldn't guarantee the service shutdown. One of the guys said, "Well, if the SQL Server needs data to generate trace events, why not send it data after you send out the thread kill order?" Duh.

So now I am sending a Thread.Abort, then sending a request to the SQL Server to select data from the trace table. This generates trace events and the thread gets free from the Read statement so it shuts down gracefully.

This is why you share your problems - so others can bring a fresh point of view to them.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Thursday, 13 September 2007

Unit testing is important to me, and makes me look good at work. Unit testing is the testing I do on my code when it is finished. It is the first testing phase and it allows me to put out code that is only slightly embarassing.

I made a change the other day to how many log files the program I am working on could create - ten total instead of ten per day. It was a one line change. I tested the change and found that every time I started the program, it started a new log file (not proper behavior). So I fixed that, and tested again. This time, the program failed to create a new file when the time clocked over midnight. So I fixed that. All before anyone else saw the program.

I had tested both of those conditions before I made the change, and they were both working. That single line change broke working code. That is why unit testing is important.


Silly sign of the day:

Am I wrong, or is someone bitter?


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Wednesday, 12 September 2007

One of the things that I dislike the most about Microsoft is the quality of its documentation.

A case in point: at work, the program I am writing now creates multiple threads to do its job. When someone tells the program to stop, it must kill each of the threads. Each thread must then remove its trace from the SQL Server it is monitoring, before the thread dies. They haven't been doing that.

I carefully read the MS docs on threads, and it says that when you Abort a thread, the thread throws a ThreadAbortException. So I monitor for that and do the closing code in that catch block. Except it doesn't work.

So last night I was reading a non-Microsoft book about threads. They say the same thing about the exception, but they go on to say that C# has no way to process that exception. They then state that you can get the same effect by having a finally block for the whole thread.

Why couldn't the MS docs come right out and say that? Oh, wait... then they couldn't sell books that explain what the original docs should have said in the first place. It's all about the money, right?


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Tuesday, 11 September 2007

I now have the MyBook World Edition II running as a normal NAS device on my LAN. My Linux workstation can see it and can write and read it. 1TB more of network storage!

How I got it working is a really geeky story, and is due to a friend of mine in North Carolina. Thanks, Sam, for the link to [H]ard|Forum.

First step was to set up the device as the instructions say. This includes installing some software on a Windows machine and entering a user name and password. I entered 'mburton' for the username, which is the standard username I use on all my machines. By the way, when I tried to enter a password, it would not take any characters except letters and numbers! Real secure, huh?

Once I had the device set up, I powered it down. I then opened up the case (4 screws) to expose the electronics. I unscrewed one screw and slid the plate it was holding down. The plate then lifted off, exposing the hard drives. There are two of them - each is 500 GB. I unhooked the power and data cables, depressed the tabs holding drive A in place and slid it out.

I then opened up my Linux workstation and hooked drive A in as another SATA hard drive. I powered up the machine and mounted the drive.

The MyBook uses Linux for its O/S, so it's easy to find things. I went into the /etc directory and made backups of the 'shadow' and 'inet.conf' files. I then edited those files.

In the 'shadow' file, you must remove the password for the root user. The password is the garbage between the two colons, right after the word 'root'. Save the file and exit (I used the vi editor in root mode).

In the 'inet.conf' file, you remove the comment character (#) from the beginning of the three lines that have one. This enables ssh, ftp and one other program. Save the file and exit.

You can now power down, remove the drive and put it back into the MyBook. When you hook it back up and look at it in the Network folder in Ubuntu, it will be there, all set to use.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Monday, 10 September 2007

I acquired a MyBook World Edition II yesterday. That's a 1 terabyte NAS that hooks right up to your LAN router, just like the LinkSys NSLU2 I have. The major difference is, the MyBook uses proprietary software to allow access to the drive and the NSLU2 doesn't. That means that I can't access all that space from my Linux box. Yet. I am in the middle of fixing that problem. More later.


I worked Saturday morning, then went the the Linux users group meeting. It was a good meeting and was productive, as we got Ubuntu installed in dual boot mode on a new Gateway that had Windows Vista on it.

I worked Sunday morning, then went to do a bunch of maintenance on some computers for a friend (the one who gave me the MyBook). Out of the four computers I worked on, the one that gave me the least amount of trouble was the one with Linux on it. The Windows machines were really frustrating. Turn the machine on, get unasked-for updates, reboot the machine. What a scam.

As part of the maintenance, I installed USB/Firewire MyBooks on three of the machines. The two Windows machines insisted I install some software to support these simple external drives. On the Linux machine, I hooked the MyBook up as a Firewire device, turned on the computer and the MyBook was completely accessible. Ah, the wonders of a real operating system.


I find it extremely interesting that Universal Music appears to be spending more time initiating and fighting lawsuits than they do producing music. Do you suppose their business model is flawed in some way? A business model that hasn't changed since Adam invented music? Duh!!


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Friday, 7 September 2007

I had no Net access again last night. I hope that whatever is causing the problem is fixed soon. This causes great havoc to me, as I have to do this blog in the morning, so I get most of the news links the night before. Not today, though.


The North Idaho Linux Users Group meets tomorrow. There will be no meeting in October, so come to this meeting before the cold sets in.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Liberty and Security/Our Rights

Other News

Thursday, 6 September 2007

I was having trouble with my Internet connection last night. It was unavailable for a couple of hours at least. I'm glad to see the problem has been resolved.

It's amazing how much you come to depend on this network. Whenever I need to look something up, the first thing that comes to mind is Google. When I see a movie or TV show and I want to know more about one of the actors, I IMDB them. I even take my notebook computer with me when I travel, so I can still have access. Last weekend, I went into Border's Books to check out a book on C#. I found what I was looking for, but I didn't buy it. I went home and ordered it on the Net from Bookpool.

Is that an addiction? It would be interesting (but non-productive) to try living without the Internet for a week.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, Copyright, DRM and Other IP Nonsense

Security/Our Rights

Other News

Wednesday, 5 September 2007

I have found a place that is willing to work on the brakes on my '52 Plymouth. I will be taking it down on Friday to let them do the job. After that, I need to find a place to do some body work - mainly in the windshield area.


I have discovered that the .Net Directory class doesn't seem to work at all from inside a Windows service. I will have to find a substitute, as that functionality is an important part of the program. I am using it to determine if a directory exists. If it doesn't, I will create it, as that is where the log files I am generating will be stored.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, DRM and Other IP Nonsense

Security/Our Rights

Other News

Tuesday, 4 September 2007

I got my '52 Plymouth running again. It was a simple matter of removing the battery cables, thoroughly cleaning both ends, then attaching them again. I just knew there was nothing wrong with that battery I bought when I got the car.

I will be working on this machine on and off when I get a chance. I have added trim from the '51 to it, and I hope to get the brakes fixed very soon.


Silly sign of the day:


Free/Open Source Software

RIAA/MPAA/IFPI/BSA/FCC

Stupid Patent Tricks, DRM and Other IP Nonsense

Security/Our Rights

Other News