Thread View: news.software.nntp
9 messages
9 total messages
Started by Tuc
Fri, 19 Dec 2003 20:46
Malloc issues with innfeed and cnfs
Author: Tuc
Date: Fri, 19 Dec 2003 20:46
Date: Fri, 19 Dec 2003 20:46
32 lines
2702 bytes
2702 bytes
Hi, Suddenly started getting more and more of these in my logs : 2003-12-19 14:02:37 innfeed: failed to malloc 921144379 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 14:26:54 innfeed: failed to malloc 725436972 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 14:34:39 innfeed: failed to malloc 1011040836 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 14:49:19 innfeed: failed to malloc 1748052044 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 14:52:40 innfeed: failed to malloc 1159615494 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 15:03:34 innfeed: failed to malloc 643126866 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 15:07:26 innfeed: failed to malloc 1177310278 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 15:10:05 innfeed: failed to malloc 1233682896 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 15:13:49 innfeed: failed to malloc 959262766 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 15:22:57 innfeed: failed to malloc 3104797339 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory 2003-12-19 15:37:15 innfeed: failed to malloc 3543819181 bytes at cnfs/cnfs.c line 1353: Cannot allocate memory We've been putting more and more memory in the machine, and it seems we get more and more of these! We have 4G of main memory in the system. Is there something we should be doing better/differently? Thanks, Tuc/TTSG Internet Services, Inc.
Re: Malloc issues with innfeed and cnfs
Author: Jeffrey M. Vinocur
Date: Fri, 19 Dec 2003 21:01
Date: Fri, 19 Dec 2003 21:01
17 lines
1755 bytes
1755 bytes
In article <b0a6af8e.0312191246.1d169f32@posting.google.com>, Tuc <google@ttsg.com> wrote: > >2003-12-19 14:02:37 innfeed: failed to malloc 921144379 bytes at >cnfs/cnfs.c line 1353: Cannot allocate memory > >We've been putting more and more memory in the machine, and it seems >we get more and more of these! We have 4G of main memory in the >system. Is there something we should be doing better/differently? Do you have a shell limit/ulimit in place for the news user in terms of per-process memory size? -- Jeffrey M. Vinocur jeff@litech.org
Re: Malloc issues with innfeed and cnfs
Author: Tuc
Date: Sat, 20 Dec 2003 19:29
Date: Sat, 20 Dec 2003 19:29
77 lines
3633 bytes
3633 bytes
jeff@litech.org (Jeffrey M. Vinocur) wrote in message news:<brvovq$3mi$1@puck.litech.org>...
> In article <b0a6af8e.0312191246.1d169f32@posting.google.com>,
> Tuc <google@ttsg.com> wrote:
> >
> >2003-12-19 14:02:37 innfeed: failed to malloc 921144379 bytes at
> >cnfs/cnfs.c line 1353: Cannot allocate memory
> >
> >We've been putting more and more memory in the machine, and it seems
> >we get more and more of these! We have 4G of main memory in the
> >system. Is there something we should be doing better/differently?
>
> Do you have a shell limit/ulimit in place for the news user in
> terms of per-process memory size?
>
hermod% limit
cputime unlimited
filesize unlimited
datasize 512MB
stacksize 64MB
coredumpsize unlimited
memoryuse unlimited
memorylocked unlimited
maxproc 7390
descriptors 40000
sockbufsize unlimited
vmemorysize unlimited
I'm using the site default FreeBSD 4.9 login.conf to control it, which is :
default:\
:passwd_format=md5:\
:copyright=/etc/COPYRIGHT:\
:welcome=/etc/motd:\
:setenv=MAIL=/var/mail/$,BLOCKSIZE=K,FTP_PASSIVE_MODE=YES:\
:path=/sbin /bin /usr/sbin /usr/bin /usr/games /usr/local/sbin /usr/loca
l/bin /usr/X11R6/bin ~/bin:\
:nologin=/var/run/nologin:\
:cputime=unlimited:\
:datasize=unlimited:\
:stacksize=unlimited:\
:memorylocked=unlimited:\
:memoryuse=unlimited:\
:filesize=unlimited:\
:coredumpsize=unlimited:\
:openfiles=unlimited:\
:maxproc=unlimited:\
:sbsize=unlimited:\
:vmemoryuse=unlimited:\
:priority=0:\
:ignoretime@:\
:umask=022:
They have a commented out entry to override that for news, which is :
#news:\
# :path=/usr/local/news/bin /bin /sbin /usr/bin /usr/sbin /usr/local/bin /
usr/local/sbin:\
# :cputime=infinity:\
# :filesize=128M:\
# :datasize-cur=64M:\
# :stacksize-cur=32M:\
# :coredumpsize-cur=0:\
# :maxmemorysize-cur=128M:\
# :memorylocked=32M:\
# :maxproc=128:\
# :openfiles=256:\
# :tc=default:
But it seems like it'd be worse, no?
And why is CNFS trying to malloc that much ANYWAY? Doesn't that seem quite
extreme?
Thanks, Tuc/TTSG Internet Services, Inc.
Re: Malloc issues with innfeed and cnfs
Author: Mark Hittinger
Date: Sun, 21 Dec 2003 02:55
Date: Sun, 21 Dec 2003 02:55
27 lines
2051 bytes
2051 bytes
google@ttsg.com (Tuc) writes: >I'm using the site default FreeBSD 4.9 login.conf to control it, which is : Have you tried setting articlemmap to true in inn.conf? This would avoid the mallocs. How large are your innfeed backlog files getting? What is your backlog limit in innfeed.conf? What is your maxartsize and localmaxartsize in inn.conf? What is the swap space total on your system? Are your CNFS partitions > 2g? Are the CNFS partitions on an NFS file system? Have you made the FreeBSD kernel changes necessary for the 4gig of ram? You might want to back out of that much ram if you haven't. I don't think your problem is lack of ram. I'd be concerned that some of the articles in your cnfs are corrupt. Sorry for the scattershot questions :-) Later Mark Hittinger bugs@pu.net
Re: Malloc issues with innfeed and cnfs
Author: Tuc
Date: Sun, 21 Dec 2003 18:51
Date: Sun, 21 Dec 2003 18:51
62 lines
3278 bytes
3278 bytes
bugs@pu.net (Mark Hittinger) wrote in message news:<PY7Fb.610054$Tr4.1587292@attbi_s03>...
> google@ttsg.com (Tuc) writes:
> >I'm using the site default FreeBSD 4.9 login.conf to control it, which is :
>
> Have you tried setting articlemmap to true in inn.conf? This would avoid
> the mallocs.
>
No, but I will now.
>
> How large are your innfeed backlog files getting?
>
70 or so meg.
>
> What is your backlog limit
> in innfeed.conf?
>
backlog-limit: 78643200
backlog-factor: 1.10
backlog-limit-highwater: 0
>
> What is your maxartsize and localmaxartsize in inn.conf?
>
maxartsize: 1000000
localmaxartsize: 1000000
>
> What is the swap space total on your system?
>
hermod# swapinfo
Device 1K-blocks Used Avail Capacity Type
/dev/twed0s1b 1048448 288 1048160 0% Interleaved
>
> Are your CNFS partitions > 2g?
>
Yes, quite large:
hermod# ls -l
total 582818834
-rw-rw-r-- 1 news news 231221501952 Dec 21 13:49 cycbuffs.one
-rw-rw-r-- 1 news news 134217728000 Dec 21 13:49 cycbuffs.three
-rw-rw-r-- 1 news news 231221501952 Dec 21 13:49 cycbuffs.two
>
> Are the CNFS partitions on an NFS file
> system?
>
Nope.
>
> Have you made the FreeBSD kernel changes necessary for the 4gig of ram? You
> might want to back out of that much ram if you haven't. I don't think your
> problem is lack of ram. I'd be concerned that some of the articles in your
> cnfs are corrupt.
>
Our integrator told us we didn't need to make any changes. It
does mention it chops off some of the top part of the memory because
its too much, but I figured at 4G I can afford a LITTLE.
How do I tell if the articles are corrupt? Is there some
"checksum" I can run?
>
> Sorry for the scattershot questions :-)
>
I'll take any help I can get. :)
Thanks, Tuc/TTSG Internet Services, Inc.
Re: Malloc issues with innfeed and cnfs
Author: Mark Hittinger
Date: Tue, 23 Dec 2003 03:59
Date: Tue, 23 Dec 2003 03:59
27 lines
2266 bytes
2266 bytes
google@ttsg.com (Tuc) writes: > I'll take any help I can get. :) Definetly try articlemmap true. Also try to cut way back on the backlog size. For awhile can you try no-backlog true? My thinking is that innfeed is corrupting its heap with those large backlog files. If you look at the backlog patterns you probably have a few feeds that have a horrible backlog and some feeds that rarely have a backlog. You might consider creating two or three seperate innfeed processes, one for the hot feeds that don't develop backlogs and others for the sites that do give you backlog problems. That way you can confine the backlog handling overhead within a dedicated innfeed memory image. You might have a backlogged peer which gets going and then drops out on you - the innfeed process will have to rewrite the backlogs when this occurs - this is a performance hit for that process and will affect the other feeds within that process. Later Mark Hittinger bugs@pu.net
Re: Malloc issues with innfeed and cnfs
Author: Tuc
Date: Tue, 23 Dec 2003 14:40
Date: Tue, 23 Dec 2003 14:40
52 lines
3121 bytes
3121 bytes
bugs@pu.net (Mark Hittinger) wrote in message news:<n4PFb.115181$8y1.359784@attbi_s52>...
> google@ttsg.com (Tuc) writes:
> > I'll take any help I can get. :)
>
> Definetly try articlemmap true.
>
I got some GOOD news, and some BAD news.
GOOD NEWS - Stopped malloc problems
BAD NEWS - Seems like now my traffic flows are cut back
considerably.
(I estimate 1/2)
>
> Also try to cut way back on the backlog size. For awhile can you try
> no-backlog true?
>
Just restarted with no-backlog true
>
> My thinking is that innfeed is corrupting its heap with those large backlog
> files.
>
:-/ Ok.
>
> If you look at the backlog patterns you probably have a few feeds that have
> a horrible backlog and some feeds that rarely have a backlog.
>
Correct.
>
> You might
> consider creating two or three seperate innfeed processes, one for the hot
> feeds that don't develop backlogs and others for the sites that do give you
> backlog problems. That way you can confine the backlog handling overhead
> within a dedicated innfeed memory image.
>
Hrm, thats a potential thought, thanks!
>
> You might have a backlogged peer which gets going and then drops out on you -
> the innfeed process will have to rewrite the backlogs when this occurs - this
> is a performance hit for that process and will affect the other feeds within
> that process.
>
Has anyone looked at other ways to handle this then? Instead of a
flat file maybe a DBM?
>
> Later
>
> Mark Hittinger
> bugs@pu.net
Thank you very much, we'll see what happens!
Tuc/TTSG Internet Services, Inc
Re: Malloc issues with innfeed and cnfs
Author: Mark Hittinger
Date: Tue, 23 Dec 2003 22:50
Date: Tue, 23 Dec 2003 22:50
23 lines
2157 bytes
2157 bytes
google@ttsg.com (Tuc) writes: > I got some GOOD news, and some BAD news. > GOOD NEWS - Stopped malloc problems > BAD NEWS - Seems like now my traffic flows are cut back >considerably. >(I estimate 1/2) Ugh! I would have expected a performance increase by going to mmap but maybe we have some issues in FreeBSD land in big ram configurations. Could you check the setting of wireformat: in your inn.conf file? Oh! - also check for "use-mmap: true" in your innfeed.conf file. Historically we would use mmap true and wireformat true to improve performance. Innfeed could just mmap the wireformat article and do an output call. Without wire format innfeed must output each line and then put a \r\n on the end of each line. A lot more context switches etc. Later Mark Hittinger bugs@pu.net
Re: Malloc issues with innfeed and cnfs
Author: Tuc
Date: Wed, 24 Dec 2003 15:05
Date: Wed, 24 Dec 2003 15:05
32 lines
2676 bytes
2676 bytes
bugs@pu.net (Mark Hittinger) wrote in message news:<uE3Gb.120443$8y1.373185@attbi_s52>...
> google@ttsg.com (Tuc) writes:
> > I got some GOOD news, and some BAD news.
> > GOOD NEWS - Stopped malloc problems
> > BAD NEWS - Seems like now my traffic flows are cut back
> >considerably.
> >(I estimate 1/2)
>
> Ugh! I would have expected a performance increase by going to mmap but
> maybe we have some issues in FreeBSD land in big ram configurations.
>
Well, it seems to have started to pick up in the last 12 hours.
Still ending up with the outbound being quite a bit more than the
inbound, but have to check other things for that.
>
> Could you check the setting of wireformat: in your inn.conf file?
>
Set to false.
>
> Oh! - also check for "use-mmap: true" in your innfeed.conf file.
>
Also false.
>
> Historically we would use mmap true and wireformat true to improve
> performance. Innfeed could just mmap the wireformat article and do an
> output call. Without wire format innfeed must output each line and then
> put a \r\n on the end of each line. A lot more context switches etc.
>
Making changes now and restarting, we'll see what happens...
THANKS!
Tuc/TTSG Internet Services, Inc.
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads