/build/static/layout/Breadcrumb_cap_w.png

How do I add everyone to the lpadmin group on a mac via a script.

How do I add everyone to the lpadmin group on a mac via a script. I found the following command but it requires a password after it has run. Is there any way to automate this?

dseditgroup -o edit -u itadmin -p -a everyone -t group _lpadmin

0 Comments   [ + ] Show comments

Answers (3)

Posted by: ms01ak 12 years ago
10th Degree Black Belt
0
Try running this as an online shell Script which should allow you to do it.
Posted by: samuelcolt 12 years ago
Orange Senior Belt
0

Use Online Shell Script

Add Machines to the list.

Choose MAC OS X versions from the supported OS list.

Enable "Run As User:" and enter a local administrator credentials

Paste the following into "Script Text"

sudo dseditgroup -o edit -t group -a everyone _lpadmin

Then hit "Run Now".

Tested and Works!


Comments:
  • Once I choose the Mac OSX versions it will not allow Run As User. This message pops up in that area:
    Run As options are only available for Online KScripts and Online Shell Scripts for Windows. - WGM_Jeff 12 years ago
  • Yes... i am using Online Shell Script and using "Run As" with admin credentials.
    I also have the following in the "script text" box and it works great.

    sudo dseditgroup -o edit -t group -a everyone _lpadmin - samuelcolt 12 years ago
Posted by: ms01ak 12 years ago
10th Degree Black Belt
0
Try running it an shell script, with the sudo command in front.

Comments:
  • I tried that and this is the output I got back.

    Running: /Library/Application Support/Dell/KACE/data/scripts/484/script.sh 2>&1

    Please enter user password:

    Failed to set credentials. - WGM_Jeff 12 years ago
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ