Udostępnij za pośrednictwem


App-V Cache Configuration Tool running silently

One of the best features in the resource kit is the App-V Cache Configuration Tool. So far it has got me fixed up on a number of really silly issues when I have been testing App-V and left my self short.

Once you download the tool from …. and extract the tool to its separate folder you are left with a three items;

App-V_CacheResiz_RdMe.chm
AppVCacheSize.exe
cachesize-eula.rtf

Anyway, so onwards to my story. There I was doing my charity work for my school. And suddenly I realised I had made a change from 4.1 to 4.5. This change was to allow my clients to background stream the remainder of the packages. What I did not think about at the time is that I had left my cache sizes a bit too low. The clients all of a sudden started to completely fill the app-v cache to the limits with packages. Oh dear…. what a silly old sole I had been.

Still I remembered about this great little resource kit tool and started to come up with a command line to push out via SCCM.

For those that don't know the App-V Cache Configuration Tool can run via the command line AppVCacheSize.exe [/f|/s]:<size>

/f  Specifies the minimum amount free disk space for the client cache
/s  Specifies the maximum cache size.
<size>   Specifies the size in megabytes.

For example AppVCacheSize /f:2048

Now back to my story. So i thought this is a doddle 10 minute job, role the command out to the estate via SCCM and that's it my job here is done!!!!

hmmmmmmmmmm how wrong. Now obviously i wanted to use SCCM for its slick immediate distribution of commands :o) Not only that but the ability to silently role these commands out without anyone knowing. Here began a slight inconvenience. You need to accept the licence agreement on the host machine before the command can run.

clip_image002

Now this agreement needs a user to agree to the license terms and conditions. The EULA is also in a rtf file that is extracted when you download it. YOU MUST READ THIS AND AGREE TO IT.

Anyway if you run the command AppVCacheSize /f:2048 the SCCM push user will try and deliver this application to the host machine (depending on your collections/advertisement). The problem is if you have not accepted the agreement the application will just sit there waiting for someone to agree to the licence rights before allowing you to run the command.

Now to get around this you need to modify a regkey, again this could pushed out via SCCM prior to the AppVCacheSize.exe command.

The registry key set on a per-user basis to indicate acceptance of the license.  If you set the following registry key prior to running AppVCacheSize , the prompt goes away:

HKCU\Software\Microsoft\AppVTools\CacheSizeTool

EulaAccepted DWORD 1

The way around this is to use the something like the SCCM task sequencer or chain your packages for deployment with the regkey before hand and then the command will complete successfully. Remember my goal here is to do an update to the client cache silently so that no one will ever know anything happened!

Again you can deploy the registry entry in a number of ways…… this is just one way that worked for me.

I hope that this helps someone. Please check out the resource kit tools as these will keep your App-V Estate to its optimized levels!

Comments