Client Agent Patch

Jan 12, 2012 at 6:17 PM

Hi pr3m, how are you?

I would like to know if is this possible to add the option PATCH="" on SCCM install client feature?

I use this command line to install and update my client

Ccmsetup.exe /service /Source:"\\SERVER\CLIENT" PATCH=\\Server\CLIENT\i386\hotfix\KB977384\update1.msp;\\Server\client\i386\hotfix\KB2586709\update2.msp

Best Regards.

Luis

Coordinator
Jan 12, 2012 at 10:33 PM

Yeah, I was actually considering adding PATCH property support to client install GUI, but then I thought that in order to enable specifying possibly multiple patch paths, it would require extra space in already bumped up area. So, I thought that anything that can't be configured in GUI can always be set in "ccmsetupParameters" value in config.ini. I admit that it would be great to control all setup parameters in user friendly GUI.

I will add this request as a low priority so that if I happen to work on GUI, I might as well figure out some way to support PATCH property.

Thank you for the feedback!

Jan 16, 2012 at 2:48 PM

Would definitely be a nice feature.

Nov 22, 2012 at 2:25 AM
Edited Nov 22, 2012 at 2:36 AM

Hello all,

Thanks for CAT! This save a lot of time for us.

Today, I was trying to list about 14 KBs (SCCMClientHotfixes) as part of CCMSetupParameters with PATCH= MSI Public Properties.

Due to possible limitation of the commandline length (e.g. 1024 on Client Push Settings), I managed to make it short by using PATCH=\\ServerName\1$\KBxxxxxx.msp;\\ServerName\1$\KBxxxxxx.msp;\\ServerName\1$\KBxxxxxx.msp; and so forth.

It works great when I have only 3 MSP listed. However, when I added 14 KBs all listed (477 letters in total) as follows, it doesn't trigger the install:

/service SMSSITECODE=AUTO FSP=SERVERNAME SMSCACHESIZE=8000 RESETKEYINFORMATION=TRUE PATCH=\\SERVERNAME\1$\kb978754.msp;\\SERVERNAME\1$\kb979199.msp;\\SERVERNAME\2$\kb2276865.msp;\\SERVERNAME\2$\kb2278119.msp;\\SERVERNAME\2$\kb2309968.msp;\\SERVERNAME\2$\kb2509007.msp;\\SERVERNAME\2$\kb2516517.msp;\\SERVERNAME\2$\kb2516850.msp;\\SERVERNAME\2$\kb2586709.msp;\\SERVERNAME\2$\kb2659258.msp;\\SERVERNAME\2$\kb2672863.msp;\\SERVERNAME\2$\kb2678547.msp;\\SERVERNAME\2$\kb2724939.msp

The log says  

--------------------------------------
Running action "Install SCCM client" on computers...
** Successfully scheduled SCCM client install on [ComputerName]!
--------------------------------------

When I opened ClientActionsTool.hta and uncomment the line 658 for MsgBox, it showed everything as specified above for ccmsetupCustomParameters.

I am not sure what the root cause is but I think it is something to do with maximum length on objWMIProcess.Create function (line 2801)

Can you take a look and find out what need to be done to list them all (under 1024 letters), please?

Thanks in advance.

 

Nov 22, 2012 at 2:58 AM

Here is the answer...

It turned out that AT command can handle up to 259 letters in total.

When I run at hh:mm /interective echo 111111111111111111111111111111111111111111111111 (... up to 500) > test.txt, it returned:

The command line cannot exceed 259 characters.
Invalid command.

So, unless we use some other method other than AT, we are limited to 259 letters for both ccmsetupPath and ccmsetupCustomParameters...

Can someone address this limitation?

Thanks,

Young-

Coordinator
Nov 22, 2012 at 5:58 PM

Thank you for providing the information about AT command. I never tested it with longer command lines.

Anyway, I believe this is something that CAT must live with unless someone comes up with a customization. I've decided to stop the development of CAT but continue supporting the project.

Nov 22, 2012 at 7:32 PM

Hi Pr3m,

Thanks for the reply.

I stayed late to find out the best way to deal with and I was thinking about the following customization:

  1. Prep
    1. Making a network share (e.g. \\ServerName\CCMSETUP\ )
    2. Put all Client files including all hotfixes under \\ServerName\CCMSETUP\0
    3. Rename all hotfixes to KBxxxxxx.MSP
  2. Create a batch file 1 (or VBscript) for the following and place it on \\ServerName\CCMSETUP\ (e.g. _CATInstallClient_Locally.bat)
    1. Check strCurrentPath
    2. Formulate ccmsetup.exe based on the current path
    3. Runs the full ccmsetup.exe command with up to 1024 letters based on the current folder location (e.g. PATCH=%strCurrentPath%\0\KBxxxxxx.MSP;%strCurrentPath%\0\KBxxxxxx.MSP;.... )
  3. Create a batch file 2 and place it on CAT folder to run via CAT (e.g. _CATTriggerInstallClient.bat)
    1. Copy everything from \\ServerName\CCMSETUP\ to C:\_ESD\1 (Lack of better choice. Unique, short and hidden from the root.)
    2. Set AT command to trigger the batch file 1
  4. Update CAT.HTA (line 280x) to
    1. Call batch file 2 to copy and trigger batch file 1 remotely.
    2. Update HTML portion to display "Instruction" how to customize these 2 batch files for your environment, etc.

However, I ran out of my "budgeted" time and could not make it work (mostly network access, permission handling and elevation, etc. issue)

If you give me some hint/guidance especially for the step 4 how you would approach this, I can figure something out.

BTW, do you think this CAT would work with SCCM 2012?

As it is using WMI everywhere, I don't see why not other than log format need to be updated for CMTrace.exe instead of Trace32.exe...

Thanks,