1NOTIFY(3PVM) PVM Version 3.4 NOTIFY(3PVM)
2
3
4
6 pvm_notify - Request notification of PVM event such as host failure.
7
8
10 C int info = pvm_notify( int what, int msgtag, int cnt, int *tids )
11
12 Fortran call pvmfnotify( what, msgtag, cnt, tids, info )
13
14
16 what Type of event to trigger the notification. Presently one of:
17 Value Meaning
18 PvmTaskExit Task exits or is killed
19 PvmHostDelete Host is deleted or crashes
20 PvmHostAdd New host is added
21
22 msgtag Message tag to be used in notification.
23
24 cnt For PvmTaskExit and PvmHostDelete, specifies the length of the
25 tids array. For PvmHostAdd, specifies the number of times to
26 notify.
27
28 tids For PvmTaskExit and PvmHostDelete, an array of length cnt of
29 task or pvmd TIDs to be notified about. The array is not used
30 with the PvmHostAdd option.
31
32 info Integer status code returned by the routine. Values less than
33 zero indicate an error.
34
35
37 The routine pvm_notify requests PVM to notify the caller on detecting
38 certain events. One or more notify messages (see below) are sent by
39 PVM back to the calling task. The messages have tag msgtag supplied to
40 notify.
41
42 The notification messages have the following format:
43
44 PvmTaskExit
45 One notify message for each TID requested. The message body
46 contains a single TID of exited task.
47
48
49 PvmHostDelete
50 One notify message for each TID requested. The message body
51 contains a single pvmd-TID of exited pvmd.
52
53
54 PvmHostAdd
55 cnt notify messages are sent, one each time the local pvmd's
56 host table is updated. The message body contains an integer
57 length followed by a list of pvmd-TIDs of new pvmds. The
58 counter of PvmHostAdd messages yet to be sent is replaced by
59 successive calls to pvm_notify. Specifying a cnt of -1 turns on
60 PvmHostAdd messages until a future notify; a count of zero dis‐
61 ables them.
62
63 TIDs in the notify messages are packed as integers.
64
65 The calling task is responsible for receiving messages with the speci‐
66 fied tag and taking appropriate action.
67
68 Future versions of PVM may expand the list of available notification
69 events.
70
71
73 C:
74 info = pvm_notify( PvmTaskExit, 9999, ntask, tids );
75
76 Fortran:
77 CALL PVMFNOTIFY( PVMHOSTDELETE, 1111, NUMHOSTS, DTIDS, INFO )
78
79
80 To "cancel" a notify request in PVM, the pvm_notify routine can be re-
81 invoked with an additional PvmNotifyCancel flag in the what argument.
82 The remaining arguments to this cancelling invocation must match the
83 original invocation exactly, aside from the additional PvmNotifyCancel
84 which can be added(+) or OR-ed(|) to the what argument:
85
86 pvm_notify( PvmTaskExit, 9999, ntask, tids );
87
88 . . .
89
90 pvm_notify( PvmTaskExit | PvmNotifyCancel, 9999, ntask, tids );
91
92 Note that when a notify is cancelled, the notify message is delivered,
93 as if the given event (i.e. task exit, host add or delete) had
94 occurred.
95
96
98 PvmSysErr
99 pvmd not responding.
100
101 PvmBadParam
102 giving an invalid argument value.
103
105 pvm_tasks(3PVM), pvm_config(3PVM)
106
107
108
109 31 January, 1994 NOTIFY(3PVM)