Be sure to send your close friends and family direct messages. You can explain the situation in a little more detail. Let them know it wasn't you who sent them inappropriate email.
You didn't bring this up, but I know it happens. Your ex might have access to racy photos of you. Sometimes these get posted online after a breakup.
Once the photos are out, there isn't a lot you can do. That's why sexting is a bad idea. Still, there are some steps you can take. Find out what you can do about your photo being posted online.
Your ex might not stop at breaking into your account. He might send you harassing messages. That's very similar to online bullying. Here are some tips on dealing with online bullies.