I know that many of us store our crock pots with the lids on them (almost as if they were gonna cook something while they’re in that cabinet).
For the best results you should store the crock pots and lids seperate. This will help to keep the inside of the crock pot from having any kind of funky smell. This isn’t always caused by negligent cleaning, but if the crock pot sweats or condensates it can actually cause mold or mildew to form. This is actually where the smell comes from the majority of the time.
If you have a concern as far as room to store them seperately (which is a reasonable concern for most) you can do like I do and store the lid turned upside down, but propped open with a chopstick, spatula or butter knife (I even put the cord inside the crockery and let it serve as the propping agent sometimes). In my oval crock pots I just turn the lid sideways and let it sit down inside the crockery. The key thing is to make sure that air can circulate.
Also, on crock pots that have lids with a rubber seal make sure you are completely drying the rubber seal before storing. If water is already there when beginning to store, it is more apt to have a problem with causing funky smells.