DISPLAY Environment Variable

I've seen articles which say "export DISPLAY=<IP>:0" and others which say "export DISPLAY=<IP>:0.0". Can someone explain what the difference is?

TIA

From a X(7) man page:

Note that an IP address can be used instead of a hostname.

Hope it's ok to join in on an environment variable question-
How to view what environment variables users have set up?
env bob doesn't work, cd'ing to their home dir and running the cmd doesn't work either.
( I know to see my own it's: env)
Thank you

If you have root rights, you can simply su - to the user and run env. Alternatively, you could just source their respective .chsrc, .bashrc etc. ( . /path/to/user/.bashrc) and then check the environment differences are. What's the purpose of your particular investigation?

Cheers,

Keith

Thank you for the reply kduffin :slight_smile:
That works great- with the exception that the next time the user logs in they will see 'Last login' as my IP - not their own and their .bash_history will contain cmds I executed.
It is also quiet a few steps to yield the results of 'env' for all users.
Is there another method to view one or all users env variables?
For example to view if any users have messed around with their history? such as 'unset HISTFILE'.
I know how to prevent them from altering it, I just want to know if they have :slight_smile: .