I've had both success and failure as an advisor to startups. Here are some of the big lessons I've learned over the years:
Only advise startups you would consider investing in. Otherwise, the startups will ask you for intros to investors and you'll be in a constantly awkward position. If you don't intro the startup, they'll be upset at you as an advisor. And if you intro them to investors and you haven't invested yourself, then it's a negative signal. It also burns relationships between you and co-investors to show them questionable deals that you wouldn't invest in.
Don't accept compensation (cash/equity) in exchange for hitting fundraising milestones. This gives you weird incentives to peddle bad deals to investors. It's also a violation of SEC broker-dealer laws. Instead, provide advisory services which include many services (such as helping find product/market fit) and which vest over a long period of time. This decouples the advisory services from fundraising.
Don't accept cash in exchange for advising. Startups are cash-strapped and can't afford to pay you. Only accept equity.
Avoid adverse selection. Often times, startups that need advice self-select into ones that are at the bottom of the list of potentially successful startups. This is (again) why advising startups that you also invest in is a good litmus test -- you want startups that demand both advice and investment.
Schedule a recurring monthly call with the startups you advise. Don't rely on them to call you -- they'll forget. Then in 6 months they'll wonder why you're vesting advisory shares. The startups that are successful will cancel their contracts with you to consolidate their cap table. The ones that are unsuccessful will keep you onboard as an advisor and waste more of your time.