MySQL session problem

Hi,

Recently I’m installing RT 3.6.5 from FreeBSD ports.
The newly installed system can not keep data in the MySQL session store,
but it works normally with the File session store.
It looks like the same problem encountered by Matthew Seaman mentioned in
[rt-users] CC: and BCC: fields when Commenting.

When a new user connect to the system,
it creates a new, empty, abnormally long (103 bytes rather than 56 bytes)
record in the ‘sessions’ table.
When being ‘thawed’ by Storable, it only returns ‘undef’, not a hash
with a _session_id.

I’m using FreeBSD 6.3, perl-5.8.8_1, rt-3.6.5, apache-2.2.8, mod_fastcgi-2.4.6,
p5-DBD-mysql-4.006, p5-Apache-Session-1.81 and mysql-server-5.0.51a.
I can provide shell access to this machine for investigating if necessary.

LCamel

P.S. The following data is from the sessions table.

mysql -u root -e ‘select id, length(a_session), hex(a_session),
LastUpdated from sessions’ rt3
| id | length(a_session) |
hex(a_session)

                                                             |

LastUpdated |
| f133995da84539778762aaa95224b518 | 56 |
050703000000010A2066313333393935646138343533393737383736326161613935323234623531380000000B5F73657373696F6E5F6964

                   | 2008-02-23 14:27:35 |

| a2885a4ed28ce68712cdd4ed3b7561a7 | 103 |
0507030000000204110F52543A3A43757272656E7455736572030000000404110C52543A3A4931384E3A3A656E03000000000000000A4C616E6748616E646C650A055573657273000000057461626C650403000000000000000676616C75657304030000000208
| 2008-02-23 14:29:02 |

Ren-Shan Luoh wrote:

Hi,

Recently I’m installing RT 3.6.5 from FreeBSD ports.
The newly installed system can not keep data in the MySQL session store,
but it works normally with the File session store.
It looks like the same problem encountered by Matthew Seaman mentioned in
[rt-users] CC: and BCC: fields when Commenting.

The fix I discovered on this list was:

ALTER TABLE sessions MODIFY a_session longblob ;

See: [rt-users] Vanishing attachment content

When a new user connect to the system,
it creates a new, empty, abnormally long (103 bytes rather than 56 bytes)
record in the ‘sessions’ table.
When being ‘thawed’ by Storable, it only returns ‘undef’, not a hash
with a _session_id.

It’s possible this is an effect due to using utf8 as the default
character set, which uses three bytes per character in certain
circumstances.

Cheers,

Matthew

Dr Matthew Seaman The Bunker, Ash Radar Station
PGP: 0x60AE908C on servers Marshborough Rd
Tel: +44 1304 814890 Sandwich
Fax: +44 1304 814899 Kent, CT13 0PL, UK

signature.asc (250 Bytes)