First of all thank you so much for walking into my nightmare and trying to help. I put the code into two files inside the idle ide and got the same
Code: Select all
Traceback (most recent call last):
File "/usr/lib/python3.8/idlelib/run.py", line 559, in runcode
exec(code, self.locals)
File "/home/dave/j_sandbox/j_raw/1_17_22_rene_client.py", line 6, in <module>
s.connect(('127.0.0.1', 1234))
ConnectionRefusedError: [Errno 111] Connection refused
>>>
so this seems to be a config issue. I SWEAR on the user manual that all I've done on this machine is install LM and upgrade to LM20.3, PROMISE!!!
the connection seems to be established and the ip addressing is a tad weird. 192.168.1.219 is another machine on the lan. Nothing to do with this so I don't know how that got into the mix. The machine that both these scripts are running on is 192.168.1.42
Code: Select all
netstat -an | grep 1234
tcp 0 0 192.168.1.42:51092 192.168.1.219:1234 ESTABLISHED
I reran the client a few times to make sure that there wasn't some kind of delay. Nope
Code: Select all
========== RESTART: /home/dave/j_sandbox/j_raw/1_17_22_rene_client.py ==========
Traceback (most recent call last):
File "/usr/lib/python3.8/idlelib/run.py", line 559, in runcode
exec(code, self.locals)
File "/home/dave/j_sandbox/j_raw/1_17_22_rene_client.py", line 6, in <module>
s.connect(('127.0.0.1', 1234))
ConnectionRefusedError: [Errno 111] Connection refused
>>>
========== RESTART: /home/dave/j_sandbox/j_raw/1_17_22_rene_client.py ==========
Traceback (most recent call last):
File "/usr/lib/python3.8/idlelib/run.py", line 559, in runcode
exec(code, self.locals)
File "/home/dave/j_sandbox/j_raw/1_17_22_rene_client.py", line 6, in <module>
s.connect(('127.0.0.1', 1234))
ConnectionRefusedError: [Errno 111] Connection refused
>>>
========== RESTART: /home/dave/j_sandbox/j_raw/1_17_22_rene_client.py ==========
Traceback (most recent call last):
File "/usr/lib/python3.8/idlelib/run.py", line 559, in runcode
exec(code, self.locals)
File "/home/dave/j_sandbox/j_raw/1_17_22_rene_client.py", line 6, in <module>
s.connect(('127.0.0.1', 1234))
ConnectionRefusedError: [Errno 111] Connection refused
>>>
So this is a problem MY end but I don't have the networking or linux skills to figure it out. I''ve checked the ufw, I don't have anything running except the defaults that LM cranks up. The ProtonVPN is off. Is there anything else I could have messed up?
I tried to hard code the ip address
[code
s.bind(('192.168.1.42', 1234))
and
s.connect(('192.168.1.42', 1234))
][/code]
Same deal
Code: Select all
========== RESTART: /home/dave/j_sandbox/j_raw/1_17_22_rene_client.py ==========
Traceback (most recent call last):
File "/usr/lib/python3.8/idlelib/run.py", line 559, in runcode
exec(code, self.locals)
File "/home/dave/j_sandbox/j_raw/1_17_22_rene_client.py", line 6, in <module>
s.connect(('192.168.1.42', 1234))
ConnectionRefusedError: [Errno 111] Connection refused
>>>
AND I get the same mysterious appearance of 192.168.1.219
Code: Select all
dave@deepthought:~$ netstat -an | grep 1234
tcp 0 0 192.168.1.42:51092 192.168.1.219:1234 ESTABLISHED
dave@deepthought:~
I do have a router on the net and I have hardwired the mac addresses to the machines but I can't see how that would have any effect on this. I tried to kill the connection from the code using the shutdown and close. That didn't work. I googled how to kill the thing using netstat and gdb. No luck.
Code: Select all
1583 netstat -an | grep 1234
1584 netstat -np
1585 netstat -np | grep 51092
1586 lsof -np $259253
1587 lsof -np 259253
1588 gdb -p gdb 259253
1589 netstat -np | grep 51092
I'm going to reboot this machine tonight and try your code again tomorrow with a fresh "mind" thank you for your help. To be honest zmq is looking pretty good about now