36
Start-Up Shell Script
The following shell script will start up the 6800 full-feature application on a Sun OpenWindows
workstation. It is recommended that the script be placed in a file called /usr/bin/StartNMS. When
setting up an X workstation, you may use the same script with minor modifications. All users must
have read and execute permission to this file (To do this, use the command
chmod 755
/usr/bin/StartNMS)
. The following line numbers provide a convenient way to subsequently
discuss the script and must not be included in an actual shell script file.
1
for i in $*
2
do
3
xhost + $i
4
done
5
xset –fp /usr/openwin/lib/fonts/nms
6
xset +fp /usr/openwin/lib/fonts/nms
7
xset fp rehash
8
xmodmap –e ’keycode 16 = F11’ \
9
-e ’keycode 18 = F12’ \
10
–e ’keycode 77 =Prior F29 KP_9’ \
11
–e ’keycode 121 = Next F35 KP_3’ \
12
–e ’keycode 75 = Home F27 KP_7’ \
13
–e ’keycode 119 = End R13 KP_1’ \
14
WRKSTN=‘uname -n‘
15
rsh -l ffw $1 “StartNMSd $WRKSTN:0 hires”
The script requires at least one argument, which is the name of the NMS host or the UIP on which
the full-feature application will run.
Lines 1 through 4 give the UIP and/or NMS host permission to connect to the workstation. If you
have a UIP, its name should be the first argument followed by the name of the NMS host. The
NMS host needs permission to support the Manage Routing Tables task for multiplexer
applications.
Lines 5 through 7 tell the workstation where to find the 6800-specific fonts. For an MIT-based X
workstation, replace /usr/openwin/lib/fonts/nms with /usr/lib/X11/fonts/nms.
Lines 8 through 13 map some of the Sun keycodes to PC-compatible key symbols required to fully
support the 6800 full-feature tasks. The keycode to keysym mappings are appropriate for a Sun-4
keyboard. Other keyboards may require different mappings. See Keyboard Mappings in this
section for more information.
Line 15 uses the
rsh
commands to remotely execute the shell script,
StartNMSd
, on the UIP
or NMS host.
StartNMSd
is installed in /usr/bin on both UIP and the NMS host. Depending on
the workstation’s operating system, you may need to replace the
rsh
command with
rcmd
or
remsh.
The
StartNMSd
script takes two arguments:
•
workstation’s display name
•
vga for 800 x 600 (or less) screen resolution or hires for higher screen resolution