I have remote access to a Mac and I'm trying to print over command line using lpr.

However, the command is stuck until I log in to the remote Mac and press an icon to confirm the password already stored in Keychain.

Can I print remotely without logging in to the remote Mac?

  • 2
    Could you show us the exact command you are using and any errors that come back. – Tony Williams Jul 28 at 10:10
  • Welcome to Ask Different. An alternative method, if both Macs reside on the same network, would be to share the printer connected to the remote Mac, see support.apple.com/en-sa/guide/mac-help/mchlp2424/mac for details. – jaume Jul 28 at 13:30
  • @TonyWilliams The command used is just $ lpr <fllename>, no error return, but nothing print out. [$ lpq returns queue correctly: LabPrinter is ready and printing// Rank Owner Job File(s) Total Size// active Mark 125 copy.sh 1024 bytes]. Then when I login mac physically, there is a pop-up window ask authentic for the printer, with user name and password already filled in. However, I have to press the confirm icon, which step I find no way to do remotely. – Grani Mark Jul 30 at 2:04
  • @jaume The URL says it's for non-network printer. The printer I use is a network printer itself. However, it cannot be accessed by Ubuntu. So I try to use a remote Mac as a medium to access printer. – Grani Mark Jul 30 at 2:15
  • Yes, it states it is for non-network printers, but you can still share it and give it a try. What is the printer manufacturer and model and your Ubuntu version? – jaume Jul 31 at 6:54

You must log in to answer this question.

Browse other questions tagged .