Looks like you are suffering from constipation
Increase your water and dietary fibre intake.
Can take isapgula husk 2 tsp at night.
Do not strain.
Can get stool occult blood one a day for 3 days if positive then get opined by a doctor.
Hope this answers your query.
Please do reply in case of any further questions.
Wish you a speedy recovery.