Recording system sound - is possible?

Is it possible to record in any way the sound from the system?
I do not mean the sound from the microphone.