MacOS – Add printer via lpadmin with custom queue

command linemacosprintingserveradmin

Is there a way to add a printer via the command line that has a custom queue that has two words separated by a space?

My command so far is below but does not set the custom queue. Without the queue, jobs won't print.

lpadmin -p Printer_Name -D "Printer Name" -L "Office" -E -v lpd://X.X.X.X/ -P /Library/Printers/PPDs/Contents/Resources/RICOH\ Aficio\ MP\ C3501

The CUPS webinterface page lists the example: lpd://hostname/queue

I have tried user a \, %20 and putting the entire lpd address in quotes but no luck.

Hopefully someone can help me out.

Best Answer

You do use %20 if you need the space between two words. I had had made a mistake in the spelling which caused me to think it didn't work.

Also, in case anyone needs it in the future, if you access the CUPS webinterface and select Manage Printers it will give you the correct lpd address syntax.