LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

TCP/IP open connection fails

Solved!
Go to solution

Hi,

 

I can't establish a TCP/IP connection between my host machine and another PC. I'm using the "Simple Data Sever" and "Simple Data Client" VIs that ship with LabVIEW. Error message is below

 

The example VIs work finw when I use them only on my host machine.

 

I can confirm the following;

  • Correct port set
  • Correct address set
  • Firewall on both PCs is OFF

Any troubleshoot ideas?

 

Error 63.PNG

0 Kudos
Message 1 of 10
(11,511 Views)

Is the server runnin gon the remote machine? What are the firewall settings between the two machines? Can you communicate with th eremote machine in any other manner, such a pinging it?



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 2 of 10
(11,495 Views)

@Mark_Yedinak wrote:

Is the server runnin gon the remote machine? What are the firewall settings between the two machines? Can you communicate with th eremote machine in any other manner, such a pinging it?


Only the client is running on the remote machine.

 

I've turned off the windows firewall on both host and remote machine if this is what you mean?

 

I've haven't tried pinging it, good idea! I'll give it a go tomorrow.

0 Kudos
Message 3 of 10
(11,483 Views)

You need to run the server on one computer and the client on the other. The server must be started first. Is your host machine the server and the remote the client? What are the IP addresses of both machines? How are they connected?



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 4 of 10
(11,477 Views)

@Mark_Yedinak wrote:

You need to run the server on one computer and the client on the other. The server must be started first. Is your host machine the server and the remote the client? What are the IP addresses of both machines? How are they connected?


I've successfully pinged the server and the client..

 

The server is running on my desktop (host) and the client is running on a laptop (remote).

 

The server is being started first as it creates a listener on my specified port.

 

Sever (host) IP is 10.0.0.175 and Client (remote) IP is 10.0.0.183

 

Both machines are on the same wireless network.

0 Kudos
Message 5 of 10
(11,458 Views)

Does your WiFi access point/router have a firewall? What port are you using? Have you tried using a different port number?



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 6 of 10
(11,440 Views)

@Mark_Yedinak wrote:

Does your WiFi access point/router have a firewall? What port are you using? Have you tried using a different port number?


Not sure if router has a firewall, I'll have to check with IT.

 

Regarding port numbers I haven't tried too many, namely 2055 and 5001.

 

I guess I also try with a range of port numbers aswell...

 

Appreciate the guidance

0 Kudos
Message 7 of 10
(11,436 Views)
Solution
Accepted by topic author Strokes

Try a port number over 50000. You are using port numbers in the user space. Port 2055 is assigned to the Iliad-Odyssey Protocol and 5001 is assigned to commplex-link. Not sure what eith erof these are or how widely they are used but you could be runnin ginto a conflict. Ports 49152-65535 are reserved for dynamic/private use. You can get more information here regarding IP ports. It is worth a try. The other thing you could do is install Wireshark on each PC and see if the packet (TCP-SYN) is getting through the client and server.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 8 of 10
(11,426 Views)

Hi, I am also having the same problem and I can ping both computers thru cmd on windows and the can see each others IP address so the firewall on both computer are off and all ports are open. I was reading you talk about using a higher port number is that more likely to be the problem?

 

Thank You, 

0 Kudos
Message 9 of 10
(4,828 Views)

@Anthony86 wrote:

Hi, I am also having the same problem and I can ping both computers thru cmd on windows and the can see each others IP address so the firewall on both computer are off and all ports are open. I was reading you talk about using a higher port number is that more likely to be the problem?

 

Thank You, 


Just because you can ping the other address does not indicate that the firewall is off. You need to verify that the firewall is actually off. Ping (ICMP) are treated differently that TCP ports in firewalls. It is quite common to be able to ping an IP address but not be able to open a connection on a specific port. You can do a "netstat -a" to see what ports are currently in use on the computer. It is possible that you are using a port that is already in use. What port are you using?



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 10 of 10
(4,795 Views)