If you have a musty odor in your house it's most likely coming from the basement. Basements are traps for moisture and over time it causes a musty smell that could be bad for your health. Follow these steps below to elimiate this.
First, you want to try and find out where the moisture is coming from. It could be from cracks in the foundation walls, a bad storm that caused water to come in, or a leak in pluming. If your basement gets water in it when it rains you might want to invest in putting sun pumps in the basement. Clogged gutters can also cause water to get into the basement because the water does not run off the house correctly.
Once you resolve where the water is coming from you can get rid of the odor by using baking soda. Pour baking soda in an open container and place it in the corners of your basement. You can also use coffee grounds.
I also suggest using a dehumidifier to keep the moisture out of the air. Use a fan to keep the air moving. This will all help eliminate the odors