vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Member Archives (https://vborg.vbsupport.ru/forumdisplay.php?f=202)
-   -   Search this Thread problem? (https://vborg.vbsupport.ru/showthread.php?t=57314)

drumsy 09-22-2003 03:01 PM

Search this Thread problem?
 
It seems this just started happening so I don't know where to start, but certain words like new car trigger this error:

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 8 bytes) in /usr/local/apache2/htdocs/honda-acura.net/forums/search.php on line 456

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 6 bytes) in /usr/local/apache2/htdocs/honda-acura.net/forums/admin/functions.php on line 2637

Running vB 2.3.2. What to do?

Velocd 09-22-2003 07:18 PM

That's a weird error. Post what is around line 456 in search.php and 2637 in functions.php.

drumsy 09-23-2003 06:12 PM

Search.php Lines 445 to 465

Line 456 is:

PHP Code:

        $goodpostlist .= "$key,"

PHP Code:

      if ( is_array($notlist) AND $good!=) {
        
reset($notlist);
        while ( list(
$keyw,$id)=each($notlist) ) {
          if ( 
strlen(strpos($val",$id,")) ) {
            
$good 0;
            break;
          }
        }
      }

      if (
$good==1) {
        
$goodpostlist .= "$key,";
      }
    }

    
$wheresql " 1=1 ";

    if (!
$goodpostlist) {
      eval(
"standarderror(\"".gettemplate("error_searchnoresults")."\");");
    }
  } 

Functions.php Lines 2630 to 2648

Line 2637 is:

PHP Code:

      $DB_site->query($query); 

PHP Code:

// ###################### Start doshutdown #######################
$shutdownqueries=array();
function 
doshutdown() {
  global 
$shutdownqueries,$DB_site;

  if (
is_array($shutdownqueries)) {
    while (list(
$devnul,$query)=each($shutdownqueries)) {
      
$DB_site->query($query);
    }
  }

  global 
$cookietimeout,$bypass,$bbuserinfo,$session;

  if (
$bypass and $bbuserinfo['userid']) {
    
// if the user has sent bypass=1 through the url (to prevent updating of last activity/visit time), reset the session
    // so the below function doesn't do update their info anyway
    
$userinfo=$DB_site->query_first("SELECT lastactivity FROM user WHERE userid='$bbuserinfo[userid]'");
    
$DB_site->query("UPDATE session SET lastactivity='$userinfo[lastactivity]' WHERE sessionhash='".addslashes($session['dbsessionhash'])."'");
  } 


Erwin 09-24-2003 04:37 AM

You need to increase the memory allocated in my.cnf from 8 MB to 12 MB or 16 MB. If you are on a shared server get your host to do it for you.

drumsy 09-24-2003 03:25 PM

I'm on dedicated. This is the what I currently have in /etc/my.cnf that Eva suggested:

Quote:

[mysqld]
set-variable = max_connections=650
set-variable = key_buffer=32M
set-variable = myisam_sort_buffer_size=64M
set-variable = join_buffer=1M
set-variable = record_buffer=2M
set-variable = sort_buffer=2M
set-variable = table_cache=1024
set-variable = thread_cache_size=64
set-variable = wait_timeout=1800
set-variable = connect_timeout=10
set-variable = max_allowed_packet=16M
set-variable = max_connect_errors=10

[safe_mysqld]
open_files_limit=8192

[mysqldump]
quick
set-variable = max_allowed_packet=16M

[myisamchk]
set-variable = key_buffer=64M
set-variable = sort_buffer=64M
set-variable = read_buffer=16M
set-variable = write_buffer=16M
I don't see where to add it? I also see that I have a /root/my.cnf, but what's listed there is different numbers than what I have in /etc/my.cnf. Should I copy /etc/my.cnf over to /root/my.cnf?


All times are GMT. The time now is 10:48 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.01011 seconds
  • Memory Usage 1,741KB
  • 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
  • (4)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete