Some bundle actions fail with "Exit code: 1" after upgrade to ZCM 11.2.1

  • 7010643
  • 17-Aug-2012
  • 09-Nov-2012

Environment

Novell ZENworks Configuration Management 11.2 Bundles

Situation

On devices with ZCM agent 11.2.1, bundles with "Launch Executable" actions may fail: for example DOS commands like "net.exe" may fail with "Exit code: 1". These worked with ZCM 11.2

Resolution

This is fixed in version 11.2.2 - see KB 7010757 "ZENworks Configuration Management 11.2.2 - update information and list of fixes" which can be found at https://support.microfocus.com/kb/doc.php?id=7010757

Workaround:
1) use cmd.exe as the executable and pass "/c" and the desired command as parameters, e.g.,
/c C:\Windows\system32\net.exe use q: \\myserver\myshare
or
2) use the full path to the executable, e.g.,
C:\windows\system32\net.exe
Note: using ${winsysdir}\net.exe results in a failure with "Exit code: 2"

Cause

ZCM is adding quotes around the parameters, so the command does not recognize them.
For example, an action to execute
net
with parameters
use q: \\myserver\myshare
will launch in  ZCM 11.2 as
"C:\Windows\system32\net.exe" use q: \\myserver\myshare
but in ZCM 11.2.1 as
"C:\Windows\system32\net.exe" "use q: \\myserver\myshare"