What are the causes of these marks on a ceiling?
My first thought is &quot;ghosting&quot;.  This is mainly seen in poorly insulated areas and often follows studs and joists (may even see it on the drywall nails or screws).  The ghosting is caused by sections of the wall or ceiling being cooler than the rest of the wall and cool enough to get some condensation.  Every house has some amount of dust floating around, and this dust sticks to the wet parts of your walls/ceilings better than it does to the dry parts and builds up.  Over time this becomes noticeable.  This is particularly bad when you have anything burning in your house (fireplace, kerosene heater, someone is a bad cook, etc.) or if you keep your windows open (more dust).  As mentioned in the comments, this is really bad around areas that get a lot of air flow a (registers, returns, etc.).
The solution is to first fix the insulation problem, clean the walls, then repaint.
That said, your second picture looks more like water damage, potentially, than ghosting.  It's hard to tell, but I can almost see where water has pooled in areas and began dripping down the wall.  However, it's hard to tell from the lighting in the picture.