"This was my first match against a top-10 player, so it's definitely my biggest win so far,'' said the 125th-ranked Petzschner, who reached the main draw through qualification.
Petzschner had two early breaks but still lost the opening set after double-faulting in the tiebreaker.
The 24-year-old German added three more breaks to win the second. He went 5-3 up in the decider, but ultimately closed out the win on his second match point in the tiebreaker when Wawrinka netted a backhand.
"I started returning very well in the second set which put him under pressure,'' Petzschner said. "I have been playing really well lately and I know I can beat the top players.''
The 10th-ranked Wawrinka became the top-seeded player after last year's winner Novak Djokovic and James Blake withdrew form the tournament.
Philipp Kohlschreiber of Germany also advanced to the second round after beating Marc Gicquel of France 6-2, 6-2, while Radek Stepanek of the Czech Republic downed his compatriot Pavel Snobel 6-4, 6-2.
The sixth-seeded Tommy Robredo of Spain, who was due to play Stefan Koubek of Austria later Tuesday, pulled out with a hip injury and was replaced in the draw by Santiago Giraldo of Columbia.
Cortés: If Kun Plays Badly, I Can Mark Him!
Isner, Reynolds, Haas win at Legg Mason
Maresca Angry With Derby Draw
Peng Shuai advances at Tashkent Open