Pyro issues with remote operation, binding IP addresses

Jason Beyers <[email protected]>
Newsgroups gmane.comp.python.pyro
Message-ID <AB6C1FF895133B438E850CDDC70FA47106C93077@mbx024-w1-ca-1.exch024.domain.local>
Hi,

Sorry for the long message.  I've been using Pyro 4 to create a performance load testing framework similar to The Grinder, and I've been loving it!  However, there's one issue with binding an ip address that I can't seem to get around, and it's preventing me from deploying this in our own network as well as others like Amazon EC2 or Microsoft Azure.

Here's my scenario:

Server process consists of a nameserver daemon and pyro daemon that publishes a particular test driver object (pyro object).  Since the server is supposed to work over a network, I set both Pyro4.config.HOST and Pyro4.config.NS_HOST to a user-defined host/ip corresponding to that system.

Client process consists of a simple python script that creates a local proxy of the test driver object (pyro object).  The client looks for a user-defined server host/ip.

Private networking is disabled for these two machines - they can't access eachother using private IP addresses, only public DNS.  Firewalls are disabled and the proper nameserver and pyro daemon ports are opened.  DNS server is working properly.  Using Ubuntu linux for all of this, and running the nameserver/pyro daemons in a custom event loop similar to the remote.py example.

Here's my problem:

It seems that the host/ip specified for the client needs to exactly match the host/ip given to the nameserver and pyro daemons, even if other hostnames resolve to the same (public) ip address.  For example:

nameserver/pyro daemons run on myhost.mydomain.net, and the remote client looks for myhost.mydomain.net.  The client can only connect to myhost.mydomain.net, and the nameserver/pyro daemons can see/ping only myhost (not the full myhost.mydomain.net).

If the nameserver/pyro daemons try to bind to myhost.mydomain.net, the nameserver throws an exception stating "Failed to bind address", since I assume it is trying to bind to a public IP address that it doesn't control.  If the nameserver/pyro daemons bind just to myhost, and the client looks for myhost.mydomain.net, the client throws an exception stating "Temporary name resolution failure" without additional details.   In the latter case, the nameserver/pyro daemons are binding to something that resolves to the same public IP that the client is looking for - verified with nslookup - yet they still can't connect.  I can't tell if this is expected behavior.

Other server daemons like sshd or the Grinder's console process for example seem to bind to every valid ip address of the host system, making it easy for clients to connect (not picky).  However, the Pyro nameserver and/or pyro daemon(s) seem to be picky about what address clients use and I'm not sure how to get around it.  Searching on google for these exceptions hasn't produced much.

What I'm hoping to find is a way to run nameserver/pyro daemons on a "server" machine such that they can respond to any TCP connections on the proper nameserver and pyro daemon ports regardless of how the client is accessing them - private IP, public IP, public DNS, etc.  If these daemons can bind to the server machine's addresses this way, I could just provide socket.gethostname() in code or another valid way to identify itself, and the clients could connect with whatever host/ip that works for them - they wouldn't need to match, as long as they're valid.  SSH and the Grinder already behave like this, so how can I get Pyro to do it too?

I likely need to provide more info about my environment but I'm not sure which additional details would be useful here - please advise.  Thanks for your time.

Thanks in advance!!
-Jason Beyers

------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov

_______________________________________________
Pyro-core mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyro-core
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.