Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to set up an Ad Hoc network between my PC running Vista and my Macbook running Leopard. It's not just the Ad Hoc network though. I have Visual Studio Developer Express and SQL Studio Express running on the PC. When I launch a web service on localhost from Visual Studio, I want the Mac to be able to access the web service on my pc (localhost). I am accessing the web service on the mac through the iphone simulator in xcode.

Basically, I am trying to access my Vista localhost web service from the iphone simulator in xCode on my mac over an ad hoc wireless network.

I tried setting up the ad hoc wireless network, but I can't even access the web service in Firefox on the mac using : http://%28ipadress%29%3A%28port%29/webservice.asmx

At this point the Mac has not even shown up in my network on the PC.

Can anyone point me in the right direction or let me know if this is even possible? Do I have to disable firewalls possibly?


share|improve this question
up vote 1 down vote accepted

It shouldn't be a problem - by default in an ad-hoc environment where you are not running a DHCP server or setting static ip's the systems should both end up with automatically assigned private ip-addresses in the link-local address range ( subnet for ipv4 )and should be able to communicate. If your systems connect to each other at the physical layer but don't end up with ipv4 addresses in this range then one or other of the relevant zero-configuration services are probably disabled.

I'd be surprised if you didn't have to disable the client firewall on the target (Windows Vista) System. This is exactly the sort of casual connectivity that the Windows Firewall is intended to block unless you explicitly tell it not to.

In a Windows environment systems broadcast based NetBIOS name resolution mechanisms will kick in (provided they are enabled and the systems are configured to treat the ad-hoc network as trusted rather than public). I believe MAC OS X also supports NetBIOS name resolution but I don't know if it is enabled by default.

Apple's Bonjour and SSDP\UpNP on Microsoft systems provide more general purpose\robust name resolution services in link-local setups. You can install a Windows Bonjour client to make it easier for the systems to find each other

share|improve this answer
I downloaded bonjour for windows and changed the settings on my PC to disable the local firewall. I get an ip-address in the range you specified on both machines and I can resolve the mac server in firefox through name-macbook.local . However, I still cannot accomplish my goal of accessing the pc localhost on my mac. Any more suggestions? You have helped so much already. – Bryan Oct 24 '09 at 18:40
Are you sure that the web service in question is listening on the ad-hoc IP address of the Wireless interface of the PC? Can you ping the PC from the Mac (you should be able to if the Firewall is off)? If you can then share a folder on the PC and you should be able to map to it from the Mac by following these instructions: If that works then your problem is definitely with the web service on the PC not binding to the link-local address, possibly restarting whatever app\service manages it might help but you may need to explicitly configure it also – Helvick Oct 24 '09 at 19:09
Wow! I am almost there! I was about to post back and say that the ip did not resolve, but when I seemingly switched my mac and pc wireless connections from the Ad-Hoc back to my internet wireless network, the ip resolved. So the ad-hoc network must persist.. Now I can find the root of localhost from the mac firefox browser, but I can't get to the port(?) my web service is on. I am trying to access localhost:49973/BaseballWebService using but nothing. localhost resolves fine. Any more suggestions? Thanks so much! – Bryan Oct 24 '09 at 20:35
Here is what I figured out: localhost and both resolve to the same page. But localhost:49973/BaseballWebService/Service.asmx resolves the web service and cannot find the webservice. FYI localhost redirects to localhost/xampp/ Could that be a problem? – Bryan Oct 24 '09 at 20:57

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.