Junaid Khan took five wickets as Pakistan ended day one of their opening Test against Sri Lanka in control, with their opponents having posted a disappointing first innings total of 204.