Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I ran vbulletin on a dedicated server that running centros with 1 gig ram, but for some reaseon when it reach about 350 user viewing the forum then the connection get time out. but im still can pinging it with really good response time avg. 50ms
This could be one of many things.
You haven't put much info in here to help.
Something I would check first is disk io.
If you have it all on the one server ( webserver, sql server etc etc )
then it is quite possible it is disk io.
You can check out the disk io, along with other things with the command iostat -x 1 ( the number is the refresh rate )
ice: rrqm/s wrqm/s r/s w/s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm %util
sda 0.03 8.41 0.52 10.12 23.37 141.13 11.68 70.57 15.46 0.03 2.69 3.17 3.38
the coloum %util tells you how busy the hard drive is. If this is constantly up around the 100% mark then that is the bottleneck.
iostat is part of the sysstat package on a fedora server.
If this is it then several things to possible do, make sure the sql server is tuned properly or move the sql server to a seperate disk array or seperate server.
Post a bit more info.
Server stats: raid 1/5 ?? drive speeds, etc etc
I looked at the iostat during peek time and the %util isn't not even 50%. So i look at apache states and figure out that when i get timeout is when the apache restart, but I don't know why it's restart it's possile to look at the log and figure out why apache restart?
according to apache error log these things happend when apache restart:
Code:
[Wed Oct 31 17:17:11 2007] [warn] VirtualHost SERVER.IP:80 overlaps with VirtualHost SERVER.IP:80, the first has precedence, perhaps you need a NameVirtualHost directive
[Wed Oct 31 17:17:11 2007] [warn] VirtualHost SERVER.IP:80 overlaps with VirtualHost SERVER.IP:80, the first has precedence, perhaps you need a NameVirtualHost directive
[Wed Oct 31 17:17:11 2007] [warn] VirtualHost SERVER.IP:80 overlaps with VirtualHost SERVER.IP:80, the first has precedence, perhaps you need a NameVirtualHost directive
[Wed Oct 31 17:17:11 2007] [warn] VirtualHost SERVER.IP:80 overlaps with VirtualHost SERVER.IP:80, the first has precedence, perhaps you need a NameVirtualHost directive
[Wed Oct 31 17:17:11 2007] [warn] VirtualHost SERVER.IP:80 overlaps with VirtualHost SERVER.IP:80, the first has precedence, perhaps you need a NameVirtualHost directive
[Wed Oct 31 17:17:11 2007] [warn] NameVirtualHost SERVER.IP:80 has no VirtualHosts
[Wed Oct 31 17:17:11 2007] [warn] NameVirtualHost SERVER.IP:80 has no VirtualHosts
[Wed Oct 31 17:17:11 2007] [warn] NameVirtualHost SERVER.IP:80 has no VirtualHosts
[Wed Oct 31 17:17:11 2007] [warn] NameVirtualHost SERVER.IP:80 has no VirtualHosts
[Wed Oct 31 17:17:11 2007] [warn] NameVirtualHost SERVER.PRIVATE.IP:80 has no VirtualHosts
[Wed Oct 31 17:17:11 2007] [notice] Apache/1.3.39 (Unix) mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 PHP/4.4.7 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.30 OpenSSL/0.9.7a configured -- resuming normal operations
[Wed Oct 31 17:17:11 2007] [notice] suEXEC mechanism enabled (wrapper: /usr/local/apache/bin/suexec)
[Wed Oct 31 17:17:11 2007] [notice] Accept mutex: sysvsem (Default: sysvsem)
From those log messages, I'd say that something's amiss with your virtualhost declarations. You should consult the apache docs ( http://httpd.apache.org/docs/2.2/vhosts/name-based.html ) and straighten that out. But that's probably just a "correctness" issue, not the likely root cause of your timeouts and other problems.
You should check out "top" and "uptime" -- both of which will tell you your load average. Also, "free" is handy for system information gathering (eg: free -m), and vmstat to see what's going on in memory. iostat only gives you one piece of the picture.
If your vmstat output shows significant swapping in and out, you probably have a bit of a memory shortage going on, and should do something about that.
If your load is very high (say, >=5), and the highest-up processes in "top" are either php or httpd processes (depending on whether you're using php as a cgi or module), you should look into PHP Opcode Caching (hint: keywords ). You may also benefit from switching from php-cgi to fastcgi, performance-tuning and trimming down apache, etc. But seriously, appropriate opcode caching is just an insane improvement in responsiveness and load time, so if you're running any significant php you should definitely be running something for it.
If MySQL is high up in the list, you should verify that thread caching, query caching, and your buffer settings are sane. Relevant variables include query_cache_limit, query_cache_size, thread_cache_size, key_buffer, join_buffer_size, sort_buffer_size. See also http://dev.mysql.com/doc/refman/5.1/...variables.html, and the "show variables" and "show status" command from within mysql. You may also benefit from making sure that your queries are appropriately indexed, leveraging the slow query log as necessary.
thank you for your reply. Before apache restore I did ran top and saw only 140mb of memory are free, couple minute later it it's restart.
So could it be memory problem.
On the old server I ran P4 single core 3.6Ghz with only 1 gig and it was able to handle 500 vbulletin users. Now on the new server I have Dual processor dual core 2.4Ghz with 4 gigs and it only handle about 800 users. I didn't expect the number to be quadrupal (2000) but isn't 800 too low for the new server specs ?
yeah, have you looked into that opcode caching thing I mentioned? And the mysql variables?
Seriously ... I have a celeron 2.4 with a gig of ram and it and it handles several hundred concurrent users on vbulletin, several dozen on a separate phpbb, loads of simultaneous downloads of video files, a fairly busy bittorrent tracker and a couple other things with no major issues. PHP Opcode caching and tuning those couple of mysql settings I mentioned dropped my system load on that machine from 35.0-70.0 to lower than 2.0.
As far as the free memory that top reports, pay little attention to it. Linux uses memory as an io cache and for various io-related buffers, and frees them on demand. If you look at "free -m" you'll see two lines: "Mem:" "-/+ buffers/cache:" and "swap". The second line's "free" column is how much memory is actually available (ie: allocated for buffers/cache, but can be dumped on demand).
The "load average" values are probably the single most telling indicator on a webserver. Load average of less than the number of cpu's means you're generally doing ok...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.