Wednesday, July 22, 2009

Micosoft Newsfeeds for Visual Studio

After I installed Visual Studio Standard Edition, I noticed that the installer left the newsfeed set to the Visual C# Express newsfeed. I looked around for the proper feed for the regular Visual Studio C# and found this:

MSDN: Visual C#

Other good feeds

MSDN: Visual Studio
MSDN: Visual C# Headlines

Visual C# Express feed

MSDN: Visual C# Express Edition

You can set the feed on the Start Page in Visual Studio by going to Options / Environment / Startup

Tuesday, July 21, 2009

Installed Visual Studio

Now that my computer is somewhat stable, I went ahead and installed the Visual Studio 2008 SP1 Standard Edition that I got on eBay a couple of weeks ago. It runs great so far. I have StyleCop installed and have been using it on a project. I have saved out the default settings that you can get if you ever need them, and have installed my own custom settings. I have used this color scheme for over a decade and it is similar to colors I used in VB 4.0 and Visual C++ 1.0 way way long ago. (Somewhere, I've still got the legendary Visual C++ 1.52c CD).

This setup uses the Consolas font, which is designed for programming environments. You can get it by following the link. It is also included in the ClearType Font Collection. You already have all of these if you have Vista or Office 2007.

Monday, July 20, 2009

Fragile Vista

I don't know what is up with this computer, drivers, or Vista 64 itself, but it has been showing itself to be very fragile and resistant to change. In my other post, I talked about how Vista would get screwed up, such as the Event Log service not working and unable to start, internet access not working, my office VPN not working, unable to connect to the Ghost service running on this computer, and maybe other problems I'm not aware of. Back then, I thought it was due to driver issues, Windows Update, or System Restore, but now I know that is not true. Well, maybe it is true, but there are other scenarios that will screw up this computer in the same way. The last two weeks have been a nightmare of backing up and restoring my system drive over and over trying to make simple changes. First of all, I originally had the system files and our family and personal files all on the same C: drive. To reduce the time to make Ghost images of the C: drive, I decided to partition the Drive 0 into two drives, one 100 GB partition for Windows and applications, and 150 GB for personal files. There is also a 250 GB 2nd drive D: in this computer as well, though I want to keep it empty and only hold temporary files there. So the first task was to copy all of the personal files from the C: to the 2nd D: drive, and retain only system files on the C:. To be able to shrink the drive using Disk Manager, you need to have free space at the end of the drive. So I defragged the C: drive, but unfortunately, Windows has unmovable files, such as the swap file, the hibernate file, and shadow copy files (Restore Points) for System Restore. One can shrink a drive up to the point of one of these unmovable files, but no further. You can get rid of the hibernate files by turning off the hibernating feature using this command:
powercfg -h off
You can get rid of all of the Restore Points by turning off System Restore, and you can get rid of the swap file by disabling virtual memory from the Control Panel. I did all of this, then Windows wants to reboot. Guess what? After rebooting, the system is screwed up. Why? Oh I have a Ghost image I can restore, but only from a week ago. Didn't think to back up before moving all of the personal files and disabling those features. Didn't think I would need to. So I got to start all over. In fact, I got to start over several times. I finally realized that any time I remove the swap file, the system gets screwed up. It is probably something to do with a low-memory condition. But as I say, that is not the only thing that will screw it up. I finally got a stable configuration for the C: drive, including good Ghost backups of the drive on my TeraStation network storage. So, the next thing I wanted to do was to install a new 1 GBit network card to speed up backups even further. I looked at a bunch of vendors and decided on the D-Link DGE-530T because I just love my new D-Link DIR-855 router. This was a huge mistake. I think. After several attempts, I have not been able to get Vista to even SEE that it is installed in the computer. My motherboard does have an onboard LAN connection, so I was sure to disable this in the BIOS before installing the new NIC. The directions say that Vista should see it and then offer to install a driver for it. But nothing I have tried will cause this NIC to be seen, and worse, it screws up my Vista, like all the other changes I make, and I have to restore from a backup... which is on the network... which requires a working network card... which requires the new NIC to be removed... which requires the PC to be powered down... then requires the BIOS to be adjusted again... and the network cable to be reinserted into the original jack... and then rebooting from the Ghost CD... then restoring the backup which takes 1.5 hrs... etc. It is very taxing. When Vista is working, it runs great. But I hate how it can get screwed up. This has been a very long two weeks. Oh, and the D: drive... I am not using Ghost to back up our personal files. I am using XXCopy to make a duplicate image of the file structure on my 1 TB TeraStation, using the command

xxcopy d:\*.* \\ts1\data\Backups\ComputerName /D /M /E /C /F /H /I
/R /K /Y /ZY /YY /EX:c:\Misc\D_Excludes.txt

I have this in a batch file, and the D_Excludes.txt file is empty at the moment. This command will compare the source and destinations for new or deleted files, and will also copy files up that have the Archive file attribute set (the a bit), and will clear the a bit after copying the file. I like this because I have an exact duplicate of the files up on the network storage, whereas Ghost file backups are stored in a proprietary format. Right now, I have 50,122 personal files in 3,530 directories, and with Vista file indexing, it only takes 1:40 for the command to run if there are no files to back up.

Sunday, July 5, 2009

A Painful Lesson

Well, I had an interesting last couple of days with Vista. I learned about how screwed up Vista can get with borked ACL's. It all started Friday morning, when a Windows update alerted me that there was an update for Windows Defender. These are usually lightweight updates that never seem to have any adverse effects. But... I also have an old flaky cable modem, a Linksys BEFCMU10, which is no longer on our ISP's list of supported modems. I have been researching getting this replaced, but haven't made a decision about which modem to go with yet. Anyhoo, I was working at the computer on Fri. morning, when WU asked to install the Defender update, and I told it to go ahead. After it installed, I noticed that my internet quit working and my Norton Ghost icon changed, indicating that it could no longer communicate with the Ghost service. I fiddled with it awhile and concluded that the WU had damaged something that used to work, though I didn't know what. So I decided to just undo the WU by using Windows' ability to Restore from a Restore Point, which the WU created as it was installing. Reboot, and no problem, right? Wrong. After the computer rebooted, the internet still didn't work, Ghost was still unhappy, and not only that, I found that my VPN network icon no longer worked, giving Access Denied when I clicked on it. I had just been using the VPN prior to the WU. Not good. Digging deeper, I learned that the Event Log service was not running, and would fail immediately when I would try to start it. That is very bad, as the Event Log is where error information is supposed to go. What to do? I googled the error message I was getting from trying to start the Event Log service, which was
Error 4201: The instance name passed was not recognized as valid by a WMI data provider
Forum threads such as this Microsoft Technet one indicated that it was a permissions problem on certain folders or files, or else it was an ACL problem. I tried a few things with permissions, but nothing was helping. The suggested ACL fixes are complicated and may not have worked anyway. So, I decided to just restore that whole computer from a backup. I just happened to have a 2-day old Ghost backup image of the drive, so that was good to restore from. Trouble is, it is on my Buffalo Terastation NAS drive, and I only have a 100 mbit NIC in this computer. When I booted up from the Ghost CD, it started to do a verify of the image before the restore. It estimated 15 hours... yowzer. Well, we were leaving for the 4th of July weekend anyway, so I just turned off the monitor and left for vacation. There is a checkbox in Ghost to tell it to reboot when it is done restoring, and I told it to go ahead, expecting that when I returned, I would see the usual login screen and everything would be fixed. But guess what? When I got back late last not, the problem was STILL THERE. WHAT?!!! This problem was NOT there when I made the backup on Wednesday. What's going on? Oh... did I mention that I also have a RAMDisk, and I have all of our temp directories pointed there, along with all of the browser cache files going there? When I upgraded to Vista 64, Superspeed required that I get a new license for Vista. It is not a license that you can get immediately. You have to send them an email, then they respond back with the key. In the meantime, you can run the software in trial mode for 30 days, at which time it expires and quits working. Here is the genesis of my trouble: I neglected to update the license key for the RAMDisk and it quit working right at the end of June. Therefore, the temp file locations were no longer valid because the drive was no longer there. Now here is the 1st lesson that I learned about Vista: If you boot up your computer with the temp file location unavailable, the Event Log service will not start up, and all sorts of other nasty inexplicable problems crop up. I noticed that this was a problem, but unfortunately, the Ghost image was not created with the RAMDisk license info installed. What I decided to try, and really hoped would work, was to predate the computer to mid-June, before restoring the backup. That way, when the computer booted up, it will think it was June and the RAMDisk would be active, thus having a valid temp file location. I also disconnected the computer from the internet, in case Vista would try to fix the time using a time server. To speed things up, I copied the network Ghost image to the D: drive on the computer, and restored from there. Then crossed my fingers. I was happy to find that this worked perfectly, and I now have a fully functioning Vista again. Oh... and the original internet problem... It was not WU at all, it was the stupid cable modem, and only needed to reset it to make it work again. The 2nd thing I learned was: Don't procrastinate on entering license keys. The 3rd thing: Norton Ghost is worth its price in times like this.

Wednesday, July 1, 2009

New Router

Yesterday, a new router was delivered to our home. I bought this D-Link DIR-855 Wireless-N gigabit router on eBay a couple of weeks ago. I was a little hesitant to get Wireless-N because the standard still hasn't been finalized. However, I have been wanting a gigabit router and we've been having weak signal problems with our wireless laptops upstairs. So, after some research, I decided on this dualband D-Link.

It replaces our old trusty Linksys WRT54GS Wireless-G router. It has worked great for years, but now it is time to retire it, partly because it is only 100 mbit.

Another nice feature of the new router is the ability to schedule the wireless access. When school starts, I want to block wireless access after bedtime.