Google Plus

install vnc-server under Centos/RHEL 5.x

Written by Mel Kham on . Posted in Linux tutorials

In this tutorial we will try to show you how to install install   vnc-server  under  Centos/RHEL 5.x

Under root

[root@localhost ~]#  yum install vnc-server

edit :

[root@localhost ~]# vi  /etc/sysconfig/vncservers

VNCSERVERS=”1:root”
VNCSERVERS=”2:pirat9″
VNCSERVERARGS[2]=”-geometry 800×600 -nolisten tcp -nohttpd -localhost”

change pirat9 if you have other users

save and exit

type

[root@localhost ~]# vncpasswd

make password the same als the user password . Then

[root@localhost ~]# vncserver

The .vnc directory wil be created under the home directory

go there and edit xstartup with

[root@localhost ~]# vi  /home/pirat9/.vnc/xstartup

remove every thing in this file and add

# Add the following line to ensure you always have an xterm available.
( while true ; do xterm ; done ) &
# Uncomment the following two lines for normal desktop:
unset SESSION_MANAGER
exec /etc/X11/xinit/xinitrc
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
xterm -geometry 80×24+10+10 -ls -title “$VNCDESKTOP Desktop” &
twm &

save and exit

start again #vncserver

go back to you windows of Linux box client start your Mocha X server

for this example i use mocha server

C:Program FilesMochaX

start your putty of other ssh client check for X11 forwarding activated .  and  X  display location  :1 or  :2  or  …

log into the machine and

start for example

#firefox www.unixmen.com


for any question put is in the forum

{loadposition user9}

Related Articles By Tags :

{loadposition user1}

For questions please refer to our Q/A forum at : http://ask.unixmen.com

Mel Kham

Founder of Unixmen, Living in Amsterdam. Am working in my free time to help people to understand the Opensource and to explain them in easy way how to make the fist steps to the the light. Working day and night with my Co-founder Zinovsky to keep this website live even with less resources.
  • http://picnicspots.info David

    If you want to install VNC Server, you need to download it from [url]http://www.realvnc.com/products/free/4.1/download.html[/url] and then execute
    [code]rpm -i vnc-4_1_3-x86_linux.rpm[/code]

  • http://www.kinoshqip.info Seethe

    when I write [b][root@localhost ~]# vi /etc/sysconfig/vncservers[/b] and when i edit user and pass I can’t save

  • Xpnetst

    This is not the best tutorial about VNC… the while of the ‘xterm’ causes log file to explode up to 10 gb and more…

  • http://www.facebook.com/profile.php?id=100003382718174 Ed Marshall

    The use of the line “( while true ; do xterm ; done ) &” seems to fill up the log files and consume all disk space.  If you look inside the log files, it mentions something about XTERM not being found, or available.  In my effort to research and find a fix for disabling the log files within VNC, I have since removed this line and VNC still happily works fine for me, but no longer fills up a log file with useless information.

Like us on Facebook

This week Top Posts

Write for us

Recent Comments

jet li

|

i try the method, and i unzip the image contain zip secret, i dont find the file that i was hide, where it go? and how to open it? :s

zinovsky

|

Yes, it is possible using Steganography, we will post another quick howto do that in the next few days

SK

|

Hey Abhishek

Yes there are many open source tools available to meet your requirements. They are easy to manage and has a decent web gui to configure. We will publish all of them one by one shortly. Stay tuned with us.

LinuxSytesNet

|

sabayon facebook group is not maintained by him but a French guy. Go back to your zorin os.

Nidal Samara

|

How do I save the entier URL?
for example: page.asp?page=12,
After adding the IfModule in .htaccess I see the correct 404, but 404 url is not shoing the query string , only page.asp

 
IDG Tech Network
Copyright © 2008-2013 Unixmen.com .
Maintained by Anblik .