The following steps show how to install VNC in RHEL/OEL Linux distros.
Setup VNC Server:
yum install tigervnc-server
Edit the vncservers config file:
vi /etc/sysconfig/vncservers
Add usernames to config file:
[...]
VNCSERVERS="2:weblogic 3:aimtiaz"
VNCSERVERARGS[2]="-geometry 1200x1024 -nolisten tcp -localhost"
Login as the user you want VNC in as and then set the password using vncpasswd command.
Run the below commands to install GNOME/KDE desktop environments.
yum groupinstall "Development Tools"
yum groupinstall "X Window System" "Desktop"
yum groupinstall "GNOME Desktop Environment"