Chris Neil tallied and Craig Anderson made 27 stops for the Senators, who lost for just the third time in their last 10 outings.
Perry snapped a scoreless deadlock at 6:15 of the second period, when he was alone in the low slot to take a Bobby Ryan feed and backhand it home.
Anaheim went up 2-0 with three minutes left on a freak play. Niklas Hagman circled the Ottawa net and dished back to Visnovsky for a right-point drive. Anderson made the save, but as the puck hung in the air, Erik Condra accidentally batted it over the goal line.
Ottawa finally struck to halve its deficit at the 8:51 mark of the third as Neil followed up his own rebound and beat Hiller in front, but that was all the visitors had in the tank.
Anaheim has taken five of the six regular-season meetings with Ottawa since 2005...The Ducks host Colorado on Sunday and the Senators continue their six- game road trip in Los Angeles on Monday.