FacetTerm  
 
FacetCorp
 

Configuring Fixed PTY's on DG


Most application packages utilize the TERM environment variable to identify what kind of terminal you are using. Some packages utilize the /etc/ttytype, /etc/ttys or alternate file for the same purpose. In these cases, you may need to utilize fixed line assignments to allow your application to identify what kind of terminal you are using. By default, FacetTerm will get the next available pseudo-devices; thus, getting random terminal types. By assigning pseudo-devices to specific terminals, this "randomness" can be avoided.

The following pages are a copy of the .facetlines.df file found in the /usr/facet directory. All instructions pertinent to your particular platform are in the .facetlines.df file.

One additional note regarding fixed line assignments on a DG/UX system: the pty numbers you utilize MUST correspond to existing pty's. If you use a number not already on your system, you will get an error message similar to the following:

   Facet process: can't open /dev/facetterm_ptm/<pts_number> 
   errno 19, assigned pty cannot be opened

If you get a message similar to this, either check to see if /dev/pts/<pts_number> actually exists (if it does not exist, creating additional pty's should correct the problem) or call FacetTerm Technical Support at the number listed in your FacetTerm manual.

NOTE: fixed line assignments can be utilized only on a few pty versions of FacetTerm. These are SCO UNIX, AIX, DG/UX and Motorola V.4. Any driver version of FacetTerm supports fixed line assignments; the instructions for driver versions of FacetTerm are detailed in the manual. Below is a list of the earliest versions of FacetTerm that support the fixed line assignments on the pty versions. Any version later than this supports the fixed line assignments.

Platform  FacetTerm 
Version
FacetTerm
Partnumber
  SCO UNIX 3.0.4   scpty.324.304
  AIX 3.1 2.3.0   rs6k.31.230
  AIX 3.2 3.3.0   rs6k.323.300
  DG/UX 3.1.1   dg.54.311
  Motorola V.4 3.2.2   m88k54.41.322
#############################################
# /usr/facet/.facetlines.df
# For DG/UX 5.4 (dg.54.311 and later)
#############################################
#
#    When FacetTerm starts, it looks for a file 
#    with the #    name ".facetlines" in:
#         1. The /etc directory.
#         2. The /usr/facet directory.
#
#    This file may be used to specify which ptys a particular
#    FacetTerm will use.
#
#    If you do not want users to be able to change the file, put 
#    ".facetlines" in the /etc directory and write protect it 
#    appropriately. Otherwise, put the file in /usr/facet.
#
#    Lines beginning with # are treated as comments.
#
#    This file consists of groups lines of the form:
#
#         1. An identifying tag line.
#
#            The "identifying tag line" must begin in column 1 and,
#            if it matches the environment variable FACETDEVICE
#            which you set and export, specifies that this group
#            of "pty assignment lines" is to be used.
#
#         2. One or more pty-assignment-lines.
#
#            The "pty assignment lines" must begin with a tab or
#            space, and specify which pty should be used for
#            a particular window.  It has 2 fields, separated by
#            tabs and/or spaces:
#         A. The window number.
#
#            The decimal number "1" through "10" for window
#            1 through 10 respectively.
#            Window 10 may also be specified as 0.
#            The extra control pty may be specified as
#            "C" or "11".
#
#         B. The master pty path name. (Since the master side
#            of the pty is normally not present on a DG 5.4
#            system, a script has been included to help
#            create them - see below.)
#
#    Any window or control pty that is not mentioned will be 
#    allocated with the normal method of finding an idle pty.
#
#    It is the users responsibility to ensure that the assigned 
#    ptys are high enough on the list that they are not allocated by
#    other FacetTerm or other programs that use ptys.
#
#    For example:
#
#         /dev/tty2
#         1     /dev/facetterm_ptm/301
#         2     /dev/facetterm_ptm/302
#         3     /dev/facetterm_ptm/303
#         4     /dev/facetterm_ptm/304
#         5     /dev/facetterm_ptm/305
#         6     /dev/facetterm_ptm/306
#         7     /dev/facetterm_ptm/307
#         8     /dev/facetterm_ptm/308
#         9     /dev/facetterm_ptm/309
#         0     /dev/facetterm_ptm/310
#         C     /dev/facetterm_ptm/311
#         sam
#         1     /dev/facetterm_ptm/316
#         3     /dev/facetterm_ptm/317
#
#    will assign ptys for all windows and control for the user
#    who sets:
#         FACETDEVICE=/dev/tty2; export FACETDEVICE
#    and will assign ptys for windows 1 and 3 for the user who sets:
#         FACETDEVICE=sam; export FACETDEVICE
#    The others will be selected by the normal method of finding an
#    idle pty.
#
#    CREATING DEVICE ENTRIES FOR THE MASTER SIDE OF THE PTY.
#
#    The master sides of the ptys are not normally present on a
#    DG 5.4 system, so they must be created in order for the
#    .facetlines file to work.
#    
#    A script "fct_makeptm" in the directory "/usr/facetterm/sys"
#    has been included to help create them.  It assumes that the
#    names of the master sides of the pty are of the form shown
#    above, i.e. /dev/facetterm_ptm/ddd where ddd corresponds
#    to the pty number.
#
#    The script removes any existing /dev/facetterm_ptm directory,
#    creates it, and then generates an entry for each line of your
#    .facetlines file.
#
#    Since the /dev directory is deleted and recreated each time
#    your system is booted, you must arrange for this script to
#    be re-run as root each time you boot.