[bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Simon Goldschmidt
URL:
  <https://savannah.nongnu.org/bugs/?55910>

                 Summary: MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: dagml
            Submitted on: Wed 13 Mar 2019 02:42:49 PM UTC
                Category: apps
                Severity: 3 - Normal
              Item Group: Faulty Behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: None
            lwIP version: 2.1.1

    _______________________________________________________

Details:

Hi

When the target is connected to a ntp server which is out of sync, the
MEMP_SYS_TIMEOUT pool runs empty.
(assert line 190 in timouts.c )

NOTE: present in lwIP version 2.1.2 which is not in the dropdown list (and an
older lwIP version).

Best Regards,
Dag




    _______________________________________________________

Reply to this item at:

  <https://savannah.nongnu.org/bugs/?55910>

_______________________________________________
  Message sent via Savannah
  https://savannah.nongnu.org/


_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

[bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Simon Goldschmidt
Follow-up Comment #1, bug #55910 (project lwip):

Could you provide more detail please?
- when does the pool run empty? Do you have MEMP_NUM_SYS_TIMEOUT set too low
or is there a memory leak?
- what does "out of sync" mean for an ntp server?

    _______________________________________________________

Reply to this item at:

  <https://savannah.nongnu.org/bugs/?55910>

_______________________________________________
  Message sent via Savannah
  https://savannah.nongnu.org/


_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

[bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Simon Goldschmidt
Follow-up Comment #2, bug #55910 (project lwip):

AFAIK there is nothing in NTP protocol to tell that a server is "out of sync",
most NTP servers implementation just discard all requests until the server
itself consider that it is synchronized.

So, what we should read is "When the target is connected to a ntp server which
does not answer" instead of "When the target is connected to a ntp server
which is out of sync".

Sylvain

    _______________________________________________________

Reply to this item at:

  <https://savannah.nongnu.org/bugs/?55910>

_______________________________________________
  Message sent via Savannah
  https://savannah.nongnu.org/


_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

Re: [Ext] [bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Dag Midling Larsen
In reply to this post by Simon Goldschmidt
Yes, there seem to be a memory leak. I've tried to increase MEMP_NUM_SYS_TIMEOUT.
What I mean by out of sync is that the ntp server is running on a PC/machine which does not have connectivity to the outside world.
Sorry, I don't know much about ntp, but I'm quite confident this is an issue.

Regards,
Dag


Schlumberger-Private

-----Original Message-----
From: Simon Goldschmidt [mailto:[hidden email]]
Sent: Wednesday, March 13, 2019 8:24 PM
To: Dag Midling Larsen <[hidden email]>; Simon Goldschmidt <[hidden email]>; [hidden email]; [hidden email]
Subject: [Ext] [bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Follow-up Comment #1, bug #55910 (project lwip):

Could you provide more detail please?
- when does the pool run empty? Do you have MEMP_NUM_SYS_TIMEOUT set too low or is there a memory leak?
- what does "out of sync" mean for an ntp server?

    _______________________________________________________

Reply to this item at:

  <https://urldefense.proofpoint.com/v2/url?u=https-3A__savannah.nongnu.org_bugs_-3F55910&d=DwIBaQ&c=CRKael6LgVt5xjvyqPD27dPR2eKsAMw5_UGvkEk3eUY&r=zOaQ5Lyf_KJptnlb-KBY1A&m=ksPP9tJj8YhwVhgvbcFqfRt8n8bqloFcf4OQTo0MOXI&s=0GM3R6_QEtUhVc2TqlS0w61t_Sa7HcOdVsr_f7ytVLM&e=>

_______________________________________________
  Message sent via Savannah
  https://urldefense.proofpoint.com/v2/url?u=https-3A__savannah.nongnu.org_&d=DwIBaQ&c=CRKael6LgVt5xjvyqPD27dPR2eKsAMw5_UGvkEk3eUY&r=zOaQ5Lyf_KJptnlb-KBY1A&m=ksPP9tJj8YhwVhgvbcFqfRt8n8bqloFcf4OQTo0MOXI&s=niTUoczAPrDzVH2Ca5GmH0F7P9FH8rZa8pi67jf2_zU&e=
_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

[bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Simon Goldschmidt
In reply to this post by Simon Goldschmidt
Follow-up Comment #3, bug #55910 (project lwip):

It could be because LWIP_NUM_SYS_TIMEOUT_INTERNAL does not take SNTP into
account, and that is not obvious until you run into the mempool running empty
(like Dag is seeing).

I use:

#define MEMP_NUM_SYS_TIMEOUT (LWIP_NUM_SYS_TIMEOUT_INTERNAL + LWIP_SNTP)

    _______________________________________________________

Reply to this item at:

  <https://savannah.nongnu.org/bugs/?55910>

_______________________________________________
  Message sent via Savannah
  https://savannah.nongnu.org/


_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

[bug #55910] MEMP_SYS_TIMEOUT pool runs empty in sntp scenario.

Simon Goldschmidt
Update of bug #55910 (project lwip):

                  Status:                    None => Duplicate              
             Assigned to:                    None => goldsimon              
             Open/Closed:                    Open => Closed                

    _______________________________________________________

Follow-up Comment #4:

Ok, this one was first, but I just close bug #56431 and patch #9878 fixing
just this.

-> closing as duplicate

    _______________________________________________________

Reply to this item at:

  <https://savannah.nongnu.org/bugs/?55910>

_______________________________________________
  Message sent via Savannah
  https://savannah.nongnu.org/


_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel