You are missing our premiere tool bar navigation system! Register and use it for FREE!

NukeCops  
•  Home •  Downloads •  Gallery •  Your Account •  Forums • 
Readme First
- Readme First! -

Read and follow the rules, otherwise your posts will be closed
Modules
· Home
· FAQ
· Buy a Theme
· Advertising
· AvantGo
· Bookmarks
· Columbia
· Community
· Donations
· Downloads
· Feedback
· Forums
· PHP-Nuke HOWTO
· Private Messages
· Search
· Statistics
· Stories Archive
· Submit News
· Surveys
· Theme Gallery
· Top
· Topics
· Your Account
Who's Online
There are currently, 66 guest(s) and 0 member(s) that are online.

You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - Speed Freaking on Computer Cops [ ]
 Forum FAQ  •  Search  •   •  Memberlist  •  Usergroups   •  Register  •  Profile •    •  Log in to check your private messages  •  Log in

 
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next topic
Author Message
Zhen-Xjell
Nuke Cops Founder
Nuke Cops Founder


Joined: Nov 14, 2002
Posts: 5939


PostPosted: Mon Apr 05, 2004 6:09 am Reply with quoteBack to top

March saw 5.1 million page hits alone. Its not optimized for speed whatsoever, and the interesting thing is... for the most part the portal runs very fast, even with 1000 or more pages served in any previous 5 minute timeframe.

Curious, one would think at such volumes there would be a sustained slag, but... I have to remind myself... the answer to the slow slag has been hardware upgrades.

So what does this mean?

To solve slag:

- optimize code
- throw better hardware at it

_________________
Paul Laudanski, Microsoft MVP Windows-Security
CastleCops: [de] [en] [wiki]
Find all posts by Zhen-XjellView user's profileSend private messageSend e-mailVisit poster's website
Mesum
Support Staff
Support Staff


Joined: Mar 11, 2003
Posts: 842

Location: Chicago

PostPosted: Mon Apr 05, 2004 7:11 am Reply with quoteBack to top

Exactly, I learned it very fast with PakistaniMedia.com too, they site was only doing 600K hits a month and our shared server started to lag so much, it will unreal. As of right now, we get about 1.2 million page views and you can check out the site, no lag what so ever! The solution was same, optimized code and own server Very Happy

_________________
Only FREE Dating site for Desis.
Find all posts by MesumView user's profileSend private messageVisit poster's websiteAIM AddressYahoo MessengerMSN Messenger
Zhen-Xjell
Nuke Cops Founder
Nuke Cops Founder


Joined: Nov 14, 2002
Posts: 5939


PostPosted: Mon Apr 05, 2004 10:00 am Reply with quoteBack to top

The problem I'm running into now is having two high volume sites on the same server... it still causes issues when lots of visitors come in during peak times. Both sites would server better if they lived on their own boxes.

_________________
Paul Laudanski, Microsoft MVP Windows-Security
CastleCops: [de] [en] [wiki]
Find all posts by Zhen-XjellView user's profileSend private messageSend e-mailVisit poster's website
Mesum
Support Staff
Support Staff


Joined: Mar 11, 2003
Posts: 842

Location: Chicago

PostPosted: Mon Apr 05, 2004 10:21 am Reply with quoteBack to top

Yeah that's what I was thinking... This site has started to lag already... Maybe time to move to a newer server.

I got mine from ServerMatrix.com, they seem to have nice prices.

_________________
Only FREE Dating site for Desis.
Find all posts by MesumView user's profileSend private messageVisit poster's websiteAIM AddressYahoo MessengerMSN Messenger
Zhen-Xjell
Nuke Cops Founder
Nuke Cops Founder


Joined: Nov 14, 2002
Posts: 5939


PostPosted: Mon Apr 05, 2004 10:42 am Reply with quoteBack to top

I see they have a 3 nines policy. However I'm happy with my current host... as my quote goes:

"My websites focus on computer security and content management development. Security is everyone's business and Computer Cops serves 4 million hits per month. Its needs are demanding: uptime, availability, responsive & engaging tech support, fast resolutions. JagPC ensures I get all these along with a great deal of personalization. The staff takes on a can-do attitude while delivering service above and beyond the call of duty to ensure ComputerCops.biz and NukeCops.com are up and running smoothly all the time."
-- Paul L. ::ComputerCops::

_________________
Paul Laudanski, Microsoft MVP Windows-Security
CastleCops: [de] [en] [wiki]
Find all posts by Zhen-XjellView user's profileSend private messageSend e-mailVisit poster's website
steven111
Lieutenant
Lieutenant


Joined: Dec 30, 2003
Posts: 283


PostPosted: Sun May 09, 2004 11:33 pm Reply with quoteBack to top

Zhen-Xjell wrote:
The problem I'm running into now is having two high volume sites on the same server... it still causes issues when lots of visitors come in during peak times. Both sites would server better if they lived on their own boxes.


Like you, I run multiple sites on one dedicated server. I would think that what makes such a config. slow is the lack of memory for mysql to cache indecis and tables required for two or more db's and applications. I don't think the limiting factor is CPU.

If I am right, then I would think adding memory, and dedicating that extra memory to mysql caching, would help a lot.

Any thoughts on that.

_________________
ezClassifieds|Forums:Auto,Mac,Job,Win,HW
Find all posts by steven111View user's profileSend private messageVisit poster's website
djmaze
Captain
Captain


Joined: Nov 29, 2003
Posts: 566

Location: Netherlands

PostPosted: Sun May 09, 2004 11:46 pm Reply with quoteBack to top

Run a
Code:
$db->sql_freeresult($result);

When you don't need the content of the query anymore.
This reduces the memmory which is used to generate the page.

That way on high load systems you have more memory free for mysql.
When there are only a few people online it's almost useless.

_________________
Famous people never give their signature Rolling Eyes
http://www.cpgnuke.com <- back online thanks to dedicatednow.com
Don't ask me to be admin on your site please Exclamation
Find all posts by djmazeView user's profileSend private messageVisit poster's website
steven111
Lieutenant
Lieutenant


Joined: Dec 30, 2003
Posts: 283


PostPosted: Sun May 09, 2004 11:54 pm Reply with quoteBack to top

Hi dj,

Long time, no talk. Always appreciate your contributions, and your great distro.

I am wondering if running: $db->sql_freeresult($result);
has any benefit, since a page completes very quickly in any case. i.e. if you don't cleanup using that statement, would the used memory sit in limbo, and would then have to be collected back by some slow garbage collection process.

Am not too familiar with php internals to know if that makes a difference. Have you run some benchmarks?

steve

_________________
ezClassifieds|Forums:Auto,Mac,Job,Win,HW
Find all posts by steven111View user's profileSend private messageVisit poster's website
djmaze
Captain
Captain


Joined: Nov 29, 2003
Posts: 566

Location: Netherlands

PostPosted: Mon May 10, 2004 1:07 am Reply with quoteBack to top

I need to run memory benchmarks for that.

So i just changed my mainfile.php to run sql_freeresult() everywhere in that file.

Now i only need to keep an eye on my mysql mem usage for today and yesterday.

But it seems not to affect page generation times, it only frees mem where needed.

Have patients Wink

_________________
Famous people never give their signature Rolling Eyes
http://www.cpgnuke.com <- back online thanks to dedicatednow.com
Don't ask me to be admin on your site please Exclamation
Find all posts by djmazeView user's profileSend private messageVisit poster's website
djmaze
Captain
Captain


Joined: Nov 29, 2003
Posts: 566

Location: Netherlands

PostPosted: Wed May 19, 2004 2:40 pm Reply with quoteBack to top

indeed my mem usage for MySQL dropped from 50 to 45 MB on occasions.
ofcourse the difference where not a lot in mainfile.php itself because we use your nice "static" tweak.

So i started modifying more files and it seems to work nicely.

_________________
Famous people never give their signature Rolling Eyes
http://www.cpgnuke.com <- back online thanks to dedicatednow.com
Don't ask me to be admin on your site please Exclamation
Find all posts by djmazeView user's profileSend private messageVisit poster's website
Coop
Nuke Soldier
Nuke Soldier


Joined: Mar 03, 2004
Posts: 23

Location: Leeds, UK

PostPosted: Thu May 20, 2004 5:46 pm Reply with quoteBack to top

So you just put that after an sql query then? (one which I don't require anymore) Show me an example if possible please Smile

_________________
My eyes! I'm not supposed to get pudding in them!
http://www.crooze-control.com
Find all posts by CoopView user's profileSend private messageSend e-mailVisit poster's websiteMSN Messenger
djmaze
Captain
Captain


Joined: Nov 29, 2003
Posts: 566

Location: Netherlands

PostPosted: Fri May 21, 2004 1:11 am Reply with quoteBack to top

$result = $db->sql_query("SELECT * FROM nuke_users WHERE username = 'bob'");
$userinfo = $db->sql_fetchrow($result);
$db->sql_freeresult($result);

_________________
Famous people never give their signature Rolling Eyes
http://www.cpgnuke.com <- back online thanks to dedicatednow.com
Don't ask me to be admin on your site please Exclamation
Find all posts by djmazeView user's profileSend private messageVisit poster's website
Zhen-Xjell
Nuke Cops Founder
Nuke Cops Founder


Joined: Nov 14, 2002
Posts: 5939


PostPosted: Fri May 21, 2004 6:04 am Reply with quoteBack to top

I've littered the entire codebase using the freeresult a few weeks back.

_________________
Paul Laudanski, Microsoft MVP Windows-Security
CastleCops: [de] [en] [wiki]
Find all posts by Zhen-XjellView user's profileSend private messageSend e-mailVisit poster's website
djmaze
Captain
Captain


Joined: Nov 29, 2003
Posts: 566

Location: Netherlands

PostPosted: Fri May 21, 2004 3:32 pm Reply with quoteBack to top

Zhen-Xjell wrote:
I've littered the entire codebase using the freeresult a few weeks back.

Great ZX Exclamation Exclamation 3 thumbs up to you.

And what was the difference ?

_________________
Famous people never give their signature Rolling Eyes
http://www.cpgnuke.com <- back online thanks to dedicatednow.com
Don't ask me to be admin on your site please Exclamation
Find all posts by djmazeView user's profileSend private messageVisit poster's website
hamesh
Support Mod
Support Mod


Joined: Feb 13, 2003
Posts: 170

Location: Canada

PostPosted: Fri May 21, 2004 4:46 pm Reply with quoteBack to top

Perhaps a little, late, but I see that nukecops doesn't use compression. You could reduce server load and speed considerably by use mod_deflate (Apache 2.x) or mod_gzip (Apache 1.x) in combination with a php accelerator. I have a high volume site serving up around 3 million page views per month/500 GB in traffic and these and mod_expires reduce my server load considerably...

_________________
Image
Find all posts by hameshView user's profileSend private messageSend e-mailVisit poster's websiteMSN MessengerICQ Number
Display posts from previous:      
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Powered by phpBB © 2001, 2005 phpBB Group

Ported by Nuke Cops © 2003 www.nukecops.com
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::
Powered by · TOGETHER TEAM srl ITALY http://www.togetherteam.it · DONDELEO E-COMMERCE http://www.DonDeLeo.com
Web site engine's code is Copyright © 2002 by PHP-Nuke. All Rights Reserved. PHP-Nuke is Free Software released under the GNU/GPL license.
Page Generation: 0.273 Seconds - 203 pages served in past 5 minutes. Nuke Cops Founded by Paul Laudanski (Zhen-Xjell)
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::