Project

General

Profile

Actions

Bug #5533

closed

MGW memory leak?

Added by keith about 2 years ago. Updated about 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
-
Start date:
04/18/2022
Due date:
% Done:

100%

Spec Reference:

Description

Running for about 12 hours:

OsmoMGW# show talloc-context application brief 
talloc report on 'mgcp-callagent' (total 2421492238 bytes in 8180552 blocks)
  telnet_connection              contains    265 bytes in   4 blocks (ref 0) 0x5618bbc01c50
  /etc/osmocom/osmo-mgw.cfg      contains     26 bytes in   1 blocks (ref 0) 0x5618bbbfe670
  struct sched_vty_opts          contains     72 bytes in   1 blocks (ref 0) 0x5618bbbf7720
  abis                           contains  48772 bytes in   8 blocks (ref 0) 0x5618bbb093e0
  logging                        contains   5246 bytes in  16 blocks (ref 0) 0x5618bbb08d60
  msgb                           contains 2421437856 bytes in 8180521 blocks (ref 0) 0x5618bbb08cf0

OsmoMGW# show talloc-context application full
full talloc report on 'mgcp-callagent' (total 2431021650 bytes in 8212742 blocks)
  telnet_connection              contains     89 bytes in   2 blocks (ref 0) 0x5618bbc01c50
    struct telnet_connection       contains     88 bytes in   1 blocks (ref 0) 0x5618d7e71a50
  /etc/osmocom/osmo-mgw.cfg      contains     26 bytes in   1 blocks (ref 0) 0x5618bbbfe670
  struct sched_vty_opts          contains     72 bytes in   1 blocks (ref 0) 0x5618bbbf7720
  abis                           contains  48772 bytes in   8 blocks (ref 0) 0x5618bbb093e0
    unixsocket                     contains      1 bytes in   1 blocks (ref 0) 0x5618bbb09630
    ipa                            contains      1 bytes in   1 blocks (ref 0) 0x5618bbb095c0
    e1inp                          contains  48770 bytes in   5 blocks (ref 0) 0x5618bbb09450
      struct e1inp_line              contains  48768 bytes in   3 blocks (ref 0) 0x5618bbc02470
        struct osmo_use_count_entry    contains     40 bytes in   1 blocks (ref 0) 0x5618bbc02350
        rate_ctr.c:230                 contains    440 bytes in   1 blocks (ref 0) 0x5618bbb47160
      e1inp_sign_link                contains      1 bytes in   1 blocks (ref 0) 0x5618bbb094c0
  logging                        contains   4818 bytes in  12 blocks (ref 0) 0x5618bbb08d60
    vty_logp_doc_str               contains   1095 bytes in   1 blocks (ref 0) 0x5618bbb62090
    vty_logp_cmd_str               contains    208 bytes in   1 blocks (ref 0) 0x5618bbb61f50
    vty_log_level_doc_str          contains    888 bytes in   1 blocks (ref 0) 0x5618bbb488f0
    vty_log_level_cmd_str          contains    184 bytes in   1 blocks (ref 0) 0x5618bbb487d0
    vty_log_level_doc_str          contains   1023 bytes in   1 blocks (ref 0) 0x5618bbb46500
    vty_log_level_cmd_str          contains    205 bytes in   1 blocks (ref 0) 0x5618bbb463c0
    struct log_target              contains    310 bytes in   3 blocks (ref 0) 0x5618bbb09230
      struct osmo_wqueue             contains     96 bytes in   1 blocks (ref 0) 0x7f40194b0090
      struct log_category            contains     54 bytes in   1 blocks (ref 0) 0x5618bbb09340
    struct log_info                contains    904 bytes in   2 blocks (ref 0) 0x5618bbb08dd0
      struct log_info_cat            contains    864 bytes in   1 blocks (ref 0) 0x5618bbb08e60
  msgb                           contains 2430967872 bytes in 8212717 blocks (ref 0) 0x5618bbb08cf0
    E1D Raw TS                     contains    296 bytes in   1 blocks (ref 0) 0x5619b39bab40
    E1D Raw TS                     contains    296 bytes in   1 blocks (ref 0) 0x5619b39ba9b0
    E1D Raw TS                     contains    296 bytes in   1 blocks (ref 0) 0x5619b39ba820

    [!! SNIP... SNIP 8,212,740 lines similar to above 3 !!]

    E1D Raw TS                     contains    296 bytes in   1 blocks (ref 0) 0x5618bbc57b20
    E1D Raw TS                     contains    296 bytes in   1 blocks (ref 0) 0x5618bbb443a0
    E1D Raw TS                     contains    296 bytes in   1 blocks (ref 0) 0x5618bbb46c80
    mgcp-msg                       contains   4232 bytes in   1 blocks (ref 0) 0x5618bbc4f790

Actions #1

Updated by fixeria about 2 years ago

  • Status changed from New to Feedback
  • Assignee set to keith

Hey Keith,

please give this patch a try:

https://gerrit.osmocom.org/c/osmo-mgw/+/27813 libosmo-mgcp: e1: fix memleaks in e1_recv_cb() [NEW]

See also:

https://gerrit.osmocom.org/c/libosmo-abis/+/27814 input/e1d: fix a memleak in handle_ts_raw_read() [NEW]
https://gerrit.osmocom.org/c/libosmo-abis/+/27815 input/e1d: use msgb_hexdump_l2() in handle_ts_raw_read() [NEW]

Actions #2

Updated by fixeria about 2 years ago

  • Status changed from Feedback to Resolved
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 48.8 MB)