To be perfectly honest with you, allocating 5GB for innodb_buffer_pool_size may not hold 5GB. Why not ??? Please take a look at the following diagram from Vadim Tkachenko
Look in the upper left-hand corner. The Buffer Pool has a section dedicated to the Insert Buffer (memory structure dedicated to holding changes to secondary indexes).
If you attempt to load all your InnoDB data and index pages into RAM, the moment you start changing columns that are part of a secondary (non-unique) index, 16K pages will start getting kicked out of the Buffer Pool to make room for such changes.
The more write-intensive your database, the more Insert Buffer changes need to be recorded in the Buffer Pool.
If you look inside the yellow box under the title "Insert buffer part of buffer_pool", the first line says "InnoDB-std: may take 1/2 of buffer_pool".
This means the most write-heavy application that has 5GB would need a 10GB Buffer Pool. Sounds ludicrous, but it is possible that can be the case.
Personally, I would make the Buffer Pool 7GB to start. I would also make sure I have these configured in
innodb_read_io_threads = 8
That way, any restart of mysqld would preserve the contents of the Buffer Pool and would reload it (won't be instantaneous but will load in a few minutes)
I doubled the number of read I/O threads to increase the speed data is read into the Buffer Pool.