HP DL385 XenServer Virtual Machine Installation 4.1.0 - Page 30

Modifying the xinetd configuration, 4.8.2.4. Firewall settings

Page 30 highlights

Installing Linux VMs 7. The original top-level menu of YaST appears. Tab to the Quit button and press Enter. 4.8.2.3. Modifying the xinetd configuration After enabling Remote Administration, you need to modify a configuration file if you want to allow XenCenter to connect, or else use a third party VNC client. 1. Open the file /etc/xinetd.d/vnc in your preferred text editor. The file contains sections like the following: service vnc1 { socket_type = stream protocol = tcp wait = no user = nobody server = /usr/X11R6/bin/Xvnc server_args = :42 -inetd -once -query localhost -geometry 1024x768 -depth 16 type = UNLISTED port = 5901 } 2. Edit the port line to read port = 5900 3. Save and close the file. 4. Restart the display manager and xinetd service with the following commands: /etc/init.d/xinetd restart rcxdm restart SUSE Linux uses runlevel 5 for graphical startup. If your remote desktop does not appear, verify that your VM is configured to start up in runlevel 5. Refer to Section 4.8.4, "Checking runlevels" for details. 4.8.2.4. Firewall settings The firewall configuration by default does not allow VNC to traffic to go through. If you have a firewall between the VM and XenCenter, you need to allow traffic over the port that the VNC connection uses. By default, a VNC server listens for connections from a VNC viewer on TCP port 5900 + N, where N is the display number (usually just zero). So a VNC server setup for Display-0 will listen on TCP port 5900, Display-1 is TCP-5901, etc. Consult your firewall documentation to make sure these ports are open. You might want to further customize your firewall configuration if you want to use IP connection tracking or limit the initiation of connections to be from one side only. Procedure 4.7. To customize SLES-based VMs firewall to open the VNC port 1. Open a text console on the VM and run the YaST utility: 25

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44

Installing Linux VMs
25
7.
The original top-level menu of YaST appears.
Tab
to the Quit button and press
Enter
.
4.8.2.3. Modifying the xinetd configuration
After enabling Remote Administration, you need to modify a configuration file if you want to allow XenCenter
to connect, or else use a third party VNC client.
1.
Open the file
/etc/xinetd.d/vnc
in your preferred text editor.
The file contains sections like the following:
service vnc1
{
socket_type = stream
protocol
= tcp
wait
= no
user
= nobody
server
= /usr/X11R6/bin/Xvnc
server_args = :42 -inetd -once -query localhost -geometry 1024x768 -depth 16
type
= UNLISTED
port
= 5901
}
2.
Edit the
port
line to read
port = 5900
3.
Save and close the file.
4.
Restart the display manager and xinetd service with the following commands:
/etc/init.d/xinetd restart
rcxdm restart
SUSE Linux uses runlevel 5 for graphical startup. If your remote desktop does not appear, verify that your
VM is configured to start up in runlevel 5. Refer to Section 4.8.4, “Checking runlevels” for details.
4.8.2.4. Firewall settings
The firewall configuration by default does not allow VNC to traffic to go through. If you have a firewall between
the VM and XenCenter, you need to allow traffic over the port that the VNC connection uses. By default,
a VNC server listens for connections from a VNC viewer on TCP port 5900 + N, where N is the display
number (usually just zero). So a VNC server setup for Display-0 will listen on TCP port 5900, Display-1 is
TCP-5901, etc. Consult your firewall documentation to make sure these ports are open.
You might want to further customize your firewall configuration if you want to use IP connection tracking or
limit the initiation of connections to be from one side only.
Procedure 4.7. To customize SLES-based VMs firewall to open the VNC port
1.
Open a text console on the VM and run the YaST utility: