Linux + Kursunterlagen
Using the entry in the proc-Filesystem of a running process, it's easy to get a sorted list of environment variables for a certain process ID (PID):
tr '\0' '\n' < /proc/<PID>/environ | sort
Since the lines in environ are null-terminated, putting proper newlines in the output with tr is necessary before sorting. (sort can only output lines terminated with \0 using the option -z, but not read them, besides: even -z doesn't quite work as expected in my case)
Using the output of above command line comparing two running processes is easy, using diff or vimdiff (even remotely, see my last blog post)