Rattling is very likely wear and tear inside.
First, do as Beverly said. Take it apart, give it a good cleaning with a small bottle brush/pipe cleaner. Then maybe even let it soak in white vinegar for a couple hours (The impeller and motor assembly). Still being annoying? Look at the magnet on the impeller... Does it have grooves worn in it? Time to replace it. Grab a pair of pliers and pull out the metal shaft. Does it look worn down in places? Time to replace that, too.
IMO they should always be replaced at the same time.. If memory serves, a 150 (now called the Aquaclear 30?) impeller at MSRP is like 8.99 and a shaft is 2.69. The shaft is really pennies by comparison.
(I'm also assuming that you aren't running it dry

)