Saturday 18 December 2010

Virtualising Delphi 6 PC (Activation Errors)

At work we had a very old machine that we used for Delphi 6 development. The time had come to upgrade it. We decided that the most flexible way of upgrading it was to virtualise it.

Below are the steps we followed to virtualise the Delphi 6 machine.

  1. Take a clone of the machine. We use CloneZilla which is free and does the job fine.
  2. Create a new virtual machine and restore the clone onto it. We use XenServer as our virtualisation server.
  3. The virtual machine will not start up and may show BSoD. This is because of a mismatch between the physical machine hardware and virtual hardware. Repair the Windows XP installation by booting from a Windows XP CD and repairing the current installation.
  4. Boot into the virtualised machine and apply all updates and Citrix client tools
Everything was hunky dory up until step 4.

I clicked on the Delphi 6 icon to start it up and I got an activation request with three options on it.
  1. Activate over the web
  2. Activate over phone /email
  3. Activate later
I chose activate later and Delphi closed down. So I tried activate over the web. This option timed out. Finally I chose Activate over phone / email. This looked more promising. I had to go to a website and enter my activation details. I entered all required information and and clicked next. The activation wizard said Delphi had been activated and registered but then behind it there was another box stating that the registration / activation information was missing or corrupt.

To test if it was something to do with my user account I decided to activate Delphi 6 on another user account. This worked fine. So it was something to do with my account...

I rang Embarcadero and they said they only way to solve this was to run D6RegClean.exe from the bin directory of the Delphi6 install. This would have removed all my third party tools and and all my customisation. So I decided to keep this option as a last resort!

From my conversation with Embarcadero I relialised that a registry entry was to blame so I delved into the murky world of Windows registry.

I found that there were three keys related to licensing
LMKEY and LMLIC had correct information about my keys. So the only other one to investigate was LM. This was a binary number and looked like is was automatically generated.

(Please note: Messing around with the registry can break your system only do it if you know what your doing)
So I took a backup of the registery and removed LM key. I tried registering again and it worked!

Hope this helps someone.

3 comments:

Unknown said...

And after 5 years this has helped me on Win10 :)

Anonymous said...

This saved my day.
I need Delphi 6 on Windows 10, and your solution worked perfectly.

Thank you!!!
Anders J

Sony said...

I'm glad this post is still helping people. Thanks for the comments