Lakmal took four for 62 in 23 overs as South Africa reached 267 for six at the end of a day on which they failed to capitalise on a century opening partnership between Stephen Cook and Dean Elgar.
Opening bowler Lakmal pegged back the hosts by taking the first three wickets and later dismissed South African captain Faf du Plessis. Left-arm spinner Rangana Herath took two wickets, including that of JP Duminy, South Africa's top scorer with a fluent 63.
Cook (59) and Elgar (45) were seldom troubled as they reached 92 for no wicket at lunch. They started cautiously and left the ball well before gradually lifting the tempo.
Any thoughts of a South Africa run feast in the afternoon were spoiled by Lakmal in a superb spell immediately after lunch. He was backed up well by Angelo Mathews and Nuwan Pradeep as only 13 runs were added in 10.2 overs for the loss of both openers.
Only one run was added off the next 29 balls before the left-handed Elgar pushed at a ball angled across him to present a second catch to Chandimal.
Duminy threatened to swing the balance back to South Africa. The left-hander hit the first ball he faced from Lakmal through the covers for four and raced to 34 off the first 23 balls he faced, including eight fours.
It was a continuation of a poor run of form by Amla, who scored only 98 runs at an average of 16.60 during South Africa's series victory in Australia last month.
The dismissal meant that Amla's Test career average dipped below 50 for the first time in more than four years.
Duminy, meanwhile, was unable to bat with his earlier fluency as the Sri Lankans altered their line to prevent his flow of off-side drives. He eventually lost patience and missed a sweep against Herath to be given out leg before wicket.
The Sri Lankans, though, successfully reviewed a decision by Oxenford four overs later when Temba Bavuma went back to Herath and was originally given not out when he was struck on the pads.
Lakmal's fourth strike came in the fourth over with the second new ball when he made the ball move sharply off the pitch to have Du Plessis caught at second slip for 37.
Disclaimer: No Business Standard Journalist was involved in creation of this content
