Archives

Blog Archives

Migrating BlogEngine.net to WordPress

Featured, Technology2 comments

I’ve been doing some website housecleaning recently and with my company name change, the old keenesoftware.com site just wasn’t up to par.  The blog on the new company site will just be company related posts, no personal posts.  So I figured I’d convert this site over to just a personal blog. Continue Reading

Move Vista’s Users folder to a Different Drive

16790fd9-cfee-4e70-830a-47f709d0f72a9 comments

OK, so I’ve finally gotten around to setting up a Vista machine as my main machine.  I opted to go with an SSD drive for the system drive and planned on putting all the user data on a different drive.  After doing a little research, the best solution to accomplish this with the least amount of hastle (or so I thought) would be to copy the content of Users to the new drive and set up a junction (symbolic link) to the new location.  Well, that was certainly easier said than done.  Everything I read suggested to do all the copying and sym-linking from the command prompt from the Vista setup disk because the Users directory is in use once Vista is running.  The problem with doing that turned out that the drive letter assigned to the new home for Users wasn’t the same during setup as when running Vista.  After multiple attempts to get the setup instance of Vista to use the same drive letters as the running instance, including re-installing Vista after failed attempts rendered the Users folder unusable, I decided there had to be a better way.

During my initial research, I found mention of people using MOUNTVOL instead of MKLINK.  The main difference is that MOUNTVOL makes the entire disk volume available at the mounted location rather than just a directory.  Depending on your application, that may be too restrictive.  But for my application, that was fine as that’s what I wanted to do anyway.  And the huge benefit of using MOUNTVOL is that the pointer is to a physical drive, not a logical drive letter.  After installing and booting to the setup CMD shell, renaming the Users directory to something else, I created an empty directory and mounted the drive on it.  I then used ROBOCOPY to copy the Users directory content back to Users, thus restoring and preserving the settings and security attributes.

So, here’s my recipe:

Install Vista (if you haven’t already)
Boot to the setup CD and once the installer is running press Shift+F10 to get to the shell

Then, on the boot drive:

ren Users Users_save
mountvol

(Note: no parameters on the mountvol command to get the volume label of the disk you want to use.  Then use the shell’s clipboard feature to copy the volume label to the clipboard.)

mountvol \Users <paste the volume label here>
robocopy \Users_save \Users /MIR /E /XJ

Reboot and enjoy.

 

New version and new theme

ecb807e3-8744-465a-8d03-1148a88a875a0 comments

I’ve been using the latest version of BlogEngine.Net and in the process of upgrading to Visual Studio 2008, I reorganized the solution for the whole site.  It’s now simpler to maintain and I’m now on a near-pristine copy of BlogEngine.Net which will make picking up future updates quite a bit easier.  As is usually the case with software, it’s much faster and simpler to implement something the second time around, especially when you don’t worry about maintaining any old data.  So, the old posts and comments are gone.

One interesting problem of note that I ran into while doing this was the blog main page would not load, complaining about not being able to find the Standard theme.  Everything worked fine on my development system but would not work when published out to GoDaddy.  Turns out that when it is running on IIS, the theme of the parent site (in this case,  www.keenesoftware.com) was defaulting onto the blog’s site (www.keenesoftware.com/blog).  The fix is to add a theme=”" attribute on the <pages> tag in the blog app’s web.config file.  Since BlogEngine.Net does it’s own theme handling, I would think this would be the default but it’s not. If you run into this issue while trying to add BlogEngine.Net to your own site as a virtual directory, this should fix it.

I’ll try to keep this blog a bit more persistent going forward so comment away.