r23785: use the GPLv3 boilerplate as recommended by the FSF and the license text
[ira/wip.git] / pcp / README
1 samba PMDA
2 ===========
3
4 This PMDA is a sample that illustrates how a simple samba monitor
5 PMDA might be constructed, using a shared memory segment to transfer
6 information about transaction activity from the smb daemon.
7
8 Note:
9         This PMDA may be remade from source and hence requires 
10         a C compiler and Perl to be installed.
11
12         Uses of make(1) may fail (without removing or clobbering files)
13         if the C compiler cannot be found.  This is most likely to
14         happen when running the PMDA ./Install script.
15
16         The only remedial action is to install the C compiler, or
17         hand-craft changes to the Makefile.
18
19 Metrics
20 =======
21
22 The file ./help contains descriptions for all of the metrics exported
23 by this PMDA.
24
25 Once the PMDA has been installed, the following command will list all
26 the available metrics and their explanatory "help" text:
27
28         $ pminfo -fT samba
29
30 Installation
31 ============
32
33  +  # mkdir /var/pcp/pmdas/samba
34  +  # cp * /var/pcp/pmdas/samba
35  +  # cp ../source/include/profile.h /var/pcp/pmdas/samba
36  +  # cd /var/pcp/pmdas/samba
37
38  +  Check that there is no clash in the Performance Metrics Domain
39     defined in ./domain.h and the other PMDAs currently in use
40     (/etc/pmcd.conf).  If there is, edit ./domain.h to choose another
41     domain number.
42
43  +  If you are not installing on an IRIX system, edit samba.c and
44     comment out the 
45
46         #define IRIX 1
47
48  +  Then simply use
49
50         # ./Install
51
52  +  Alternatively, to install just the Performance Metrics Name Space
53     for the samba metrics on the local system, but not the samba PMDA
54     (presumably because the local system is running PCP 1.x and you
55     wish to connect to a remote system where PCP 2.0 and the samba PMDA
56     is running), make sure the Performance Metrics Domain defined in
57     ./domain.h matches the domain chosen for the samba PMDA on the
58     remote system (check the second field in the corresponding line of
59     the pmcd.conf file on the remote system - located in /etc on IRIX
60     and /var/pcp/config/pmcd on Linux), then
61
62         # ./Install -N
63
64 De-installation
65 ===============
66
67  +  Simply use
68
69         # cd /var/pcp/pmdas/samba
70         # ./Remove
71
72  +  If you also want to remove the sources use
73
74         # cd /
75         # rm -rf /var/pcp/pmdas/samba
76
77 Making something happen
78 =======================
79
80 The application "smbd" updates the shared memory segment to add
81 profile information about smbd. By default updating is disabled.
82 To start updating of the shared memory segment you need to run the
83 smbcontrol command to turn on profiling for one or more smbd processes
84 (see the man page for smbcontrol).
85
86
87
88 Troubleshooting
89 ===============
90
91  +  After installing or restarting the agent, the PMCD log file
92     (pmcd.log) and the PMDA log file (samba.log) should be checked 
93     for any warnings or errors. These logs are located in 
94     /var/log/pcp/pmcd on Linux and /var/adm/pcplog on IRIX.