Error with double IP adress

Hello! Recently I’ve configured my AXC F 2152 to be able to connect to two different subnets following what was said in this post: https://www.plcnext-community.net/index.php?option=com_easydiscuss&view;=post&id;=610&Itemid;=224⟨=en#reply-611 The problem I have right now is very similar to the one talked about here (https://www.plcnext-community.net/en/discussions-2-offcanvas/can-you-connect-the-plcnext-to-2-different-networks.html#reply-1035). When I try to connect the PLCnext to the internet through one of its ports I lose the connection with it. When this happens I can also find two different PLCs when searching in the PLCnext Engineer (Image). I was wondering if anyone could expand on the topic posted on the forum before explaining how this can be solved so both connections can be stablished. You can also take a look at the image with the network configuration. I’m using the 192.168.0.72 as the main connection between the PLCnext, my laptop, and the internet. And then the 10.2.19.80 is to communicate with other PLCs is that subnet. Thank you very much in advance, Kind regards Guzman

Hello Guzman, I can not reproduce this issue. What are the Versions of FW and PLCnext Engineer you are using. I notice that there are two different MAC addresses so my guess is that you have two AXC F 2152 in your network? To check the active IP Addresses and activate the use the command. $ ipaddr $ netstat -rn What do you mean when you try to connect to the internet you lose connection. PC IP ? → AXC IP ? Are you changing the IP settings in that case? kind regards, Oliver

Hello Oliver, thank you for your answer, The version of PLCnext Engineer is 2021.0.1 Build 4.7.1144.0 while the firmware in the controller is 2021.0.2 LTS (21.0.2.35550). You can see in the image the response given to the commands you indicated. The two subnets configured in the ethernet interface appear. What I mean when I say I lose connection to the PLC is that, when I’m connected with my laptop to PLC through one of the two ports, if I connect the ethernet cable of the router in the other port, the PLCnext Engineer gives a message of Connection lost and if I try to connect again it gives Credential withdrawn. I’m not changing the IP address in any case. Could the error be related to the two PLCs found while searching in PLCnext Engineer having the same name? Kind regards, Guzmán

cmdEth.JPG

Hello Guzmán Sorry „ip addr“ is what I meant. That error could happen because some other device on your network has the same IP as your PLC → 192.168.0.72 Try ping the 192.168.0.72 when the PLC is connected and disconnected. The name only would matter if you have a PN connection running in your network kind regards, Oliver

Update, I tried changing the names of both stations but even if they are different the error is still the same. When the PLC is connected to the router and my laptop, while it is booted up, I’m unable to connect and the message is Credentials withdrawn. However, if the PLC is booted up only connected to my laptop and then the connection to the router is made, the connection with the laptop is still active and I can also ping google.com to check that internet is available in the PLC through the router. Thank you, Regards Guzmán

Hello Oliver, I tried pinging 192.168.0.72 with my laptop connected to the router but there seems to be no device with that IP. The behaviour is quite erratic because I can sometimes connect to the PLCnext even if it’s connected to the router but other times I’m not able to. In some tries, the PLCnext Engineer gives out a Credentials withdrawn error but sometimes it just gives a Connection failure error. I’m at all times able to ping the controller. I attach the result of the id addr command Thanks again Guzman

ipaddr.JPG

Hello Guzman, you can check the Arp table of your PC and PLC to check for the IP tables. This way you can make sure you dont have duplicate IPs Same IP Different MAC means something is wrong in your network. root@axcf2152:/opt/plcnext/# arp -a ? (192.168.1.1) at on eth0 ? (192.168.1.41) at 00:xx:xx:xx:xx:cf [ether] on eth0 You could also use the „PLCnext Engineer Network Toplogie Viewer.“ [attachment]23-04-_2021_12-49-01.jpg[/attachment]

23-04-_2021_12-49-01.jpg

Hello again Oliver, I tried scanning the network for other devices but there is nothing on the PLCnext Engineer Network Topology. Where did you find the different IPs with the same MAC? Maybe it is because I configured the AXC F 2152 to connect to two different subnets in the interfaces file via WinSCP. Today I was able to connect again once I unplugged the PLCnext and the router but the PLCnext Engineer showed a red shield next to the project name instead of the common blue shield, maybe that tells you something. Thanks again, Regards, Guzmán

Hi Guzman, well, I’ve just tried your config as well on my setup and I can also not reproduce what you are seeing. I guess you mean the shield next to the PLC in the tree view, maybe you can hower with your mouse to give us more details, also the log messages in the debug bar might give us a hint. However, it seems to have something to do with your specific setup. Can you maybe strip your setup down to the absolute less necessary, so maybe just the plc, router and your PC. It might be also a good idea to use (just for a test) a different PC or VM to exclude any issues there. Maybe another point for your condideration. We normally suggest our customers to use a seperate NIC (like AXC F XT ETH 2403115) to have a clear seperation between the LAN and the WAN network. Next to the benefet of the useability you’ve a clear security advantage. BR, Frank

Hi Guzman, to you question. The First picture you uploaded show two plcs with different MAC addresses. Additional to what frank suggested you could create a TCPdump recording on the PLC to find out what exactly is happening in the case of addind the Router. Also please make sure that the Dynamic IP range of your router does not cross into the IP area of static IPs you are using. Every device maybe some Smartphone could be assigned the same IP as your PC or PLC. Or simply add the router network via a DHCP to your PLC.