If needed, dogs will perform their own anal gland expression by sitting, pulling their hind legs up, and wiping their butt across your carpet. My dogs like to look at me when they do this like it's a fucking joke.
I've seen videos on youtube of people expressing a dog's anal glands, but I myself have never once been able to do it. There must be a special technique that I just can't get.