James Cassell's Blog

Monday, September 08, 2008

Never Let Windows XP Touch Your Partition Table

The other day, I decided to re-install XP. I have a triple-boot system; on my ThinkPad, I have Vista, XP, and Fedora. I told the XP installer to delete the partition that had my old install of XP, and when I told it to put a new one in its place, it told me that I already had four primary partitions.

My partition table was a follows: first primary partition: Vista; second primary partition: XP; third primary partition: boot partition for Fedora; fourth primary partition: extended partition which holds: 2 encrypted partitions for Fedora.

After the XP installer touched my partition table, the I could only boot into Vista. GParted saw my entire disk as "uninitialized," or basically, empty. At this point, I was in a slight panic; I had a lot of important stuff in my Fedora partitions.

My eventual solution was both tedious and dangerous. I basically edited the partition table by hand, using the command line tool sfdisk. I did this using the Fedora 9 Live CD. This time, I had gparted create an empty NTFS partition, and I told XP to just use that, and I let it format it when it asked, which turned out to be a mistake. This caused it to mess up my partitions again, and I had to use sfdisk to set them straight. I now have a working setup, as I had before re-installing XP.

The moral of this story happens to be the title of this post: Never let Windows XP touch your partition table.

Labels: , , , ,

Saturday, September 06, 2008

Broken Ctrl and Shift Keys

I have been having a very intermittent problem in Linux where my Ctrl and Shift keys would stop working. This prevented me from typing a question mark, as well as preventing me from entering my passwords when they were required. (All but my most insecure passwords require the use of the shift key.) Additionally, this breaks many, many keyboard shortcuts. I had noticed that this problem seemed to show itself whenever I used a program that captured the mouse and keyboard, such as a remote desktop application, or a virtual machine application.

Today, after having failed many times in the past, Google helped me find a solution that didn't require rebooting my machine (which was my only-known solution previously.) In a forum somewhere, someone said that fidgeting about with setxkbmap could sometimes help. It turns out that he was correct. If this happens to you, you can type, "setxkbmap dvorak; setxkbmap us" (without the quotes) into the command line. It worked very well for me, but your mileage may vary.

(Now, if only someone were to make a post like this whenever they solved an obscure computer problem. It would make Google's job much easier.)

Labels: , , ,

Tuesday, September 02, 2008

An Unexpected Adventure

This past Saturday, I woke around noon to the sound of my cell phone. Strangely, it wasn't a telemarketer calling to tell me that the non-existent warranty on my non-existent car was about to expire. One of my friends was having a computer problem, the likes of which I had never heard before. One thing that I have noticed semi-recently is that it is difficult to troubleshoot an unknown computer problem over the phone. (If it's something I've run into before, that's a different story.)

Technical Aspect

Not that it will interest the reader, but I'll describe the symptoms of the problem anyway. (Maybe someone who has a solution will post it in a comment.) Windows Vista would boot fine to the login screen. After typing the password was when the problems started appearing. The "Welcome" message would show for a few seconds, then, when the desktop should have appeared, only a royal blue background appeared. At this point, the mouse was functional (i.e., it moved around,) but there was nothing to click on. It seemed as if explorer had never started. All of the normal approaches to diagnose such a problem (e.g., Ctrl+Alt+Del, Ctrl+Alt+Esc, etc.) were useless. I asked on IRC, but no one had any solutions. Neither did Google. As a side note, it would boot into safe mode.

Eventually, we were able to get the desktop to come up by going into msconfig and disabling all of the startup items as well as all of the (non-essential) services (as defined by msconfig.) Upon re-enabling the services, we were able to get a functional desktop for about one boot, but when we rebooted, the initial problem re-appeared.

I didn't want to try the same solution again because, as Einstein said, it is insane to do the same thing over and over again and expect different results. My next suggestion would have been to get the computer re-imaged. We had been working on this problem for over five hours by this point, and I didn't want to send my friend away having wasted so much time. Since the Help Desk wouldn't be open until the following afternoon, I proposed another solution. Last year, I had taken a backup image of my computer the day that it was issued. I still had this backup, (that consisted of six DVDs,) and proposed that we do a restore from this image. We did so, followed by downloading all of the updates that had been released since. This second option took about six hours. The system was now in a pristine state.

Human Aspect

As can be inferred from the above, this ended up being an all-day event. Some may exclaim, "what a boring way to spend one's Saturday!" I look at it differently. In addition to the fact that "...we know that all things work together for good to them that love God..." (Romans 8:28, KJV), I can't think of a better way to spend a Saturday than getting to better know my friends. In case you know nothing about humans, people don't sit and stare blankly at one another for more than eleven hours, while waiting for a computer to do its thing. Another of my friends joined us about half-way through, and hung out until the end. I met both of these friends at Silver Bay, where, many will agree, the best times since heading off to college, have taken place. This opinion was voiced several times through the day.

While this day may have been a bad day for the victim of the computer problem, it was one of the best days that I have had since returning to Rensselaer. The only thing that I would change about the day is my allowing the conversation to be steered to my planned activity for the day: sleeping into the late afternoon. This caused my friend to feel bad for waking me, and, in turn, made me feel guilty for causing this bad feeling. This could become a vicious circle. Aside from that, I'd say that the day was an excellent unexpected adventure!

Labels: , , ,