Thursday, November 6, 2008

Enabling VNC Server on Fedora Core 9 - Painful way

Enabling the VNC server on Fedora Core 9 is not a very straight-forward process.
Here are the steps that I took to enable the VNC server.

1. install vncserver

2. modify /etc/sysconfig/vncservers
------VNCSERVERS="1:username"
------VNCSERVERARGS[1]="-geometry 1200x800"

3. logon as username

4. run vncpasswd
$ vncpasswd
Password:
Verify:

5. logon as root

6. Start the VNCServer
/sbin/service vncserver start
7. Allow X display
modify /home/username/.vnc/xstartup and uncomment the following two lines

unset SESSION_MANAGER
exec /etc/X11/xinit/xinitrc

$ vi ~/.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 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
twm &

8. service vncserver restart

Linux Networking

I have setup my Linux Fedora Core - Sulphur 9(Linux kernel 2.6.25-14.) Networking Machine on my Old Dell Notebook - Inspiron 710m.

Note sure how long this server will last. This is another old laptop running the Linux machine. Seems that Linux is good for old machines but can never make it to new machine. I just treat Linux as a toy.

Here is the setup for myself. To remind myself how the network is setup in case, I forget again.

Start up the Network
System->Administration->Network

If you are not ROOT, Linux will ask for a password.

Double-click on the eth0 device. This time I have opt for a Static IP address configuration.
Select the static IP address radio button and enter the IP Address.
DNS is mapped from a DNS server. The advantage of DNS setting is the auto mapping of the IP address to the name.

Under the DNS tab, Enter the Primary DNS and Secondary DNS.
My DNS address are as follows:
192.168.9.10
165.21.83.88
dnssec1.singnet.com.sg

After the setting is completed, the network needs to be restarted.

Restart the network using this command
# /etc/init.d/network restart

Lighttpd, FTP, SSH are all enabled now.


If the network does not "remember" the DNS, manually change the configuration file.
/etc/sysconfig/network-scripts/ifcfg-eth0

# Broadcom Corporation BCM4401-B0 100Base-TX
DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
NM_CONTROLLED=yes
TYPE=Ethernet
USERCTL=yes
PEERDNS=yes
IPV6INIT=no
DHCP_HOSTNAME=192.168.29.1
IPADDR=192.168.29.131
NETMASK=255.255.255.0
GATEWAY=192.168.29.1
HWADDR=00:14:22:8a:41:5f
DNS1=192.168.9.10
DNS2=165.21.83.88
SEARCH=dnssec1.singnet.com.sg