![]() |
check your templates. the way is designed the hack, it will not interfere with any blocks.. due to {getmicrostats} variable. there are several users who installed this on phpportals without any problem.
|
Got it working now...
Page generated in 3.88498294 seconds (7.21% PHP - 92.79% MySQL) with 55 queries. 55 queries... ouch :( How can I find out why there's so many queries and how to cut that number down? |
first congrats on get it working... :)
second, hmm there are your hacks that generate alot of queries. i personally think 55queries is huge, extremly high. your server gets on the red line at 40-45queries. phportals are known for adding alot of queries. unfortunatelly there is nothing you can do about it, unless you disable as many options as you can. a decent number of queries should be 25. that's the only reason i didnt install phpportals. the extreme no. of queries. btw, did you know that vB3 will have only 12queries? :) |
Which of the vbPortal options are we talking about, specifically?
(Just so I've got an idea of things I can try and reduce that huge number of queries!) |
@X-Fan: I just visited your forums, and got this:
Quote:
|
Quote:
|
I got my forum index page down to 15 queries. :D That is less than default. And I have LOTS of hacks running.
|
that's a great job there erwin. you probably tied the 3 pm queries into one, on forumhome page, that will take it down to 15. :)
i wonder how many queries vb3 will have on showthread? that's the only place where we see the highest number of queries performed. |
My showthread has 18 queries - that is the bare minimum I can get it down to, without removing hacks I want.
|
So Erwin, how did you do it? Any advice for us PHP newbies?
|
Make sure you include all your templates in the PHP file's templatesused=" " section. Each template called not in that section is one extra query.
Do a search for the word "query" in the file and then remove all queries that you can make do without. For example, I disabled invisibility, which means I can remove the queries for people browsing a forum etc. - it all adds up. |
I did that for my forums/index.php and it only reduced the number of queries by two.
|
How fo you tie those 3 queries together? Mind giving us the code to do it? :)
Quote:
|
What about the templates that don't always get used unless you link to it? Will including them hurt at all?
Quote:
|
Quote:
a showthread have 18-19queries when is an empty thread (no threads posted in the last 30days). as soon as you post once, it pops to 22. firefly (who i'm pretty sure he started slowly to implement on this board vb3 code technique) have it at 29queries. |
Quote:
|
I figured I'd get that answer from you. I just wanted to make sure you would react that way. You've proven yourself once again, my friend. Some things never change :)
|
did you noticed that nobody is answering you related to your 'deviated from thread' questions? in any post? why do you think we have several forums here?
firefly, i have an idea: delete all the forums and make only one ok? "full releases". and yes, i dont forget when someone is calling me a liar in public. |
Why don't you calm down, there, son? We all know how you get when you don't get your nap. :)
As far as being not on topic goes, if I remeber right, you brought it up in the first place when you basically called Erwin a liar. And as far as you being called a liar, that was never actually said in the thread. But, then, you proved yourself when you added the fix from Neo to the file and kept the old version number on it. Do it once, do it again? :) Firefly, did you catch that? He had an idea! Was it an original one, or someone else's rehash. Just curious. :) Quote:
|
you make me smile when you call me son.
the discussion with erwin was not off topic because it didnt involved any extra hacking that does interfere with this hack. it's simple information related to users experience with the hack, since they are able to actually see the number of queries performed. your request involved a different hack that have nothing to do with vbmicrostats. as far as our personal issues, is off topic from this hack. if you have any issues, open a new thread or use pm or email. |
Then you might want to take your own advice and do the same in the future, when you start to ramble elsewhere in a thread. ;) And unless I missed something somewhere, I don't think you were made a moderator here, yet. If that sad day ever happens, I guess I'll have to "find a new place to dwell, uh-huh!" :)
'Nuff said. I'm done. Quote:
|
Quote:
so far i discussed only issues related to the specific thread, anywhere. btw, that's have nothing to do with being a moderator, is with being efficient. basically you save time if you do a search and if you dont find it, simply ask. people will answer you. i know i will, even if you dont believe it. as for your query question, try this search: "tie pm query", you will be amased... |
Doesn't work. pm is only 2 letters. Thanks, anyway. :)
Quote:
|
i send you a pm with all the info you need.
|
Are we all friends again? Don't let it happen again.
|
Seems like a very useful hack - I'll give it a shot. :)
|
Installed and works like a charm :). This is probably the most useful hack I have on my boards, and I think a lot of fellow vBulletin owners agree with that, especially if they are using servers that are being pushed to their limits. This is perfect, now I can keep an eye on the server load and at the same time browse the boards. :D
|
martin64, i looked at your site and i noticed you didnt hacked properly the db_mysql.php file, that's why you have 100% and 0% values. please double check the steps in that file.
|
Okay, thanks. I overwrote some files and had to re-add my 3 most recently added hacks so that's probably why I missed it. I don't know what went wrong, but I had to download the 2.2.6 package again and overwrite my old files. :hurt:
It was working earlier, I just hadn't noticed yet. Thanks once again. :D Edit: fixed. :cool: |
Quote:
It is possible, but only if you remove a few standard features. I took out invisibility (that's 1), and forumjump (that's 2). The hacks in my showthread did not do queries. Since then though, I have moved servers, and with a faster server I have put back forumjump, and reinstalled who is browsing this thread. I also reinstalled the "Users Online in Header". This has brought my showthread back up to 23. (Page generated in 1.00907195 seconds (67.16% PHP - 32.84% MySQL) with 23 queries.) My index is now at 17 queries. (Page generated in 0.29747605 seconds (82.73% PHP - 17.27% MySQL) with 17 queries.) - I did this by combining the PM queries, removing the query to count threads (I only display posts), and also keeping invisibility off. But using the "Users Online in Header" adds an extra 2 queries to every page. |
Oh yeah, I disabled forum access masks as well, and made the "Who's Online" page only for admins to prevent the private forum bug.
|
I haven't been keeping up with this thread for a while, but I noticed a 'flaw' in this hack that is rather scary...
When I installed it (just after the 226 db_mysql.php came out) it didn't add the $query_count var. to the query_first function. The Query_first function is, however, as the name implies, another function using queries, and all these queries were omitted since there was no global $query_count and $query_count++; part palced in it. If you do, you'll suddenly notice how much queries are added. On my board, the count went up with an average of 15 queries. Those are all queries with limit 1 (the query_first function) but still queries. I don't think that's a very good thing.... I'm probably missing out on some info here, but to me, that seems bad. Showthread pages now have a standard of 46 queries on average, with a few 1-query hacks installed.... :/ |
btw...
Is it me, or is it rather silly that Invisibility (I assume this is the normal feature that says whether a user is displayed as logged in or invisible (guest) ?) is something that doesn't require an independant query at all? I really don't see why that feature requires its own query to be enabled. Someone please explain? |
Quote:
here it is an example of the original db_mysql.php: Code:
function query($query_string) { i recommend you to download the latest vb226 package from members area and look at the db_mysql.php file. then to modify it properly. there have been several versions of this file and my hack includes instructions with the latest downloadable .zip file from members area. also, i dont see where you added query_first string, because is not required in my hack. at no time you will see 15queries added. this is related to other hacks you added, not vbMicroStats. |
Nakkid, was my post that unclear to you???
I Never said that it was this hack that added queries. Nowhere. I was talking about the QUERY_FIRST function of vBulletin itself that adds queries, but with this hack all those queries were omitted from the variable $query_count, therefore the number displayed at the bottom in the microstats - this hack allowing for that to be seen - is actually quite a lot higher (15 queries higher on average) than you get with the default install of this hack (last I checked the install instructions, that is). There are TWO functions in vBulletin to do a query, and your hack counted only the queries done by ONE of them, therefore at the bottom where it says "with XX queries" the number was wrong, by a shocking 15 on average, which are all the queries done by vBulletin's QUERY_FIRST function. Are you getting this, now? :/ |
Quote:
If you had taken the time to actually look at the query_first() method you would see that it calls query() itself. What you did was count all the query_first() queries twice. Look: Code:
function query_first($query_string) { |
I wasn't confused, I was just uncertain that what I thought was actually how vB worked, which, thankfully, isn't the case.
Nakkid totally didn't get my post up there, but that may well be cos he already knew about that. (notice how I asked for clarity on this thing in my first post on this page? :)) thx btw for that :up: |
What private forum bug? :)
Quote:
|
Quote:
Basically if you switch off forum access mask, members can look at the titles of threads in a private forum if a staff member is reading the thread by lookin at the Who's Online page. (At least on my site and a few others). |
ok i want last vr for this hacks :)
thankx |
All times are GMT. The time now is 06:32 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|