server Optimisation Request(Big hosting)
January 6th, 2009
2.
cpu speed/type single or dual cpus): Dual Xeon 2.8Ghz HT EMT64 (64 Bit)
how much memory installed: 4 GB DDR Registered ECC
hard drive type/configuration: 160 GB 7200RPM Sata Primary Drive + 160 GB 7200RPM Sata Secondary Drive
linux distributor or windows version: CentOS 4.3 i686
apache/IIS version: apache 1.3.37
PHP version: php 4.4.4
MySQL version: mysql 4.1.21-standard
Panel : Cpanel + WHM + Fantastico Included + Rvskin
3. no innodb
4. unsure... cpanel
5.
top - 21:22:00 up 2 days, 21:34, 1 user, load average: 24.13, 25.10, 26.38
Tasks: 375 total, 9 running, 363 sleeping, 1 stopped, 2 zombie
Cpu(s): 0.5% us, 13.1% sy, 85.3% ni, 0.9% id, 0.0% wa, 0.2% hi, 0.0% si
Mem: 4149932k total, 3734312k used, 415620k free, 95916k buffers
Swap: 2040244k total, 41180k used, 1999064k free, 2757740k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
2911 mysql 21 6 344m 249m 2584 S 99.9 6.2 1047:02 mysqld
12307 imagecom 26 4 17076 9704 3200 R 18.5 0.2 0:00.56 php
12313 gencforu 20 4 20020 12m 3240 S 17.2 0.3 0:00.52 php
12222 aramafor 22 4 19408 10m 3236 S 9.9 0.3 0:01.37 php
12332 mendes 20 4 15556 8716 3184 R 9.6 0.2 0:00.29 php
12319 forza 19 4 15204 8000 3192 S 7.6 0.2 0:00.23 php
12328 forum 20 4 18532 10m 3324 S 7.6 0.3 0:00.23 php
12179 aramafor 20 4 19212 11m 3260 S 6.9 0.3 0:01.12 php
12283 forum 26 4 20752 12m 3356 S 5.9 0.3 0:00.85 php
12270 forum 20 4 23816 16m 3352 S 5.0 0.4 0:00.95 php
12329 imagecom 20 4 0 0 0 Z 5.0 0.0 0:00.15 php
12339 forum 21 4 14108 6388 3204 R 4.6 0.2 0:00.14 php
12338 imagecom 20 4 15108 6820 3196 S 3.6 0.2 0:00.11 php
12337 gencforu 20 4 13704 6640 2860 R 3.3 0.2 0:00.10 php
12340 kanayany 22 4 17332 9548 2864 R 1.7 0.2 0:00.05 php
12866 nobody 19 4 12292 8308 1184 S 1.0 0.2 0:02.52 httpd
16175 nobody 19 4 12288 8312 1192 S 1.0 0.2 0:01.99 httpd
6.
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
skip-locking
safe-show-database
skip-innodb
max_connections = 250
max_user_connections = 30
key_buffer = 16M
myisam_sort_buffer_size = 64M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 1800
thread_cache_size = 384
wait_timeout = 120
connect_timeout = 10
tmp_table_size = 128M
max_allowed_packet = 64M
max_connect_errors = 10
read_rnd_buffer_size = 524288
bulk_insert_buffer_size = 8M
thread_concurrency = 4
query_cache_limit = 2M
query_cache_size = 128M
query_cache_type = 1
query_prealloc_size = 16384
query_alloc_block_size = 16384
[mysql.server]
user=mysql
basedir=/var/lib
old-passwords = 1
[mysqld_safe]
open_files_limit = 8192
err-log=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
log-slow-queries=/var/log/mysql-slow
[mysqldump]
quick
max_allowed_packet = 16M
[myisamchk]
key_buffer = 64M
sort_buffer = 64M
read_buffer = 16M
write_buffer = 16M
[mysqlhotcopy]
interactive-timeout7.
MySQL 4.1.21-standard uptime 0 0:29:43 Fri Nov 3 21:56:52 2006
__ Key __________________________________________________ _______________
Buffer used 14.16M of 16.00M %Used: 88.48
Current 16.00M %Usage: 100.00
Write ratio 0.58
Read ratio 0.01
__ Questions __________________________________________________ _________
Total 297.95k 167.11/s
QC Hits 133.43k 74.84/s %Total: 44.78
DMS 118.03k 66.20/s 39.62
Com_ 27.09k 15.19/s 9.09
COM_QUIT 19.35k 10.85/s 6.50
+Unknown 46 0.03/s 0.02
Slow 0 0.00/s 0.00 %DMS: 0.00
DMS 118.03k 66.20/s 39.62
SELECT 83.29k 46.71/s 27.95 70.57
UPDATE 23.79k 13.34/s 7.98 20.16
DELETE 5.33k 2.99/s 1.79 4.51
INSERT 4.67k 2.62/s 1.57 3.96
REPLACE 958 0.54/s 0.32 0.81
Com_ 27.09k 15.19/s 9.09
change_db 24.91k 13.97/s 8.36
show_tables 1.47k 0.82/s 0.49
unlock_tabl 238 0.13/s 0.08
__ SELECT and Sort __________________________________________________ ___
Scan 27.18k 15.25/s %SELECT: 32.64
Range 11.13k 6.24/s 13.36
Full join 235 0.13/s 0.28
Range check 2 0.00/s 0.00
Full rng join 0 0.00/s 0.00
Sort scan 13.49k 7.57/s
Sort range 12.72k 7.13/s
Sort mrg pass 127 0.07/s
__ Query Cache __________________________________________________ _______
Memory usage 69.28M of 128.00M %Used: 54.13
Block Fragmnt 7.50%
Hits 133.43k 74.84/s
Inserts 80.91k 45.38/s
Prunes 1 0.00/s
Insrt:Prune 80.91k:1 45.38/s
Hit:Insert 1.65:1
__ Table Locks __________________________________________________ _______
Waited 178 0.10/s %Total: 0.09
Immediate 190.94k 107.09/s
__ Tables __________________________________________________ ____________
Open 1.80k of 1800 %Cache: 100.00
Opened 2.36k 1.32/s
__ Connections __________________________________________________ _______
Max used 57 of 250 %Max: 22.80
Total 19.37k 10.86/s
__ Created Temp __________________________________________________ ______
Disk table 339 0.19/s
Table 9.63k 5.40/s
File 254 0.14/s
__ Threads __________________________________________________ ___________
Running 3 of 23
Cached 34 of 384 %Hit: 99.71
Created 57 0.03/s
Slow 0 0.00/s
__ Aborted __________________________________________________ ___________
Clients 20 0.01/s
Connects 1 0.00/s
__ Bytes __________________________________________________ _____________
Sent 4.22G 2.36M/s
Received 56.24M 31.54k/s
8. 10-15 vbulletin forum , 10 phpnuke
6-7 vbulletin big forum , 1 imagehost script
9. 600 online users, 1500 cookie timeout
10. www.idealhosting.org/phpini.php (http://www.idealhosting.org/phpini.php)
11.
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 7
MinSpareServers 6
MaxSpareServers 12
StartServers 5
MaxClients 250
12.vb 3.6.2
13. none
14.
Linux host.idealhosting.org 2.6.9-42.0.3.ELsmp #1 SMP Fri Oct 6 06:21:39 CDT 2006 i686 i686 i386 GNU/Linux
ulimit -aH
core file size (blocks, -c) 1000000
data seg size (kbytes, -d) unlimited
file size (blocks, -f) unlimited
pending signals (-i) 1024
max locked memory (kbytes, -l) 32
max memory size (kbytes, -m) unlimited
open files (-n) 4096
pipe size (512 bytes, -p) 8
POSIX message queues (bytes, -q) 819200
stack size (kbytes, -s) 8192
cpu time (seconds, -t) unlimited
max user processes (-u) 14335
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited
cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 15
model : 4
model name : Intel(R) Xeon(TM) CPU 2.80GHz
stepping : 10
cpu MHz : 2802.095
cache size : 2048 KB
physical id : 0
siblings : 2
core id : 0
cpu cores : 1
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 5
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor ds_cpl cid xtpr
bogomips : 5603.90
processor : 1
vendor_id : GenuineIntel
cpu family : 15
model : 4
model name : Intel(R) Xeon(TM) CPU 2.80GHz
stepping : 10
cpu MHz : 2802.095
cache size : 2048 KB
physical id : 0
siblings : 2
core id : 0
cpu cores : 1
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 5
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor ds_cpl cid xtpr
bogomips : 5599.46
processor : 2
vendor_id : GenuineIntel
cpu family : 15
model : 4
model name : Intel(R) Xeon(TM) CPU 2.80GHz
stepping : 10
cpu MHz : 2802.095
cache size : 2048 KB
physical id : 3
siblings : 2
core id : 3
cpu cores : 1
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 5
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor ds_cpl cid xtpr
bogomips : 5599.49
processor : 3
vendor_id : GenuineIntel
cpu family : 15
model : 4
model name : Intel(R) Xeon(TM) CPU 2.80GHz
stepping : 10
cpu MHz : 2802.095
cache size : 2048 KB
physical id : 3
siblings : 2
core id : 3
cpu cores : 1
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 5
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor ds_cpl cid xtpr
bogomips : 5599.48
Hello,
I do not see anything in particular that is causing the load on the server,
just high usage. It appears that the PHP forums under various accounts are
putting load on the server, but there is no single site that is causing more
than any other.
Please help you :(
2. Edit /etc/my.cnf and place the following mysql server settings in /etc/my.cnf and restart mysql server afterwards
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
safe-show-database
old_passwords
back_log = 75
skip-innodb
max_connections = 500
key_buffer = 64M
myisam_sort_buffer_size = 64M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 2000
thread_cache_size = 768
wait_timeout = 25
connect_timeout = 10
tmp_table_size = 128M
max_heap_table_size = 64M
max_allowed_packet = 64M
max_connect_errors = 10
read_rnd_buffer_size = 524288
bulk_insert_buffer_size = 8M
query_cache_limit = 5M
query_cache_size = 80M
query_cache_type = 1
query_prealloc_size = 163840
query_alloc_block_size = 32768
default-storage-engine = MyISAM
[mysqld_safe]
nice = -5
open_files_limit = 8192
[mysqldump]
quick
max_allowed_packet = 16M
[myisamchk]
key_buffer = 64M
sort_buffer = 64M
read_buffer = 16M
write_buffer = 16M
[mysqlhotcopy]
interactive-timeout
4. Install APC Cache lastest version from http://pecl.php.net/package/APC. Read install guide at http://www.vbulletin.com/forum/showthread.php?t=165367 - please remove Zend Optimizer from php.ini before installing APC Cache
5. Edit httpd.conf values from
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 7
MinSpareServers 6
MaxSpareServers 12
StartServers 5
MaxClients 250
to
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 5
MinSpareServers 10
MaxSpareServers 15
StartServers 10
MaxClients 180
maxrequestsperchild set to 500
restart apache
6. If you just upgraded to vB 3.5.x/3.6.x try to disable these 4 options:
Admin CP -> vBulletin Options -> Forums Home Page Options -> Display Logged in Users?
Admin CP -> vBulletin Options -> Forum Display Options (forumdisplay) -> Show Users Browsing Forums
Admin CP -> vBulletin Options -> Thread Display Options -> Show Users Browsing Thread
Admin CP -> vBulletin Options -> Message Searching Options -> Automatic Similar Thread search
7. If you're using CentOS 4.x linxu operating system, then check out http://www.vbulletin.com/forum/showthread.php?t=171071 could be 2.6.9-42.0.3 kernel issue, try downgrading to 2.6.9-42.0.2 or the suggested swappiness tweak
#If you have any other info about this subject , Please add it free.# |