If just airing it out well doesn’t help, and you have checked that there are no water or mold or pest issues, the best solution I have ever come across is to buy some lavender essential oil and put just a few drops on a small dish or a piece of paper in each room. It might take a few repeats for lasting effects. I used this on an overwhelming odor from a bad bat infestation when nothing else worked -even the pest control guy was impressed!
You might need a whole house dehumidifier if you live in a humid climate. Running the a.c. or fans will help too. Or do what or ancestors did - open up all the doors and windows and air the house out. Here are some things to try.
If you know the source, use a scoopable kitty litter to absorb the odors, then vacuum or sweep. Apply, let sit, then remove. I also recommend spreading a carpet freshener powder to add a nice scent. Apply and remove.