It's good advice. I guess it implies indebtedness to some benevolent universal presence, but I hear complete atheists saying that they are thankful, too. It's still valid for them. "Glad" is a good substitute word: "I'm glad I have such a great life."
Sometimes, we use the idea of being thankful as an argument that we have no right to ever complain. It's like the old mom thing, when a kid won't eat his Lima beans: "You should be thankful you have Lima beans. There are starving children who would love to have Lima beans."
Of course, this doesn't work. First of all, it just doesn't work, psychologically. Second, I don't even think starving kids would eat Lima beans.