Posted on 02-03-2020 09:42 AM
Hey,
I would like to add a printer via command line. Now I find several lpadmin scripts on the web that make this possible, but I haven't succeeded yet.
So I hope I can get some help here.
If I now want to add a printer via the GUI, I can do this with the following information:
Adres: 192.100.200.300
Name: Printer123
Location: http://192.100.200.300:53000
the above information is the only thing I enter and would like to see this processed in a script, so that I can kick it off remotely.
Posted on 02-03-2020 09:47 AM
here is an edited line that we use to install.
lpadmin -p *printqueue* -D "*Printer Display Name*" -E -v http://*printServer*/printers/*PrintQueue*/.printer -m Library/Printers/PPDs/Contents/Resources/KONICAMINOLTAC658.gz -o auth-info-required=negotiate
Posted on 02-03-2020 09:52 AM
Thank you for ur response but what about this line?
-m Library/Printers/PPDs/Contents/Resources/KONICAMINOLTAC658.gz
Is this what he creates?
Posted on 02-03-2020 09:55 AM
That assigns the driver to use. So if you were going to use the Post Generic PS it would be -m drv:///sample.drv/generic.ppd or -m drv:///sample.drv/generpcl.ppd for Generic PCL.
Posted on 02-03-2020 09:59 AM
Ok shall be a stupid question, but how he get the driver? I never sign a driver when I have a new macbook, he does this automaticly?
Posted on 02-03-2020 10:02 AM
you can download the drivers from the manufacture's webpage and install them or use the Generic ones I updated my last post with.
Posted on 02-03-2020 10:06 AM
Ok Ill test it out.
lpadmin -p *printqueue* -D "Test123 -E -v http://192.200.300:53000 -m /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks /PrintCore.framework/Versions/A/Resources/Generic.ppd" -o auth-info-required=negotiate"
What about printqueues ?
Posted on 02-03-2020 10:08 AM
Is this on a print server or just a stand alone printer?
Posted on 02-03-2020 10:17 AM
It's an stand alone printer.
Posted on 02-03-2020 10:20 AM
We use an Enterprise Print management solution called PrinterLogic. We push a client to WIN & MAC. The icon resides in the task bar and the user can click on it to add any printer. It will open a web browser where the user has to authenticate. Once authenticated, they will see a directory of all offices and printers within that office that are available to them to install. In the admin portal, you upload drivers for MAC/WIN and based on their OS, it will install automatically.
https://www.printerlogic.com/
Attached a screenshot for example
Posted on 02-03-2020 10:26 AM
You will probably want to use something like this then....
lpadmin -p test123 -D "Test123" -E -v http://192.200.300:53000/.printer -m drv:///sample.drv/generic.ppd
Posted on 02-03-2020 10:27 AM
Thank you very much, I let you tomorrow know if I succeed.
Posted on 02-11-2020 10:16 PM
Sorry for the late response, I was only able to test with a user yesterday, because we don't do a lot of MacOs.
We can add the Ricoh printers with a generic printer driver, but they cannot print, probably because of the driver.
So I am thinking of a way how I can add this driver through the script, because if I add the printer via the GUI, then I don't have to add a driver, he does this automatically. Is there a way how I can process this in a script so that it can grab the right driver right away?
Posted on 02-12-2020 03:59 AM
I added the printer via GUI and looked up the folder.
He creates these files "RICOH MP C3003 JPN.gz" in the following folder:
/Library/Printers/PPDs/Contents/Resources/
Are these files sufficient to add the printer?