I occasionally have bouts of insomnia. Mostly I just try to up physical activity and reduce caffeine usage. It's a hellish couple of days, but usually I can regain normal sleeping habits.
My issue is sometimes I just don't feel tired until very, very late (4-5am). I can sleep fine, it's just getting tired enough to fall asleep takes an abnormally long time.