[Linux-disciples] Replaying MySQL commands

Stephen R Laniel steve at laniels.org
Fri Apr 21 11:35:50 EDT 2006


I've got a bunch of SQL commands, recorded from a live (and
very busy) website using the MySQL logging commands. Now I
want to replay them on a local website. What's the best way
to do that? There must be some good way to script such
things.

I mean, I could do

mysql -u [username] --password=[password] [databaseName] "[command]"

for each [command] in the logfile, but there has to be a
better way. Particularly since the logfile marks off
database connections, and I'd like all the commands that
were executed in separate connections to be replayed
in separate connections.

-- 
Stephen R. Laniel
steve at laniels.org
+(617) 308-5571
http://laniels.org/
PGP key: http://laniels.org/slaniel.key
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.bostoncoop.net/pipermail/linux-disciples/attachments/20060421/da714250/attachment.pgp


More information about the Linux-disciples mailing list