I cannot give medical advice. It sounds like your Shih Tzu is experiencing discomfort, and it is important to get him checked out by a veterinarian as soon as possible.
Possible Reasons
* Anal gland issues: Shih Tzus are prone to impacted or infected anal glands.
* Parasites: Internal parasites like roundworms can cause digestive upset and pain.
* Injury: A tail injury or slipped disc can cause pain.
* Other medical conditions: Urinary tract infections, constipation, or tumors.
What to Do
Observe your dog's behavior and note any other changes. Keep your dog comfortable in a quiet place. Avoid giving medications without consulting a veterinarian.
It is always best to err on the side of caution when it comes to your pet's health. Get him to a veterinarian as soon as possible for a proper diagnosis and treatment.