Rasmus Lerdorf关于PHP5性能优化的talk
时间:2007-04-24 来源:blau
主题: Better Web Apps with PHP 5
作者: Rasmus Lerdorf
时间: Jan.18, 2007
地址:
http://talks.php.net/show/lca07
PHP创始人之一做的报告,要用Firefox才能看,IE还看不了
报告的线索是:怎样将一个只能实现17 fetches/sec的程序,通过优化达到1700 fetches/sec,性能提高了100倍,相当厉害,图文并茂,细细品味相信都会有收货!
测试环境:
Hardware:
1.8GHz AMD Athlon,
1GByte RAM
3ware 7200rpm drives under
3ware 7500-4 RAID card
full-duplex 100MBit dedicated segment with no other traffic
Software:
Ubuntu Linux 2.6.15
Apache-1.3.34
PHP 5.1.3-dev
PostgreSQL 8.1
主题要点总结如下:
- disabling SSL in postgres
- turning on persistent connections in PHP's PDO
- switching to MySQL and using it's query caching
- disabling MySQL's internal prepare by using the PDO::ATTR_EMULATE_PREPARES attribute
- Using APC as an opcode cache to avoid repeated compiling
- Configuring APC to only use absolute paths, and setting apc.stat to 0 to avoid having to stat files
- Storing common variables in shared memory via APC
- Caching DB results via APC as well
- Removing unnecessary include files.
关于APC的要点有三条,不过国内关于APC的讨论不多见
作者: Rasmus Lerdorf
时间: Jan.18, 2007
地址:
http://talks.php.net/show/lca07
PHP创始人之一做的报告,要用Firefox才能看,IE还看不了
报告的线索是:怎样将一个只能实现17 fetches/sec的程序,通过优化达到1700 fetches/sec,性能提高了100倍,相当厉害,图文并茂,细细品味相信都会有收货!
测试环境:
Hardware:
1.8GHz AMD Athlon,
1GByte RAM
3ware 7200rpm drives under
3ware 7500-4 RAID card
full-duplex 100MBit dedicated segment with no other traffic
Software:
Ubuntu Linux 2.6.15
Apache-1.3.34
PHP 5.1.3-dev
PostgreSQL 8.1
主题要点总结如下:
- disabling SSL in postgres
- turning on persistent connections in PHP's PDO
- switching to MySQL and using it's query caching
- disabling MySQL's internal prepare by using the PDO::ATTR_EMULATE_PREPARES attribute
- Using APC as an opcode cache to avoid repeated compiling
- Configuring APC to only use absolute paths, and setting apc.stat to 0 to avoid having to stat files
- Storing common variables in shared memory via APC
- Caching DB results via APC as well
- Removing unnecessary include files.
关于APC的要点有三条,不过国内关于APC的讨论不多见
相关阅读 更多 +
排行榜 更多 +