Weeks after Donald Trump was elected president, Russia-backed online “trolls” flooded social media to try to block Mitt Romney from securing a top job in the incoming administration, a Wall Street Journal analysis shows.

The operatives called the 2012 GOP presidential nominee, then a contender for secretary of state, a “two headed snake” and a “globalist puppet,” promoted a rally outside Trump Tower and spread a petition to block Mr. Romney’s appointment to the top diplomatic job, according to a review of now-deleted social-media...