cyber communicate in two pc or on run in docker and other one run outside docker
We want to use apollo cyberRT in serversral pc; AT first I tried to change the export CYBER_IP in two pc ,and source setup.bash; but it not worked. I'm sure I have followed the past issue well ,but I cannot communicate in two pc;
but the way, don't we need to modify the docker config ? or open the docker port ..etc; I use the aem to start the docker and don't know how to change the docker config in aem;
please give me some addvice,thanks
There are 2 conditions that need to be met here
- 2 physical machines are in the same network segment
- Modify the cyber IP configuration
There are 2 conditions that need to be met here
- 2 physical machines are in the same network segment
- Modify the cyber IP configuration
YES, they are in same network segment ,and I have modified the CYBER_IP then did the export CYBER_IP=XX.XX.XX.XX in both side; but I cannot get the message form remote pc. So, can I achieve remote communication by running the apollo in aem docker? should I do some change about docker?
这里需要满足两个条件
- 2台物理机在同一个网段
- 修改cyber IP配置
是的,它们在同一个网段,我修改了 CYBER_IP,然后在两端都导出了 CYBER_IP=XX.XX.XX.XX;但我无法从远程电脑获取消息。 那么,我能通过在 AEM Docker 中运行 Apollo 来实现远程通信吗?我需要对 Docker 进行一些修改吗?
请问您实现了嘛,问题有被解决嘛?我也遇到了这个问题,但是没有解决
In Apollo, Docker containers are typically configured with the host network mode by default, aiming for higher performance and simplified network setup. In this mode, the container shares the host machine's network namespace, directly utilizing the host's IP address and ports.
While this offers high network performance, it has a significant drawback: if you launch multiple such host mode containers on the same physical host and their internal applications attempt to listen on or use the same ports, a severe port conflict will occur, leading to service startup failures or communication errors.
To enable communication between multiple Apollo containers running on the same physical machine (such as Cyber communication between different modules), independent of host port mapping and without conflicts, it is necessary to switch to the bridge network mode. In bridge mode, Docker assigns each container an independent IP address within a private internal network. Containers can then access each other via this internal network while being isolated from the host's port space, thereby preventing port conflicts.
Therefore, when you need to run multiple Apollo containers on the same physical machine for testing or deployment, you must modify your Docker startup or configuration parameters to explicitly set the network mode to bridge.