[rt-users] Setting initial ticket number (auto_increment)

Mahoney, Tim Tim.Mahoney at magicorp.com
Thu Sep 15 12:46:12 EDT 2005


AFAIK, AUTO INCREMENT is useful only in MyISAM tables not InnoDB.  My system
automatically updates the AUTO INCREMENT setting for the next ticket number,
anyway (currently at 9609).  If you initially set it for 60000, create a
ticket, check to make sure AUTO INCREMENT has advanced to the next number,
then restart your server, what happens?

Thanks
Tim Mahoney
Win Svr 2003 / RT 3.0.12 / Apache 1.33 / Perl 5.8.6 / MySQL4.1.18

-----Original Message-----
From: Mike Friedman [mailto:mikef at ack.Berkeley.EDU] 
Sent: Thursday, September 15, 2005 11:12 AM
To: rt-users at lists.bestpractical.com
Subject: [rt-users] Setting initial ticket number (auto_increment)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Checking the archives of this list, I see advice on setting the initial
ticket number for a new RT database. This is for mysql 4.1.13.  The advice
is to use the following command:

    ALTER TABLES Tickets auto_increment=nnnn

to cause ticket numbers to begin with nnnn + 1.

However, the mysql manual says, "The effect of this option is canceled by a
server restart".  I verified that this is the case by restarting my mysql
server after setting auto_increment for the Tickets table to 60000. 
The value did get set to 60000, as shown by a SHOW TABLE STATUS (BTW, is
there a better way to display just the value of auto_increment?). 
However, after restarting the mysql server, the value of auto_increment went
back to 1.

So, what do I do if I want to retain the value of 60000 even if my server
happens to restart (say because of a reboot)?  Once I start creating tickets
in my new RT database (starting at 60001, I hope), I wouldn't want new
ticket numbers suddenly to be assigned lower values just because the server
happened to restart at some point in the future.

Could someone clarify all this?

Thanks.

Mike

_____________________________________________________________________
Mike Friedman                   System and Network Security
mikef at ack.Berkeley.EDU          2484 Shattuck Avenue
1-510-642-1410                  University of California at Berkeley
http://ack.Berkeley.EDU/~mikef  http://security.berkeley.edu
_____________________________________________________________________

-----BEGIN PGP SIGNATURE-----
Version: PGP 6.5.8

iQA/AwUBQymdO60bf1iNr4mCEQIAHgCggse1KcIIHotS8CbBlkXzZerLXWcAoKbj
KeOkFTSidYkIKg8Kn+6FvneQ
=83Jv
-----END PGP SIGNATURE-----
_______________________________________________
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Buy your copy of our new book, RT Essentials, today! 

Download a free sample chapter from http://rtbook.bestpractical.com



More information about the rt-users mailing list