Upgrading Windows Operating System
From BPWiki
When upgrading Windows Operating System the following notes may help
Contents
Prerequesites
- New Windows Operating System Install Media
- New Windows Operating System Install Key
- Any licensed software Install Media and Key (e.g. Office 2010)
Before Starting
- Ensure Windows Updates are current
- Install Windows Easy Transfer if required (e.g. Windows XP)
Saving Install State
- Export the registry for the system and each user to the Desktop (you never know!)
- If the user has a special folder on another drive (e.g. My Documents), make a note of it and move back to the default drive but do not move the files, leave in place
- Run the PowerShell script below to extract installed program names and versions
$computername=$env.computername
#Define the variable to hold the location of Currently Installed Programs
$array = @()
#Create an instance of the Registry Object and open the HKLM base key
$reg=[microsoft.win32.registrykey]::OpenRemoteBaseKey('LocalMachine',$computername)
# Do 64 bit then 32 bit
$UninstallKey="SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall"
#Drill down into the Uninstall key using the OpenSubKey Method
$regkey=$reg.OpenSubKey($UninstallKey)
#Retrieve an array of string that contain all the subkey names
$subkeys=$regkey.GetSubKeyNames()
#Open each Subkey and use GetValue Method to return the required values for each
foreach($key in $subkeys){
$thisKey=$UninstallKey+"\\"+$key
$thisSubKey=$reg.OpenSubKey($thisKey)
$obj = New-Object PSObject
$obj | Add-Member -MemberType NoteProperty -Name "DisplayName" -Value $($thisSubKey.GetValue("DisplayName"))
$obj | Add-Member -MemberType NoteProperty -Name "DisplayVersion" -Value $($thisSubKey.GetValue("DisplayVersion"))
$obj | Add-Member -MemberType NoteProperty -Name "Publisher" -Value $($thisSubKey.GetValue("Publisher"))
$array += $obj
}
# Do 32 bit then 64 bit keys
$UninstallKey="SOFTWARE\\Wow6432Node\\Microsoft\\Windows\\CurrentVersion\\Uninstall"
#Drill down into the Uninstall key using the OpenSubKey Method
$regkey=$reg.OpenSubKey($UninstallKey)
#Retrieve an array of string that contain all the subkey names
$subkeys=$regkey.GetSubKeyNames()
#Open each Subkey and use GetValue Method to return the required values for each
foreach($key in $subkeys){
$thisKey=$UninstallKey+"\\"+$key
$thisSubKey=$reg.OpenSubKey($thisKey)
$obj = New-Object PSObject
$obj | Add-Member -MemberType NoteProperty -Name "DisplayName" -Value $($thisSubKey.GetValue("DisplayName"))
$obj | Add-Member -MemberType NoteProperty -Name "DisplayVersion" -Value $($thisSubKey.GetValue("DisplayVersion"))
$obj | Add-Member -MemberType NoteProperty -Name "Publisher" -Value $($thisSubKey.GetValue("Publisher"))
$array += $obj
}
$array.GetEnumerator() | Sort-Object DisplayName | select DisplayName, DisplayVersion, Publisher | ft -auto
- Perform any special steps for Chrome, Firefox, Thunderbird etc
- Backup each user using Windows Easy Transfer
Special Steps for Firefox and Thunderbird
- On Old System
- Upgrade Firefox and/or Thunderbird to Current Version
- Intall MozBackup
- Backup each users data using MozBackup
- On New System
- Install Firefox and/or Thunderbird to same current version
- Install same version of MozBackup
- Restore each users data using MozBackup
New Installation
- Install new operating system
- Do not create new users, restore using Easy Transfer
- Move users special folders to old locations if using the non-system drive
- Reinstall licensed software