Scripts not executing either by Policy for via Casper Remote

abz_mungul
New Contributor III

Hi

was wondering if anyone could help out with this

I'm using a VPN script that Cem created which works a treat, but I find when I try deploying the script either at imaging time, casper remote or via Policies that it fails

Here is what I'm getting

/usr/sbin/jamf is version 8.22
Executing Policy 2012-01-04 at 1:40 PM | administrator | 1 Computer...
Mounting afp://buildbox-lon3.imagination.com/CasperShare to /Volumes/CasperShare...
Installing Imagination VPN.dmg...
Closing package...
Running Script hong_kong_vpn.sh...
Script Exit Code:0
Script Result: Variable "vpnFilePath" value is set to: /Applications/Utilities/Hong Kong VPN.networkConnect
Assistive Device Access is already enabled.
Importing Network Adapter...
Renaming the VPN interface to Hong Kong VPN...
The following network adapters are present after the import:
An asterisk () denotes that a network service is disabled.
Bluetooth DUN
Ethernet
AirPort
Hong Kong VPN
Running Script london_vpn.sh...
Script Exit Code:0
Script Result: Variable "vpnFilePath" value is set to: /Applications/Utilities/London VPN.networkConnect
Assistive Device Access is already enabled.
Importing Network Adapter...
LSOpenURLsWithRole() failed with error -10810 for the file /Applications/Utilities/London VPN.networkConnect.
Renaming the VPN interface to London VPN...
VPN (IPSec) is not a recognized network service.
VPN (IPSec) is not a valid network service name.
** Error: The parameters were not valid.
The following network adapters are present after the import:
An asterisk (
) denotes that a network service is disabled.
Bluetooth DUN
Ethernet
AirPort
Hong Kong VPN
London VPN is not a recognized network service.
** Error: The parameters were not valid.
Running Script nyc_vpn.sh...
Script Exit Code:0
Script Result: Variable "vpnFilePath" value is set to: /Applications/Utilities/NYC VPN.networkConnect
Assistive Device Access is already enabled.
Importing Network Adapter...
LSOpenURLsWithRole() failed with error -10810 for the file /Applications/Utilities/NYC VPN.networkConnect.
Renaming the VPN interface to NYC VPN...
VPN (IPSec) is not a recognized network service.
VPN (IPSec) is not a valid network service name.
** Error: The parameters were not valid.
The following network adapters are present after the import:
An asterisk (*) denotes that a network service is disabled.
Bluetooth DUN
Ethernet
AirPort
Hong Kong VPN
NYC VPN is not a recognized network service.
** Error: The parameters were not valid.
Unmounting file server...

4 REPLIES 4

tlarkin
Honored Contributor

Don't run scripts at imaging time, run them at reboot. Any script ran at imaging time will try to run on the netboot installer you are netbooted from.

Try switching it to run at reboot then image the client, does that work?

-Tom

abz_mungul
New Contributor III

Hi Tom

I'll give that a go.

How about via Casper Remote, I get the same issue, What im doing is deploying the VPN profiles first then running the scripts straight after. Just seems really weird because if I run the scripts locally they work perfectly find

bentoms
Release Candidate Programs Tester

Hi Abz,

Can you doubly make sure that all the .networkconnect files exist where your calling them from?

Looks like the hong kong VPN is working right, just not london or ny (if I'm reading the post right).

msample
Contributor II

Does this apply to any script that's written (including JAMF's) ?