50 User gleichzeitig sind bei mir schon ein Problem....
Hier mal ein paar Informationen:
Sys: Suse 9.1
CPU: 2000MHz
Ram: 2000MB
Anbindung ans Inet: 100Mbit
HTTPD.CONF
- Code: Select all
ServerRoot "/opt/lampp"
Listen 80
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authn_dbm_module modules/mod_authn_dbm.so
LoadModule authn_anon_module modules/mod_authn_anon.so
LoadModule authn_dbd_module modules/mod_authn_dbd.so
LoadModule authn_default_module modules/mod_authn_default.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule authz_dbm_module modules/mod_authz_dbm.so
LoadModule authz_owner_module modules/mod_authz_owner.so
LoadModule authz_default_module modules/mod_authz_default.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule include_module modules/mod_include.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule env_module modules/mod_env.so
LoadModule expires_module modules/mod_expires.so
LoadModule headers_module modules/mod_headers.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule mime_module modules/mod_mime.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule cgi_module modules/mod_cgi.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule dir_module modules/mod_dir.so
LoadModule actions_module modules/mod_actions.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so
..
... Servername und Serveradmin etc.
...
<Directory />
Options FollowSymLinks
AllowOverride None
#XAMPP
#Order deny,allow
#Deny from all
</Directory>
<Directory "/home/www">
Options Indexes ExecCGI Includes FollowSymLinks
AllowOverride None
AllowOverride All
Order allow,deny
Allow from all
</Directory>
<IfModule dir_module>
#DirectoryIndex index.html
# XAMPP
DirectoryIndex index.html index.html.var index.php index.php3 index.php4
</IfModule>
<FilesMatch "^\.ht">
Order allow,deny
Deny from all
</FilesMatch>
ErrorLog logs/error_log
LogLevel warn
Include etc/extra/httpd-mpm.conf
Include etc/extra/httpd-autoindex.conf
Include etc/extra/httpd-vhosts.conf
Include etc/extra/httpd-default.conf
<IfModule ssl_module>
Include etc/extra/httpd-ssl.conf
</IfModule>
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
Include etc/extra/httpd-xampp.conf
HTTPD-DEFAULT.CONF
- Code: Select all
Timeout 120
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 4
UseCanonicalName Off
AccessFileName .htaccess
ServerTokens Full
ServerSignature On
HostnameLookups Off
HTTPD-MPM.CONF
- Code: Select all
<IfModule !mpm_netware_module>
PidFile logs/httpd.pid
</IfModule>
<IfModule !mpm_winnt_module>
<IfModule !mpm_netware_module>
LockFile logs/accept.lock
</IfModule>
</IfModule>
<IfModule mpm_prefork_module>
StartServers 5
MinSpareServers 5
MaxSpareServers 10
MaxClients 256
MaxRequestsPerChild 500
</IfModule>
<IfModule mpm_worker_module>
StartServers 5 #2
MaxClients 256 #150 #1800
MinSpareThreads 25 #30
MaxSpareThreads 75 #60
ThreadsPerChild 25 #60
MaxRequestsPerChild 500 #0
</IfModule>
HTTPD-XAMPP.CONF
- Code: Select all
<IfDefine PHP4>
LoadModule php4_module modules/libphp4.so
</IfDefine>
<IfDefine PHP5>
LoadModule php5_module modules/libphp5.so
</IfDefine>
# since LAMPP 0.9.8:
LoadModule perl_module modules/mod_perl.so
Alias /phpmyadmin "/opt/lampp/phpmyadmin"
Alias /phpsqliteadmin "/opt/lampp/phpsqliteadmin"
# since XAMPP 1.4.3
<Directory "/opt/lampp/phpmyadmin">
AllowOverride AuthConfig Limit
Order allow,deny
Allow from all
</Directory>
<Directory "/opt/lampp/phpsqliteadmin">
AllowOverride AuthConfig Limit
Order allow,deny
Allow from all
</Directory>
# since LAMPP 1.0RC1
AddType application/x-httpd-php .php .php3 .php4
XBitHack on
# since 0.9.8 we've mod_perl
PerlModule Bundle::Apache2
# demo for mod_perl responsehandler
#PerlModule Apache::CurrentTime
#<Location /time>
# SetHandler modperl
# PerlResponseHandler Apache::CurrentTime
#</Location>
# AcceptMutex sysvsem is default but on some systems we need this
# thanks to jeff ort for this hint
#AcceptMutex flock
#LockFile /opt/lampp/logs/accept.lock
Apachebenchmark sagt, bei 50 gleichzeitigen Usern und einer Gesamtsumme von 5000 Anfragen, benötigt meine Webseite (www.onlinewars.eu) 22 Sekunden. Dabei verursacht der Benchmark, ausgeführt von einem anderen Server, eine CPU-Last von 96% auf dem Webserver. Der Arbeitsspeicher hingegen wird kaum/garnicht angefasst.
Eventuell noch Interessant wäre die my.cnf
- Code: Select all
[client]
#password = your_password
port = 3306
socket = /opt/lampp/var/mysql/mysql.sock
# Here follows entries for some specific programs
# The MySQL server
[mysqld]
# commented out by lampp security
#port = 3306
set-variable = max_connections=2500
port = 0
socket = /opt/lampp/var/mysql/mysql.sock
skip-locking
key_buffer = 200M
max_allowed_packet = 10M #1M
table_cache = 128M #512
sort_buffer_size = 100M #50M
net_buffer_length = 8K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 128M #64M
query_cache_limit = 20M #1M
query_cache_size = 100M #32M
query_cache_type = 1
server-id = 1
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
no-auto-rehash
[isamchk]
key_buffer = 128M
sort_buffer_size = 128M
read_buffer = 8M #2M
write_buffer = 8M #2M
[myisamchk]
key_buffer = 128M
sort_buffer_size = 128M
read_buffer = 2M
write_buffer = 2M
[mysqlhotcopy]
interactive-timeout
Hat jemand eine Idee was ich sonst noch optimieren könnte damit der Server schneller wird? Oder anderst gefragt: Was ist alles falsch?
Für eure Hilfe bedanke ich mich schonmal vielmals!