RT3 woes still

Ok. I found the comments about Crypt::SSLeay and have added that in using CPAN…

I still get:

Nov 26 12:15:05 caduceus RT: DBD::Pg::st execute failed: ERROR: Cannot insert a
duplicate key into unique index users1 at /usr/local/lib/perl5/site_perl/5.8.0/
DBIx/SearchBuilder/Handle.pm line 410. (/sw/rt/lib/RT.pm:247)
Nov 26 12:15:05 caduceus RT: RT::Handle=HASH(0x9294e1c) couldn’t execute the que
ry 'INSERT INTO Users (Comments, Password, LastUpdatedBy, Created, id, RealName,
Name, EmailAddress, Creator, LastUpdated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
’ at /usr/local/lib/perl5/site_perl/5.8.0/DBIx/SearchBuilder/Handle.pm line 417.
(/sw/rt/lib/RT.pm:247)
Nov 26 12:15:05 caduceus RT: Could not create a new user - (/sw/rt/lib/RT/User_
Overlay.pm:282)
Nov 26 12:15:06 caduceus RT: DBD::Pg::st execute failed: ERROR: Cannot insert a
duplicate key into unique index tickets_pkey at /usr/local/lib/perl5/site_perl/
5.8.0/DBIx/SearchBuilder/Handle.pm line 410. (/sw/rt/lib/RT.pm:247)
Nov 26 12:15:06 caduceus RT: DBD::Pg::st execute failed: ERROR: Cannot insert a
duplicate key into unique index tickets_pkey at /usr/local/lib/perl5/site_perl/
5.8.0/DBIx/SearchBuilder/Handle.pm line 410. (/sw/rt/lib/RT.pm:247)
Nov 26 12:15:06 caduceus RT: RT::Handle=HASH(0x9294e1c) couldn’t execute the que
ry ‘INSERT INTO Tickets (Subject, Status, Queue, Creator, Owner, LastUpdatedBy,
Type, Started, Starts, Resolved, Created, Priority, Due, LastUpdated) VALUES (?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)’ at /usr/local/lib/perl5/site_perl/5.8.0
/DBIx/SearchBuilder/Handle.pm line 417. (/sw/rt/lib/RT.pm:247)
Nov 26 12:15:06 caduceus RT: RT::Handle=HASH(0x9294e1c) couldn’t execute the que
ry ‘INSERT INTO Tickets (Subject, Status, Queue, Creator, Owner, LastUpdatedBy,
Type, Started, Starts, Resolved, Created, Priority, Due, LastUpdated) VALUES (?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)’ at /usr/local/lib/perl5/site_perl/5.8.0
/DBIx/SearchBuilder/Handle.pm line 417. (/sw/rt/lib/RT.pm:247)
Nov 26 12:15:06 caduceus RT: Couldn’t create a ticket (/sw/rt/lib/RT/Ticket_Over
lay.pm:518)
Nov 26 12:15:06 caduceus RT: Couldn’t create a ticket (/sw/rt/lib/RT/Ticket_Over
lay.pm:518)
Nov 26 12:15:06 caduceus RT: Ticket could not be created due to an internal erro
r (/sw/rt/lib/RT/Interface/Email.pm:684)
Nov 26 12:15:06 caduceus RT: Ticket could not be created due to an internal erro
r (/sw/rt/lib/RT/Interface/Email.pm:684)
Nov 26 12:15:06 caduceus RT: Create failed: 0 / 0 / Ticket could not be created
due to an internal error (/sw/rt/lib/RT/Interface/Email.pm:690)
Nov 26 12:15:06 caduceus RT: Create failed: 0 / 0 / Ticket could not be created
due to an internal error (/sw/rt/lib/RT/Interface/Email.pm:690)
Nov 26 12:19:58 caduceus sudo: ges : TTY=ttyp0 ; PWD=/u1/home/ges ; USER=ro
ot ; COMMAND=/usr/bin/su -

I have 3.0.6, non-elixus on FBSD 4.9 and perl 5.8.0…

Can anyone clue me in as to what’s going on here? The fact that I can’t get this running on my home server means I’m very reticent to try this upgrade at work… :-/

Help?

Please?

With cookies on top?

Thanks,
Glenn
Glenn E. Sieb
System Administrator
Lumeta Corporation
+1 732 357-3514 (V)
+1 732 564-0731 (Fax)

Glenn E. Sieb wrote:

Nov 26 12:15:05 caduceus RT: DBD::Pg::st execute failed: ERROR: Cannot insert a
duplicate key into unique index users1 at /usr/local/lib/perl5/site_perl/5.8.0/
DBIx/SearchBuilder/Handle.pm line 410. (/sw/rt/lib/RT.pm:247)

You need to update Postgres’s autoincrement counters. Info on
this can be found in the rt-users archives; it comes up every
now and then.
Phil Homewood, Systems Janitor, http://www.SnapGear.com
pdh@snapgear.com Ph: +61 7 3435 2810 Fx: +61 7 3891 3630
SnapGear - A CyberGuard Company

Hey Phil… Thanks for the reply :slight_smile:

I found one post that had the following info in it, but it allows me only to seemingly create a ticket… But when I try to view said ticket I get an error saying "RT Error: Could not load ticket 75 (in this case).

I’m not much of a DB guru :-/ (obviously), but if someone has a script or can expound on this fix, I’d be grateful… :slight_smile: I couldn’t find anything else other than the stuff from rt1-to-rt2 importer which said to do: select setval(‘tickets_id_seq’, (select max(id) from tickets)); (which also didn’t fix the above error)…

Thanks in advance! If someone can help me fix this, I’ll gladly send them pizza come payday! :slight_smile:

Glenn

(from: http://lists.fsck.com/pipermail/rt-users/2003-April/013103.html)

This one time, at band camp, Jesse Vincent wrote:

Ack. that needs to get into the upgrade notes. See the RT1 to RT2
importer for the explanation of what postgres is losing on.
you need to manually increment the sequence counters.

Okay, for reference I’ve done the following (within psql)

rt3=# select max(id) from tickets;
max

365
(1 row)

rt3=# select setval(‘tickets_id_seq’, 366);
setval

366
(1 row)

rt3=# select max(id) from transactions;
max

2024
(1 row)

rt3=# select setval(‘transactions_id_seq’, 2025);
setval

2025
(1 row)

and that’s fixed the immediate problem. I guess I’ll have to go through the other sequence >types and fix them up too.

I think that the migration script could do this though.

Glenn E. Sieb
System Administrator
Lumeta Corporation
+1 732 357-3514 (V)
+1 732 564-0731 (Fax)

Glenn E. Sieb wrote:

I found one post that had the following info in it, but it allows me
only to seemingly create a ticket… But when I try to view said ticket
I get an error saying "RT Error: Could not load ticket 75 (in this case).

Do your RT and/or DB logs show the reason for that?
Phil Homewood, Systems Janitor, http://www.SnapGear.com
pdh@snapgear.com Ph: +61 7 3435 2810 Fx: +61 7 3891 3630
SnapGear - A CyberGuard Company

Phil Homewood wrote:

Do your RT and/or DB logs show the reason for that?

I only get this:

Dec 3 22:09:52 caduceus RT: WebRT: Could not load ticket 77 ()
(/sw/rt/share/html/Elements/Error:54)

:-/ Any ideas?

Thanks, Phil!
Glenn