Strange lpadmin Error from script in a policy

ahambidge
New Contributor II

Good morning all!

I'm seeing a strange, intermittent error from my policy logs on a printer installation policy.

The scenario is that I have a lab, protected by DeepFreeze, that gets two printers installed at login via script. The driver is also being installed at login as I've had to manually modify the PPD (Ricohs; I have a fun story about their new models and SNMP if anyone's interested).

I can post the details of the script if anyone would find that useful, but the error I'm receiving is this:

Script result: /Library/Application Support/JAMF/tmp/Library Printers PCounter - SNMP: line 5: lpadmin: command not found
/Library/Application Support/JAMF/tmp/Library Printers PCounter - SNMP: line 8: lpadmin: command not found

This happens intermittently and not always on the same machine. Right now, my script is just calling 'lpadmin' without the full path to the binary; is it better/proper practice to do so, which is why I'm receiving this error?

Thanks for any and all help!

1 REPLY 1

mike_levenick
New Contributor III
New Contributor III

Not sure if this will resolve it, but I found: http://www.linuxquestions.org/questions/programming-9/strange-problem-with-centos-5-a-863083/

Try using the full path to the binary and see if that helps. /usr/sbin/lpadmin