Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in AWS by (19.1k points)

I would like to use Amazon EC2 but I need to know if an AMI with Linux distribution with GUI exists.

1 Answer

0 votes
by (44.4k points)

Try this in RHEL 6.3 64-bit:

# yum groupinstall "Desktop"

# yum install tigervnc-server xorg-x11-fonts-Type1

# vncserver

# chkconfig vncserver on

# vi /etc/sysconfig/vncservers

Edit the last two lines, uncommenting them, where myuser is a created user (usually ec2-user).

VNCSERVERS="2:myuser"

VNCSERVERARGS[2]="-geometry 1280x1024"

Save changes.

Edit iptables:

# vi /etc/iptables

Add this line:

-A INPUT -m state --state NEW -m tcp -p tcp --dport 5902 -j ACCEPT

Restart iptables:

# service iptables restart

Next, edit the xstartup file:

# vi /root/.vnc/xstartup

Make the last line be:

exec gnome-session

To finish:

  • Reboot the instance (to reset your vncserver services)
  • Ensure the amazon security group permits TCP 5902 traffic
  • Launch a VNC Viewer like RealVNC's on your local pc
  • Connect to public_ip:5902

Related questions

Want to get 50% Hike on your Salary?

Learn how we helped 50,000+ professionals like you !

0 votes
1 answer
0 votes
1 answer

Browse Categories

...