Killing A Process; Creating Scripts - DEC Digital Alpha VME 4/224 User Manual

Table of Contents

Advertisement

>>> ps
ID
PCB
Pri CPU Time Affinity CPU Program
-------- -------- --- -------- -------- --- ---------- ----------------------
0000006c 001423a0 3
0000005c 00144b40 2
0000005b 00147a60 2
00000059 0014c060 2
00000058 0014edc0 2
00000056 00152860 2
00000055 00153ae0 2
00000054 00181580 2
0000004f 00154d60 5
.
.
.
>>> ps | grep exer
00000056 00152860 2
00000055 00153ae0 2

12.7.2 Killing a Process

To stop a process, use the process ID that you get from using the ps command as
the argument of the kill command.
>>> ps | grep memtest
0000005c 00144b40 2
00000059 0014c060 2
>>> kill 59
>>> ps | grep memtest
0000005c 00144b40 2

12.8 Creating Scripts

A script is a file that contains console commands, similar to an OpenVMS
command file. The console firmware contains many scripts, such as the powerup
script, that you can run by typing the name of the script file.
If you have a complex command or a series of commands that you have to use
frequently, you can write a script for your convenience. Use the echo command
and the output creation operator, >, to write characters to a file. The file is the
script. The following example creates the foo script, containing the examine
command.
>>> echo e pmem:3fff000 > foo
>>> cat foo
e pmem:3fff000
>>> foo
pmem:
3FFF000 0000000000000000
12–14 Console Primer
# Display complete process status.
2 00000001 0
19253 00000001 0
9 00000001 0
21750 00000001 0
5 00000001 0
3 00000001 0
exer_kid waiting on mscp_rsp
2 00000001 0
6 00000001 0
38 ffffffff 0
pke0_poll waiting on tqe
# Check exer.
6 00000001 0
exer_kid waiting on mscp_rsp
2 00000001 0
# Find a process to kill.
135733 00000001 0
138258 00000001 0
# Kill one of the memtests.
# Display our background tasks.
135733 00000001 0
# Write "e 0" to file foo.
# List foo.
# Execute script foo.
State
ps running
memtest ready
sh_bg waiting on 00144B40
memtest ready
sh_bg waiting on 0014C060
exer waiting on exer_tqe
sh_bg waiting on 00153AE0
exer waiting on exer_tqe
memtest ready
memtest ready
memtest ready

Advertisement

Table of Contents
loading

This manual is also suitable for:

Digital alpha vme 4/288

Table of Contents