I've got my main page load time down to about half a second by having only one toplist which sorted by id descending (there is a mysql index on the index field so this loads pretty fast (correct me if im wrong Paul). Also, my main categories don't change that often so I simply use a static html include for these.
Using the static categories saved me about a second, removing toplist saved me another half second.
I used mrowton suggestions and created static includes. It did speed up my home page, but I do have very hard time with dilsplaying links in categories. If you check out some heavy categories like CA, FL and SC - you'll see that load time can be anywhere from 3 to 9 seconds... I can stand 3 seconds, but not more. I have only 1 toplist there right now which is featured areas at the top right, the states on the right are included from static template. Any suggestions to speed up those pages?
Paul, I used attachments as pictures for the listings/links - each listing has an attachment query through the download.php - it's just not every one has it. I actually replaced download.php?id={LINKID} with attachments/{LINKFILETITLE} but it hasn't reduced the load time at all.. plus not all attachments showed up since some time ago I had random attachment names generated.
I also have 4 different types of links and the total number of links limited to 14 on the page... I guess it does not include sponsored ones, but still seams like pretty small number. I guess, I'll have to go through each query and see what I can eliminate.
I changed all the download.php queries to attachments/{LINKFILENAME} - this works fine, but still I have a query for each link to check if the file exists. Not exactly sure which way is faster. It did cut down some queries, but still not much.
Paul, I know this is not your concern, but may be you can point me into right direction. My shared host recently kicked me out for CPU overload, so I had to get a dedicated server, which I did. I was fine for a couple of days until yesterday my CPU went to 100% - usually it was staying under 2%. I didn't have any traffic spikes or anything like that. I talked to customer support and they told me that mysql and apache were overloaded. They told me I have a lot of mysql queries. Anyways, I was trying to test if I can drop the load by turning the wsnlinks off from the admin panel and it didn't help even though noone could access it from the web. The load droped to 0% only when I chmoded wsnlinks folder to 000. I have never managed linux servers so I have no clue what to look into. Customer Support told me that they can not tell me exactly which pages or queries creating the load from the logs - I would have to look for some linux tools and figure it out on my own. I just don't understand, if those were mysql queries off the directory pages, then they should've died after I turned wsnlinks off from the admin pannel... but they didn't. Any suggestions?
I'm going through every single query and this one takes 1.62seconds to perform
That's not a query, it's stuff between queries. Anyhow all your queries are taking around 3-5 times longer than the same queries normally do, so you don't seem to have any particular bad query.
Maybe it's the connection. Is it a remote mysql server? Those are usually very slow.
Have you tested installing WSN Links in a place where no one could possibly know of it to be browsing it, disabling the one that could be known of, and then seeing if the pages still take 3+ seconds to load? If they do then it can't be anything but a slow mysql.
It is actually VPS with MediaTemple, not phisical dedicated one (not sure how different that is since this is my first one and I haven't had much time to do research when my shared host pulled the plug). MySQL server is local.
Do you mean just try lading a new WSNLinks and hooking it up to existing database and brows it on my own while the old version is off?
Per your suggestion, I installed empty WSNLinks into separate folder and turned the old one off. The empty main page loads as fast as 0.72-0.81. I tried probably a dozen of times and one time it took 1.34sec. I'll see if I can fill it in with some info for better testing experience.
Paul, I just edited config.php to pull the data off the existing database and with the default templates there are only 38 queries on the category pages - they load anywhere from 3sec to 3.5sec and CPU load goes up tp 86% while page is loading and it goes back to 0% after it's loaded. Can it have anything to do with the new fields I added to the categories and links tables?
0/5
1
2
3
4
5
This thread is closed, so you cannot post a reply.
Comments on high traffic web sites
Beginner
Usergroup: Customer
Joined: Jul 11, 2005
Total Topics: 4
Total Comments: 5
Is there any high traffic web sites that use WSN Links ( like SecurityDocs.com, GameLinks.com and others listed in Showcase) ?
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
You've just named two that appear to have fair alexa ranks (as does this site, actually). "High traffic" however is very subjective.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
I'm pulling a little over 120K uniques this month - a little slow, but I have shit load of graphics - gotta get rid of some
Forum Regular
Usergroup: Customer
Joined: Feb 19, 2004
Location: Michigan
Total Topics: 57
Total Comments: 185
I'm pulling a little over 120K uniques this month - a little slow, but I have shit load of graphics - gotta get rid of some
looks like you're taking about 2 seconds on the wsnlinks index page with a fairly low load average, thats about what mine used to be.
http://www.ibsteam.net/wsnlinks/index.php?debug=4
I've got my main page load time down to about half a second by having only one toplist which sorted by id descending (there is a mysql index on the index field so this loads pretty fast (correct me if im wrong Paul). Also, my main categories don't change that often so I simply use a static html include for these.
Using the static categories saved me about a second, removing toplist saved me another half second.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
Good tip. I like the toplists - don't think I can get rid of those need to play around and see what happens.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
I used mrowton suggestions and created static includes. It did speed up my home page, but I do have very hard time with dilsplaying links in categories. If you check out some heavy categories like CA, FL and SC - you'll see that load time can be anywhere from 3 to 9 seconds... I can stand 3 seconds, but not more. I have only 1 toplist there right now which is featured areas at the top right, the states on the right are included from static template. Any suggestions to speed up those pages?
Thank you.
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
Reducing the number of links per page always helps.
www.ibsteam.net/wsnlinks/in...displaycat&catid=5&debug=1 indicates an unusually large number of attachment queries for some reason but they don't seem to take much time.
Compare with www.wsnforum.com/linksuserd...isplaycat&catid=10&debug=1 and you can see you've somehow managed to induce three times as many queries per page.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
Paul, I used attachments as pictures for the listings/links - each listing has an attachment query through the download.php - it's just not every one has it. I actually replaced download.php?id={LINKID} with attachments/{LINKFILETITLE} but it hasn't reduced the load time at all.. plus not all attachments showed up since some time ago I had random attachment names generated.
I also have 4 different types of links and the total number of links limited to 14 on the page... I guess it does not include sponsored ones, but still seams like pretty small number. I guess, I'll have to go through each query and see what I can eliminate.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
I changed all the download.php queries to attachments/{LINKFILENAME} - this works fine, but still I have a query for each link to check if the file exists. Not exactly sure which way is faster. It did cut down some queries, but still not much.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
Paul, I know this is not your concern, but may be you can point me into right direction. My shared host recently kicked me out for CPU overload, so I had to get a dedicated server, which I did. I was fine for a couple of days until yesterday my CPU went to 100% - usually it was staying under 2%. I didn't have any traffic spikes or anything like that. I talked to customer support and they told me that mysql and apache were overloaded. They told me I have a lot of mysql queries. Anyways, I was trying to test if I can drop the load by turning the wsnlinks off from the admin panel and it didn't help even though noone could access it from the web. The load droped to 0% only when I chmoded wsnlinks folder to 000. I have never managed linux servers so I have no clue what to look into. Customer Support told me that they can not tell me exactly which pages or queries creating the load from the logs - I would have to look for some linux tools and figure it out on my own. I just don't understand, if those were mysql queries off the directory pages, then they should've died after I turned wsnlinks off from the admin pannel... but they didn't. Any suggestions?
Thank you.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
I'm going through every single query and this one takes 1.62seconds to perform
Setting cookie with name returnto, value index.php?action=displaycat&catid=11 and duration 1156434846
I looked at your debug example and it's less then 0.01sec.
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
I'm going through every single query and this one takes 1.62seconds to perform
That's not a query, it's stuff between queries. Anyhow all your queries are taking around 3-5 times longer than the same queries normally do, so you don't seem to have any particular bad query.
Maybe it's the connection. Is it a remote mysql server? Those are usually very slow.
Have you tested installing WSN Links in a place where no one could possibly know of it to be browsing it, disabling the one that could be known of, and then seeing if the pages still take 3+ seconds to load? If they do then it can't be anything but a slow mysql.
VPS is a lot cheaper than dedicated, by the way.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
It is actually VPS with MediaTemple, not phisical dedicated one (not sure how different that is since this is my first one and I haven't had much time to do research when my shared host pulled the plug).
MySQL server is local.
Do you mean just try lading a new WSNLinks and hooking it up to existing database and brows it on my own while the old version is off?
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
Per your suggestion, I installed empty WSNLinks into separate folder and turned the old one off. The empty main page loads as fast as 0.72-0.81. I tried probably a dozen of times and one time it took 1.34sec. I'll see if I can fill it in with some info for better testing experience.
Forum Regular
Usergroup: Customer
Joined: Oct 30, 2003
Total Topics: 54
Total Comments: 197
Paul, I just edited config.php to pull the data off the existing database and with the default templates there are only 38 queries on the category pages - they load anywhere from 3sec to 3.5sec and CPU load goes up tp 86% while page is loading and it goes back to 0% after it's loaded. Can it have anything to do with the new fields I added to the categories and links tables?