Re: Deploying CPM always failed on the same spot

(imported topic written by LuisTorres)

hello

I’m trying to install on some machines but CPM and some tell me that the action is unsuccessful, in the action information I can see that the error is always on the same line

Fail waithidden “{download path “TMCPMInstaller.exe”}” -f “multi-language” -i “{name of drive of system folder & “” & following text of last “” of value of variable “ProgramFiles” of environment & “\Trend Micro”}”

Completado

// action script to deploy CPM Endpoint application

Completado

begin prefetch block

Completado

if {((name of it as lowercase = “win8.1” or name of it as lowercase = “win2012r2”) of (operating system))}

Completado

if {x64 of operating system}

Completado

add prefetch item name=TMCPMInstaller.exe sha1=6fb79a5da6fcfb9407638d245967302db782c20c size=131754009 url=http://esp-download.trendmicro.com/download/cpm/TMCPMInstaller_x64_10.6.0.3021_en.exe

Completado

else

Completado

// add prefetch item for 32-bit installer

Completado

add prefetch item name=TMCPMInstaller.exe sha1=ff7e15bdd316fb2faed685a60facd20ec5085315 size=114466116 url=http://esp-download.trendmicro.com/download/cpm/TMCPMInstaller_x86_10.6.0.3021_en.exe

Completado

endif

Completado

else

Completado

if {x64 of operating system}

Completado

add prefetch item name=TMCPMInstaller.exe sha1=2034f356a8a2f18c0af7799ec63bbc10dfa0485b size=131720166 url=http://esp-download.trendmicro.com/download/cpm/TMCPMInstaller_x64_10.6.0.3014_en.exe

Completado

else

Completado

// add prefetch item for 32-bit installer

Completado

add prefetch item name=TMCPMInstaller.exe sha1=6bebc7cd3e2de6e619d08d4984a907efd7fcad54 size=114434959 url=http://esp-download.trendmicro.com/download/cpm/TMCPMInstaller_x86_10.6.0.3014_en.exe

Completado

endif

Completado

endif

Completado

end prefetch block

Completado

// specify custom install path

Completado

action parameter query “install_path” with description “Specify an installation path%0A%0AFor default installation path, leave blank”

Completado

// *** CHECK *** Action fails here if install path contains %environment_variables% OR illegal characters " ? * | / < > and :

Completado

// OR if the path has no drive letter specified, i.e. “\folder1\folder2”

Completado

continue if {(if (it = “”) then (true) else ((not exists matches (regular expression “[%25%22?|/<>:]") of it) of ((parenthesized part 3 of matches (regular expression "^(\w+):(\)?(.)$”) of it) as string) of (if (it starts with “%22” AND it ends with “%22”) then ((preceding text of position (length of it - 1) of it) of (following text of position 1 of it) of it) else (it)))) of ((parameter “install_path” of action) as string)}

Completado

// *** CHECK *** Action fails here if default install path ("") OR custom install path does not contain a valid drive that meets minimum 700 MB space requirement

Completado

continue if {(if (it = “”) then (exists it whose (type of it = “DRIVE_FIXED” AND free space of it >= 70010241024) of (drive of parent folder of client)) else (if (exists parenthesized part 2 of matches (regular expression “^(%22)?(\w):”) of it) then ((exists drive it whose (type of it = “DRIVE_FIXED” AND free space of it >= 70010241024)) of ((parenthesized part 2 of matches (regular expression “^(%22)?(\w):”) of it as string) & “:”)) else (false))) of ((parameter “install_path” of action) as string)}

Completado

//delete CPMInstallResult.log

Completado

delete “{pathname of windows folder}\CPMInstallResult.log”

Completado

//rename temp file(if exist) at SYSTEMDRIVE before running installer

Completado

if {exist file ((value of variable “SYSTEMDRIVE” of environment) & “” & “temp”)}

Completado

move {((value of variable “SYSTEMDRIVE” of environment) & “” & “temp”)} {((value of variable “SYSTEMDRIVE” of environment) & “” & “temp_trendmicrocpm”)}

Completado

endif

Completado

continue if { not exist file ((value of variable “SYSTEMDRIVE” of environment) & “” & “temp”)}

Completado

// run installer. To avoid a Windows API bug, the -i option should always be the last one

Completado

if {((parameter “install_path” of action)) as string = “”}

Completado

// default path

Completado

if {version of client < “8.0”}

Completado

waithidden “{download path “TMCPMInstaller.exe”}” -l “en” -i “{name of drive of system folder & “” & following text of last “” of value of variable “ProgramFiles” of environment & “\Trend Micro”}”

Completado

else

Fail

waithidden “{download path “TMCPMInstaller.exe”}” -f “multi-language” -i “{name of drive of system folder & “” & following text of last “” of value of variable “ProgramFiles” of environment & “\Trend Micro”}”

(imported comment written by Xie_Ran91)

You may try to debug a bit yourself by checking the logs and exit code

C:\Windows\CPMInstallResult.log

Error Code   Definition
0                Installation or Migration Success
-1               Not Supported Platform
-2               Extract Install Package Fail
-3               No Enough Disk Space
-4               No Administrator Privilege
-5               Detect Newer CPM Installed
-6               Require Reboot Before Installation or Migration
-7               Start Services Failed
-8               Stop Services Failed
-9               Wait Timeout
-10              Another Installer Exist
-11              Invalid Timeout
-12              Copy File Failed
-13              Unknown Error
-14              Configure File Missed
-15              Invalid Argument
-16              Detect OSCE Exist for Fresh Install
-17              Detect CPM Corrupted before Migration
-18              Uninstall Competitor's Product Fail

If there is still issue, please contact the IBM support and they will give you detailed instruction for log collection and help you debug.

  • Xie Ran