I work at a school, so applications like Microsoft Live Movie Maker are highly usefull in an educational environment. So I thought to myself: lets deploy this stuff throughout our network. Movie maker is a part of Live Essentials, but has some limiations though as I found out.
Firstly I deployed Live Essentials 2012 through GPO startup script. This is the script:
setlocal
REM ****************************************************************
REM Environment customization begins here. Modify variables below.
REM ****************************************************************
REM Set DeployServer to a network-accessible location containing the Office source files.
set DeployServer=\\server\share\WindowsLiveFolder
REM Set LogLocation to a central directory to collect log files.
set LogLocation=\\server\share\WindowsLiveFolder\logfiles
REM ****************************************************************
REM Deployment code begins here. Do not modify anything below this line.
REM ****************************************************************
REM check if this is Windows 7
if exist “C:\Users\All Users\ntuser.dat” goto win7
if exist “C:\Documents and Settings\All Users\ntuser.dat” goto End
:win7
reg query HKEY_CLASSES_ROOT\Applications\MovieMaker.exe
if %errorlevel%==1 (goto DeployApp) else (goto End)
REM If 1 returned, the product was not found. Run setup here.
:DeployApp
start /wait %DeployServer%\WLSetup-all.exe /q /NOToolbarCEIP /NOhomepage /Nolaunch /nosearch /AppSelect:MovieMaker
echo %date% %time% Setup ended with error code %errorlevel%. >> %LogLocation%\%computername%.txt
REM If 0 or other was returned, the product was found or another error occurred. Do nothing.
:End
Endlocal
The script first checks if it is dealing with a Windows 7 installation. If not it ends since Live Movie Maker 2012 is not supported on XP (we don’t have any Vista so I’m ignoring this OS). Then the script checks if Movie Maker is allready installed. Otherwise it would try to install it at every boot, slowing down the machine. Finally it installs moviemaker and writes the results to a logfile. In this way you can monitor wich machines have sucessfully installed your app.
Then I created a new gpo and added a computer startup script to it under Group Policy object/Computer Configuration/Windows Settings/Scripts (Startup/Shutdown).
But now the problems occured. It seemed a number of computers were to old to run direct x 10, wich is a requirement of Live Moviemaker 2012. Live Moviemaker 2011 however runs on machines with directx 9.x (for more info http://windows.microsoft.com/en-US/windows-live/movie-maker-system-requirements-ui)
So a downgrade was necessary, but Live Essentials doesn’t have a clean unattended uninstall function. So I searched the registry for the uninstall strings of all the components of Live Essentials. I came up with the following list
start /WAIT “Uninstalling Windows Live Communications Platform” MsiExec.exe /X{0454BB9A-2A7A-4214-BDFF-937F7A711A44} /qn
start /WAIT “Uninstalling Photo Gallery” MsiExec.exe /X{30F99474-EBE3-4134-A02B-F6CD38CFE243} /qn
start /WAIT “Uninstalling Windows Live UX Platform Language Pack” MsiExec.exe /X{4AA2A466-8031-403A-8236-5301B4E391FB} /qn
start /WAIT “Uninstalling Windows Live UX Platform” MsiExec.exe /X{4CCBD1F4-CEEC-452A-9CB8-46564B501315} /qn
start /WAIT “Uninstalling Windows Live PIMT Platform” MsiExec.exe /X{6A8DB215-7BCD-4377-B015-2E4541A3E7C6} /qn
start /WAIT “Uninstalling Photo Common” MsiExec.exe /X{743FD554-A73F-4FE8-BE7B-C283D16297F9} /qn
start /WAIT “Uninstalling Windows Live SOXE Definitions” MsiExec.exe /X{8A642ACD-CE3A-4A23-A8B1-A0F7EB12B214} /qn
start /WAIT “Uninstalling MSVCRT” MsiExec.exe /X{8DD46C6A-0056-4FEC-B70A-28BB16A1F11F} /qn
start /WAIT “Uninstalling MSVCRT110” MsiExec.exe /X{8E14DDC8-EA60-4E18-B3E3-1937104D5BDA} /qn
start /WAIT “Uninstalling Movie Maker” MsiExec.exe /X{AE8044B5-FCA3-4EBE-AC78-0FB3A6E8DC76} /qn
start /WAIT “Uninstalling Windows Live Essentials” MsiExec.exe /X{B7F31B9C-8775-4500-8E9D-6ABE9AE17CF4} /qn
start /WAIT “Uninstalling Windows Live Installer” MsiExec.exe /X{C424CD5E-EA05-4D3E-B5DA-F9F149E1D3AC} /qn
start /WAIT “Uninstalling Windows Live Photo Common” MsiExec.exe /X{C9B6EFD0-4F01-4BBA-8374-39AD99A3ED72} /qn
start /WAIT “Uninstalling D3DX10” MsiExec.exe /X{E09C4DB7-630C-4F06-A631-8EA7239923AF} /qn
start /WAIT “Uninstalling Movie Maker” MsiExec.exe /X{ED6C77F9-4D7E-447C-9EC0-9A212D075535} /qn
start /WAIT “Uninstalling Microsoft SQL Server 2005 Compact Edition [ENU]” MsiExec.exe /X{F0B430D1-B6AA-473D-9B06-AA3DD01FD0B8} /qn
start /WAIT “Uninstalling Photo Gallery” MsiExec.exe /X{F67CA22C-C11F-4573-8406-57F75BA06B51} /qn
start /WAIT “Uninstalling Windows Live SOXE” MsiExec.exe /X{FE7C0B3D-50B9-4951-BE78-A321CBF86552} /qn
start /WAIT “Microsoft Office Outlook Connector” MsiExec.exe /X{95140000-007A-0409-0000-0000000FF1CE} /qn
The /X means “uninstall” and the /qn switch means quiet and no interface. This is necessary because we are running this as a computer startup script. Remember allso that I only choose to install Movie Maker and none of the other components. If you install everything you should search the key HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall on 64-bit windows 7 and HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall on 32-bit windows 7 for Live Essentials components. The uninstall string is located in the UninstallString property. Just remember to change /I to /X and add /QN to the end.
The work is not done however: when you try to install live essentials 2011 after this, the installer claims that there is a newer version installed. This is caused by some leftover files in the common program files. Running
rd /S /Q “c:\Program Files (x86)\Common Files\Windows Live”
on 64-bit and
rd /S /Q “c:\Program Files\Common Files\Windows Live”
on 32-bit will solve this.
The last step is to run the installer for Live Essentials 2011
WLSetup-all.exe /q /NOToolbarCEIP /NOhomepage /Nolaunch /nosearch /AppSelect:MovieMaker
All done! So this is the complete script
setlocal
REM *********************************************************************
REM Environment customization begins here. Modify variables below.
REM *********************************************************************
REM Set DeployServer to a network-accessible location containing the Office source files.
set DeployServer=\\server\share\WindowsLive2011
REM Set LogLocation to a central directory to collect log files.
set LogLocation=\\server\share\2011\logfiles
REM *********************************************************************
REM Deployment code begins here. Do not modify anything below this line.
REM *********************************************************************
REM check if this is Windows 7
if exist “C:\Users\All Users\ntuser.dat” goto checkversion
if exist “C:\Documents and Settings\All Users\ntuser.dat” goto End
:checkversion
rem check if this 64-bit
reg query HKLM\SOFTWARE\Wow6432Node
if %errorlevel%==1 (goto 32bit) else (goto 64bit)
rem if version 2012 is found a downgrade is necessary
:64bit
set progfiles=”c:\Program Files (x86)\Common Files\Windows Live”
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\WinLiveSuite /f 16.4.3505.0912
if %errorlevel%==1 (goto win7) else (goto remove)
:32bit
set progfiles=”c:\Program Files\Common Files\Windows Live”
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\WinLiveSuite /f 16.4.3505.0912
if %errorlevel%==1 (goto win7) else (goto remove)
:remove
start /WAIT “Uninstalling Windows Live Communications Platform” MsiExec.exe /X{0454BB9A-2A7A-4214-BDFF-937F7A711A44} /qn
start /WAIT “Uninstalling Photo Gallery” MsiExec.exe /X{30F99474-EBE3-4134-A02B-F6CD38CFE243} /qn
start /WAIT “Uninstalling Windows Live UX Platform Language Pack” MsiExec.exe /X{4AA2A466-8031-403A-8236-5301B4E391FB} /qn
start /WAIT “Uninstalling Windows Live UX Platform” MsiExec.exe /X{4CCBD1F4-CEEC-452A-9CB8-46564B501315} /qn
start /WAIT “Uninstalling Windows Live PIMT Platform” MsiExec.exe /X{6A8DB215-7BCD-4377-B015-2E4541A3E7C6} /qn
start /WAIT “Uninstalling Photo Common” MsiExec.exe /X{743FD554-A73F-4FE8-BE7B-C283D16297F9} /qn
start /WAIT “Uninstalling Windows Live SOXE Definitions” MsiExec.exe /X{8A642ACD-CE3A-4A23-A8B1-A0F7EB12B214} /qn
start /WAIT “Uninstalling MSVCRT” MsiExec.exe /X{8DD46C6A-0056-4FEC-B70A-28BB16A1F11F} /qn
start /WAIT “Uninstalling MSVCRT110” MsiExec.exe /X{8E14DDC8-EA60-4E18-B3E3-1937104D5BDA} /qn
start /WAIT “Uninstalling Movie Maker” MsiExec.exe /X{AE8044B5-FCA3-4EBE-AC78-0FB3A6E8DC76} /qn
start /WAIT “Uninstalling Windows Live Essentials” MsiExec.exe /X{B7F31B9C-8775-4500-8E9D-6ABE9AE17CF4} /qn
start /WAIT “Uninstalling Windows Live Installer” MsiExec.exe /X{C424CD5E-EA05-4D3E-B5DA-F9F149E1D3AC} /qn
start /WAIT “Uninstalling Windows Live Photo Common” MsiExec.exe /X{C9B6EFD0-4F01-4BBA-8374-39AD99A3ED72} /qn
start /WAIT “Uninstalling D3DX10” MsiExec.exe /X{E09C4DB7-630C-4F06-A631-8EA7239923AF} /qn
start /WAIT “Uninstalling Movie Maker” MsiExec.exe /X{ED6C77F9-4D7E-447C-9EC0-9A212D075535} /qn
start /WAIT “Uninstalling Microsoft SQL Server 2005 Compact Edition [ENU]” MsiExec.exe /X{F0B430D1-B6AA-473D-9B06-AA3DD01FD0B8} /qn
start /WAIT “Uninstalling Photo Gallery” MsiExec.exe /X{F67CA22C-C11F-4573-8406-57F75BA06B51} /qn
start /WAIT “Uninstalling Windows Live SOXE” MsiExec.exe /X{FE7C0B3D-50B9-4951-BE78-A321CBF86552} /qn
start /WAIT “Microsoft Office Outlook Connector” MsiExec.exe /X{95140000-007A-0409-0000-0000000FF1CE} /qn
rem del
rd /S /Q %progfiles%
:win7
reg query HKEY_CLASSES_ROOT\Applications\MovieMaker.exe
if %errorlevel%==1 (goto DeployApp) else (goto End)
REM If 1 returned, the product was not found. Run setup here.
:DeployApp
start /wait %DeployServer%\WLSetup-all.exe /q /NOToolbarCEIP /NOhomepage /Nolaunch /nosearch /AppSelect:MovieMaker
echo %date% %time% Setup ended with error code %errorlevel%. >> %LogLocation%\%computername%.txt
REM If 0 or other was returned, the product was found or another error occurred. Do nothing.
:End
Endlocal
References