what ports on print server need to be opened for iPhone to see printer

I have a Linux (Ubuntu) print server. I'm able to print from my iPhone just fine as long as I don't turn on the firewall. However when the firewall is enabled, the iPhone can't see the printer as an option. Someone pointed me to this page, TCP and UDP ports used by Apple software products - Apple Support. From it I've tried opening all of the ports that were related to printer and airplay but nothing. So far I have 139, 515, 631, 5353, 9100, 80, 443, 554, 3689 open. Can anyone tell me what ports are actually required?

iPhone 8 Plus, iOS 11

Posted on Nov 7, 2018 2:40 PM

Reply
4 replies

Nov 10, 2018 7:37 AM in response to Technojunky01

If Linux is enabling AirPrint and is advertising the printer, iOS will see it. Otherwise, iOS needs add-on software to intermediate the printing...


If your target supports AirPrint, here’s the list that Aruba Networks is recommending:


https://community.arubanetworks.com/t5/Controller-Based-WLANs/What-are-the-port- based-recommendations-for-Airplay-and-Airprint/ta-p/184424


Which looks like mDNS, in conjunction with the typical and printer-specific printing services ports and protocols.



A chunk of the network traffic for Apple services including AirPrint is using ephemeral ports.


I’m using an add-on app to reach Brother printers, as the particular models I’m dealing with do not support AirPrint.


This makes it appear that TCP 631 and UDP 5353 might minimally be enough, though your target printer (CUPS or otherwise) will have to be configured to advertise itself via mDNS. From the client end, I’d expect to see ephemeral ports used.

https://wiki.debian.org/AirPrint


If you’re on a remote network via a VPN, you’re going to have to figure out how to pass along the mDNS traffic.


CUPS is (also) part of macOS. (I’ve not checked whether macOS by default or with manual configuration changes can advertise AirPrint for connected printers. All the local printers are network, so none of the boxes I’m currently dealing with should be advertising printers. Though it’d be handy to configure for relay, which would involve advertising. But I’ve not waded into that part of CUPS recently, nor have I encountered that configuration.)


If you’re really stuck, mirror a port on your switch and run a packet capture via WireShark or otherwise, and see what the traffic is trying to use. The firewall logs might also be useful for tracking the ports, if your segment is quiet enough not to drown that traffic.

Nov 10, 2018 6:12 AM in response to MrHoffman

I have to argue with you on that point. Linux printers use CUPS, which was designed by Apple, no addons needed. There was no fuss when it came to my iPhone printing to my Linux server as long as the firewall was not running on the Linux server. I setup the printer, I shared the printer, the printer is available to print from the iPhone. That easy. My issue is not how do I setup printing. It's how do I see the printer when the firewall is enabled? What port do I need to open on the firewall in order for my iPhone to continue seeing the printer when the firewall is enabled.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

what ports on print server need to be opened for iPhone to see printer

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.