OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki


another "DB Error: Duplicate entry 'xxx' for key 1"

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, michael, jheckman, barbarah, btbell, bdgregg, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

another "DB Error: Duplicate entry 'xxx' for key 1"

Postby rsenise » Tue Apr 15, 2008 11:59 am

Hi!

I'm having a problem with sessions. When I try to visit the site I get the message "DB Error: Duplicate entry 'xxx' for key 1".

Someone had some trouble like mine, but I believe it's worst now: I can only see the homepage once, if I click anywhere I get the Duplicate entry error. If I try to login, it happens the same.

Yes, I did clean up my database, and the error comes again. And yes, my "session.auto_start" is set to off, and OJS's "force_login_ssl" is off, too.

What could I do?
rsenise
 
Posts: 3
Joined: Tue Apr 15, 2008 11:24 am

Re: another "DB Error: Duplicate entry 'xxx' for key 1"

Postby jmacgreg » Wed Apr 16, 2008 10:54 am

Hi rsenise,

Can you follow Alec's advice on finding more errors in the following link and get back to us with what you find:

viewtopic.php?f=8&t=2885&p=10244#p10244

Thanks,
James
James MacGregor
PKP Support Team
--
Questions? Before posting, please try:
Advanced Forums Search
OJS and OCS Documentation
Video Tutorials

Visit #PKP on IRC!
jmacgreg
 
Posts: 4153
Joined: Tue Feb 14, 2006 10:50 am

Re: another "DB Error: Duplicate entry 'xxx' for key 1"

Postby rsenise » Thu Apr 17, 2008 12:06 pm

Hi!
I put "ini_set('display_errors', E_ALL);" in index.php, but it didn't work.

Then I turned On the show_stacktrace option in config.inc.php, and it shows these errors:

Stack Trace:
File: /home/anptur1/public_html/rbtur/classes/session/SessionDAO.inc.php line 79
Function: DAO->update("INSERT INTO sessions (session_id, ip_address, user_agent, cr...", Array(7))

File: /home/anptur1/public_html/rbtur/classes/session/SessionManager.inc.php line 78
Function: SessionDAO->insertSession(Object(Session))

File: /home/anptur1/public_html/rbtur/classes/session/SessionManager.inc.php line 105
Function: SessionManager->SessionManager(Object(SessionDAO))

File: /home/anptur1/public_html/rbtur/index.php line 38
Function: SessionManager::getManager()

File: /home/anptur1/public_html/rbtur/index.php line 57
Function: handleRequest()

My site URI is http://anptur1.tempsite.ws/rbtur/index.php, if it happens....

Thanks, Ricardo Senise.
rsenise
 
Posts: 3
Joined: Tue Apr 15, 2008 11:24 am

Re: another "DB Error: Duplicate entry 'xxx' for key 1"

Postby smiri » Thu Apr 17, 2008 10:20 pm

Hi Ricardo,

have you checked your server error_logs yet?

Also what happens if you delete your sessions from your database

Code: Select all
DELETE FROM sessions;

can you access the site then?
Siavash Miri
PKP Support Team
smiri
 
Posts: 183
Joined: Thu Sep 06, 2007 7:01 pm


Return to OJS Technical Support

Who is online

Users browsing this forum: mendesrocha and 6 guests