🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
1 messages
1 total messages Started by Brian Wed, 19 Nov 1997 00:00
Re: Buffers/Tuning and Linux
#23416
Author: Brian
Date: Wed, 19 Nov 1997 00:00
121 lines
4874 bytes
> : I am always seeing posts about admins changing various kernel limits and
> : buffers, to fine tune there news setups with BSD.  I was wondering if
> : anyone knew of anything that could be done with Linux in that respect.
> 
> Make sure you have enough file descriptors (which you probably do).
> 
> Make sure there are no memory limits on the news user, I used to do
> this:
> 
> 	in ~news/etc/rc.news:
> 
> 		#!/bin/csh
> 		ulimit unlimited
> 		exec ~news/bin/rc.news
> 
> This would remove all process limits and then fire up news for me.

I am curious about this one.  First off, I launch news rather
traditionally, in bash in rc.local:

# Start actived
su news -c /usr/local/bin/actived
# Start innd
su news -c /usr/news/bin/rc.news > /dev/console

Does BASH impose limits?  I mean, if bash doesnt have limits to begin
with, then using CSH as a parent doesn't really accomplish much.  But if
bash does have limits..........limits that can only be overcome by CSH's
"unlimit" command, then I can see the point.  I don't see how I can gain
anything on a "user" level process however, check this out:

%id
uid=9(news) gid=13(news) groups=13(news)
%limit
cputime         unlimited
filesize        1048576 kbytes
datasize        unlimited
stacksize       8192 kbytes
coredumpsize    2097151 kbytes
memoryuse       unlimited
descriptors     256
memorylocked    unlimited
maxproc         256
%unlimit
%limit
cputime         unlimited
filesize        1048576 kbytes
datasize        unlimited
stacksize       8192 kbytes
coredumpsize    unlimited
memoryuse       unlimited
descriptors     256
memorylocked    unlimited
maxproc         256


So I gained an unlimited core dump size, which really isnt going to help
me.  Now, when root runs it, I can see it change the limits for "root" and
for root only:

%limit
cputime         unlimited
filesize        1048576 kbytes
datasize        unlimited
stacksize       8192 kbytes
coredumpsize    unlimited
memoryuse       unlimited
descriptors     256
memorylocked    unlimited
maxproc         256
%unlimit
unlimit: descriptors: Can't remove limit
%limit
cputime         unlimited
filesize        unlimited
datasize        unlimited
stacksize       unlimited
coredumpsize    unlimited
memoryuse       unlimited
descriptors     256
memorylocked    unlimited
maxproc         unlimited


Now I can see where things change.  Note that no matter what, it wont
change the descriptors, which I assume is file-descriptors.  Now my kernel
has /proc/sys/kernel/file-max set to 1024, and thatsa "total" max.  I am
assuming that what CSH is talking about is a "per process" max, and
hopefully that doesnt mean parents and children combined.  Now, what kind
of "per process" limit is bash setting? I do not know if there is a
mechinism to view limits in bash like in csh, or to act on them.

If I could get CSH to go unlimited for a "user" like it does root, and if
256 max descriptors is something BASH has anyways (on a per process), then
I can see I would definitly want to do this like you did it.  But if BASH
doesnt have the 256 descriptor limit (and lets me have as much of the 1024
as I need), and there is no way for a user process like news to get
unlimited datasize etc, then I really dont see the benefit.

Are datasize, cputime, etc unlimited in BASH anyways?

> 
> -- 
> Mike Horwath    IRC: Drechsau    LIFE: Lover    drechsau@yuck.net
> Visi:  info@visi.com                           drechsau@Geeks.ORG
> Twin Cities area Internet Access:  612-288-0880 for more info
> The founding member of Minn. Coalition for Internet Accessibility
> 

/-------------------------- signal@shreve.net -----------------------------\
| Brian Feeny                | USR TC Hubs | ShreveNet Inc. (318)222-2638  |
| Systems Administrator      | Perl, Linux | Web hosting, online stores,   |
| ShreveNet Inc.             |  USR Pilot  | Dial-Up 14.4-56k, ISDN & LANs |
| 89 CRX DX w/MPFI, lots of  |-=*:Quake:*=-| http://www.shreve.net/        |
| mods/Homepage coming soon  |LordSignal/SN| Quake server: 208.206.76.3    |
\-------------------------- 318-222-2638 x109 -----------------------------/



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