<?php
$post_amount = 5;
$random_posts = get_posts('numberposts='.$post_amount.'&orderby=rand');
foreach( $random_posts as $post ){
setup_postdata($post);
?>
<div>
<a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
<div><?php the_excerpt(); ?></div>
</div>
<?php
}
?>