Groupe des Utilisateurs Altiris Suisses et Francophones Group

 View Only

Sample script to deploy agent from Startup machine 

Jun 13, 2012 05:34 PM

I just correct the script gived from Gilles, to add the NS server name (to change yours).

Notice: not tested yet this one. Notice also: best to install a data partition, if available, instead a system partition !! :)

You should put, the msi file (from <\\SMPserver\NSCap\bin\Win32\X86\NS Client Installation>) and this script into NETLOGON domain folder, and add a GPO to run it at machine startup.

I would like to test if the system is a server with a data partition, or a workstation a single C drive, to deploy different path according the system type.

@echo off

set MYALTIRISPATH=%programfiles%\Altiris
if exist "%MYALTIRISPATH%\Altiris7agent.log" exit 183

rem remove all plug-in et agent altiris
if exist "%MYALTIRISPATH%\Altiris Agent\AeXNSAgent.exe" start "" /b /wait "%MYALTIRISPATH%\Altiris Agent\aexagentutil.exe" /uninstallagents /clean

rem cleanup Setup folder
if exist "%MYALTIRISPATH%\Setup Files\." rd /S /Q "%MYALTIRISPATH%\Setup Files"

rem cleanup eXpress folder
if exist "%MYALTIRISPATH%\eXpress\." rd /S /Q "%MYALTIRISPATH%\eXpress"

rem cleanup Carbon Copy folder
if exist "%MYALTIRISPATH%\Carbon Copy\." rd /S /Q "%MYALTIRISPATH%\Carbon Copy"

rem cleanup Altiris Agent folder
if exist "%MYALTIRISPATH%\Altiris Agent\." rd /S /Q "%MYALTIRISPATH%\Altiris Agent"

rem install latest agent from altiris server msi
start "" /b /wait MsiExec.exe /i "AeXNSCInstSvc.msi" NS="SMPserver" /qn

echo "Altiris 7 Agent install finished" > "%MYALTIRISPATH%\Altiris7agent.log"

Thanks a lot the author: gbs916

Statistics
0 Favorited
0 Views
0 Files
0 Shares
0 Downloads

Tags and Keywords

Related Entries and Links

No Related Resource entered.