Could not delete stale confirm data???

This is an archive of the phpBB 2.0.x support forum. Support for phpBB2 has now ended.
Forum rules
Following phpBB2's EoL, this forum is now archived for reference purposes only.
Please see the following announcement for more information: viewtopic.php?f=14&t=1385785
Registered User
Posts: 17905
Joined: Wed Dec 22, 2004 1:14 am
Location: Woodstock, IL

Re: Could not delete stale confirm data???

Post by espicom » Tue Oct 07, 2008 6:56 pm

It will last until the number of active sessions gets big enough to exceed the package size your host allows. A way to estimate it is to ask the server how big the packet can be - if you have phpmyadmin or similar, run this query:

Code: Select all

show variables like 'max_allowed_packet';
That number is how big the communications packet can be. Yours is probably in the 65,000 byte range. Divide that by 80, and you will have a reasonable idea of how many active sessions it will take to trip the error.
Fixing 1016/1030/1034 Errors | (obsolete link) | MySQL 4.1/5.x Client Error | phpBBv2 Logo in ACP
Support requests via PM are ignored!
"To be fully alive is to feel that everything is possible." - Eric Hoffer

User avatar
Dog Cow
Registered User
Posts: 2495
Joined: Fri Jan 28, 2005 12:14 am

Adjustment for time

Post by Dog Cow » Tue Oct 07, 2008 9:26 pm

I worked on it last night, like I said. Here's what I got:

1.) Add a new field 'time' to phpbb_confirm which is INT(11). Make it an index.

2.) Remove the query in usercp_register.php that selects all the sessions. Change the DELETE FROM ' . CONFIRM_TABLE . ' query to instead go like this:

Code: Select all

'DELETE FROM phpbb_confirm WHERE time < ' . (time() - 480)
3.) Change the query which inserts a new confirm row and add the current time to it.

That will delete all confirm entries older than 8 minutes without involving the user sessions.
Mac GUI Vault: Retro Apple II & Macintosh computing archive.
Inside Allerton bookMac GUIMac 512K Blog

User avatar
Registered User
Posts: 149
Joined: Wed Dec 20, 2006 7:15 pm

Re: Could not delete stale confirm data???

Post by qspypl » Wed Nov 26, 2008 3:55 pm

Good listing of changes which must be made. Works great :).



Return to “2.0.x Support Forum”