Installing Novell ZEN-Works Client in SCCM OSD Tasksequence

Hi there,

I know, I know, why would you install the ZENworks Client when you got SCCM? Well, sometimes that¬īs just the way it is…

Installting the ZENwork Clients is not as easy as it may seem. There is an installer that brings everything needed and so I started by just running that installer during the OSD Tasksequence. But the result was really disappointing: Sometimes the Installation would work, sometimes not, sometimes the device would be registered, sometimes the device would remain in a state where it was impossible to repair the ZENwork Client.

Nearly giving up, I searched again and found a blog post by Vaughn Miller, where he describes how he installs the ZENworks Client with MDT.

Long Story short: The ZENworks installer starts up to 52 separate installers. The last one it starts is called Setup.exe. Voughn wrote a vbs-script waiting for this Setup.exe and stopping the script when this Setup.exe has finished.

Beeing a PowerShell Guy, I rewrote the script and put this script into the OSD Tasksequence:

Here is the script:


D:\yourfiles\ZCM\PreAgentPkg_AgentCompleteX64.exe -q -x

$loop = 1

do {

Start-Sleep 5

$isrunning = get-process setup -ErrorAction SilentlyContinue

if ($isrunning) {$loop = 0}

}

until ($loop -eq 0)

$2ndloop = 1

do {

Start-Sleep 5

$isrunning = get-process setup -ErrorAction SilentlyContinue

if (!$isrunning) {$2ndloop = 0}

}

until ($2ndloop -eq 0)


What is this script doing?

1. It starts the installer

2. It checks if Setup.exe is running (in a Loop)

3. When Setup.exe is running, it checks if Setup.exe is not running any more

4. The script finishes.

Now we can put this script in a Package, distribute it to our DPs and run it in the OSD Tasksequence.

The tasksequence will wait until the script is finished and proceed to the next step.

As a result we get the ZCM-agent installed and the device registered in ZENworks correctly. ūüôā

Thanks to Voughn!

 

Leave a Reply

Your email address will not be published. Required fields are marked *