Socket Problem on True64 Alpha
Rolf Wester
wester at ilt.fhg.de
Fri Jun 6 12:03:45 EDT 2003
Hi,
I just tried the socket server examples that are in the Python docs on a
Tru64 Alpha machine. My Python version is 2.2.1. Unfortunately these
examples don't work. This:
import socket
HOST = '' # Symbolic name meaning the local host
PORT = 50007 # Arbitrary non-privileged port
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.bind((HOST, PORT))
gives the error message:
Traceback (most recent call last):
File "server.py", line 7, in ?
s.bind((HOST, PORT))
socket.gaierror: (9, 'The service passed was not recognized for the
specified socket type.')
and this:
import socket
import sys
HOST = '' # Symbolic name meaning the local host
PORT = 50007 # Arbitrary non-privileged port
s = None
for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC,
socket.SOCK_STREAM,
0,socket.AI_PASSIVE):
results in:
Traceback (most recent call last):
File "socket2.py", line 8, in ?
for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC,
socket.SOCK_STREAM, 0, socket.AI_PASSIVE):
socket.gaierror: (8, 'Name does not resolv to supplied parameters;
neither nodename nor servname were passed.')
I don't have any idea what is wrong here. I would be very appreciative
for any help.
Thanks in advance
Rolf Wester
More information about the Python-list
mailing list