I've just upgraded MySQL version to 4.1.15-log, and with that, I'm going to make some changes to my.cnf. Due to some serious table locking issues that kill the forum's speed, I'm converting maybe four to six tables to InnoDB. Others here have reported it has helped--these locked tables tie up the database far too long.
With this in mind, I need help with my.cnf once again. But, I do need to have the configuration variables for InnoDB addressed as well, and will be adding the variable innodb_file_per_table to my.cnf so we can create individual files for each table. (This is available in 4.1.15.) The variables that may need tweaking are innodb_buffer_pool_size and innodb_log_buffer_size.
Here's the appropriate server information--I don't have "root", but it is a dedicated server, so while I can suggest configuration choices, I'm in no position to update other software (including OS or Apache) or make changes in hardware. With 3.25 GB of memory, I've already filled all four slots, although I could remove the smallest stick and get a 1GB stick to bring it up to 4GB.
1. Dedicated server--we're only running three websites, and only one is the busy one with vBulletin. The MySQL database is shared between the public forum and the private 'test' forum, and two lower-traffic phpBB forums.
2. Server info as follows...
CPU: Celeron 2.8GHz (1)
Hard drive: 40GB S-ATA
Memory: 3.25GB total (three 1GB plus one 256MB stick)
OS: FreeBSD 4.8-STABLE
PHP 4.3.10
MySQL 4..1.15-log
Apache 1.3.29
3. One forum (phpBB) is using InnoDB tables for larger tables; forum is not as active though.
4. MySQL installed by host (Pair Networks)
5. Stats:
Threads: 68,837, Posts: 1,526,940, Members: 6,892
We currently average between 500 and 600 "currently active users".
(What other stats would be needed?)
6. MySQL configuration variables:
+---------------------------------+----------------------------------+
Variable_name Value
+---------------------------------+----------------------------------+
back_log 128
basedir /usr/local/
binlog_cache_size 32768
bulk_insert_buffer_size 8388608
character_set_client latin1
character_set_connection latin1
character_set_database latin1
character_set_results latin1
character_set_server latin1
character_set_system utf8
character_sets_dir /usr/local/share/mysql/charsets/
collation_connection latin1_swedish_ci
collation_database latin1_swedish_ci
collation_server latin1_swedish_ci
concurrent_insert ON
connect_timeout 10
datadir /usr/local/var/
date_format %Y-%m-%d
datetime_format %Y-%m-%d %H:%i:%s
default_week_format 0
delay_key_write ON
delayed_insert_limit 100
delayed_insert_timeout 300
delayed_queue_size 1000
expire_logs_days 0
flush OFF
flush_time 0
ft_boolean_syntax + -><()~*:""&
ft_max_word_len 84
ft_min_word_len 4
ft_query_expansion_limit 20
ft_stopword_file (built-in)
group_concat_max_len 1024
have_archive NO
have_bdb NO
have_blackhole_engine NO
have_compress YES
have_crypt YES
have_csv NO
have_example_engine NO
have_geometry YES
have_innodb YES
have_isam YES
have_ndbcluster NO
have_openssl NO
have_query_cache YES
have_raid NO
have_rtree_keys YES
have_symlink YES
init_connect
init_file
init_slave
innodb_additional_mem_pool_size 1048576
innodb_autoextend_increment 8
innodb_buffer_pool_awe_mem_mb 0
innodb_buffer_pool_size 8388608
innodb_data_file_path ibdata1:10M:autoextend
innodb_data_home_dir
innodb_fast_shutdown ON
innodb_file_io_threads 4
innodb_file_per_table OFF
innodb_flush_log_at_trx_commit 1 Installing RPM doesn't contain my.cnf file (no replies):: Where is the my.cnf file? (no replies) · my.cnf file help (6 replies) my.cnf Help Needed (no replies) · define default database in ~/.my.cnf file http://search.code-head.com/F-Installing-RPM-doesn-t-contain-my.cnf-file-no-replies-2250868HOME |
innodb_flush_method
innodb_force_recovery 0
innodb_lock_wait_timeout 50
innodb_locks_unsafe_for_binlog OFF
innodb_log_arch_dir
innodb_log_archive OFF
innodb_log_buffer_size 1048576
innodb_log_file_size 5242880
innodb_log_files_in_group 2
innodb_log_group_home_dir ./
innodb_max_dirty_pages_pct 90
innodb_max_purge_lag 0
innodb_mirrored_log_groups 1
innodb_open_files 300
innodb_table_locks ON
innodb_thread_concurrency 8
interactive_timeout 28800
join_buffer_size 1044480
key_buffer_size 67108864
key_cache_age_threshold 300
key_cache_block_size 1024
key_cache_division_limit 100
language /usr/local/share/mysql/english/
large_files_support ON
license GPL
local_infile ON
log ON
log_bin OFF
log_error
log_slave_updates OFF
log_slow_queries ON
log_update OFF
log_warnings 1
long_query_time 10
low_priority_updates OFF
lower_case_file_system OFF
lower_case_table_names 0
max_allowed_packet 16776192
max_binlog_cache_size 4294967295
max_binlog_size 1073741824
max_connect_errors 10
max_connections 500
max_delayed_threads 20
max_error_count 64
max_heap_table_size 16777216
max_insert_delayed_threads 20
max_join_size 4294967295
max_length_for_sort_data 1024
max_relay_log_size 0
max_seeks_for_key 4294967295
max_sort_length 1024
max_tmp_tables 32
max_user_connections 0
max_write_lock_count 4294967295
myisam_data_pointer_size 4
myisam_max_extra_sort_file_size 2147483648
myisam_max_sort_file_size 2147483647
myisam_recover_options OFF
myisam_repair_threads 1
myisam_sort_buffer_size 67108864
myisam_stats_method nulls_unequal
net_buffer_length 16384
net_read_timeout 30
net_retry_count 1000000
net_write_timeout 60
new OFF
old_passwords ON
open_files_limit 7408
pid_file /usr/local/var/qs816.pid
port 3306
preload_buffer_size 32768
protocol_version 10
query_alloc_block_size 16384
query_cache_limit 2097152
query_cache_min_res_unit 4096
query_cache_size 134217728
query_cache_type ON
query_cache_wlock_invalidate OFF
query_prealloc_size 16384
range_alloc_block_size 2048
read_buffer_size 1044480
read_only OFF
read_rnd_buffer_size 262144
relay_log_purge ON
relay_log_space_limit 0
rpl_recovery_rank 0
secure_auth OFF
server_id 0
skip_external_locking OFF
skip_networking OFF
skip_show_database OFF
slave_net_timeout 3600
slave_transaction_retries 0
slow_launch_time 2
socket /tmp/mysql.sock
sort_buffer_size 2097144
sql_mode
sql_notes OFF
sql_warnings OFF
storage_engine MyISAM
sync_binlog 0
sync_frm ON
sync_replication 0
sync_replication_slave_id 0
sync_replication_timeout 0
system_time_zone EST
table_cache 1500
table_type MyISAM
thread_cache_size 128
thread_stack 196608
time_format %H:%i:%s
time_zone SYSTEM
tmp_table_size 268435456
tmpdir /usr/tmp
transaction_alloc_block_size 8192
transaction_prealloc_size 4096
tx_isolation REPEATABLE-READ
version 4.1.15-log
version_comment Source distribution
version_compile_machine i386
version_compile_os unknown-freebsd4.8
wait_timeout 28800
+---------------------------------+----------------------------------+
7. MySQL status
+----------------------------+------------+
Variable_name Value
+----------------------------+------------+
Aborted_clients 2
Aborted_connects 31
Binlog_cache_disk_use 0
Binlog_cache_use 0
Bytes_received 154577954
Bytes_sent 2627265196
Com_admin_commands 0
Com_alter_db 0
Com_alter_table 0
Com_analyze 0
Com_backup_table 0
Com_begin 0
Com_change_db 31645
Com_change_master 0
Com_check 0
Com_checksum 0
Com_commit 0
Com_create_db 0
Com_create_function 0
Com_create_index 0
Com_create_table 0
Com_dealloc_sql 0
Com_delete 2102
Com_delete_multi 0
Com_do 0
Com_drop_db 0
Com_drop_function 0
Com_drop_index 0
Com_drop_table 0
Com_drop_user 0
Com_execute_sql 0
Com_flush 0
Com_grant 0
Com_ha_close 0
Com_ha_open 0
Com_ha_read 0
Com_help 0
Com_insert 20299
Com_insert_select 124
Com_kill 0
Com_load 0
Com_load_master_data 0
Com_load_master_table 0
Com_lock_tables 0
Com_optimize 0
Com_preload_keys 0
Com_prepare_sql 0
Com_purge 0
Com_purge_before_date 0
Com_rename_table 0
Com_repair 0
Com_replace 2601
Com_replace_select 0
Com_reset 0
Com_restore_table 0
Com_revoke 0
Com_revoke_all 0
Com_rollback 0
Com_savepoint 0
Com_select 182313
Com_set_option 0
Com_show_binlog_events 0
Com_show_binlogs 0
Com_show_charsets 1
Com_show_collations 1
Com_show_column_types 0
Com_show_create_db 1
Com_show_create_table 95
Com_show_databases 0
Com_show_errors 0
Com_show_fields 0
Com_show_grants 0
Com_show_innodb_status 0
Com_show_keys 0
Com_show_logs 0
Com_show_master_status 0
Com_show_ndb_status 0
Com_show_new_master 0
Com_show_open_tables 0
Com_show_privileges 0
Com_show_processlist 375
Com_show_slave_hosts 0
Com_show_slave_status 0
Com_show_status 377
Com_show_storage_engines 0
Com_show_tables 236
Com_show_variables 5
Com_show_warnings 0
Com_slave_start 0
Com_slave_stop 0
Com_stmt_close 0
Com_stmt_execute 0
Com_stmt_prepare 0
Com_stmt_reset 0
Com_stmt_send_long_data 0
Com_truncate 0
Com_unlock_tables 0
Com_update 57166
Com_update_multi 0
Connections 31916
Created_tmp_disk_tables 251
Created_tmp_files 161
Created_tmp_tables 11256
Delayed_errors 0
Delayed_insert_threads 0
Delayed_writes 0
Flush_commands 1
Handler_commit 0
Handler_delete 13562
Handler_discover 0
Handler_read_first 40598
Handler_read_key 82049742
Handler_read_next 72870933
Handler_read_prev 317128
Handler_read_rnd 4601591
Handler_read_rnd_next 25910457
Handler_rollback 805
Handler_update 4280413
Handler_write 5062026
Key_blocks_not_flushed 0
Key_blocks_unused 0
Key_blocks_used 57990
Key_read_requests 153890565
Key_reads 70546
Key_write_requests 60905
Key_writes 52328
Max_used_connections 80
Not_flushed_delayed_rows 0
Open_files 693
Open_streams 0
Open_tables 628
Opened_tables 629
Qcache_free_blocks 1124
Qcache_free_memory 118902008
Qcache_hits 162259
Qcache_inserts 179826
Qcache_lowmem_prunes 0
Qcache_not_cached 2485
Qcache_queries_in_cache 3256
Qcache_total_blocks 8041
Questions 491479
Rpl_status NULL
Select_full_join 52
Select_full_range_join 0
Select_range 36043
Select_range_check 0
Select_scan 39562
Slave_open_temp_tables 0
Slave_retried_transactions 0
Slave_running OFF
Slow_launch_threads 0
Slow_queries 406
Sort_merge_passes 79
Sort_range 31472
Sort_rows 14982676
Sort_scan 27146
Table_locks_immediate 525224
Table_locks_waited 11398
Threads_cached 76
Threads_connected 4
Threads_created 80
Threads_running 3
Uptime 28137
+----------------------------+------------+
8. Other sites: one active vB forum. One "test" forum in private directory, low volume. Two phpBB forums, extremely low traffic. A few other custom-built applications that use PHP and MySQL, very low volume single-query scripts.
9. Cookie timeout: 2400 seconds (would prefer 1800 seconds though)
10. PHP info enabled temporarily:
http://www.stevehoffman.tv/forums/index.php?do=phpinfo
11. Apache info from phpinfo (no direct access to httpd.conf but can request from host if needed):
Max Requests Per Child: 64000 - Keep Alive: on - Max Per Connection: 100 Timeouts Connection: 150 - Keep-Alive: 5
12. Running vB 3.0.8, but planning upgrade this evening to 3.0.12 now that our database has been upgraded.
13. No files in excess of 2GB, including log files.
Additional:
We are not using fulltext searches at this time.
Our post table has about 1,530,000 rows and is 702MB. The postindex has 29,551,000+ rows and is 627MB. The database tables are optimized weekly. Attachments, CSS, JavaScript apnd avatars are all stored in the file system. Searches are available for members only, so only about half of currently active users have access to search.
(IDEA: how a vB generated page that would show you all of our configuration chioces in admincp?)
Edit: even when we're encountering table locking issues, our server load rarely creeps above 2.00; even so, it won't spike high enough to trigger the "Forum Too Busy" message, which triggers at server loads of 5.00 or more. On our old server, we were getting slammed with double-digit loads when queries were backlogged.
I've posted about troublesome queries elsewhere in the 3.0 troubleshooting forum, if you want to see which queries are causing us problems...
http://www.vbulletin.com/forum/showthread.php?t=170832
Thanks in advance!
Looking good i guess if you care to repost
mysqladmin -u root -p ext stat
we can see how it's fairing
a beefier cpu would help with table locking as well...
but try this for my.cnf
[mysqld]
old_passwords
max_connections = 500
key_buffer = 128M
myisam_sort_buffer_size = 128M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 1800
thread_cache_size = 384
wait_timeout = 180
connect_timeout = 10
tmp_table_size = 256M
max_allowed_packet = 64M
max_connect_errors = 10
read_rnd_buffer_size = 524288
bulk_insert_buffer_size = 8M
thread_concurrency = 2
query_cache_limit = 2M
query_cache_size = 128M
query_cache_type = 1
query_prealloc_size = 16384
query_alloc_block_size = 16384
# innodb settings
innodb_file_per_table
innodb_data_file_path=ibdata1:1G:autoextend:max:2G
innodb_buffer_pool_size=256M
innodb_additional_mem_pool_size=10M
innodb_log_file_size=20M
innodb_log_buffer_size=8M
innodb_flush_log_at_trx_commit=1
innodb_open_files = 300
innodb_status_file
innodb_thread_concurrency = 8
[mysqld_safe]
open_files_limit = 8192
[mysqldump]
quick
max_allowed_packet = 16M
[myisamchk]
key_buffer = 64M
sort_buffer = 64M
read_buffer = 16M
write_buffer = 16M
restart mysql
Only 264 slow queries in almost five days since restarting mysqld. Must be some kind of record. :D
Here's the latest status:
+----------------------------+------------+
Variable_name Value
+----------------------------+------------+
Aborted_clients 8
Aborted_connects 20
Binlog_cache_disk_use 0
Binlog_cache_use 0
Bytes_received 3008687534
Bytes_sent 1801512475
Com_admin_commands 3
Com_alter_db 0
Com_alter_table 0
Com_analyze 0
Com_backup_table 0
Com_begin 0
Com_change_db 604007
Com_change_master 0
Com_check 4
Com_checksum 0
Com_commit 0
Com_create_db 0
Com_create_function 0
Com_create_index 0
Com_create_table 0
Com_dealloc_sql 0
Com_delete 39729
Com_delete_multi 0
Com_do 0
Com_drop_db 0
Com_drop_function 0
Com_drop_index 0
Com_drop_table 0
Com_drop_user 0
Com_execute_sql 0
Com_flush 5
Com_grant 0
Com_ha_close 0
Com_ha_open 0
Com_ha_read 0
Com_help 0
Com_insert 346599
Com_insert_select 1910
Com_kill 0
Com_load 0
Com_load_master_data 0
Com_load_master_table 0
Com_lock_tables 0
Com_optimize 515
Com_preload_keys 0
Com_prepare_sql 0
Com_purge 0
Com_purge_before_date 0
Com_rename_table 0
Com_repair 1
Com_replace 48206
Com_replace_select 0
Com_reset 0
Com_restore_table 0
Com_revoke 0
Com_revoke_all 0
Com_rollback 0
Com_savepoint 0
Com_select 3547642
Com_set_option 0
Com_show_binlog_events 0
Com_show_binlogs 0
Com_show_charsets 2
Com_show_collations 2
Com_show_column_types 0
Com_show_create_db 2
Com_show_create_table 417
Com_show_databases 1
Com_show_errors 0
Com_show_fields 84
Com_show_grants 0
Com_show_innodb_status 0
Com_show_keys 0
Com_show_logs 0
Com_show_master_status 0
Com_show_ndb_status 0
Com_show_new_master 0
Com_show_open_tables 0
Com_show_privileges 0
Com_show_processlist 53723
Com_show_slave_hosts 0
Com_show_slave_status 0
Com_show_status 53718
Com_show_storage_engines 0
Com_show_tables 3478
Com_show_variables 156
Com_show_warnings 0
Com_slave_start 0
Com_slave_stop 0
Com_stmt_close 0
Com_stmt_execute 0
Com_stmt_prepare 0
Com_stmt_reset 0
Com_stmt_send_long_data 0
Com_truncate 0
Com_unlock_tables 0
Com_update 1164782
Com_update_multi 0
Connections 607658
Created_tmp_disk_tables 4876
Created_tmp_files 5701
Created_tmp_tables 184048
Delayed_errors 0
Delayed_insert_threads 0
Delayed_writes 0
Flush_commands 6
Handler_commit 24
Handler_delete 197872
Handler_discover 0
Handler_read_first 774629
Handler_read_key 1401153835
Handler_read_next 1229609527
Handler_read_prev 181000
Handler_read_rnd 67366167
Handler_read_rnd_next 748997338
Handler_rollback 569850
Handler_update 112947154
Handler_write 81669729
Key_blocks_not_flushed 0
Key_blocks_unused 29191
Key_blocks_used 115980
Key_read_requests 148159625
Key_reads 2156025
Key_write_requests 970446
Key_writes 827986
Max_used_connections 41
Not_flushed_delayed_rows 0
Open_files 339
Open_streams 0
Open_tables 259
Opened_tables 2962
Qcache_free_blocks 1799
Qcache_free_memory 115909672
Qcache_hits 3071006
Qcache_inserts 3458959
Qcache_lowmem_prunes 0
Qcache_not_cached 87842
Qcache_queries_in_cache 4808
Qcache_total_blocks 11928
Questions 9543624
Rpl_status NULL
Select_full_join 2807
Select_full_range_join 5
Select_range 634146
Select_range_check 0
Select_scan 676417
Slave_open_temp_tables 0
Slave_retried_transactions 0
Slave_running OFF
Slow_launch_threads 0
Slow_queries 264
Sort_merge_passes 2830
Sort_range 712218
Sort_rows 306557844
Sort_scan 407231
Table_locks_immediate 10368307
Table_locks_waited 91517
Threads_cached 17
Threads_connected 1
Threads_created 150
Threads_running 1
Uptime 414808
+----------------------------+------------+
Uptime: 414808 Threads: 1 Questions: 9543625 Slow queries: 264 Opens: 2962 Flush tables: 6 Open tables: 259 Queries per second avg: 23.007
it doesn't seem mysql related to me .... how did top look ? you still on that poor excuse for a web serving celery cpu (no offense) ? :)
i say it's time to upgrade the server! you should be really on dual cpus with scsi disks and at least 2-3GB ram with those mysql/forum usage stats
I don't think it's MySQL related either! But, something is slowing us down, and for the life of me I can't figure out what is going on.
Looking at top shows the usual suspects. The mysqld is right at the top, as always, followed by at least a dozen httpd processes. Business as usual, in other words. Server loads are very low too--I haven't seen anything above 2.0 the entire time I've monitored it, even when the database is slammed. So, it doesn't seem as though another process is killing the server.
As I mentioned, we had 970 users online at our peak, and we were running fine. Now, even with 300-400 users, we're sometimes dragging along. And it did just happen overnight, literally! Ran fine the prior day with 650 users online during our peak, and the next morning? Wham! Not quite 400 users and queries were stacking up.
Was there anything in mysqlreport that showed anything out of the ordinary? From what I'm seeing using mytop, the queries showing up are random. I do see the 'session' table being slow, but as far as the other queries, they're pretty much an assortment. (IOW, it's not any one or two queries like I used to see when the tables were locking.)
I'm going to keep checking, and I'm also going to ask the host to check the hardware again as well. If performance had degraded over time, I would definitely point to the server being slow. But, performance has been quite acceptable up until a few days ago.
It's giving me grey hair, George! :D I'll let you know what els
Still looking good, George! Almost 550 users online and server load is 0.87 as I write this.
Question: my other moderators and admins are discussing upgrading to 3.5. After reading Erwin's post in the 1 million + large forums thread, he noticed resource usage went up for the web servers, but dropped slightly for MySQL. Will I need a new config for my.cnf if we make the jump to 3.5? I have us running nicely now, and I don't want to upset the apple cart, so to speak... ;)
personally, I'd stick with vB 3.0.13 and wait for vB 3.6 based on the server hardware you're running
So far, so good: we made it through the weekend without any major slowdowns. Our true test is this week, during peak hours (early afternoon through early evening). So far it appears as though our cache hits have improved, and we've only had 259 slow queries in the past 64 hours (since restarting mysqld).
I have also switched the table types of "thread", "deletionlog" and "user" to InnoDB and it has made a huge difference, as the queries accessing these tables are not hanging up the forum.
I just had to report this here: we were hit by the Yahoo Slurp spider last week and as a result, had almost 1,000 users online at one time--we hovered in the 800s and 900s during peak hours, and nobody noticed any major slowdowns. Server loads remained sane also--I don't think we ever went above 2.00. Granted, a Slurp isn't going to generate as much activity as a forum search, but on the other hand, I'm relieved to know that it did not hurt our performance very much.
Another "thanks" from all of us at stevehoffman.tv! :)
Excellent!!
Spoke too soon!
Our forum has been running great since the recent my.cnf tweaking. BUT, when I woke up this morning, everything is running slow. Even around 400 users, it was taking at least several seconds to load a page, but sometimes on the order of a minute or so. It was like somebody flipped a switch! One telling sign was that mysqld had restarted--our host has it set up so that if mysqld gets too far bogged down, it automatically restarts. It didin't help matters.
Server load? It hasn't even crept above 2.0 all day long! In the past, our server loads would go nuts when mysqld was busy. Today, nope--the server barely breaks a sweat.
How much of a difference? I've been monitoring with mytop daily, and our slow queries before the mysqld restart amounted to maybe 1,100 or 1,200 over the course of about seven or eight weeks, which is excellent. In the matter of three hours this morning, we had over 1,000 slow queries. At our peak, we had 970 users online one afternoon in February with NO slowdowns whatsoever--I thought we'd have been dead in the water at that point!
I just had the host reboot the entire server, no go. The host has also gone over our server extensively today, and there are no known hardware issues either. (I thought maybe a memory stick went bad on us.)
I do have a handful of tables as InnoDB, and that was also a big help. However, today, I've noticed that even the session table (which I've verified is type HEAP) has been sluggish! I emptied that table out just in case something was corrupted, but it made no difference. I also ran CHECK TABLE on all of the tables, and optimized all of them as well.
I'm wondering if we have hit a memory limit in one of the buffers, or something similar. Maybe a table has grown larger than what our settings allow for. I did convert our post and postindex tables to InnoDB, but it made no difference at all--it's like anything is slow right now. (How's that for vague! :D )
Anyway, my data is still pretty much the same as what I posted at the beginning of this thread. You can grab a live mysqlreport output here:
http://www.stevehoffman.tv/test/mysqlreport.php
Below are the most recent status and variables output from MySQL. Keep in mind that this is fresh after a reboot. I might try to setup a "live" page where you can get the output instantly from the database, rather than cut/paste it here. (I'll post a reply if I can do so this evening.) Anyway, here we go:
mysql> SHOW STATUS;
+----------------------------+-----------+
Variable_name Value
+----------------------------+-----------+
Aborted_clients 0
Aborted_connects 0
Binlog_cache_disk_use 0
Binlog_cache_use 0
Bytes_received 6836416
Bytes_sent 323557535
Com_admin_commands 18
Com_alter_db 0
Com_alter_table 0
Com_analyze 0
Com_backup_table 0
Com_begin 0
Com_change_db 1623
Com_change_master 0
Com_check 0
Com_checksum 0
Com_commit 0
Com_create_db 0
Com_create_function 0
Com_create_index 0
Com_create_table 0
Com_dealloc_sql 0
Com_delete 98
Com_delete_multi 0
Com_do 0
Com_drop_db 0
Com_drop_function 0
Com_drop_index 0
Com_drop_table 0
Com_drop_user 0
Com_execute_sql 0
Com_flush 0
Com_grant 0
Com_ha_close 0
Com_ha_open 0
Com_ha_read 0
Com_help 0
Com_insert 879
Com_insert_select 4
Com_kill 0
Com_load 0
Com_load_master_data 0
Com_load_master_table 0
Com_lock_tables 0
Com_optimize 0
Com_preload_keys 0
Com_prepare_sql 0
Com_purge 0
Com_purge_before_date 0
Com_rename_table 0
Com_repair 0
Com_replace 104
Com_replace_select 0
Com_reset 0
Com_restore_table 0
Com_revoke 0
Com_revoke_all 0
Com_rollback 0
Com_savepoint 0
Com_select 8044
Com_set_option 0
Com_show_binlog_events 0
Com_show_binlogs 0
Com_show_charsets 0
Com_show_collations 0
Com_show_column_types 0
Com_show_create_db 0
Com_show_create_table 0
Com_show_databases 0
Com_show_errors 0
Com_show_fields 0
Com_show_grants 0
Com_show_innodb_status 0
Com_show_keys 0
Com_show_logs 0
Com_show_master_status 0
Com_show_ndb_status 0
Com_show_new_master 0
Com_show_open_tables 0
Com_show_privileges 0
Com_show_processlist 885
Com_show_slave_hosts 0
Com_show_slave_status 0
Com_show_status 887
Com_show_storage_engines 0
Com_show_tables 9
Com_show_variables 3
Com_show_warnings 0
Com_slave_start 0
Com_slave_stop 0
Com_stmt_close 0
Com_stmt_execute 0
Com_stmt_prepare 0
Com_stmt_reset 0
Com_stmt_send_long_data 0
Com_truncate 0
Com_unlock_tables 0
Com_update 2482
Com_update_multi 0
Connections 1637
Created_tmp_disk_tables 12
Created_tmp_files 4
Created_tmp_tables 576
Delayed_errors 0
Delayed_insert_threads 0
Delayed_writes 0
Flush_commands 1
Handler_commit 0
Handler_delete 110
Handler_discover 0
Handler_read_first 1980
Handler_read_key 2088079
Handler_read_next 1568566
Handler_read_prev 1
Handler_read_rnd 95513
Handler_read_rnd_next 413553
Handler_rollback 1457
Handler_update 326362
Handler_write 135845
Key_blocks_not_flushed 0
Key_blocks_unused 114879
Key_blocks_used 1101
Key_read_requests 124062
Key_reads 1107
Key_write_requests 1048
Key_writes 682
Max_used_connections 71
Not_flushed_delayed_rows 0
Open_files 439
Open_streams 0
Open_tables 491
Opened_tables 492
Qcache_free_blocks 253
Qcache_free_memory 127404160
Qcache_hits 8027
Qcache_inserts 5866
Qcache_lowmem_prunes 0
Qcache_not_cached 2176
Qcache_queries_in_cache 633
Qcache_total_blocks 1776
Questions 24659
Rpl_status NULL
Select_full_join 7
Select_full_range_join 0
Select_range 1668
Select_range_check 0
Select_scan 1757
Slave_open_temp_tables 0
Slave_retried_transactions 0
Slave_running OFF
Slow_launch_threads 0
Slow_queries 14
Sort_merge_passes 1
Sort_range 1231
Sort_rows 303194
Sort_scan 1049
Table_locks_immediate 20547
Table_locks_waited 2020
Threads_cached 42
Threads_connected 29
Threads_created 71
Threads_running 28
Uptime 1044
+----------------------------+-----------+
163 rows in set (0.00 sec)
mysql> show variables;
+---------------------------------+----------------------------------+
Variable_name Value
+---------------------------------+----------------------------------+
back_log 128
basedir /usr/local/
binlog_cache_size 32768
bulk_insert_buffer_size 8388608
character_set_client latin1
character_set_connection latin1
character_set_database latin1
character_set_results latin1
character_set_server latin1
character_set_system utf8
character_sets_dir /usr/local/share/mysql/charsets/
collation_connection latin1_swedish_ci
collation_database latin1_swedish_ci
collation_server latin1_swedish_ci
concurrent_insert ON
connect_timeout 10
datadir /usr/local/var/
date_format %Y-%m-%d
datetime_format %Y-%m-%d %H:%i:%s
default_week_format 0
delay_key_write ON
delayed_insert_limit 100
delayed_insert_timeout 300
delayed_queue_size 1000
expire_logs_days 0
flush OFF
flush_time 0
ft_boolean_syntax + -><()~*:""&
ft_max_word_len 84
ft_min_word_len 4
ft_query_expansion_limit 20
ft_stopword_file (built-in)
group_concat_max_len 1024
have_archive NO
have_bdb NO
have_blackhole_engine NO
have_compress YES
have_crypt YES
have_csv NO
have_example_engine NO
have_geometry YES
have_innodb YES
have_isam YES
have_ndbcluster NO
have_openssl NO
have_query_cache YES
have_raid NO
have_rtree_keys YES
have_symlink YES
init_connect
init_file
init_slave
innodb_additional_mem_pool_size 10485760
innodb_autoextend_increment 8
innodb_buffer_pool_awe_mem_mb 0
innodb_buffer_pool_size 268435456
innodb_data_file_path ibdata1:50M:autoextend
innodb_data_home_dir
innodb_fast_shutdown ON
innodb_file_io_threads 4
innodb_file_per_table ON
innodb_flush_log_at_trx_commit 1
innodb_flush_method
innodb_force_recovery 0
innodb_lock_wait_timeout 50
innodb_locks_unsafe_for_binlog OFF
innodb_log_arch_dir
innodb_log_archive OFF
innodb_log_buffer_size 8388608
innodb_log_file_size 20971520
innodb_log_files_in_group 2
innodb_log_group_home_dir ./
innodb_max_dirty_pages_pct 90
innodb_max_purge_lag 0
innodb_mirrored_log_groups 1
innodb_open_files 300
innodb_table_locks ON
innodb_thread_concurrency 8
interactive_timeout 28800
join_buffer_size 1044480
key_buffer_size 134217728
key_cache_age_threshold 300
key_cache_block_size 1024
key_cache_division_limit 100
language /usr/local/share/mysql/english/
large_files_support ON
license GPL
local_infile ON
log ON
log_bin OFF
log_error
log_slave_updates OFF
log_slow_queries ON
log_update OFF
log_warnings 1
long_query_time 10
low_priority_updates OFF
lower_case_file_system OFF
lower_case_table_names 0
max_allowed_packet 67107840
max_binlog_cache_size 4294967295
max_binlog_size 1073741824
max_connect_errors 10
max_connections 500
max_delayed_threads 20
max_error_count 64
max_heap_table_size 16777216
max_insert_delayed_threads 20
max_join_size 4294967295
max_length_for_sort_data 1024
max_relay_log_size 0
max_seeks_for_key 4294967295
max_sort_length 1024
max_tmp_tables 32
max_user_connections 0
max_write_lock_count 4294967295
myisam_data_pointer_size 4
myisam_max_extra_sort_file_size 2147483648
myisam_max_sort_file_size 2147483647
myisam_recover_options OFF
myisam_repair_threads 1
myisam_sort_buffer_size 134217728
myisam_stats_method nulls_unequal
net_buffer_length 16384
net_read_timeout 30
net_retry_count 1000000
net_write_timeout 60
new OFF
old_passwords ON
open_files_limit 7408
pid_file /usr/local/var/qs816.pid
port 3306
preload_buffer_size 32768
protocol_version 10
query_alloc_block_size 16384
query_cache_limit 2097152
query_cache_min_res_unit 4096
query_cache_size 134217728
query_cache_type ON
query_cache_wlock_invalidate OFF
query_prealloc_size 16384
range_alloc_block_size 2048
read_buffer_size 1044480
read_only OFF
read_rnd_buffer_size 5238784
relay_log_purge ON
relay_log_space_limit 0
rpl_recovery_rank 0
secure_auth OFF
server_id 0
skip_external_locking OFF
skip_networking OFF
skip_show_database OFF
slave_net_timeout 3600
slave_transaction_retries 0
slow_launch_time 2
socket /tmp/mysql.sock
sort_buffer_size 2097144
sql_mode
sql_notes OFF
sql_warnings OFF
storage_engine MyISAM
sync_binlog 0
sync_frm ON
sync_replication 0
sync_replication_slave_id 0
sync_replication_timeout 0
system_time_zone EST
table_cache 1800
table_type MyISAM
thread_cache_size 128
thread_stack 196608
time_format %H:%i:%s
time_zone SYSTEM
tmp_table_size 268435456
tmpdir /usr/tmp
transaction_alloc_block_size 8192
transaction_prealloc_size 4096
tx_isolation REPEATABLE-READ
version 4.1.15-log
version_comment Source distribution
version_compile_machine i386
version_compile_os unknown-freebsd4.8
wait_timeout 28800
+---------------------------------+----------------------------------+
184 rows in set (0.00 sec)
The only thing we didn't do was change the size of the InnoDB data file in innodb_data_file_path since our host thought there was a chance of corrupting the data (since it would have to build a new file...I think that's what the reason was).
Also, our host said we have about 1.5GB of unused memory on the server right now. It is OK to leave some of that memory as a cushion for Apache and other processes, but they feel we could probably allocate a good additional chunk of this memory to MySQL if we need it. If so, some of these settings could probably be bumped a bit.
Anything else we could check? I can PM or e-mail a login if you need it.
EDIT: current live VARIABLES and STATUS can be found here:
http://www.stevehoffman.tv/test/showvariables.php
http://www.stevehoffman.tv/test/showstatus.php
Handy, since we can peek in on these at any time. PHP executes the mysqladmin commands to generate the pages, so they're always fresh.
Thanks much--I'll get this one installed and reboot later, and let you know how we're doing. :)
looking very good :D
I just had to report this here: we were hit by the Yahoo Slurp spider last week and as a result, had almost 1,000 users online at one time--we hovered in the 800s and 900s during peak hours, and nobody noticed any major slowdowns. Server loads remained sane also--I don't think we ever went above 2.00. Granted, a Slurp isn't going to generate as much activity as a forum search, but on the other hand, I'm relieved to know that it did not hurt our performance very much.
Another "thanks" from all of us at stevehoffman.tv! :)
it doesn't seem mysql related to me .... how did top look ? you still on that poor excuse for a web serving celery cpu (no offense) ? :)
i say it's time to upgrade the server! you should be really on dual cpus with scsi disks and at least 2-3GB ram with those mysql/forum usage stats
Where was the last debate on wednesday with Mccain and Obama?
INSTANCE / WAITING FOR SPRING
|