As far as I know you can use
$collection->getSelect()->order(new Zend_Db_Expr('RAND()'));
$collection->getSelect()->limit(2);
Or with just PHP (not elegant though) you can read this in order to use $first_id = mt_rand(1,$count)
and then exclude $first_id from the second call of mt_rand() by reading How to get a random value from 1~N but excluding several specific values in PHP?