Everything eventually comes to an end: civilizations, stars, individuals, species.
Dinosaurs ruled the earth for a longer time than elapsed since they've been extinct. Almost double, in fact.
Humanity is extremely recent; at the most, homo sapiens sapiens is 200,000 years old -- and history goes back 10,000 years. There is no special reason why humanity would (or should!) survive indefinitely.