The following is from just two invocations of "mongrel_rails". Is this normal? 57M x 3 seems a little high to me. This is the latest pre-release, Debian sarge, on my VPS. Two Rails apps running against SQLite3, with Pound in front. top - 10:50:12 up 47 days, 12:09, 1 user, load average: 0.06, 0.03, 0.01 Tasks: 52 total, 2 running, 50 sleeping, 0 stopped, 0 zombie Cpu(s): 0.0% us, 0.0% sy, 0.0% ni, 99.3% id, 0.7% wa, 0.0% hi, 0.0% si Mem: 196772k total, 193036k used, 3736k free, 40404k buffers Swap: 131064k total, 27688k used, 103376k free, 16160k cached PID %MEM USER PR NI VIRT SHR RES S %CPU TIME+ COMMAND 20220 29.7 wilson 16 0 63352 2044 57m S 0.0 0:03.19 mongrel_rails 20222 29.7 wilson 16 0 63352 2044 57m S 0.0 0:00.00 mongrel_rails 20223 29.7 wilson 15 0 63352 2044 57m S 0.0 0:00.00 mongrel_rails 20191 11.0 wilson 16 0 27144 1704 21m S 0.0 0:02.58 mongrel_rails 20193 11.0 wilson 16 0 27144 1704 21m S 0.0 0:00.00 mongrel_rails 20194 11.0 wilson 15 0 27144 1704 21m S 0.0 0:00.00 mongrel_rails 21746 0.8 wilson 16 0 6684 1308 1668 R 0.0 0:00.00 sshd 21742 0.8 root 16 0 6552 1340 1648 S 0.0 0:00.00 sshd 21744 0.8 root 16 0 6552 1340 1648 S 0.0 0:00.00 sshd 21747 0.8 wilson 15 0 2680 1140 1480 S 0.0 0:00.00 bash 25903 0.7 www-data 16 0 5356 672 1292 S 0.0 0:00.00 pound 25904 0.7 www-data 16 0 5356 672 1292 S 0.0 0:00.01 pound 25905 0.7 www-data 16 0 5356 672 1292 S 0.0 0:00.02 pound 25906 0.7 www-data 19 0 5356 672 1292 S 0.0 188:06.70 pound
On Fri, 2006-06-16 at 11:23 -0400, Wilson Bilkovich wrote:> The following is from just two invocations of "mongrel_rails". Is > this normal? 57M x 3 seems a little high to me.Man, if this was Java you''d be jumping with joy at "just" 57M for three instances. :-)> This is the latest pre-release, Debian sarge, on my VPS. Two Rails > apps running against SQLite3, with Pound in front.Kind of OT, but do you run into problems with the three instances accessing one SQLite3 db at the same time? There has always been concurrency problems with the sqlite3 driver (and sqlite2).> PID %MEM USER PR NI VIRT SHR RES S %CPU TIME+ COMMAND > 20220 29.7 wilson 16 0 63352 2044 57m S 0.0 0:03.19 > mongrel_rails > 20222 29.7 wilson 16 0 63352 2044 57m S 0.0 0:00.00 > mongrel_rails > 20223 29.7 wilson 15 0 63352 2044 57m S 0.0 0:00.00 > mongrel_rails > 20191 11.0 wilson 16 0 27144 1704 21m S 0.0 0:02.58 > mongrel_rails > 20193 11.0 wilson 16 0 27144 1704 21m S 0.0 0:00.00 > mongrel_rails > 20194 11.0 wilson 15 0 27144 1704 21m S 0.0 0:00.00 > mongrel_railsYou''re running a total of 6 instances and 3 of them seem to have high ram? First off your pound setup may be "favoring" those first three, which isn''t so bad but would explain why it''s unevenly distributed. If this is the case then you could probably just get rid of the other three since it seems like they aren''t being used. Second, make sure you have the very latest pre-release as it fixes a big socket/thread leak which could very well cause this. One way to verify that you have the right version is run this comman: while true; do ab -n 1000 -c 30 http://localhost:3000/ 2>/dev/null | grep quest.*mean ; echo -- ; done against one of the intances and see if your speed continually drops. If it drops then update from the pre-release. Hit me up on IRC for more help. -- Zed A. Shaw http://www.zedshaw.com/ http://mongrel.rubyforge.org/
On 6/16/06, Zed Shaw <zedshaw at zedshaw.com> wrote:> On Fri, 2006-06-16 at 11:23 -0400, Wilson Bilkovich wrote: > > The following is from just two invocations of "mongrel_rails". Is > > this normal? 57M x 3 seems a little high to me. > > Man, if this was Java you''d be jumping with joy at "just" 57M for three > instances. :-)Aah. Then there is some kind of problem, right? I only typed "mongrel_rails start" twice, one for each app. I''m intending to only be running one instance per app.> > > This is the latest pre-release, Debian sarge, on my VPS. Two Rails > > apps running against SQLite3, with Pound in front. > > Kind of OT, but do you run into problems with the three instances > accessing one SQLite3 db at the same time? There has always been > concurrency problems with the sqlite3 driver (and sqlite2).Someone on IRC today was saying that it was OK to do that for apps that were read-heavy, but personally I''d move up to postgresql as soon as I needed multiple Mongrels.> > Second, make sure you have the very latest pre-release as it fixes a big > socket/thread leak which could very well cause this. One way to verify > that you have the right version is run this comman: >I updated the install last night from mongrel.rubyforge.org/releases/> Hit me up on IRC for more help. >I don''t see you in the channel. Thanks, --Wilson.