vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Optimizing Forumhome (https://vborg.vbsupport.ru/showthread.php?t=46848)

jeffj 12-28-2002 11:29 AM

most excellent... I had it up and running on my test site in about 5 minutes...and it worked great!

then I moved index.php to my production site... and ....too bad I forgot to add the cache table to my production site....but that only took about 10 seconds and I beat everyone before they saw the mysql error that I did...

it works great and I love it!

- jeff

Xenon 12-28-2002 08:21 PM

thanks for the kind words :)

i found out it works nearly perfect, just a small thing i had to change before it will be moved into full releases :)

i think it will be there before next year ;)

freeshares1 12-28-2002 09:08 PM

:clicks on install:

It works very well and i have noticed that my forum home loads a lot quicker.

DrkFusion 12-29-2002 03:29 AM

One for forumdispay and showthread would be really nice:)
This is the next best thing to microstats :p

Thanks to Xenon my forumhome:
Page generated in 0.09714496 seconds (75.75% PHP - 24.25% MySQL) with 13 queries.

fury 12-29-2002 03:33 AM

Great hack! It = teh winnar. I now get 0.2-0.3 second forumhome generation times, with 18 queries if cached, 25 if not.

Since I have the persistent mark forums read hack by ethank installed I had to modify part of that in member.php to be able to get forum lights to turn off, but other than that, it looks to be working perfectly.

fury 12-29-2002 03:37 AM

One for showthread would be HUGE :eek:

fury 12-29-2002 11:24 PM

I noticed after installing this hack, total post count is off by 10... there are 111979 post records in the database but the sum of the replycount column is 111989.. there are 10 extra posts somehow (10 is how many forums I have which have posts in them, but I don't know why this would have any effect)

Running the counters again didn't help.

X-Fan 12-30-2002 12:54 AM

Just installed this, and it works great! My forum home page went from around 32 queries down to 19!

I'm wondering if there's any way to add this to vbHome for those (like me) who use that as their site's portal page?

DrkFusion 12-30-2002 02:20 AM

Vote Xenon for vB Dev :-p

This is a great method, I would love this for the all of vb

Xenon 12-30-2002 10:17 AM

*ggg* thx Arunan :)

@X-Fan: When i have more time and completly finished this beta, i will work with TECK on an inclusion into vBhom (lite) :)

@fury: There are two possibilities:
1. your counters are wrong (update your counters, be sure you'll do in the right order (first threads then forums)
2. you have orphan posts which don't appear in any threads...

Xenon 12-30-2002 11:33 AM

Ok, uploaded a little modified file now
Moved the thread to Full Releases

thanks to all who helped me in the betaphase :)

NuclioN 12-30-2002 11:45 AM

i get a gzinflate parse error at the top of the forum index after replacing the old code with the new. (?)

Dean C 12-30-2002 12:45 PM

Awesome i'll try this on my localhost tonite :p

Xenon 12-30-2002 01:43 PM

@NuclioN: How old was your last version?
the last update justs changes a small if-clause nothing with the gzinflate function...

as a tip, just empty the whole forumcache table and it should work again

Dean C 12-30-2002 09:16 PM

Wow this works wonders Xenon..

Reduced my testboard from 19queries to 14queries when dont on a fresh install :)

- miSt

Smoothie 12-31-2002 01:34 AM

How well does this work with hacks that are installed?

Boofo 12-31-2002 01:43 AM

There's some that won't work very well (or at all) with it, that is why I had to un-install it. Great idea, though. :)

Smoothie 12-31-2002 03:01 AM

thats a shame.

Dean C 12-31-2002 09:05 AM

Yep well i'm sure there's a way around it and Xenon will guid you all the way :p

Xenon 12-31-2002 12:53 PM

@Smoothie: it depends on the hack, subforums on forumhome for example works perfect and has a huge effect on reducing queries.

if you are a little experience you can nearly make every hack to work with it.

but it doesn't work with this hack:
# of users browsing on Forumhome

Chris M 12-31-2002 01:15 PM

Hmm...

I can't remember if I have that one installed:(

*damned script kiddies attacking my Hosts server:mad:*

I will test it out on DB when it gets back up:)

Satan

Xenon 12-31-2002 01:24 PM

you'll like it chris :)

Chris M 12-31-2002 01:35 PM

Hehe no doubt;) It will probably reduce my Forumhome queries considerably - At last check, I think I had 24 or 26:)

Satan

Smoothie 12-31-2002 04:09 PM

Quote:

Originally posted by Xenon
@Smoothie: it depends on the hack, subforums on forumhome for example works perfect and has a huge effect on reducing queries.

if you are a little experience you can nearly make every hack to work with it.

but it doesn't work with this hack:
# of users browsing on Forumhome

Don't have that one installed, but I do have a hack for Photo Post installed.

fury 01-01-2003 01:27 PM

Quote:

Originally posted by Xenon
*ggg* thx Arunan :)

@X-Fan: When i have more time and completly finished this beta, i will work with TECK on an inclusion into vBhom (lite) :)

@fury: There are two possibilities:
1. your counters are wrong (update your counters, be sure you'll do in the right order (first threads then forums)
2. you have orphan posts which don't appear in any threads...

My counters were already updated like a billion times. Doing the orphan posts option didn't find anything either. :(

nuno 01-01-2003 04:51 PM

Quote:

Originally posted by nuno
By adding a new mod to the forum it will not be displayed on forumhome Xenon :confused:
Quote:

Originally posted by Xenon
@nuno: Yes you are right, just make a new post that there is a new mod and you'll see next time on forumhome he will be displayed ;)
Xenon, it shouldn't work that way IMO.
It would be tons cleaner if it was only updated when a new mod is added.
Current version waits for a new post/new thread for being made and then updates the moderator db table.
Not so useful for busy boards. ;)

Xenon 01-01-2003 05:46 PM

@Smoothie: Just test it out if it works :)

@fury: As i know the orphan post function just finds posts where threadid is 0.
but there can also be some posts where threadid > 0 but the thread they belong to is deleted.
my hack shows not the ammount of posts that are saved in the db, just the ammount of posts which can be viewed by at least the admin. So i'd say my method is better, normally the ammount should be the same, but if you've had a little problem some time ago you can have this difference :)

@nuno: It's an optimization of the loading time of the forumhome.
When you have a busy board the updated way is really enough, because you'll surely have a new post shortly after adding a new moderator.
just on not so busy boards the cache can be too old for you :)
For the hackinstructions i prefer the easier way, but of course you can add one query to the add moderator function to always update the cahce afterwards: [sql]DELETE FROM cache_forumhome[/sql]
As i say it's not needed, you have to modify other files, too, but you can do, without any negative aspects except of little more work ;)

Martin CX 01-03-2003 12:20 PM

It worked fine for some hours, then this:

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 4081664 bytes) in .../index.php on line 408

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 45 bytes) in .../admin/db_mysql.php on line 77


Any ideas?

Xenon 01-03-2003 08:36 PM

hmm, you don't have the zlib installed on your host have you?
if you have not, the whole html is saved uncompressed in the db, which will blow the table very fast. especiall when there are much users online.

try to contact your host to install zlib and allow more memory :)

i think that's the problem....

Martin CX 01-04-2003 12:45 AM

Quote:

Originally posted by Xenon
hmm, you don't have the zlib installed on your host have you?
I do! (Or I think I do - I'm obviously no expert. :D) This is what phpinfo tells me:

zlib:
ZLib Support - enabled
'zlib:' fopen wrapper - enabled
Compiled Version - 1.1.3
Linked Version - 1.1.3

Xenon 01-04-2003 09:50 AM

hmm, then the error seems a bit confusing to me...

maybe you can try this:
instead of
PHP Code:

$DB_site->query('DELETE FROM cache_forumhome WHERE userid=' $bbuserinfo[userid] . iif($numbersmembers['lastpost']>(time()-3600*5), ' OR lastpost<'.(time()-3600*5),'')); 

use smaller values as the timespan:
PHP Code:

$DB_site->query('DELETE FROM cache_forumhome WHERE userid=' $bbuserinfo[userid] . iif($numbersmembers['lastpost']>(time()-3600*3), ' OR lastpost<'.(time()-3600*3),'')); 


nuno 01-04-2003 09:52 AM

heh Xenon, could it be some kind of caching proggie, Martin's problem?

Xenon 01-04-2003 10:04 AM

i really have no idea what the problem could be...
Quote:

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 4081664 bytes)
4081664 < 8388608, so it shouldn't be an error....

You mean a caching proggie on the server right?
Well i haven't seen any till now, so i don't know how they work exactly, i wouldn't say this would be the problem, but i can't say for sure :)

nuno 01-04-2003 10:31 AM

Yup, something like php cache, apc used to do that, the memory errors.
Wild guess i think.

Xenon 01-04-2003 03:38 PM

hmm, maybe you're right, i don't know these scripts.
but it could be, the hack is ok....
also if this is the bug with those cach?ng software, i can't do anything :)

Martin CX 01-04-2003 04:32 PM

Is there some way of finding out if this is the problem?

Xenon 01-04-2003 04:37 PM

hmm, disable the software ;)

Martin CX 01-04-2003 04:42 PM

Quote:

Originally posted by Xenon
hmm, disable the software ;)
But WHAT software? :confused: What software is it that might cause these problems, and how can I check whether it is installed? (Sorry for all my whining ;))

nuno 01-04-2003 05:29 PM

Is it a dedicated or shared server?
FreeBSD, Linux, Windoze?
Upload this code into your forums folder
Code:

<?
phpinfo();
?>

Save it as phpinfo.php
You should see something like
Quote:

This program makes use of the Zend scripting language engine:
Zend Engine v1.2.0, Copyright (c) 1998-2002 Zend Technologies
with Your accelerator software credits go here

Martin CX 01-04-2003 06:18 PM

Nope. It just says
Quote:

This program makes use of the Zend Scripting Language Engine:
Zend Engine v1.1.1, Copyright (c) 1998-2001 Zend Technologies
And it's Linux, BTW.


All times are GMT. The time now is 11:11 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01344 seconds
  • Memory Usage 1,824KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (2)bbcode_php_printable
  • (9)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete