cell programming

Just another WordPress.com weblog

Remote Desktop YDL6

Sometimes we can’t be physically accesing a computer due to several reasons and in those moments we wish be there. If that is the case we could use remote desktop to access the computer. I am explaining in this post how to access a Yellow Dog Linux 6.

The main prerequisite is vncserver to be installed, so if it is not installed the first step is to install it.

The next step is to launch a console and launch vncserver.

[jsanchez@localhost ~]$ vncserver

You will require a password to access your desktops.

Password:

Verify:

New ‘localhost.localdomain:1 (jsanchez)’ desktop is localhost.localdomain:1

Creating default startup script /home/jsanchez/.vnc/xstartup

Starting applications specified in /home/jsanchez/.vnc/xstartup

Log file is /home/jsanchez/.vnc/localhost.localdomain:1.log

A directory named .vnc has been created in our home folder. This folder now contains a file storing the password needed for remote access (encrypted) and a startup script.

The startup script contains the following lines.

[jsanchez@localhost ~]$ more ~/.vnc/xstartup

#!/bin/sh

# 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 &

After executed the vncserver command and entered the remote access password the server listens in the specified display. The display is the number that apears after the ip or hostname. To find out the display the server is atached have a look to the log name.

Log file is /home/jsanchez/.vnc/localhost.localdomain:1.log

You can use then a vncviewer. In the server text box you have to introduce the ip host followed by : plus display number.  For example:            192.168.1.28:1

To test vncserver I have use Ultr@vnc in a windows xp laptop. I have capture the screen with the initial desktop.

EscritorioTWM vncviewer YDL 6

In my opinion this desktop is not very friendly, so I have changed my startup script to initiate an alternative session.

The way to change the desktop is to edit the script and change the last line. Instead of using twm we can use startkde (for  kde users) or gnome-session (for gnome users). I have used the last one.

#!/bin/sh

# 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” &

gnome-session &

<center>

<a href=”http://www.flickr.com/photos/egido/3202731159/” title=”Escritorio Gnome vncviewer YDL6 by Javier Sánchez Egido, on Flickr”><img src=”http://farm4.static.flickr.com/3337/3202731159_cdeb27081a.jpg” width=”500″ height=”373″ alt=”Escritorio Gnome vncviewer YDL6″ border=”0″ /></a>

</center>

We can launch the vncserver command several times, but note that have a server launched spends resources and the ps3 has not enought memory to handle it.

If we wish to kill one svnserver using an especific display we can use the following command (killing display 2).

svnserver –kill :2

January 17, 2009 Posted by Javier Sánchez Egido | General, Linux | , | No Comments Yet