Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Enthusiast Zone > Networking > Printer sharing "Unable to lookup host" port issue?

Printer sharing "Unable to lookup host" port issue?
Thread Tools
Spoffo
Forum Regular
Join Date: Feb 2004
Location: San Rafael, CA
Status: Offline
Reply With Quote
Aug 11, 2006, 06:38 PM
 
I have a very simple ethernet network: two Macs, both running 10.3.9, and an old ethernet-capable laserwriter (which I only use for the occasional high-volume job.) These are all connected to a little Linksys 4-port router which is connected to my cable modem. Our everyday printer is an HP 4215 all-in-one connected to one Mac via USB (the host mac) and made available to the other Mac (the non-printer mac) via printer sharing.

This setup has worked like a charm for about 2 years. Then the other day, my router went belly-up. So I replaced it with the comparable current-model Lynksys and reconnected the network exactly as before.

After re-booting everything and without touching the factory default settings on the router, it all seemed to work just fine: Both Macs had internet access; both could do file-sharing with each other and both could see and use the Laserwriter on the network.

However, something is now wrong with the USB printer sharing. The non-printer Mac can see the shared USB printer in the Printer Setup utility, and offers it up as a choice in the print dialogue. However, when you try to print from this Mac nothing happens and you get the message "Unable to locate host " {Name of host Mac} " unknown host."

My first thought was this this had something to do with stale prefs settings and IPs from the old router, so I tried everything I could think of to address that - turn off printer sharing on the host Mac, delete all shared printers on the non-printer mac, re-boot both macs, confirm that the non-printer mac isn't seeing any shared printers, turn printer sharing back on at the host, re-acquire the shared printer on the non-printer mac, etc. I am now convinced that the printer setup utility really is seeing a fresh, valid link to the shared printer, but when I try to print via that link, I get "unable to lookup host . . . "

I even reversed the whole setup, connnecting the USB prnter to the previously non-printer Mac - - which had never before hosted this or any other USB printer. Everything went just the same. The old host now saw the printer as a shared printer on the other Mac, and set up the printer choices the way it's supposed to. But when I tried to print, same result "Unable to locate host {Name of new host mac} " Unknown Host"

All I can conclude at this point is that something having to do with settings in the new router is blocking the actual printing activity, maybe something to do with "Port Forwarding" ??? However, I'm reluctant to start messing with this because a) I have no idea what I'm doing if I go there and b) it all worked just fine on the old router with the standard factory defaults.

Anyone have an idea?

PS: It also has nothing to do with HP drivers. Both Macs will offer the networked Laserwriter as a shared printer possibility, since it sits in their local Appletalk zone. So I tried printing to it as a shared printer and got the same result: Sets up fine, but reports "unable to lookup host" when you actually try to print.
( Last edited by Spoffo; Aug 11, 2006 at 07:11 PM. )
Dual 1.8 G5 tower w/ Pioneer 112, 4 gb RAM, 500 & 200gb HDs
MacBook Pro 2.16 gHz Core 2 Duo, 4 gb RAM, VM Ware Fusion & Boot Camp installed with Win XP Pro (Previously used Parallels)
     
Spoffo  (op)
Forum Regular
Join Date: Feb 2004
Location: San Rafael, CA
Status: Offline
Reply With Quote
Aug 11, 2006, 09:02 PM
 
It's definitely something in the router. I just tried swapping it out for an old dumb hub I had, and shared printing worked just fine,
Dual 1.8 G5 tower w/ Pioneer 112, 4 gb RAM, 500 & 200gb HDs
MacBook Pro 2.16 gHz Core 2 Duo, 4 gb RAM, VM Ware Fusion & Boot Camp installed with Win XP Pro (Previously used Parallels)
     
Spoffo  (op)
Forum Regular
Join Date: Feb 2004
Location: San Rafael, CA
Status: Offline
Reply With Quote
Aug 11, 2006, 09:19 PM
 
Problem solved, though I'd still like to know why. On my old router, I had changed the setup from the default (IPs on the network starting with 192.168.1.100) to DCHP IPs starting with 192.168.1.201 I don't remember why exactly, but it had something to do with keeping the laserwriter from pre-empting the IP of one of the macs if it was powered up when the Mac was asleep. (It also involved giving the laserwriter a static IP.)

In any case, I just changed the basic setup of the new router to match this and Voila! Shared printing works.

It's all back magic, and don't let anyone tell you otherwise.
Dual 1.8 G5 tower w/ Pioneer 112, 4 gb RAM, 500 & 200gb HDs
MacBook Pro 2.16 gHz Core 2 Duo, 4 gb RAM, VM Ware Fusion & Boot Camp installed with Win XP Pro (Previously used Parallels)
     
ghporter
Administrator
Join Date: Apr 2001
Location: San Antonio TX USA
Status: Offline
Reply With Quote
Aug 11, 2006, 09:45 PM
 
That would have been my first thought-static IPs are usually best for printers anyway. But WRITE DOWN YOUR CONFIGURATION BEFORE YOU FORGET IT! If something happens and you have to change hardware again, you'll want to have some way to restore the working configuration.

And yes, sometimes it IS black magic. Just roll with it.

Glenn -----OTR/L, MOT, Tx
     
Spoffo  (op)
Forum Regular
Join Date: Feb 2004
Location: San Rafael, CA
Status: Offline
Reply With Quote
Aug 21, 2006, 12:53 AM
 
It happened again today. I don't know why, but after a lot of experimenting, I have come up with a relaible fix (two of them, in fact.) I’m convinced that this definitely has something to do with host Mac addresses/aliases that are stored in prefs on the printing Mac and for some reason can no longer connect to the host (even though none of the DHCP IPs have changed and file sharing still works fine. Maybe it has something to do with ports?)

To solve the problem you have to get rid of the bogus shared printer identities on the non-host (aka the printing Mac) to create new ones. There are two ways.

First method: the elegant way (though I haven’t done this too many times, so it might not always work.)

1. Turn off printer sharing on the host
2. Open the printer setup utility on the printing Mac and delete all shared printers. You may have to do this more than once. They keep trying to pop back up, which supports the idea that they are actually files stored on the printing Mac
3. Open Library/preferences and delete the 3 or 4 prefs with the word “printer” in them. If you also have a printer attached to this computer via USB, you may see a prefs file specifically for that, which you can leave alone.
4. Open Library/printers. You may see one or more files for the shared printer, something like “officejet4200series.app” delete these also.
5. Restart the printing Mac.
6. Open the printer setup utility again and check that it is NOT showing any shared printers. (You can leave the printer list window open.) If it is, re-check steps 1 - 4.
7. Go to the host Mac and turn printer sharing back on.
8. Look at the printer list on the printing computer. The shared printer(s) should appear within a few seconds. When I did this, it was a good sign that they first appeared showing the IP of the host Mac instead of the computer name. I don’t know if this is a requirement, but it seems to indicate that the setup utility really did create a new identity (see the brute force method) and didn’t somehow resurrect the old, bogus one.
9. Now try to print to the shared printer. It should work. By the way, one way to tell if it’s working is this: If you are successful, the printer icon that appears in the dock will be the specific one for the shared printer, but if you’re suffering from the “Unable to lookup host” problem, the icon in the dock will be a generic HP (or other brand) icon.

Second method: the brute force approach. I know this always works, but it’s ugly.

1. Open up the control panel for your router. Normally by entering http://192.168.1.1 in your browser.
2. Change the DHCP setup so that it assigns IPs in a new range. For example, if it’s set up to assign them starting with 192.168.1.101 (which is the factory default on most routers) change it to start at .110.
3. You may have to do a “renew DHCP lease” on each Mac on the network, though they usually seem to do this on their own.
4. Open the printer setup utility on the printing Mac. You should see a new listing for the shared printer that indicates the new IP for the host Mac. (You’ll also see one or more old, non-working identities, which you can try to delete.) In any case, check-mark this new identity as the only shared printer to display in the print dialogue.
5. Now print to this new identity for the shared printer. It should work fine.
Dual 1.8 G5 tower w/ Pioneer 112, 4 gb RAM, 500 & 200gb HDs
MacBook Pro 2.16 gHz Core 2 Duo, 4 gb RAM, VM Ware Fusion & Boot Camp installed with Win XP Pro (Previously used Parallels)
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 06:44 PM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,