How to install BESclient in a batch file

We are trying to automate the installation of the client in a script by calling a batch file to install the client on the target server.

@buzz, while I haven’t tried this, @jgstew has a install_bigfix_universal.bat in his personal GitHub. There’s also a great post on this forum again by @jgstew named Thin Imaging and installing the BigFix agent that may be helpful.

1 Like

UPDATE:
This is the code we are using in an attempt to install the BigFix Client:
“C:\Users\someuser\Desktop\InstallBigfixClient\setup.exe” /i /L"1033" /v/quiet /v"INSTALLDIR=“D:\Program Files (x86)\BigFix Enterprise\BES Client”"

Inside of the InstallBigfixClient folder, we also have the clientsettings.cfg file, and the masthead.afxm file. Whenever we run our .BAT file, the installer runs, but doesn’t appear to be applying the additional settings from the CFG and AFXM files properly. When attempting to start the BigFix BESClient service, we receive the error “Windows could not start the BES Client on Local Computer. For more information, review the System Event Log. If this is a non-Microsoft service, contact the service vendor, and referto a service-specific error code 29.”

Manually running the exe works without issue, so the problem definitely lies with the script. Any suggestions?

@buzz, do you see the BESClient daily log files under the following path?

D:\Program Files (x86)\BigFix Enterprise\BES Client__BESData__Global\Logs

If so, what errors are you seeing in today’s yyyyMMdd.log under the above path on the endpoint that’s failing to start after installing.

Casey,

Found the logs, fixed the problem.

Thanks,
Jim

3 Likes

Correction: Found the logs. Problem still exists.

What error messages do you see in the daily BESClient log after running the action/fixlet in question?

I don’t think that having two /v parameters is valid for InstallShield packages. All of the MSI options should be in a single /v/quiet InstallDir="path" but I’m not sure how the quoting works, so it might take you a few tries to get that part.

1 Like

give this a try.

"C:\Users\someuser\Desktop\InstallBigfixClient\setup.exe" /s /v"INSTALLDIR="D:\Program Files (x86)\BigFix Enterprise\BES Client" REBOOT=ReallySuppress MSIRESTARTMANAGERCONTROL=Disable /qn"

1 Like

Thanks Mark! I will give that a try.

Unfortunately that didn’t work either.

Sorry, give this a go, the mst should actually be in the install folder on the target pc as well, it is located on your bigfix server here: Program Files (x86)\BigFix Enterprise\BES Installers\ClientMSI

"C:\Users\someuser\Desktop\InstallBigfixClient\setup.exe" /s /v"/L*vx! "D:\ClientInstallLog.log" INSTALLDIR="D:\Program Files (x86)\BigFix Enterprise\BES Client" TRANSFORMS=1033.mst REBOOT=ReallySuppress MSIRESTARTMANAGERCONTROL=Disable /qn"

This should also give us a log file

1 Like

Mark,

Thanks! we will give that a try.

Jim

This is likely due to a missing masthead, but I am not certain.

You need to change directory into that folder before invoking the bigfix installer, otherwise it will not pick up the masthead and clientsettings.cfg during install. They should be picked up from the current directory, which in this case is probably not the InstallBigfixClient directory.

cd C:\Users\someuser\Desktop\InstallBigfixClient

It also might not be ideal to run this out of a user folder, but I also don’t know why that would cause a specific problem either as long as the installation is being invoked with Admin rights and the Admin user is the same user as the user folder the installer is within. If the Admin user is not the same user invoking the installer from their user folder, then that would cause additional problems. I personally use something like C:\Windows\Temp or C:\Users\Public\Downloads or similar.

2 Likes