ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzaha_5.4.0.1/vnc.htm

100 lines
6.1 KiB
HTML
Raw Normal View History

2024-04-02 14:02:31 +00:00
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="concept" />
<meta name="DC.Title" content="Tips on using VNC" />
<meta name="abstract" content="Use i5/OS control language (CL) commands to start and stop a Virtual Network Computing (VNC) server, and to display information about the currently running VNC servers." />
<meta name="description" content="Use i5/OS control language (CL) commands to start and stop a Virtual Network Computing (VNC) server, and to display information about the currently running VNC servers." />
<meta name="DC.Relation" scheme="URI" content="nawt.htm" />
<meta name="DC.Relation" scheme="URI" content="nawtcreatevncpassword.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="vnc" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Tips on using VNC</title>
</head>
<body id="vnc"><a name="vnc"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Tips on using VNC</h1>
<div><p>Use <span class="keyword">i5/OS™</span> control
language (CL) commands to start and stop a Virtual Network Computing (VNC)
server, and to display information about the currently running VNC servers.</p>
<div class="section"><h4 class="sectiontitle">Starting a VNC display server from a CL program</h4><p>The
following example is one way to set the DISPLAY environment variable and start
VNC automatically by using control language (CL) commands:</p>
<pre> CALL QP2SHELL PARM('/QOpenSys/QIBM/ProdData/DeveloperTools/vnc/vncserver_java' ':<em>n</em>')
ADDENVVAR ENVVAR(DISPLAY) VALUE('<em>systemname</em>:<em>n</em>')</pre>
<p>where:</p>
<ul><li><em>systemname</em> is the host name or IP address of the iSeries™ system
where VNC is running</li>
<li><em>n</em> is the numeric value that represents the display number that
you want to start</li>
</ul>
<div class="note"><span class="notetitle">Note:</span> The example assumes that you are not already running display :<em>n</em> and
that you have successfully created the required VNC password file. For more
information about creating a password file, see <a href="nawtcreatevncpassword.htm">Creating
a VNC password file</a>.</div>
</div>
<div class="section"><h4 class="sectiontitle">Stopping a VNC display server from a CL program</h4><p>The
following code shows one way to stop a VNC server from a CL program:</p>
<pre> CALL QP2SHELL PARM('/QOpenSys/QIBM/ProdData/DeveloperTools/vnc/vncserver_java' '-kill' ':<em>n</em>')</pre>
<p>where <em>n</em> is the numeric value that represents
the display number that you want to terminate.</p>
</div>
<div class="section"><h4 class="sectiontitle">Checking for running VNC display servers</h4><p>To determine
what (if any) VNC servers are currently running on an iSeries system, complete the following
steps:</p>
<ol><li>From an <span class="keyword">i5/OS</span> command
line, start a PASE shell: <pre> CALL QP2TERM</pre>
</li>
<li>From the PASE shell prompt, use the PASE <kbd class="userinput">ps</kbd> command
to list the VNC servers: <pre> ps gaxuw | grep Xvnc</pre>
</li>
</ol>
<p>The resulting output from this command will reveal running VNC servers
in the following format:</p>
<pre>
john 418 0.9 0.0 5020 0 - A Jan 31 222:26
/QOpenSys/QIBM/ProdData/DeveloperTools/vnc/Xvnc :1 -desktop X -httpd
jane 96 0.2 0.0 384 0 - A Jan 30 83:54
/QOpenSys/QIBM/ProdData/DeveloperTools/vnc/Xvnc :2 -desktop X -httpd</pre>
<p>Where:</p>
<ul><li>The first column is the profile which started the server.</li>
<li>The second column is the PASE process ID of the server.</li>
<li>The information starting with <em>/QOpensys/</em> is the command that started
the VNC server (including arguments). The display number typically is the
first item in the argument list for the Xvnc command. <p><strong>Note:</strong> The
Xvnc process, shown in the previous example output, is the name of the actual
VNC server program. You start Xvnc when you run the vncserver_java script,
which prepares the environment and parameters for Xvnc and then starts Xvnc.</p>
</li>
</ul>
</div>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="nawtcreatevncpassword.htm">Creating a VNC password file</a></strong><br />
To install and run Native Abstract Windowing Toolkit (NAWT), you need to create a Virtual Network Computing (VNC) server password file. The VNC server default setting requires a password file that it uses to protect the VNC display against unauthorized user access. You must create the VNC password file under the profile that starts the VNC server.</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="nawt.htm" title="The Native Abstract Windowing Toolkit (NAWT) provides Java applications and servlets with the capability to use the Abstract Windowing Toolkit (AWT) graphics function offered by the Java 2 Software Development Kit (J2SDK), Standard Edition.">Native Abstract Windowing Toolkit</a></div>
</div>
</div>
</body>
</html>