Categories
DATABASE JOB System/Linux/Unix*

Protected: oracle problem 2010.0131

This content is password protected. To view it please enter your password below:

Categories
DATABASE JOB

Protected: 2010.0130 shutdown web

This content is password protected. To view it please enter your password below:

Categories
JOB

Protected: msg 0129

This content is password protected. To view it please enter your password below:

Categories
DATABASE JOB

Protected: mysql myisam performance tunning 過程 – sample data

This content is password protected. To view it please enter your password below:

Categories
DATABASE JOB

Protected: mysql innodb 的部份參數 , my.cnf

This content is password protected. To view it please enter your password below:

Categories
JOB

MySQL performance tunning

重要參數1 = key_buffer_size 這個值只針對 MYISAM engine 有作用 , 這個值用來設定 index 使用多少 memory , mysql 把 index 儘可能的放在 memory 中, 這 key_buffer_size 決定 index 的使用效率 , 效率高的話就是多數的 索引 index 都是存在 memory 中, 那就 select 會快, 一般這個值是 16M , 這兩個狀態值可以用來判斷: Key_reads , Key_read_requests

看以下的例子:
DBM53 的 
show global status like ‘Key_read%’
Key_read_requests 36,479,348,961 
Key_reads 1,009,874,537 

Key_reads / Key_read_requests = 0.02 這樣偏高, 不太好 , 這個值正常是 0.01 , 0.001 最佳

好朋友 phpmyadmin 裡面有很好的解釋:

Key_read_requests 36 G The number of requests to read a key block from the cache.
Key_reads 1,010 M The number of physical reads of a key block from disk. If Key_reads is big, then your key_buffer_size value is probably too small. The cache miss rate can be calculated as Key_reads/Key_read_requests.

這台的 show global variables like ‘key_%’ 是 128MB
key_buffer_size 134,217,728

set global key_buffer_size=1024M

重要參數2 = table_cache

show global status like ‘Open%’

Open_tables 2,048 

若等於

show global variables like ‘%table%cache%’

table_cache 2,048 

並且 Opened_tables 一直增加 , 那要增加 table_cache 的值 , server 1G RAM 推薦 table_cache 128 ~ 256

沒錯, phpmyadmin 指示

Open_tables 2,048 The number of tables that are open.
Opened_tables 6,529 The number of tables that have been opened. If opened tables is big, your table cache value is probably too small.

那麼就來修改 table_cache 吧!

set global table_cache=3000;

 

 

 

not finish!

參考網址:

Categories
System/Linux/Unix*

把 fstab 改壞了, 怎麼辦? Booting into Rescue Mode

開機進入 single user mode 了, 那 / 都 mount 成了 read-only 怎改 /etc/fstab 呢?

mount -o remount,rw /

另外可以參考這篇講 Redhat 的 rescue mode steps : http://bbs.518z.net/read-htm-tid-242.html

Categories
JOB Programming/php

50 個超好用的 PHP 工具 – 50 Extremely Useful PHP Tools

http://www.smashingmagazine.com/2009/01/20/50-extremely-useful-php-tools/

Categories
JOB

Protected: 觀察 22:40 – 23:15 apache log 的變化

This content is password protected. To view it please enter your password below:

Categories
PHOTO

GRDIII – 拍早餐

R0010880