Even though laboratory evolution experiments have demonstrated genetic variation for learning ability, we know little about the underlying genetic architecture and genetic relationships with other ecologically relevant traits. With a full diallel cross among twelve inbred lines of Drosophila melanogaster originating from a natural population (0.75 < F < 0.93), we investigated the genetic architecture of olfactory learning ability and compared it to that for another behavioral trait (unconditional preference for odors), as well as three traits quantifying the ability to deal with environmental challenges: egg-to-adult survival and developmental rate on a low-quality food, and resistance to a bacterial pathogen. Substantial additive genetic variation was detected for each trait, highlighting their potential to evolve. Genetic effects contributed more than nongenetic parental effects to variation in traits measured at the adult stage: learning, odorant perception, and resistance to infection. In contrast, the two traits quantifying larval tolerance to low-quality food were more strongly affected by parental effects. We found no evidence for genetic correlations between traits, suggesting that these traits could evolve at least to some degree independently of one another. Finally, inbreeding adversely affected all traits.