I believe i've experienced DMT during sleep, at least three times in my life. The first time was when i was 17, didn't even know about DMT/Ayahuasca or Psychedelics back then, and i had a dream that turned out to be a precognitive vision about me being in the hospital, and two months later, i almost died from Salmonella Sepsis.
Fast forward to 2012, i hear about Ayahuasca and decide to start working with it (using Rue and Mimosa), and one night while sleeping i had a dream where i saw the word Ayahuasca, and then next thing i know i'm being blasted with bright colors, shapes and patterns, and the body feelings felt just like DMT, but it only lasted like maybe 15 to 30 seconds or so before i jolted up and was like "woah i just experienced DMT in a dream", as to me it was completely obvious that it was DMT.
Then, in January 2014, one night i had taken some pure Harmalas (extracted from Rue), some Acacia Confusa, and some Lemon Balm tea, and i had another precognitive vision, but this vision was much, much clearer than the one i had in the dream back in 2007. The vision was about my dads death, and two weeks later, the event came to pass.
But the vision i had in the dream when i was 17, and the vision i had on Acacia/Harmalas/Lemon Balm, were of the same space, they felt exactly like the same precognitive space, except the vision in the dream was foggy/cloudy and was hard to make sense of, but the vision on Acacia was very clear, very detailed, even had real time emotion that came with it, but they were both of the same space.
So the visions, plus the quick DMT flash, leads me to believe that DMT can be released during sleep, but i don't think it happens all the time or consistently, only when it needs to happen i guess.