Insomnia prevents the ability-bearer from falling asleep, whether from moves like Sing or from self-inflicted sleep like Rest.
If a sleeping Pokémon acquires Insomnia (e.g., from Worry Seed), it will wake up on its next turn.