LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

TCP connection on windows 10

Solved!
Go to solution

Hello everyone,

We are using a labview (2015) programm to access a database. It has been working just fine for the pasts months, but I can't have it to work on the new windows 10 (april update) computers. I've reduced the test to a simple TCP open connection which give me error code 1 TCP: Verbindung herstellen. 
From this same computer I can access the database from other softs than labview...

Have you heard about something like this ??

Thank you very much 
Martin

0 Kudos
Message 1 of 18
(10,806 Views)

Hi Martin,

 

I personally have not tested this exact configuration.

Error 1 seems to indicate an invalid input parameter in the TCP: Open Connection VI. Can anything about your inputs to that VI or the way Windows understands it have changed with the update?



Remember Cunningham's Law
0 Kudos
Message 2 of 18
(10,786 Views)

Hi Peter,

Thank you, this is possible indeed. But I have no idea what as I still can connect to my database through sql workbench for example. 
Would I have forgotten to install something specific to LabView with SQL communication? 

Or is it simply a Windows related bug ? .. 

0 Kudos
Message 3 of 18
(10,761 Views)

Wait, did you re-install recently? I thought you just updated windows 10. 



Remember Cunningham's Law
0 Kudos
Message 4 of 18
(10,757 Views)

Sorry yes, this is a brand new computer running on Windows 10, so yes, I reinstalled the runtime engine as well as ODBC drivers. Do you know if labview needs anything else to communicate with sql ? 

0 Kudos
Message 5 of 18
(10,747 Views)

I mean, there's the database connectivity toolkit, you can try and install that.

Do you still have a working setup? If so, you could just check the installed software there and add everything that's missing. Just go to NI MAX >> Mein System >> Software to get a complete list.



Remember Cunningham's Law
0 Kudos
Message 6 of 18
(10,742 Views)

Well, 
I think the problem is deeper than this, in the way Windows 10 and labview react together. I don't have labiew installed on the windows 10 machine, I just run the .exe
The thing is, from this machine I can access the adresse with port 3306. 
But when I try to do exactly the same from labview, I get the error. 

Please see here some pictures. Do you have an idea of what could cause this between LV and Windows ? On this specific Windows version ?I tried disabling firewall and security with no succes... 


This is what does not even workThis is what does not even workError I gotError I gotConnection test from the same pc to the same serverConnection test from the same pc to the same server


0 Kudos
Message 7 of 18
(10,719 Views)

Check the Windows firewall settings if it has an entry for your executable forbidding to use TCP. It's damn easy to dismiss the dialog that shows up when a newly installed application tries to open a new network connection for the first time. Once you dismissed that dialog however, the firewall will do what it is supposed to do and simply fail any network operation not explicitly allowed in the rules for that application. 

 

Error 1 is a parameter error which for the Open TCP Connection with the parameters you show is a pretty strange error, unless of course the firewall is blocking Winsock calls for your process and the Winsock address resolution that LabVIEW calls to convert the IP dot formatted string into an ipaddr to actually open a socket simply returns with an error (which it never should do for a dot formatted IP address).

 

And if that is the case your firewall is broken. It should not give itself away in such an obvious way to a potentially malicious process, that it is actively getting blocked.

Rolf Kalbermatter
My Blog
0 Kudos
Message 8 of 18
(10,715 Views)

Hi Rolfk and thank you for your help, I've just tried it but it didn't work. 
(I tried to : 

- add rules for port 3306 in and out :Always authorise
- disable all firewalls

- Add the specifi lv.exe to autorised softwares on the firewall.


No luck until now...

0 Kudos
Message 9 of 18
(10,704 Views)

Problem "solved" ...

I installed WireShark and noticed some connections to the server but not my TCP... 
So I tried to copy the labview.exe directly on the machine, instead of having a shortcut pointing to the Labview.exe on the server. 

And it works fine.

It seems to be linked to the newest versions of windows which have not implemented Samba.

Weird.

Message 10 of 18
(10,696 Views)