Posted on 10-12-2011 04:35 PM
Good morning.
I have packaged each of our Adobe point products and they are available from Self Service.
I have developed a script that determines if a machine has enough hard drive space available for the download and install.
How can I ask the script to invoke the install or not depending on the availability of hard drive space. I have used the jamf message command to inform the user they need to free up some space, but then I want the script to stop the self service install going ahead.
Thanking you in advance.
Chris.
Posted on 10-12-2011 07:37 PM
Are you really in a place where a majority of your users - who, as I would assume given your terse explanation - already have Adobe products installed on their machines, but yet somehow don't have enough space on their HDs to have Adobe updates? To that end, why limit the question to Adobe products? Does everyone have enough room for 10.7.2 for that matter? Is everyone at St. Joseph's using SSDs and keeping all their Midnight Oil albums on their business machines or something?
I kid. I love Midnight Oil. I have all their albums (and the live recordings) -- but even at lossless, all their stuff only comes in at like 700MB or something on AIFF, so what gives? ;)
I should think that if space were so much a consideration, you'd be dealing with far more severe trouble tickets than merely Adobe updates. Perhaps you need to rethink this a bit. But if you must... I rather doubt you are in a position to know what exact amount of space or swap space is needed to update, well.. anything.
Rule of thumb is less than 10% of the max gets you into trouble - it sucks for "regular" HDs, but it's the end of the show for SSDs as they hit a brick wall in most cases.
Casper can't compensate for poor planning and workflows. If you have lots of people who are filling up their HDs to the point where mere updating causes problems, than you need to rethink the entire support apparatus or at least storage infrastructure. The level of interactivity you want via scripting is a fool's errand, you can't script yourself to stability no matter how solid your skills. Hand holding does no end user favors - and will more than likely place your enterprise in certain jeopardy. The new self service can do some cool stuff, but only if you have end user interaction. If you have a problem with updating on this level, I'd rather think you not are going to get them to click on the Self Service app in the first place.
BTW - what the heck is an "Adobe Point Product"? Do you get points if you use the product, and if so - what do you get? I hope it's drink tickets like the CCA gets you.
Namaste, friend,
Michael Crispin
Duke University
Posted on 10-13-2011 06:57 AM
I would use an if/then or case statement in the shell script to trigger your
install using policy triggers. So, you have your Self Service policy that
runs the script, and then each of the Adobe installs are triggered by a
policy trigger.
For example, if I were creating one to install Soundbooth, I would have two
policies:
Policy 1: this is the SS policy, and the only thing it does is run the
script that checks hard drive space and then triggers the actual install.
Let's call it "soundboothinstall.sh".
Policy 2: this is the policy that actually installs Soundbooth. It is set
to "Triggered by: other" in the General tab of the policy. I would then
give it a Manual Trigger of "cs4sound" or whatever you want.
Now, in the script "soundboothinstall.sh" you would have something like this
(and this is completely off the top of my bald head):
#!/bin/sh
checkHDSpace=`some commands to get space'
if [ $checkHDSpace = some size ]; then
/usr/sbin/jamf policy -trigger cs4sound
else
/usr/sbin/jamf displayMessage -message "You do not have enough space
available on your hard drive, please free up some space and then run the
Self Service policy again."
fi
exit 0
Now, that is completely off the top of my head, so you want to flesh it out
a bit more and test. However, that should accomplish what you need it to.
Steve Wood
Director of IT
swood at integer.com
The Integer Group | 1999 Bryan St. | Ste. 1700 | Dallas, TX 75201
T 214.758.6813 | F 214.758.6901 | C 940.312.2475