Have you read the docs for CGI::Session on CPAN? Be sure to look at CGI::Session::Driver::DBI also (may not be immediately obvious). All you need to do to store session data in mysql is create a session like this:
# need to customize 'table', 'username' and 'password'
my $dbh = DBI->connect("dbi:mysql:table", "username", "password");
my $session = CGI::Session->new("driver:mysql;serializer:storable;id:m
+d5", undef,
{Handle => $dbh});
So you don't need to modify the apache config file.
You CAN use Apache::DBI to enable persistent database connections, but I would recommend getting the basic idea working first, then use that to improve performance, if necessary.
|