components/net-snmp-57/sun/agent/modules/seaExtensions/sunProcesses.h
changeset 5867 445e2cf1c845
parent 252 ee0fb1eabcbf
equal deleted inserted replaced
5866:683c5c035a79 5867:445e2cf1c845
       
     1 /*
       
     2  * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved.
       
     3  *
       
     4  * U.S. Government Rights - Commercial software. Government users are subject
       
     5  * to the Sun Microsystems, Inc. standard license agreement and applicable
       
     6  * provisions of the FAR and its supplements.
       
     7  *
       
     8  *
       
     9  * This distribution may include materials developed by third parties. Sun,
       
    10  * Sun Microsystems, the Sun logo and Solaris are trademarks or registered
       
    11  * trademarks of Sun Microsystems, Inc. in the U.S. and other countries.
       
    12  *
       
    13  */
       
    14 /*
       
    15  * Note: this file originally auto-generated by mib2c using
       
    16  *         : mib2c.iterate.conf,v 5.5 2002/12/16 22:50:18 hardaker Exp $
       
    17  */
       
    18 #ifndef SUNPROCESSES_H
       
    19 #define SUNPROCESSES_H
       
    20 
       
    21 
       
    22 /* function declarations */
       
    23 void init_sunProcesses(void);
       
    24 void initialize_table_sunProcessTable(void);
       
    25 Netsnmp_Node_Handler sunProcessTable_handler;
       
    26 
       
    27 Netsnmp_First_Data_Point  sunProcessTable_get_first_data_point;
       
    28 Netsnmp_Next_Data_Point   sunProcessTable_get_next_data_point;
       
    29 
       
    30 /* column number definitions for table sunProcessTable */
       
    31 #define COLUMN_PSPROCESSID          1
       
    32 #define COLUMN_PSPARENTPROCESSID    2
       
    33 #define COLUMN_PSPROCESSSIZE        3
       
    34 #define COLUMN_PSPROCESSCPUTIME     4
       
    35 #define COLUMN_PSPROCESSSTATE       5
       
    36 #define COLUMN_PSPROCESSWAITCHANNEL 6
       
    37 #define COLUMN_PSPROCESSTTY         7
       
    38 #define COLUMN_PSPROCESSUSERNAME    8
       
    39 #define COLUMN_PSPROCESSUSERID      9
       
    40 #define COLUMN_PSPROCESSNAME       10
       
    41 #define COLUMN_PSPROCESSSTATUS     11
       
    42 
       
    43 #define USRNM_SZ 16
       
    44 #define WCHAN_SZ 16
       
    45 #define TTYNM_SZ 16
       
    46 #define STAT_SZ 4
       
    47 #define CMD_SZ 64
       
    48 
       
    49 typedef struct ps_data_s
       
    50     {
       
    51     uid_t   uid;
       
    52     pid_t   pid;
       
    53     pid_t   ppid;
       
    54     int     sz;
       
    55     time_t  cpu;
       
    56     char    stat[STAT_SZ+1];
       
    57     char    wchan[WCHAN_SZ+1];
       
    58     char    tty[TTYNM_SZ+1];
       
    59     char    usrname[USRNM_SZ+1];
       
    60     char    cmd[CMD_SZ+1];
       
    61     } ps_data_t;
       
    62 #define PS_NULL (ps_data_t *)0
       
    63 
       
    64 typedef struct ps_ldata_s
       
    65     {
       
    66     struct ps_ldata_s        *link;
       
    67     ps_data_t                pdata;
       
    68     } ps_ldata_t;
       
    69 #define PS_LNULL (ps_ldata_t *)0
       
    70 
       
    71 extern time_t cache_now;
       
    72 extern ps_data_t *pstable;
       
    73 extern int pstable_lines;
       
    74 
       
    75 #endif /* SUNPROCESSES_H */