As with people, probably the most important measure for keeping dogs healthy and promoting a long, active and happy life is to keep them trim.

As Max the First neared his 17th birthday, we knew his days were numbered. He approached the wrong side of the door to go out and often started to pee in the vestibule, a common sign of cognitive impairment. Long walks — and sometimes any walks — were now out of the question.

But not until I was home all day and heard him whimper almost constantly did I realize we were not doing this much-adored pet any favors by prolonging his life. As a 40-pound springer spaniel mix wintering in New York and summering in Minnesota, he’d led a very full and active life. He hiked in the woods year-round, frolicked in every snowfall in Brooklyn’s Prospect Park and even swam a river with me summer mornings in Minnesota until he was 15.

Although he had no discernible fatal disease, we knew that as Max the First (hereafter, Max-I) passed the equivalent of 110 in people years, it was time to say a tearful goodbye. Much to our surprise, he seemed grateful. We had planned to wheel him to the vet in a little red wagon but Max-I, who until then refused to set foot on any block near the vet’s office, now walked there without hesitation under his own steam. I admit that 18 years later I still weep recalling how omniscient he seemed on his last day.

Now, though, I’m the happy parent of Max-II, a 6-year-old Havanese who still runs and swims like a puppy as he approaches what some veterinarians consider middle age for a 17-pound dog. And I hope I’m even smarter now about what it takes to keep him vibrant for as long as his biology will allow.

While Max-I thrived on store-brand dog food, Max-II gets a premium kibble (after a pet-smart woman told me that the much cheaper store brand was like feeding him McDonald’s!) and he gets to run off-leash every morning, rain or shine. In summer we hike in the woods in upstate New York and he swims after sticks I throw into a stream.

I’ve been diligent about routine vet visits and all the shots now recommended to prevent debilitating ailments. But having just read a very comprehensive book as background for preparing this column, “Good Old Dog” by the faculty of the Cummings School of Veterinary Medicine at Tufts University, I realize that I’ve thus far made one important slip: I have never brushed Max-II’s teeth. Dr. Jean Joo, who trained at Tufts in veterinary dentistry, noted that although dogs usually don’t get cavities, they are prone to gum disease that can lead to tooth loss and allow noxious bacteria to enter the bloodstream.

Max-II now has a vet-approved toothbrush and enzymatic paste I try to use nightly, supplemented by the chew treats I’ve long given him that purport to promote dental hygiene.

But as with people, probably the most important measure for keeping dogs healthy and promoting a long, active and happy life — both for the dogs and their owners — is to keep them trim. A fat dog is not a happy dog, even if it means denying precious pets treats that they beg for. Max-II gets to lick my empty dinner plate, but leftover food goes into the fridge or the trash. He also gets weighed at every vet visit so I know whether the half-cup of kibble he gets twice a day is too much or too little to keep him lean and healthy.

Like people, as dogs get older they often develop one or more chronic diseases. But unlike in people, coronary artery disease, or atherosclerosis, is much less likely to be one of them, though dogs can develop congestive heart failure, especially if they have a malformed heart valve. (Rather than heart disease, cancer is the leading cause of death in dogs, and unfortunately its symptoms are often missed until it is too late for a cure.)

In addition to dental disease, dogs are susceptible to diabetes, making some dependent on twice-daily insulin injections that their owners must administer. And with the enormous increase in canine obesity, mirroring the rise in obese people, dogs are now developing Type 2 diabetes at alarming rates. Be alert to signs of diabetes in your dog: increased thirst and a more frequent need to pee, as well as weight loss despite a hearty appetite.

Another treatable cause of increased thirst and urination in older dogs, especially large female dogs, is Cushing’s syndrome, an adrenal gland disorder. But rather than feeling the urge to urinate, the dog is likely to pass urine without realizing it and may even soil her bed, the Tufts vets reported. Older male dogs, primarily those that are not neutered, may develop an enlarged prostate that makes bowel movements (not urination) more difficult.

Osteoarthritis, the wear-and-tear kind that makes people and dogs creaky, is another common affliction as dogs age. It often develops as a result of a malformed joint the dog was born with, prompting some owners to opt for corrective surgery. Operating on a young dog with a congenital malformation may delay the development of arthritis though not necessarily prevent it indefinitely. There are also well-tested veterinary medications to reduce inflammation and pain in dogs with arthritis. Signs to watch for, especially in older dogs, include a tendency to favor a limb, difficulty standing or sitting and stiffness when walking.

Chronic Lyme disease has become an all-too-common cause of debilitating arthritis in dogs as well as people. Max-I acquired it before vets were savvy to the infection and before there was a veterinary vaccine to prevent it or monthly pesticide treatments to repel Lyme-carrying ticks. But we minimized his arthritic symptoms with regular activity and a daily supplement of Cosequin, a combination of glucosamine and chondroitin originally developed for horses. Thus far, although we summer in tick country, Max-II has remained free of Lyme with the aid of a yearly vaccine and monthly tick preventive.

Kidney disease, another common affliction of older dogs prompting them to produce copious amounts of dilute urine, is most often detected during an annual checkup. The Tufts experts advise minimizing the dog’s stress, providing constant access to water and feeding a diet reduced in protein and phosphorus as soon as the kidney problem is noted.

In caring for older dogs, experts urge owners not to assume that changes in behavior result from age and nothing can be done to help them. Veterinary science has taken many leads from human medicine that can enable aging dogs to live fuller, happier lives.