Sirs, I am tuning my squid proxy para ma increase ang number ng
filedescriptors. Saan ba dapat i insert ang ulimit -HSn 8192 command
dito sa RunCache script ko?
Sabi kasi sa isang portion ng documentation na binabasa ko (Optimizing
Squid for high performance on Linux...),
----
Now you have to modify Squid's startup scripts:...
ulimit -HSn 8192
On other distributions, or if you start Squid from its own RunCache
script, you should edit RunCache and add the same command somewhere at
the beginning of the file.
The idea is, whatever script you use to launch Squid, you should put
the limit command just before launching Squid. If you fail to do that,
Squid will not be able to use all those filedescriptors. Make sure
that the ulimit binary is in the script's path; otherwise modify the
path or use /sbin/ulimit or whatever the ulimit's full path is on your
system.
----
Eto (below) ang RunCache script sa Squid ko. Again, saan ko dapat i
insert ang ulimit command? Thanks in advance.
#!/bin/sh
#
# $Id: RunCache.in,v 1.9.8.1 2003/01/06 20:52:55 wessels Exp $
prefix=/usr/local/squid
exec_prefix=${prefix}
logdir=${prefix}/var
PATH=${exec_prefix}/sbin:/bin:/usr/bin
export PATH
conf=""
if test "$1" ; then
conf="-f $1"
shift
fi
failcount=0
while : ; do
echo "Running: squid -sY $conf >> $logdir/squid.out 2>&1"
echo "Startup: `date`" >> $logdir/squid.out
start=`date '+%d%H%M%S'`
squid -NsY $conf >> $logdir/squid.out 2>&1
stop=`date '+%d%H%M%S'`
t=`expr $stop - $start`
if test 0 -le $t -a $t -lt 5 ; then
failcount=`expr $failcount + 1`
else
failcount=0
fi
if test $failcount -gt 5 ; then
echo "RunCache: EXITING DUE TO REPEATED, FREQUENT FAILURES" >&2
exit 1
fi
sleep 10
done
--
Angeles Communications (Phils.), Inc. - Angelcom
System Administrator,
It is more blessed to give than to receive.
_________________________________________________
Philippine Linux Users' Group (PLUG) Mailing List
[email protected] (#PLUG @ irc.free.net.ph)
Read the Guidelines: http://linux.org.ph/lists
Searchable Archives: http://archives.free.net.ph