Fri Mar 23 09:46:54 2007 - lightening talks
chad phillips - delete api -
derek wright - help with issues/cvs/tracker stuffs
allie micka - client project source management. managing drupal/module code. svn.advantagelabs.com. "svn:externals" allows 'symlinking' of other repositories in a local repo. info@advantagelabs.com
Fri Mar 23 10:09:29 2007 - state of drupal. CMSs all becoming very similar. ockham's razor will prevail. required functionality + ease of use = chosen CMS. Data API, drupal as a web service. timeframe for dropping php4 support.
Fri Mar 23 11:20:33 2007 - forms api
Fri Mar 23 14:00:12 2007 - jquery
Performance / Scaling Seminar
Sat Mar 24 2007Isolating bottlenecks -
tools:
- df -h
- w
- last
- top / top > M
- vmstate ( 1 10)
- ? sar - ongoing monitoring, prevent problems
- cpu
- opcode
- profiling
- memory:
- reduce maxclients
- reduce php, drupal modules that are enabled
- db / memory
- !!add memory
- faster disks, raid 0
- disk i/o
- debugging, excessive logging
- excess temp tables
- raid config
- network
- send less, use conpression
- drupal optimization
- page caching
- cron
- disable unused modules
apache/php optimization
- unnecessary modues apache
- ssi, status,
- minimize RAM useage
- maxclients - not enough = blocking, too many = mem hog. available RAM / httpd process size = maxclients.
- symlinks off
- user mem/ not disks
- reduce bandwidth
- mod_gzip, mod_deflate
- mod_expires + drupal .htaccess
- alt server
- lighty much faster by default, but apache can be configured to perform the same. see dries blogpost. Allie mentioned mod to configure apache like lighty.
- php.ini
- memory limit - max that can get away with
- opcode cache
- eaccelerator preferred by bryght, issues with php5,
- APC
- maintained by core developers,
- uses mem rater than FS for cache , much faster
Architecture
- more servers + dns round robin - crude approach, no failover
- load distribution
- pound (bryght)
- ha-proxy (lullabot)
- squid as reverse proxy
- commercial solutions generally faster
- handling static files separately
- file cache
- squid
- apache mode_cache
- ram cache
- media files
- thttpd
- more
- separate machines
- proxy squid / apache
- patch drupal file_url() ??
MySQL Optimization
- Tools
- show status
- show processlist
- mytop
- mysqlreport
- engine
- myisam preferred typically
- not transactional, OS IO dependent, performance loss on large tables
- innodb
- can be much faster than myisam
- auto crash recovery
- hot backups (commercial)
- tuning more important. out of box config will not scale.
- optimized for reads not writes
- purported problems with lock contention. deadlocks.
- tables significantly larger. index is not compressed. more indexes means larger innodb tables. 2-5 X size of myisam.
- oracle owns innodb, claims good intentions, but ????
- innodb_* vars,
- falcon - in development alternative to innodb, not stable. early beta q3 07.
- archive engine - long term, read only data.
- Tuning
- key_buffer size - 30/40% of available ram. all indexes should be cached ideally.
- table_cache - doesn't need to be as large, large enough to open tables, each connection requires its own memory. start with arbitrary 1024 then enlarge as tables are no longer cached.
- thread_cache - mysql preserves threads for reuse.
- query_cache -
- max_connections, wait_timeout, connect_timeout
- idle_connections - reduce this to 15-60 seconds
- caches
- query cache - is byte sensetive, so case of query has effect
- memcached
- underutilized servers
- anything with a lot of memory and sufficient network access. cpu/disk not important.
- reduces load on web / db servers
- can cache anything, any bit of data
- (apc also does generic memory caching but requires redundant copies on each web server)
- memory required 4+ Meg only
- memcached doesn't do any access checking. must be behind firewall and be locked down.
- replication
- after setup, modify _db_query to detect select/show and redirect to slave. . dries interested in adding this functionality to core, patch rumored to exist.
- master - master: not officially supported or part of design.
- master -> slave:
- ucarp
- enable binary logging on master and slave
- slave becomes master on first write
Dries
- summary of existing cache within drupal.
- gzip
- new aggressive page caching (drupal5). skips init() http://www.zmanda.com/and loads fewer modules.
- url alising - itentional.
- tools
- ab
- jmeter
- devel module
- cachegrind / vgrind / etc...
References:
- http://jeremy.zawodny.com/blog/archives/000034.html
- https://www.day32.com/MySQL/ - mysql optimization script
- http://danga.com/memcached/ -
- http://pecl.php.net/package/memcache -
- https://www.drupal.org/project/memcache -
- https://www.zmanda.com:443/ -
- https://jmeter.apache.org/ -
Heya great checklist, I'll definately be printing this out.
Currently looking for some list for performance and code effiency, though I need more, but your 1 is a great addition to me. Thanks and appreciate it!
Maxiderm
maxiderm_pat85@yahoo.com
Apache was designed to be as fast as possible. It's easy, with a fairly low-powered machine, to completely saturate a low-end Internet link with little effort. However, as sites become more complex and the bandwidth needs of different connection types increase, getting the best performance out of an Apache installation and Web sites becomes more important.
thanks for sharing it really help me
Well, it's all done now. It was an awesome experience - I got to meet all the luminaries of the Drupal world (Dries Buytaert, Rasmus Lerdorf, the Lullabots, the Bryght folks, etc etc). I learned a bunch of little things about Drupal, and revitalised my Drupal spirit.You can find the session notes etc on the OSCMS 2007 page at drupal.org. Also, see OSCMS 2007 Photos on Flickr , in particular morten.dk's photos (he's a cool guy).Now I'm itching to do a few more things with Drupal, finish some of my personal projects, and get ready for Drupalcon Barcelona...
Thats a very helpful information thanks for sharing.
Good job