Hi there everyone!
First off, I posted this here as I couldn't quite find a place that best fit for it, I apologize if I made a mistake.
I have a dedicated server from a host in Denver, running FreeBSD 7.4 that runs an ircd, IRC services, an eggdrop, apache, inetd, sshd and Icecast. As Icecast begins receiving connections, the other apps are getting disk write "permission denied" errors and, in some cases, appear to be none-allowed disk access from that point on and eventually, the apps will crash! This includes IRC services, and even connections to the IRCD itself, the webserver, sshd, inetd and finally icecast itself will implode.
Although the issue begins at around 10 connections, it get progressively worse and worse as the connections increase; at around 260 connections, everything pukes and the server locks everything OUT- including SSH! The only remedy to this is to REBOOT the server to restore disk access again; that is, until icecast starts receiving connections again!
I have gone through all the tunables and tweaks that I can find.. I have had the host run tests on the hardware and they, too, can't figure it out, and then recommended that they replace the entire machine.. Which they did.. and lone behold.. the problem is STILL there.
I don't know how to describe it- its like a "memory leak, but for descriptors" I'm not even sure Icecast itself is the blame, however that surely aggravates the problem REAL QUICK.
Here's some info: (note the server is not running anything except sshd)
The Server itself is a Intel E800 (3 Ghz) with 4 GBs RAM and a 1 TB HDD, connected with 100 Base T (ethernet) to the net, Dedicated.
OS: FreeBSD 7.4-RELEASE (GENERIC) #0: Fri Feb 18 01:55:22 UTC 2011
top:
tunables:
ipfw:
I'm not sure what else to include..
But this thing sure has me PUZZLED.. I have ran FreeBSD for years, but only RECENTLY has this issue cropped up on the last 2 hosts...
ANY help would be appreciated!
-DjZ-
First off, I posted this here as I couldn't quite find a place that best fit for it, I apologize if I made a mistake.
I have a dedicated server from a host in Denver, running FreeBSD 7.4 that runs an ircd, IRC services, an eggdrop, apache, inetd, sshd and Icecast. As Icecast begins receiving connections, the other apps are getting disk write "permission denied" errors and, in some cases, appear to be none-allowed disk access from that point on and eventually, the apps will crash! This includes IRC services, and even connections to the IRCD itself, the webserver, sshd, inetd and finally icecast itself will implode.
Although the issue begins at around 10 connections, it get progressively worse and worse as the connections increase; at around 260 connections, everything pukes and the server locks everything OUT- including SSH! The only remedy to this is to REBOOT the server to restore disk access again; that is, until icecast starts receiving connections again!
I have gone through all the tunables and tweaks that I can find.. I have had the host run tests on the hardware and they, too, can't figure it out, and then recommended that they replace the entire machine.. Which they did.. and lone behold.. the problem is STILL there.
I don't know how to describe it- its like a "memory leak, but for descriptors" I'm not even sure Icecast itself is the blame, however that surely aggravates the problem REAL QUICK.
Here's some info: (note the server is not running anything except sshd)
The Server itself is a Intel E800 (3 Ghz) with 4 GBs RAM and a 1 TB HDD, connected with 100 Base T (ethernet) to the net, Dedicated.
OS: FreeBSD 7.4-RELEASE (GENERIC) #0: Fri Feb 18 01:55:22 UTC 2011
Code:
Resource limits (current):
cputime infinity secs
filesize infinity kB
datasize-cur 131072 kB
stacksize-cur 8192 kB
coredumpsize infinity kB
memoryuse-cur 3994576 kB
memorylocked-cur 1331525 kB
maxprocesses 5547
openfiles 11095
sbsize infinity bytes
vmemoryuse infinity kB
top:
Code:
last pid: 4080; load averages: 0.00, 0.00, 0.00 up 0+22:42:57 00:57:40
12 processes: 1 running, 11 sleeping
CPU: 0.0% user, 0.0% nice, 0.0% system, 0.0% interrupt, 100% idle
Mem: 6992K Active, 59M Inact, 297M Wired, 124K Cache, 417M Buf, 3559M Free
tunables:
Code:
security.bsd.see_other_uids=0
net.inet.ip.fw.enable=1
net.inet.ip.fw.verbose=0
net.inet.ip.fw.verbose_limit=1
net.inet.ip.fw.dyn_short_lifetime=5
net.inet.ip.fw.dyn_udp_lifetime=5
net.inet.ip.fw.dyn_rst_lifetime=1
net.inet.ip.fw.dyn_fin_lifetime=1
net.inet.ip.fw.dyn_syn_lifetime=5
net.inet.ip.fw.dyn_ack_lifetime=10
net.inet.tcp.nolocaltimewait=1
net.inet.tcp.msl=5000
net.inet.tcp.delayed_ack=0
net.inet.tcp.finwait2_timeout=5
net.inet.tcp.fast_finwait2_recycle=1
net.inet.tcp.blackhole=2
net.inet.udp.blackhole=1
net.inet.ip.fastforwarding=1
net.inet.ip.redirect=0
net.inet.ip.random_id=1
net.inet.ip.portrange.first=2048
net.inet.ip.portrange.last=63500
net.inet.ip.portrange.randomized=0
net.inet.icmp.icmplim=2000
net.inet.icmp.icmplim_output=0
kern.ipc.somaxconn=32500
kern.maxfiles=36958
kern.maxfilesperproc=18450
kern.coredump=0
ipfw:
Code:
/sbin/ipfw -q -f flush
/sbin/ipfw -q -f flush
/sbin/ipfw zero
/sbin/ipfw zero
/sbin/ipfw add 2 check-state
/sbin/ipfw add 4 check-state
/sbin/ipfw add 6 unreach 255 tcp from any to any tcpflags fin,psh,urg recv any
/sbin/ipfw add 8 deny tcp from any to any tcpflags fin,psh,urg recv any
/sbin/ipfw add 10 unreach 255 tcp from any to any tcpflags !fin,!syn,!rst,!psh,!ack,!urg recv any
/sbin/ipfw add 12 deny tcp from any to any tcpflags !fin,!syn,!rst,!psh,!ack,!urg recv any
/sbin/ipfw add 14 unreach 255 tcp from any to any tcpflags syn,fin recv any
/sbin/ipfw add 16 deny tcp from any to any tcpflags syn,fin recv any
/sbin/ipfw add 18 unreach 255 tcp from any to any tcpflags fin,rst recv any
/sbin/ipfw add 20 deny tcp from any to any tcpflags fin,rst recv any
/sbin/ipfw add 22 unreach 255 tcp from any to any ipoptions ssrr,lsrr,rr,ts recv any
/sbin/ipfw add 24 deny tcp from any to any ipoptions ssrr,lsrr,rr,ts recv any
/sbin/ipfw add 26 unreach 255 tcp from any to any tcpflags ack,rst recv any
/sbin/ipfw add 28 deny tcp from any to any tcpflags ack,rst recv any
/sbin/ipfw add 30 unreach 255 icmp from any to any via any
/sbin/ipfw add 32 deny icmp from any to any via any
### /sbin/ipfw add 34 unreach 255 all from any to any frag via any
### /sbin/ipfw add 36 deny all from any to any frag via any
/sbin/ipfw add 38 unreach 255 tcp from any to any established via any
/sbin/ipfw add 40 deny tcp from any to any established via any
/sbin/ipfw add 42 pass tcp from me to (DNS private IP) 53 out via re0 setup limit dst-addr 100
/sbin/ipfw add 44 pass udp from me to (DNS Private IP) 53 out via re0 limit dst-addr 100
/sbin/ipfw add 46 pass tcp from (private IP) to me 22 in via re0 setup limit src-addr 5
/sbin/ipfw add 48 pass udp from me to any 123 out via re0 limit dst-addr 2
/sbin/ipfw add 1000 pass tcp from any to any 80 in via re0 setup limit src-addr 5
/sbin/ipfw add 2000 pass tcp from any to me 843 in via re0 setup limit src-addr 5
/sbin/ipfw add 2002 pass tcp from any to me 6667 in via re0 setup limit src-addr 5
/sbin/ipfw add 2004 pass tcp from any to me 6697 in via re0 setup limit src-addr 5
/sbin/ipfw add 3000 pass tcp from 127.0.0.1 to 127.0.0.1 6670 out via lo0 keep-state
/sbin/ipfw add 3002 pass tcp from 127.0.0.1 to 127.0.0.1 8000 out via lo0 keep-state
/sbin/ipfw add 3004 pass tcp from me to (private IP) 10000 out via re0 limit dst-addr 5
/sbin/ipfw add 5000 pass tcp from (private IP) to me 8000 in via re0 setup limit src-addr 5
/sbin/ipfw add 5004 pass tcp from any to me 8000 in via re0 setup limit src-addr 3
/sbin/ipfw add 5006 pass tcp from any to me 8001 in via re0 setup limit src-addr 3
/sbin/ipfw add 5008 pass tcp from 127.0.0.1 to 127.0.0.1 8000 in via lo0 setup keep-state
/sbin/ipfw add 5010 pass tcp from me to any 80 out via re0 limit dst-addr 5
/sbin/ipfw add 5008 pass tcp from 127.0.0.1 to 127.0.0.1 8000 in via lo0 setup keep-state
/sbin/ipfw add 5010 pass tcp from me to any 80 out via re0 limit dst-addr 5
/sbin/ipfw add 65511 unreach 255 tcp from any to me via any
/sbin/ipfw add 65512 unreach 255 udp from any to me via any
/sbin/ipfw add 65513 unreach 255 icmp from any to me via any
/sbin/ipfw add 65514 unreach 255 tcp6 from any to me via any
/sbin/ipfw add 65515 unreach 255 udp6 from any to me via any
/sbin/ipfw add 65516 unreach 255 icmp6 from any to me via any
/sbin/ipfw add 65517 unreach 255 tcp from me to any via any
/sbin/ipfw add 65518 unreach 255 udp from me to any via any
/sbin/ipfw add 65519 unreach 255 icmp from me to any via any
/sbin/ipfw add 65520 unreach 255 tcp6 from me to any via any
/sbin/ipfw add 65521 unreach 255 udp6 from me to any via any
/sbin/ipfw add 65522 unreach 255 icmp6 from me to any via any
/sbin/ipfw add 65523 unreach 255 tcp from any to any via any
/sbin/ipfw add 65524 unreach 255 udp from any to any via any
/sbin/ipfw add 65525 unreach 255 icmp from any to any via any
/sbin/ipfw add 65526 unreach 255 tcp6 from any to any via any
/sbin/ipfw add 65527 unreach 255 udp6 from any to any via any
/sbin/ipfw add 65528 unreach 255 icmp6 from any to any via any
/sbin/ipfw add 65529 deny ip from any to any via any
/sbin/ipfw add 65530 deny ip via any
/sbin/ipfw add 65531 deny ip6 from any to any via any
/sbin/ipfw add 65532 deny ip6 via any
/sbin/ipfw add 65533 deny any via any
/sbin/ipfw add 65534 deny any via any
I'm not sure what else to include..
But this thing sure has me PUZZLED.. I have ran FreeBSD for years, but only RECENTLY has this issue cropped up on the last 2 hosts...
ANY help would be appreciated!
-DjZ-