1. Have a boss who doesn't take the credit for your work. If your direct manager is a decent person they'll put your work in front of leadership and attribute it to you. This has a very positive impact on your career.
2. Change job 'often', where often is a cadence that doesn't make it look like you're running away from things. Your best opportunity for self-promotion that has a high impact on your career is in a job interview.
However, I'll add a third insight - try to define success in a way that means you're feeling like you're moving upwards even if it's not recognized externally. Taking pride in the work you do, improving your skills, volunteering for challenging projects, etc really helps you feel like you're progressing, and that really helps with #2 above.
And if none of that works just pretend HN karma is an important metric. It works for me.