Monday, 15 April 2013

php - Amazon RDS speed -



php - Amazon RDS speed -

i know if ok. signed amazon rds web service speed php application. have basic debian virtual server , queries take 4s execute. thought hosting on amazon's cloud speed running time. exported database, imported amazon rds , found out running time 2 times higher.

one of reason type of business relationship have - free (db.t1.micro). sec - in european union , availability zone set us-west-1 (for reason couldnt select eu). however, checked sql execution time, without network time distance shouldnt matter in case.

so slower non-cloud solution because of type of account? database not big - around 25mb.

thanks.

there many reasons why database query slow:

complexity of query tables not set (e.g. no indexes) power of machine it's running on (aws micro instances weaker laptop) network latency between database machine , client machine (i have case on hands in client close 1000 queries in single page load; both rds instance , web server idle while, yet page load super slow (~2 secs) because close 1000 queries need traverse aws internal network between ec2 instance , rds instance , forth)

you need figure out of applies , how can mitigate it. there's no general reply why slow.

php mysql amazon rds

No comments:

Post a Comment