Narf

Anonymous
Hi guys, hope you can help!

Recently my site went down with a sql error, so I checked for everthing obvious I could think of...the DB login still works, everything seems to be up and running (SQL wise)

Anyway this is the error I get when I enable error reporting:

Notice: Undefined variable: _USER in /home/powellri/public_html/system/lib-sessions.php on line 206

I looked in lib-sessions.php and it appears to be related to cookies. Anyone have any ideas? I'm stuck!

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
That's only a notice, not an error. But it may prevent you from logging in.

You shouldn't be seeing notices, actually. Make sure you still have this line near the top in lib-common.php:
Text Formatted Code
error_reporting( E_ERROR | E_WARNING | E_PARSE | E_COMPILE_ERROR );
 


bye, Dirk

Narf

Anonymous
I enabled it to try to figure out what was happening in the site.

I changed it to 'All'

Narf

Anonymous
I misread that!

How can I enable error logging? Or perhaps you can point me in the right direction

That error comes up when I visit any php page on the site...

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Quote by Narf: I enabled it to try to figure out what was happening in the site.

I changed it to 'All'

That's what I suspected. Change it back to what I quoted above.

bye, Dirk

Narf

Anonymous
I changed it back the error now reads

An SQL error has occured. Please see error.log for details.

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
So what is the SQL error?

bye, Dirk

Narf

Anonymous
The error is as follows:

Text Formatted Code

Wed Aug 31 12:00:55 2005 - 1016: Can't open file: 'gl_sessions.MYI'. (errno: 145). SQL in question: DELETE FROM gl_sessions WHERE remote_ip = '24.6x.2x3.204' AND uid = 1

 


The IP varies but the error remains the same

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Your sessions table is corrupted. Try repairing it in phpMyAdmin.

bye, Dirk

Narf

Anonymous
That did it!

You rock! Thanks man! Now to find the cause of it...