Multiple loops with / without sticky posts and different post limits

your problem is that in the first loop you overwrite $do_not_duplicate for each post in the loop so at the end you only have the id of the last post.
if you change $do_not_duplicate into an array then you can add each post to the array:

//before the loop
$do_not_duplicate = array();

//in the loop

$do_not_duplicate[] = $post->ID;

then you can just use in in the second query :

<?php query_posts($query_string . '&cat=-15,-17, -5, -2&post_type=post&posts_per_page=9&post__not_in='.$do_not_duplicate); ?>