OK ich gebe zu, die Ã?berschrift könnte besser sein, aber ich weis nicht genau wie ichs stellen soll :roll:
Mein Server ist der Rootie L mit 256MB Ram... Apache 1.2.26 rennt drauf, MySQL sowie PHP 4.3.3
MySQL-Einstellung: my.cnf
Code: Select all
[mysqld]
#port = 3306
socket = /var/lib/mysql/mysql.sock
skip-locking
skip-networking
set-variable = key_buffer=16M
set-variable = max_allowed_packet=12M
set-variable = table_cache=64
set-variable = sort_buffer=512K
set-variable = net_buffer_length=8K
set-variable = myisam_sort_buffer_size=12M
log-bin
server-id = 1
# Point the following paths to different dedicated disks
#tmpdir = /tmp/
#log-update = /path-to-dedicated-directory/hostname
# Uncomment the following if you are using BDB tables
#set-variable = bdb_cache_size=4M
#set-variable = bdb_max_lock=10000
# Uncomment the following if you are using InnoDB tables
#innodb_data_home_dir = /var/lib/mysql/
#innodb_data_file_path = ibdata1:10M:autoextend
#innodb_log_group_home_dir = /var/lib/mysql/
#innodb_log_arch_dir = /var/lib/mysql/
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
#set-variable = innodb_buffer_pool_size=16M
#set-variable = innodb_additional_mem_pool_size=2M
# Set .._log_file_size to 25 % of buffer pool size
#set-variable = innodb_log_file_size=5M
#set-variable = innodb_log_buffer_size=8M
#innodb_flush_log_at_trx_commit=1
#set-variable = innodb_lock_wait_timeout=50
# The safe_mysqld script
[safe_mysqld]
err-log=/var/lib/mysql/mysqld.log
[mysqldump]
quick
set-variable = max_allowed_packet=40M
[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates
[isamchk]
set-variable = key_buffer=20M
set-variable = sort_buffer=20M
set-variable = read_buffer=2M
set-variable = write_buffer=2M
[myisamchk]
set-variable = key_buffer=20M
set-variable = sort_buffer=20M
set-variable = read_buffer=2M
set-variable = write_buffer=2M
[mysqlhotcopy]
interactive-timeout
Code: Select all
;;;;;;;;;;;;;;;;;;;
; Resource Limits ;
;;;;;;;;;;;;;;;;;;;
max_execution_time = 30 ; Maximum execution time of each script, in seconds
max_input_time = 60 ; Maximum amount of time each script may spend parsing request data
memory_limit = 12M ; Maximum amount of memory a script may consume (8MB)
Code: Select all
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 15
MinSpareServers 5
MaxSpareServers 10
StartServers 5
MaxClients 150
MaxRequestsPerChild 1000
Nachdem ich dann den Apache Restartet hatte war sofort die Swap leer und nach ca. 5 Minuten sah es dann so aus...
Code: Select all
Mem: 248328K av, 103800K used, 144528K free, 0K shrd, 9384K buff
Swap: 787176K av, 19268K used, 767908K free 34932K cached
PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND
1240 wwwrun 9 0 14620 14M 8756 S 0.0 5.8 0:07 httpd
1242 wwwrun 9 0 13040 12M 8732 S 0.0 5.2 0:06 httpd
1243 wwwrun 9 0 12916 12M 8728 S 0.0 5.2 0:06 httpd
1256 wwwrun 9 0 12780 12M 8660 S 0.0 5.1 0:05 httpd
1239 wwwrun 9 0 12728 12M 8816 S 0.0 5.1 0:04 httpd
1257 wwwrun 9 0 12672 12M 8816 S 0.0 5.1 0:04 httpd
1241 wwwrun 9 0 12504 12M 8668 S 0.0 5.0 0:05 httpd
1259 wwwrun 9 0 11928 11M 8656 S 0.0 4.8 0:04 httpd
1252 wwwrun 9 0 11480 11M 8760 S 0.0 4.6 0:02 httpd
1255 wwwrun 9 0 11260 10M 8768 S 0.0 4.5 0:01 httpd
Denn Teamspeak und MySQL zeigen mir absolut normalen Speicherwert an und belegen kaum Speicher, wenn der Apache aus ist belegt das System grade mal 40MB Ram...
Kann bei dieser Sache jemand ein paar Tipps und Hinweise geben wie man den Apachen 'optimal' einstellt (Ich weis das es sowas nicht gibt, aber halt in die Richtung :))
Gruss,
Michael