We are looking to blow away all printers via a Self Service policy so folks may re-download the proper printers that have been installed. Our students are not admins and i believe we do not allow them to delete printers via system preferences. Teachers are full admins but have rarely if ever have logged into a student computer to help elevate a permission. Anyone have ideas on how to accomplish this for a Self Service policy? We wish to get our clients helped out with cleaning up the old removed printers by deleting via a policy anyone may execute from Self Service. I have tried several scripts and unix commands at root from JSS but lpadmin almost always gives a "unauthorized" error in the JSS logs. I may run any of the scripts and unix commands locally and it just works! Stuck on the JSS deployment getting lpadmin "Unauthorized" errors!
Solved
Delete all printers Self Service Policy fails with lpadmin "Unauthorized"
Best answer by stevevalle
I have a self service policy which runs the following command:
lpstat -p | cut -d' ' -f2 | xargs -I{} lpadmin -x {}Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
