Tips - how to migrate PDQ deploy and PDQ inventory to another server

I already mentioned on very old post about PDQ deploy and PDQ inventory that is SCCM 2012 in "very light" version but it work quite well.

http://www.alessandromazzanti.com/2012/08/server-pdq-deploy-utility-per.html

I take note about procedure to be done to migrate them to another server mantaining relative settings and licences.

The following keys and values are maintained under HKEY_LOCAL_MACHINE.
Key
Value
Description
SOFTWARE\Admin Arsenal\PDQ Inventory
InstallDir
The folder where PDQ Inventory is installed.  This value is removed on uninstall and is needed for other applications to interact with PDQ Inventory.
This value will be in SOFTWARE\Wow6432Node\Admin Arsenal\PDQ Inventory on 64-bit system.
License
The Pro Mode license key, if it has been entered.  The key is stored exactly as it was sent to you so it can be exported or copied and pasted to a new computer.
Secure Key
One of the keys used to encrypt sensitive information in the database.  This key is generated when the system is installed and will need to be copied to a new computer if the database is moved.
Our support staff will never ask for this entry.
SOFTWARE\Admin Arsenal\PDQ Inventory Console
Disable Hardware Rendering
Used to troubleshoot issues with .NET GUI rendering on some systems.  When the application's windows aren't showing correctly, or at all, create this value as DWORD = 1.  This will cause the application to use only software rendering which fixes many of these issues.



Copy the Database File(s)


There is really only one database file, but there are some other files you may want to copy as well (they're listed below).  The database is located in "%ProgramData%\Admin Arsenal\PDQ Inventory".  %ProgramData% will be vary depending on the version of Windows but it will generally be either "C:\ProgramData" or "C:\Documents and Settings\All Users\Application Data". 
You can just copy over the Database.db file to the new computer.  You can also copy over the Backups folder which contains backups from prior versions.  There may also be some backup files in the database folder (they're named with the version that was backed up, such as Database.1.1.5.0.db). There are some other files and folders you can copy as well, but they will be re-created on the new computer so there's no need. 
Note: There are a couple of temporary files called Database.db-shm and Database.db-walthat you will not want to copy.  It usually isn't a problem to copy them, but if they get out of sync with the Database.db file then it won't be possible to start PDQ Inventory until they are deleted.

.NET Installer File

If you downloaded the .NET installer in preferences it will be placed, by default, in the database directory named DotNetFX40.exe.  Copy it over if it's there or you can download it again.
Copy the Registry Key
There is a registry key to be exported and imported on the new computer.  This key holds one of the encryption keys used by PDQ Inventory and the license key (if in Pro Mode).  If you don't copy the encryption key a new one will be generated and you will need to update the passwords for all stored credentials.  The registry key is "HKEY_LOCAL_MACHINE\SOFTWARE\Admin Arsenal\PDQ Inventory".

Install PDQ Inventory


Make sure you are installing the same version of PDQ Inventory that exists on the old computer. 
Verify Permissions
On the new computer check that the permissions set on the database folder are set to your liking.  When first installed PDQ Inventory will set the directory to only be accessible to members of the Administrators group.  You may need to set this manually after copying the directory. 
Set the Background Service credentials
The background service will be installed with the default "LocalSystem" account and will need to be set again to the admin user you're using.  Newer versions of PDQ Inventory will set this for you when you start up the console, but you will want to double-check that it gets done correctly.
Eat a cookie and enjoy a beverage
You've earned it.


Moving PDQ Deploy to another computer


Moving PDQ Deploy from one computer to another is a simple matter of copying the database files and a registry key.  The files and keys to be moved are documented here. However, here's an overview of the steps to follow.

Close the PDQ Deploy console and stop the Background Service

You want to make sure that no programs are accessing the files while you copy. It's very unlikely that you will lose any data, but copying files while there in use always entails some risk. To stop the background service go to File > Preferences > Background Service and push the Stop button. You can also stop the service from an elevated CMD window by running:
net stop pdqdeploy

Copy the Database File(s)

There is really only one database file, but there are some other files you may want to copy as well (they're listed below).  The database is located in "%ProgramData%\Admin Arsenal\PDQ Deploy".  %ProgramData% will be vary depending on the version of Windows but it will generally be either "C:\ProgramData" or "C:\Documents and Settings\All Users\Application Data". 
You can just copy over the Database.db file to the new computer.  You can also copy over the Backups folder which contains backups from prior versions.  There may also be some compressed backup files in the database folder (they're named with the version that was backed up, such as Database.2.1.1.0.db.gz). There are some other files and folders you can copy as well, but they will be re-created on the new computer so there's no need. 
Note: There are a couple of temporary files called Database.db-shm and Database.db-wal that you will not want to copy.  It usually isn't a problem to copy them, but if they get out of sync with theDatabase.db file then it won't be possible to start PDQ Deploy until they are deleted.

Copy the Registry Key

There is a registry key to be exported and imported on the new computer.  This key holds one of the encryption keys used by PDQ Deploy and the license key (if in Pro Mode).  If you don't copy the encryption key a new one will be generated and you will need to re-enter the passwords for all stored credentials.  The registry key is "HKEY_LOCAL_MACHINE\SOFTWARE\Admin Arsenal\PDQ Deploy".

Verify Permissions

On the new computer check that the permissions set on the database folder are set to your liking.  When first installed PDQ Deploy will set the directory to only be accessible to members of the Administrators group.  You may need to set this manually after copying the directory. 

Set the Background Service credentials

The background service will be installed with the default "LocalSystem" account and will need to be set again to the admin user you're using.  Newer versions of PDQ Deploy will set this for you when you start up the console, but you will want to double-check that it gets done correctly.

Move your existing $(Repository) files and folders

If your $(Repository) folder is on the local drive of your old computer make sure to copy all the files and folders to the new location. By default the repository variable points to the following paths (depending on your OS). 

Windows Vista / 7 / 8 / 2008 / 2012 - %PUBLIC%\Documents\Admin Arsenal\PDQ Deploy\Repository

Windows XP / 2003 %AllUsersProfile%\Documents\Admin Arsenal\PDQ Deploy\Repository

If you stored your Repository on a network share (and you intend to keep it this way) you don't need to move any packages from your old Repository.

Any other packages that don't use the $(Repository) variable but otherwise have their respective Install Files stored on the local drive will also need to be moved to the new machine.