This chapter discusses how you configure a session manager. Topics include:
If you have CDE installed on your host, you can use dtlogin as your
X session manager. Otherwise, use whichever X session manager is available
to you:
vuelogin.
These products use similar processes; for example, both communicate
with X stations by using XDMCP (X Display Manager Control Protocol).
Dtlogin or vuelogin can run either an HP VUE environment, or
an XDM mode in which it runs a user's .xsession script.
If you are upgrading from a previous version of the software
and were running XDM, the default is XDM mode.
If you still wish to run XDM instead, the 7.0 software
contains the X11R5 version of XDM. For more information, refer to
Starting XDM.
scologin as their session manager. Refer to
Configuring scologin on SCO Systems.
You can specify
colors, fonts, and other application defaults in the
.Xdefaults file.
If you do not have an
.Xdefaults file in your home directory, copy one of the following files:
cp /usr/lib/X11/sys.Xdefaults $HOME/.Xdefaults
cp /etc/dt/appconfig/C/sys.resources $HOME/.Xdefaults
cp /usr/openwin/lib/Xdefaults $HOME/.Xdefaults
The values that you specify in
the .Xdefaults file override the values specified in the
/usr/lib/X11/app-defaults directory.
No matter which X session management program is available on your system, XDMCP is the underlying mechanism that makes the login process automatic.
By default, HP X stations are configured to
use [XDMCP Direct] as their startup mode,
and the default X session server is the file server.
However, you can configure the X station to any of four types of XDMCP
operation:
dtlogin; not available with some versions of vuelogin)
You can change the default X session server in the remote configuration file
or from the [Server] configuration screen.
If you choose XDMCP Direct to host(s) or Indirect, you must also specify the host name or IP address of the X session server.
If there are several hosts that the X station could use, you can specify
these host names in the [Login Host] field as a comma-separated list. If
the first host on the list times out or does not respond,
the request will be sent to each host in sequence
until a connection can be made.
If you want to log into a remote host (one that is outside of a gateway), follow these steps:
[Server] configuration screen, select [XDMCP Direct].
Login Host
[OK].
Alternatively, you can specify a remote host from the Select Session Manager screen:
Select Session Manager screen, click on the [Direct] button.
Host Address (Name) field with the IP address or host name of
the host you want to log into.
[Connect].
Select Session Manager screen
along with the number of users logged in and
the host load for each computer over the last 1, 5, and 15
minute periods.
(If the host is running HP VUE Version 2,
only the computer's hostname is displayed, not the host load.)
To choose the host, click on the host name, then on [OK].
If you want to shorten the list of hosts displayed,
list the hosts to which you normally connect in the [Login Host] field.
If you want to log in to a host that is across a gateway, follow these steps:
Select Session Manager screen, click on the [Direct] button.
Host Address (Name) field with the IP address or the
host name of the host you want to log into.
[Connect].
Note that the indirect request applies to XDM and dtlogin,
and is not available with some versions of
vuelogin.
Login Host field on the [Server]
configuration screen.
If no host is specified in the Login Host field,
the request is sent to all
hosts listed on the Select Session Manager screen. The first host
to respond automatically gets the connection.
This feature helps to balance the
load across all available hosts (if your system administrator has set up the
hosts to do so).
This section contains the following topics:
Dtlogin can run in XDM mode, which gives users an XDM session. By default, users get a dtlogin session.
If you want dtlogin to run in XDM mode for some users, complete the following steps:
/etc/dt/config/Xconfig.
dtlogin to read users' .xsession file,
as superuser, edit the Xconfig file.
Dtlogin*xdmMode: TrueYou can choose to run XDM-style X sessions for selected displays by replacing the
* with .terminalname_0.)
for the X stations:
Dtlogin.terminalname_0.xdmMode: True
For example, the X station in the accounting department
that has the terminal name acctsmith would be listed as:
Dtlogin.acctsmith_0.xdmMode: True
dtlogin in XDM-mode, you
can override this option at login time.
Vuelogin can run in XDM mode, which gives users an XDM session. By default, users get an HP VUE session.
If you want vuelogin to run in XDM mode for some users, complete the following steps:
/usr/vue/config/Xconfig.
vuelogin to read users' .xsession file,
as superuser, edit the Xconfig file.
Vuelogin*xdmMode: TrueYou can choose to run XDM-style X sessions for selected displays by replacing the
* with .terminalname_0.)
for the X stations:
Vuelogin.terminalname_0.xdmMode: True
For example, the X station in the accounting department
that has the terminal name acctsmith would be listed as:
Vuelogin.acctsmith_0.xdmMode: True
vuelogin in XDM-mode, you
can override this option at login time.
vuelogin,
you can bypass the login screen and automatically start a
specified user's X session at login.
To do this,
complete the following steps:
Xaccess file: /usr/vue/config/Xaccess.
Xaccess lines similar to the following:
display BYPASS_LOGIN loginname.
For example:
xterm1 BYPASS_LOGIN ksmith
xterm1 reboots or resets,
it automatically runs an X session for user ksmith.
Dtlogin and vuelogin provide an access control
list (Xaccess) that prevents an X station or a range of X stations
from receiving X session management services from the host computer.
The access control list is in
/usr/vue/config/Xaccess for vuelogin, or
/etc/dt/config/Xaccess for dtlogin.
The host computer can receive a direct or a broadcast request for X session management from X stations. To set up Xaccess to control direct and broadcast requests from X stations, use the following syntax:
!terminalname to refuse to manage an X station
? to represent any single character
* to represent any number of characters.
Xaccess:
*
xterm1 and xterm2,
put the following lines in Xaccess:
xterm1 xterm2
xterm8,
put the following lines in Xaccess:
!xterm8 *
For information about running XDM, refer to the following sections:
To run XDM as the session manager (instead of vuelogin or dtlogin), do the following:
XDM Administration from the main menu.
Start XDM from the XDM administration menu.
On HP-UX systems, if you prefer to update files manually, you can set up XDM as follows:
/etc/inittab:
xd:234:respawn:/usr/bin/X11/xdm -nodaemon < /dev/null > /dev/null 2>&1
For HP-UX 10.x, replace /usr/bin/X11/xdm with
/opt/hpxt/enware/xdm/xdm.
dt: (for dtlogin)
or vue (for vuelogin), and use the # character to comment it out.
For example:
#vue :34:respawn:/etc/vuerc # VUE validation and invocation
xdm directory is
context-dependent. To use XDM on
a diskless workstation, you need to edit the files in this
directory so that they have appropriate context. The files are located in:
/usr/lib/X11/xdm
To each node's /etc/inittab file, add the following line:
xd:234:respawn:/usr/bin/X11/xdm -nodaemon < /dev/null > /dev/null 2>&1
You get to the XDM administration menu as follows:
XDM Administration from the main menu.
The XDM administration menu contains options such as:
This script modifies the Xsession file.
XDM bypasses /etc/securetty, a file which you can create
to limit the X stations where a root login can occur.
Use this option periodically to trim the
xdm-errors file.
For HP-UX 10.x systems, the error log is a temporary file /tmp/xdm-errors,
but you may still want to trim it periodically.
The X11R5 version of XDM provides an access control
list (Xaccess) that prevents an X station or a range of X stations
from receiving X session management services from the host computer.
For the host computer, there are two types of X session management requests: a request for the host to manage a particular X station (which could be either a direct or a broadcast request) and a request for the host to provide the X station with a list of willing hosts (which is an indirect request).
!terminalname to refuse to manage that X station
? to represent any single character
* to represent any number of characters.
CHOOSER %hostlistand use the "chooser" process to relay the X station's request to the appropriate hosts.
Xaccess:
*
xterm1 and xterm2,
put the following lines in Xaccess:
xterm1 xterm2
xterm8,
put the following lines in Xaccess:
!xterm8 *
xterm1 through xterm9 (as represented by the ? wildcard)
but not from xterm6, put the following lines in Xaccess:
%hosts hp720_1 hp720_3 hp750 !xterm6 dummy xterm? CHOOSER %hosts *
/usr/lib/X11/xdm/Xaccess
For HP-UX 10.x systems: /opt/hpxt/enware/xdm/Xaccess
Xaccess lines similar to the following:
display BYPASS_LOGIN loginname
For example:
xterm1 BYPASS_LOGIN ksmith
xterm1 reboots or resets, it automatically runs
$HOME/.xsession
for user ksmith.
The X server classname is used by XDM as part of the XDMCP
protocol. By adding the X server classname to a resource listed in
the Xconfig file, you can set
a resource to affect a specific class of X stations.
The Xconfig file is usually: /usr/lib/X11/xdm/Xconfig
For HP-UX 10.x systems, the file is: /opt/hpxt/enware/xdm/Xconfig
The X server classname is:
Hewlett_Packard_Company-CxxxxA
where CxxxxA is the X station hardware model number.
You can
find the hardware model number by accessing the configuration screens
and selecting
[Diagnostics] and then Installed Configuration.
Insert the classname between the resource name and the final
resource name segment. For example:
DisplayManager.Hewlett_Packard_Company-C2731A.startup
If you are using the Korn shell or the Bourne shell and you wish to set up a restricted shell environment for your users, refer to the comments and code in the following files:
/usr/vue/config/Xsession
/usr/lib/X11/xdm/Xsession
For HP-UX 10.x systems, refer to:
/opt/hpxt/enware/xdm/Xsession
The X session manager available on SCO UNIX systems is called scologin. This section describes:
To run scologin as the session manager, do the following:
scologin Administration from the main menu.
scologin , or a startup method appropriate for your system.
The script scologin begins by running /usr/lib/X11/scologin/Xsession.
Xsession attempts to run the .xsession script in the
user's home directory.
Unedited, .xsession starts an
scoterm window, the mwm window manager, and an X.desktop or
Desktop window. .xsession can be customized for each user.
If .xsession is not found, Xsession attempts to run
the .startxrc script in the user's home directory; otherwise,
it defaults to /usr/lib/X11/sys.startxrc, which starts
an odtterm window and an icon manager window.
If you type xdt3 & in the terminal emulator window, you
get an X.desktop or Desktop window.
.xsession file in the user's
home directory. However, if there is an
.xsession file in the user's home directory, logging in through
scologin on the console may cause unwanted results,
since Xsession bypasses
the startx routine which configures the console. From the console,
either log in as another user (root) or disable scologin.
scologin logs out the user when $HOME/.xsession, $HOME/.startxrc
or /usr/lib/X11/sys.startxrc
runs to completion.
The foreground task, that is,
the first client that does not have a & at the end of its
command line, is the last client started by the
startup script.
Therefore when the user closes the foreground task, mwm in the
default .startxrc script and scoterm in the .xsession script,
scologin logs the user out.