A sudden burst of water can scare the muskrats away, and sprinklers may deter other animal pests. Try riprapping with gravel ...