To Open the VNC Port on SLES 11.x VMs' Firewall

1.Open a text console on the VM and run the YaST utility:

yast

2.Use the arrow keys to select Security and Users in the left menu, then Tab to the right menu and use the arrow keys to select Firewall. Press Enter.

3.In the Firewall screen, use the arrow keys to select Custom Rules in the left menu and then press Enter.

4.Tab to the Add button in the Custom Allowed Rules section and then press Enter.

5.In the Source Network field, enter 0/0. Tab to the Destination Port field and enter 5900.

6.Tab to the Add button and then press Enter.

7.Tab to the Next button and press Enter, then in the Summary screen Tab to the Finish button and press Enter, and finally on the top-level YaST screen Tab to the Quit button and press Enter.

8.Restart the display manager and xinetd service with the following commands:

/etc/init.d/xinetd restart rcxdm restart

Alternatively, you can disable the firewall until the next reboot by running the rcSuSEfirewall2 stop command, or permanently by using YaST. This can of course expose additional services to the outside world and reduce the overall security of your VM.

D.3.5. VNC Screen Resolution

If, after connecting to a Virtual Machine with the Graphical Console, the screen resolution is mismatched (for example, the VM display is too big to comfortably fit in the Graphical Console pane), you can control it by setting the VNC server geometry parameter as follows:

1.Open the /etc/xinetd.d/vnc file with your preferred text editor and find the service_vnc1 section (corresponding to displayID 1).

2.Edit the geometry argument in the server-argsline to the desired display resolution. For example,

server_args = :42 -inetd -once -query localhost -geometry 800x600 -depth 16 where the value of the geometry parameter can be any valid screen width and height.

3.Save and close the file.

4.Restart the VNC server:

/etc/init.d/xinetd restart rcxdm restart

D.4. Checking Runlevels

Red Hat and SUSE Linux VMs use runlevel 5 for graphical startup. This section describes how to verify that your VM is configured to start up in runlevel 5 and how to change it if it is not.

1.Check /etc/inittab to see what the default runlevel is set to. Look for the line that reads:

id:n:initdefault:

If n is not 5, edit the file to make it so.

2.You can run the command telinit q ; telinit 5 after this change to avoid having to actually reboot to switch runlevels.

67

Page 74
Image 74
Citrix Systems 6.2.0 manual Checking Runlevels, To Open the VNC Port on Sles 11.x VMs Firewall