News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Topic Times Out

Started by jaymrvn, September 07, 2009, 08:15:16 PM

Previous topic - Next topic

jaymrvn

 : :-\ Several times in the past we had issues where a member would be posting something and then as they "entered/saved" thier post the script would hang up. After timing out they get a time out error and then from that moment on no one can access any page displaying the link to that specific post made by a member of the forum.

In the past the post would appear but you had to go into the database after getting all it's info. I would find the log entry and delete the post in question (causing errors) after deletion the thread worked great and that user who caused the issue would continue posting as usual. This has happened to us 5 times already. Again we lost a major topic on the forum that we need back.

QuoteFatal error: Maximum execution time of 60 seconds exceeded in /home/wwgfanet/public_html/The Glove Group/Sources/Subs.php on line 1863


TheListener

When logging in do the members tick the log in for xx seconds box?

jaymrvn

Sometimes they do, often they do not.

I am fully upgraded too, I thought the most recent upgrade would fix this issue but it has happened after having a peaceful 3 months without issue.

The user who caused the error has no idea what happened except that it timed out on posting. Then upon returning to view the post it timed out each and every time. This goes for anyone trying to see the topic, or thread it was posted in. 

I have nothing from the error log as another Admin., clears logs and recounts the stats every Saturday.

Tyrsson

Quotebut it has happened after having a peaceful 3 months without issue.
Leads  me to think it is server side. Can you please post the code that is referenced in the error from around line 1850 to 1875 and please mark the line in question.
PM at your own risk, some I answer, if they are interesting, some I ignore.

jaymrvn

This is found at line 24: if (!defined('SMF'))
   die('Hacking attempt...');

--------------------------------------------------
line 604:
   die('OK');
}

?>
--------------------------------------------
In fact that is all, it ends there and never even goes past 700 lines.....WTF? This is very unusual and I know this issue has come up several times so far. The server said that this happened before and they had to change a "script" that was bogging down the server and timing out after 15min. so they changed "the script" to 1 min. - Does that sound correct? The issue has happened 5 times in 1 year and started after I upgraded to version 1.8. It has happened to users from various countries and bandwidths. I can come up with no idea and I am surprised I am the only one who has seen this as it has persisted through 2 previous upgrades.

jaymrvn

Ok, found it.... >:(
;D Subs.php

1840 - 1887:
      $no_autolink_area = false;
            if (!empty($open_tags))
            {
               foreach ($open_tags as $open_tag)
                  if (in_array($open_tag['tag'], $no_autolink_tags))
                     $no_autolink_area = true;
            }

            // Don't go backwards.
            //!!! Don't think is the real solution....
            $lastAutoPos = isset($lastAutoPos) ? $lastAutoPos : 0;
            if ($pos < $lastAutoPos)
               $no_autolink_area = true;
            $lastAutoPos = $pos;

            if (!$no_autolink_area)
            {
               // Parse any URLs.... have to get rid of the @ problems some things cause... stupid email addresses.
               if (!isset($disabled['url']) && (strpos($data, '://') !== false || strpos($data, 'www.') !== false))
               {
                  // Switch out quotes really quick because they can cause problems.
                  $data = strtr($data, array('&#039;' => '\'', '&nbsp;' => $context['utf8'] ? "\xC2\xA0" : "\xA0", '&quot;' => '>">', '"' => '<"<', '&lt;' => '<lt<'));
                  $data = preg_replace(array('~(?<=[\s>\.(;\'"]|^)((?:http|https|ftp|ftps)://[\w\-_%@:|]+(?:\.[\w\-_%]+)*(?::\d+)?(?:/[\w\-_\~%\.@,\?&;=#+:\'\\\\]*|[\(\{][\w\-_\~%\.@,\?&;=#(){}+:\'\\\\]*)*[/\w\-_\~%@\?;=#}\\\\])~i', '~(?<=[\s>(\'<]|^)(www(?:\.[\w\-_]+)+(?::\d+)?(?:/[\w\-_\~%\.@,\?&;=#+:\'\\\\]*|[\(\{][\w\-_\~%\.@,\?&;=#(){}+:\'\\\\]*)*[/\w\-_\~%@\?;=#}\\\\])~i'), array('$1', '$1'), $data);
                  $data = strtr($data, array('\'' => '&#039;', $context['utf8'] ? "\xC2\xA0" : "\xA0" => '&nbsp;', '>">' => '&quot;', '<"<' => '"', '<lt<' => '&lt;'));
               }

               // Next, emails...
               if (!isset($disabled['email']) && strpos($data, '@') !== false)
               {
                  $data = preg_replace('~(?<=[\?\s' . $non_breaking_space . '\[\]()*\\\;>]|^)([\w\-\.]{1,80}@[\w\-]+\.[\w\-\.]+[\w\-])(?=[?,\s' . $non_breaking_space . '\[\]()*\\\]|$|<br />|&nbsp;|&gt;|&lt;|&quot;|&#039;|\.(?:\.|;|&nbsp;|\s|$|<br />))~' . ($context['utf8'] ? 'u' : ''), '$1', $data);
                  $data = preg_replace('~(?<=<br />)([\w\-\.]{1,80}@[\w\-]+\.[\w\-\.]+[\w\-])(?=[?\.,;\s' . $non_breaking_space . '\[\]()*\\\]|$|<br />|&nbsp;|&gt;|&lt;|&quot;|&#039;)~' . ($context['utf8'] ? 'u' : ''), '$1', $data);
               }
            }
         }

         $data = strtr($data, array("\t" => '&nbsp;&nbsp;&nbsp;'));

         if (!empty($modSettings['fixLongWords']) && $modSettings['fixLongWords'] > 5)
         {


.................any ideas? :-\

jaymrvn

 ;D I fixed this issue and it was a bone head mistake.... :'(

O:) The topic ID and Message numbers appeared in the bottom of my Firefox Browser.

I then went to my servers Cpanel, opened the MySQL feature and under forum name/messages

I searched for the topic id, and in there I found the same message number as I saw listed as highlighted the last post that TOPIC in the main forum. As you move the cursor over the post listed under the name of your TOPIC you find the info to the link/post at the bottom of the browser.

QuoteSo if your forum has a TOPIC that WILL NOT LOAD and times out, you need to follow these steps to fix it. But, you will need to be the server manager with access to Cpanel (installed on your server)...if your forum is free and you have never heard of Cpanel.....your out of luck!

Arantor

Do you require any further support with this?

Advertisement: