eMEraLdwPn
08-29-2005, 10:14 PM
i've been with my host for the past 5 months on the same server with no problems at all until this weekend. friday night, the database for my largest site disappeared from the server. i emailed my host asking what happened, and they replied saying that there were too many queries on the database and it was causing the server to overload, so they disabled it and won't enable it until i fix my code. this site receives a large amount of traffic and is completely database driven, so i'm well aware of the fact that it queries the database often, which is why i've spent many hours optimizing the code and all the queries in the past. so when they told me i needed to fix my code i wasn't really sure what to fix, so i just made some minor changes that i thought could help, and sent the code to a friend who also said he couldn't find any problems with it. i email my host telling them i made some changes, a bit later they say the script looks fine now and re-enable the db. this seemed kind of like bs to me, seeing as how the script is 100+ pages and i only edited about 3 of those files, so how could they say that the script looks fine? but whatever, it seems like the problem is resolved.
sunday afternoon i wake up, the database is disabled again. i send an email asking them why, same reason as before and it won't be turned back on until i fix the code. i try to explain to them that this script is huge, and them telling me "it's bad, fix it" really is pointless since i have no idea where to start. after two days of emailing them back and forth trying to get some sort of useful information out of them, i get absolutely nothing, and finally they just randomly decide to turn the db back on and tell me "this better not happen again", but it almost certainly will since they were absolutely no help. basically they told me "we won't look at your script or help you in any way whatsoever, you're on your own, take care of the problem".
what i can't seem to understand is how after 5 months, the script is first starting to cause problems now, especially due to the fact that:
1) my traffic is about 2/3 the traffic i had last month
2) friday - sunday are my lowest traffic days
i really have no idea what to do at this point. they've disabled my site for the past 3 out of 4 days, which has really pissed me off. i'd switch to a new host, but i recognize that this site is very database heavy and most hosts probably wouldn't be able to handle it on a shared server. at the same time, i don't use enough bandwith to justify buying a dedicated server. the only thing i can think of doing is find some sort of script that will keep track of all my queries on the database, and how much time it takes to process each one. all i can think of is that i have a few bad queries that i haven't been able to pick out that are overloading the server. this post probably went on for way too long... sorry :p.. thanks in advance for any help.
sunday afternoon i wake up, the database is disabled again. i send an email asking them why, same reason as before and it won't be turned back on until i fix the code. i try to explain to them that this script is huge, and them telling me "it's bad, fix it" really is pointless since i have no idea where to start. after two days of emailing them back and forth trying to get some sort of useful information out of them, i get absolutely nothing, and finally they just randomly decide to turn the db back on and tell me "this better not happen again", but it almost certainly will since they were absolutely no help. basically they told me "we won't look at your script or help you in any way whatsoever, you're on your own, take care of the problem".
what i can't seem to understand is how after 5 months, the script is first starting to cause problems now, especially due to the fact that:
1) my traffic is about 2/3 the traffic i had last month
2) friday - sunday are my lowest traffic days
i really have no idea what to do at this point. they've disabled my site for the past 3 out of 4 days, which has really pissed me off. i'd switch to a new host, but i recognize that this site is very database heavy and most hosts probably wouldn't be able to handle it on a shared server. at the same time, i don't use enough bandwith to justify buying a dedicated server. the only thing i can think of doing is find some sort of script that will keep track of all my queries on the database, and how much time it takes to process each one. all i can think of is that i have a few bad queries that i haven't been able to pick out that are overloading the server. this post probably went on for way too long... sorry :p.. thanks in advance for any help.