Re: memory leak issues

2023-09-15 Thread Walt Karas
I'd strongly recommend putting the relevant autotools config.nice (or a hopefully-exisitng cmake equivalent) in the issue. Has information like whether you used gcc or clang. On Fri, Sep 15, 2023 at 10:56 AM Walt Karas wrote: > When you write an issue for a memory leak, please make it clear whe

Re: memory leak

2019-06-03 Thread Dk Jack
Opened... https://github.com/apache/trafficserver/issues/5596 and https://github.com/apache/trafficserver/issues/5595 On Mon, Jun 3, 2019 at 1:25 PM Leif Hedstrom wrote: > > > > On Jun 3, 2019, at 2:23 PM, Dk Jack wrote: > > > > Yeah, I tried moving to 7.1.6. However, I ran into a couple of

Re: memory leak

2019-06-03 Thread Leif Hedstrom
> On Jun 3, 2019, at 2:23 PM, Dk Jack wrote: > > Yeah, I tried moving to 7.1.6. However, I ran into a couple of crashes with > the new releases… Those would be good to get reports on, and fixes :) Can you try the latest 7.1.1 RC0 that I just posted about? — leif > > Bhasker. > > On Mon,

Re: memory leak

2019-06-03 Thread Dk Jack
Yeah, I tried moving to 7.1.6. However, I ran into a couple of crashes with the new releases... Bhasker. On Mon, Jun 3, 2019 at 12:20 PM Leif Hedstrom wrote: > > > > On Jun 2, 2019, at 6:24 PM, Dk Jack wrote: > > > > Thanks Leif for responding, > > > > some questions... > > > > How do I turn o

Re: memory leak

2019-06-03 Thread Dk Jack
btw, I thing I forgot to mention, I am running ATS in a docker container. I suspect it should not matter, but wanted to provide all the details. Are there any options that I can enable or commands that I can run to further diagnose this? Lief, We you mentioned disable freelist, did you mean the '

Re: memory leak

2019-06-03 Thread Leif Hedstrom
> On Jun 2, 2019, at 6:24 PM, Dk Jack wrote: > > Thanks Leif for responding, > > some questions... > > How do I turn off the freelist? Could you please elaborate on your RAM disk > reference? In my setup, HTTP cache is turned off. Would ram disk still come > into play? Optino to traffic_ser

Re: memory leak

2019-06-02 Thread Dk Jack
Thanks Leif for responding, some questions... How do I turn off the freelist? Could you please elaborate on your RAM disk reference? In my setup, HTTP cache is turned off. Would ram disk still come into play? Is your suggestion 'kill -USR1' different from enabling 'proxy.config.dump_mem_info_fre

Re: memory leak

2019-06-02 Thread Leif Hedstrom
Did you try turning off the freelist? If you do, you likely want to use jemalloc or tcmalloc instead. If that stops the “leak”, then it’s likely related to how the RAM disk. The other thing to do is to kill -USR1 and look at the allocator usage. Do that a few times, with a few hours between and

Re: memory leak

2019-06-02 Thread Dk Jack
Does anyone have an idea of how much memory is allocated for processing each request? In this particular environment (from the graphs), it looks like none of the memory allocated is being freed. Strange thing is, with no change to software of configuration (besides a restart of ats), the memory con

Re: memory leak

2019-05-31 Thread Dk Jack
stats collected via 'traffic_ctl metric ...' commands... https://www.dropbox.com/s/fmamnvrk5v1dq82/ats_6.2.1.txt?dl=0 On Fri, May 31, 2019 at 3:41 PM Dk Jack wrote: > No. I only have healthcheck plugin, stats plugin and my plugin. > > On Fri, May 31, 2019 at 2:45 PM Steve Malenfant > wrote: >

Re: memory leak

2019-05-31 Thread Dk Jack
No. I only have healthcheck plugin, stats plugin and my plugin. On Fri, May 31, 2019 at 2:45 PM Steve Malenfant wrote: > Do you have stale while revalidation plug-in? If so, disable. > > On Fri, May 31, 2019 at 5:42 PM Dk Jack wrote: > > > Hi, > > I am running ATS 6.2.1 and I am seeing memory l

Re: memory leak

2019-05-31 Thread Steve Malenfant
Do you have stale while revalidation plug-in? If so, disable. On Fri, May 31, 2019 at 5:42 PM Dk Jack wrote: > Hi, > I am running ATS 6.2.1 and I am seeing memory leaks. The link below shows > memory dump graphs for a half-hour period (dump freq is 15s). I have a > custom plugin that's using ats

Re: memory leak

2019-03-08 Thread Dk Jack
Could someone let me know the atscppapi's AsyncHttpFetch and AsyncReceiver classes can only used in the context of a Transaction or can they be used like I was using independent of the Transaction. Most of the examples seem to be using it in the context of a transaction. For my plugin, I'd like it

Re: memory leak

2019-03-07 Thread Dk Jack
I narrowed down my problem to the async fetcher class which is derived from AsyncReceiver class. In my plugin, I maintain a few maps which get periodically updated. In my plugin, I create a thread to constantly (every 30s) poll an external server. When the thread wakes up, it uses the async fetcher

Re: memory leak

2019-03-05 Thread Dk Jack
Thanks Leif, I'd like to understand a bit more before introducing another variable. The thing that puzzles me the most is why the system objects are behaving erratically when I am not modifying them or holding on to them.. On Mon, Mar 4, 2019 at 7:11 PM Leif Hedstrom wrote: > Before going down t

Re: memory leak

2019-03-04 Thread Leif Hedstrom
Before going down this rathole, I’d give v7.1.6 or v8.0.2 a spin. Remember, v6.x is an unsupported version, there is no more development nor any more releases. Cheers, — Leif > On Mar 4, 2019, at 20:00, Dk Jack wrote: > > I am using atscppapi's for my plugin. I do something like this... >

Re: memory leak

2019-03-04 Thread Dk Jack
I am using atscppapi's for my plugin. I do something like this... Headers& headers = transaction.getClientRequest().getHeaders(); On Mon, Mar 4, 2019 at 6:09 PM Pushkar Pradhan wrote: > I am also trying to learn the TS APIs. I think you are supposed to call the > TS...Release if you get a ref

Re: memory leak

2019-03-04 Thread Pushkar Pradhan
No I don't think so. It's a gcc feature so it should pull in what's required. On Mon, Mar 4, 2019 at 6:08 PM Dk Jack wrote: > btw, do I need to link it with any additional libraries to use lsan? > Thanks. > > > On Mon, Mar 4, 2019 at 6:05 PM Dk Jack wrote: > > > Thanks Pushkar, I'll try that...

Re: memory leak

2019-03-04 Thread Pushkar Pradhan
I am also trying to learn the TS APIs. I think you are supposed to call the TS...Release if you get a reference. E.g. if (TS_SUCCESS == TSHttpTxnClientReqGet(txnp, &buffer, &hdr_loc)) { TSDebug(PLUGIN_NAME, "Found client request"); txn_info += R"(,"client-request":)" + collect_heade

Re: memory leak

2019-03-04 Thread Dk Jack
btw, do I need to link it with any additional libraries to use lsan? Thanks. On Mon, Mar 4, 2019 at 6:05 PM Dk Jack wrote: > Thanks Pushkar, I'll try that... > > On Mon, Mar 4, 2019 at 4:44 PM Pushkar Pradhan > wrote: > >> Perhaps compiling with LSAN will help: --enable-lsan enable

Re: memory leak

2019-03-04 Thread Dk Jack
Thanks Pushkar, I'll try that... On Mon, Mar 4, 2019 at 4:44 PM Pushkar Pradhan wrote: > Perhaps compiling with LSAN will help: --enable-lsan enable > stand-alone Leak Sanitizer > > > On Mon, Mar 4, 2019 at 4:42 PM Bryan Call wrote: > > > Looking at the graphs it looks like your head

Re: memory leak

2019-03-04 Thread Dk Jack
I saw that too. However, I don't do anything besides getting a reference to headers and iterating over them. http1client, I don't even know how it's involved since I am mostly dealing with XXXPlugin apis in c++ library. On Mon, Mar 4, 2019 at 4:42 PM Bryan Call wrote: > Looking at the graphs it

Re: memory leak

2019-03-04 Thread Pushkar Pradhan
Perhaps compiling with LSAN will help: --enable-lsan enable stand-alone Leak Sanitizer On Mon, Mar 4, 2019 at 4:42 PM Bryan Call wrote: > Looking at the graphs it looks like your headers and http1client sessions > are leaking. Have you looked at this example to on how to send back e

Re: memory leak

2019-03-04 Thread Bryan Call
Looking at the graphs it looks like your headers and http1client sessions are leaking. Have you looked at this example to on how to send back error messages using the C++ API: https://github.com/apache/trafficserver/blob/master/example/cppapi/customresponse/CustomResponse.cc -Bryan > On Mar 4

Re: Memory leak at head?

2019-02-20 Thread Brian Geffon
Done: https://github.com/apache/trafficserver/issues/5042 On Wed, Feb 20, 2019 at 7:20 PM 宋辰伟 <616955...@qq.com> wrote: > Could you guys open issues. It would be more helpful to find the detail > than email. > > Thanks > Scw00 > > > 在 2019年2月21日,上午11:13,zzz 写道: > > > > a37f0d91ec0bbc5cd1f0700a69

Re: Memory leak at head?

2019-02-20 Thread 宋辰伟
Could you guys open issues. It would be more helpful to find the detail than email. Thanks Scw00 > 在 2019年2月21日,上午11:13,zzz 写道: > > a37f0d91ec0bbc5cd1f0700a69d76df54b9484fc

Re: Memory leak at head?

2019-02-20 Thread zzz
git bisect said "a37f0d91ec0bbc5cd1f0700a69d76df54b9484fc is the first bad commit". Glad to see Brian here again! We miss you so much! 😘 Brian Geffon 于2019年2月20日周三 下午4:17写道: > Lol twist my arm amc ;D > > Leif's leak is different that what I'm seeing, mine is trivially reproduced > but here is t

Re: Memory leak at head?

2019-02-20 Thread Brian Geffon
Lol twist my arm amc ;D Leif's leak is different that what I'm seeing, mine is trivially reproduced but here is the ASAN result: https://paste.apache.org/6ttx On Wed, Feb 20, 2019 at 3:55 PM Alan Carroll wrote: > I don't think he's "coming" back, as far as I am concerned he's already > returne

Re: Memory leak at head?

2019-02-20 Thread Alan Carroll
I don't think he's "coming" back, as far as I am concerned he's already returned. I think you're onboard with that too, Leif. I've been looking at this more recent leak and I can't figure out what might be going on. It definitely looks like a std::string leak, but I was told the leak is also on ma

Re: Memory leak at head?

2019-02-20 Thread Leif Hedstrom
> On Feb 20, 2019, at 7:21 AM, Susan Hinrichs > wrote: > > Yes, that does look like a problem. Fei or I will dig into it. Don’t know if it’s the same, but we’re seeing a pretty significant leak on Docs / CI: https://pastebin.com/jf2WU49i And tha

Re: Memory leak at head?

2019-02-20 Thread Susan Hinrichs
Yes, that does look like a problem. Fei or I will dig into it. On Tue, Feb 19, 2019 at 8:09 PM Brian Geffon wrote: > I just pulled down a fresh copy of master, did nothing special: > > autoreconf -i > ./configure --prefix=/tmp/ats > make -j12 && make install > > /tmp/ats/bin/traffic_server > ab

Re: Memory leak detection

2014-07-18 Thread Acácio Centeno
Thanks for your help, yesterday we managed to find and fix the bug. I'll briefly describe what the problem was and how we found it for the record, should someone have a similar issue. First we used the proxy.config.dump_mem_info_frequency configuration and it clearly showed that our TSIOBuffers w

Re: Memory leak detection

2014-07-16 Thread Yunkai Zhang
Why not use the following option to dump memory usage? # Great for tracking down memory leaks, but you need to use the # ink allocators CONFIG proxy.config.dump_mem_info_frequency INT 0 I always use it to detect memory leak when working with freelist. There are two parts memory in ATS: 1) al

Re: Memory leak detection

2014-07-16 Thread Leif Hedstrom
On Jul 16, 2014, at 12:07 PM, James Peach wrote: > Sometimes I've gone to the extent of using placement new() in order to be > consistent about using TSmalloc+TSfree, but there's no additional memory leak > tracking in those. The only practical difference I can think of is that if > ATS is us

Re: Memory leak detection

2014-07-16 Thread James Peach
On Jul 16, 2014, at 10:54 AM, Acácio Centeno wrote: >>> Also we're creating and deleting some objects using new / delete. Could >>> that be a problem? > >> Sure, those objects could leak. > > I'm sorry, the sentence was not good, I meant using new / delete instead of > TSmalloc / TSfree. :-) S

Re: Memory leak detection

2014-07-16 Thread Acácio Centeno
>> Also we're creating and deleting some objects using new / delete. Could >> that be a problem? > Sure, those objects could leak. I'm sorry, the sentence was not good, I meant using new / delete instead of TSmalloc / TSfree. :-) Acácio Centeno Software Engineering Azion Technologies Porto Aleg

Re: Memory leak detection

2014-07-16 Thread Sudheer Vinukonda
traffic_server dumps memory allocation with the setting ³proxy.config.dump_mem_info_frequency². https://docs.trafficserver.apache.org/en/latest/sdk/troubleshooting-tips/de bugging-memory-leaks.en.html I find this useful (in some cases) to detect IOBuffer leaks. Thanks, Sudheer On 7/16/14, 10

Re: Memory leak detection

2014-07-16 Thread James Peach
On Jul 16, 2014, at 10:03 AM, Acácio Centeno wrote: > Hello, > > One of our plugins is leaking memory and we can't find where. Do you guys > have any mechanism in place to help find where the problem is? > > I found an old doc about how to run under Valgrind, by compiling with > --disable-freel