Ethernet stops working after 3 hours

I am using the S7G2 controller runs without problem till 3 hours after that Ethernet stops working.

I have checked the packet pool in 1 min frequency by the function nx_packet_pool_info_get ()

status = nx_packet_pool_info_get (&g_packet_pool0, &total_packets, &free_packets, &empty_pool_requests,
                                                  &empty_pool_suspensions, &invalid_packet_releases);

on the below conditions i am trying to obtained the logs and this logs will starts after 3 hours

if (!g_packet_pool0.nx_packet_pool_available || invalid_packet_releases || empty_pool_requests
                        || empty_pool_suspensions)

total_packets free_packets empty_pool_requests empty_pool_suspensions invalid_packet_releases
200 2 6 1 0
200 0 585 2 0
200 0 1352 2 0
200 0 2076 2 0
200 0 2864 2 0
200 0 3638 2 0
200 0 4415 2 0

how to find where the packets been getting filled and is there a way to release directly 

how to over come this.

  • Hi Amar,

    It appears that you are depleting the packet pool because there is a leak in the packet pool and packets are not being returned to the pool after they are used.  Please check you code and insure that packets are returned to the pool in all execution paths including all error handling and other scenarios.


  • Hi garyj,

    I had taken care of the proper release of the packet on the receiving  success release and sending fail release. in all


  • If that were true, you wouldn't run out of packets, right? This seems easy enough to debug - add some global counters that increment and decrement when packets are used/returned, and halt the processor periodically and take a peek at them.  

    Other that that, you're going to have to explain a bit more about what this application does with all these ethernet packets.

    good luck


  • its happening in one of the site where these controllers installed we can put debugger to analyses this.

    this application sends and receives periodic the data over tcp.

    how to take a look at where these packets are not getting released as with logs