0

I'm running 16 GB of RAM with dual 3.0 Ghz processors with Ubuntu Server

My PHPMyAdmin is showing: Opened_tables 2,573 - The number of tables that have been opened. If opened tables is big, your table cache value is probably too small.

I just restarted MySQL about 4 minutes ago and adjusted table_cache from default to 256, it's not a heavy load time. My databases combined are all under 250 MB at the moment. Is it possible that this number PHpMyAdmin is showing is old and I just need to wait to get it updated?

Current configuration:

key_buffer              = 1024M
max_allowed_packet      = 16M
thread_stack            = 192K
thread_cache_size       = 8
# This replaces the startup script and checks MyISAM tables if needed
# the first time they are touched
myisam-recover         = BACKUP
max_connections        = 1500
table_cache            = 256
thread_concurrency     = 4
#
# * Query Cache Configuration
#
query_cache_limit       = 10M
query_cache_size        = 512M
query_cache_type        = 1
#
# * Custom Configuration
#
tmp_table_size          = 512M
max_heap_table_size     = 128M
join_buffer_size        = 512M
myisam_sort_buffer_size = 512M
Ben
  • 3,800
  • 18
  • 65
  • 96
  • Are you seeing poor performance? If not, I wouldn't worry about it... – EEAA Nov 08 '10 at 16:30
  • Some of my pages are loading slowly, I'm working to determine if it's the query or if it's a server setting. And it shows up in red so I want to get rid of it ^_^ – Ben Nov 08 '10 at 17:42

2 Answers2

1

If you look at the example config files that come with mysql-server, you can find the values 256 and 512 for the large and huge configurations respectively. They can be found under:

/usr/share/doc/mysql-server-5.0/examples/

So, the value you have chosen should be fine. You may need to restart apache process and/or clear the browser cache.

Sometimes, I fail to connect to mysql server even though I was supplying the correct credentials. This is because the browser was showing me a cache version of the page!!

Khaled
  • 36,533
  • 8
  • 72
  • 99
0

I believe that number is actually including temp tables (memory and disk)..

How about occasionally running flush tables;

See what it says after that.

Jubin Patel
  • 103
  • 4
Arenstar
  • 3,602
  • 2
  • 25
  • 34
  • It still shows the old numbers :-\ – Ben Nov 08 '10 at 17:41
  • Interesting... im suprised as you are.. Do you actually have 2000+ tables? Are they all being used often?? Your databases are 250MB compressed or uncompressed.. Im asking because its quite alot of tables.. for your data size.. Are you sure flush tables invoked? Try from command line, _flush tables_ and _show status like 'Open_tables';_ – Arenstar Nov 08 '10 at 18:19