libilb.h revision 2
1N/A * The contents of this file are subject to the terms of the 1N/A * Common Development and Distribution License (the "License"). 1N/A * You may not use this file except in compliance with the License. 1N/A * See the License for the specific language governing permissions 1N/A * and limitations under the License. 1N/A * When distributing Covered Code, include this CDDL HEADER in each 1N/A * If applicable, add the following below this CDDL HEADER, with the 1N/A * fields enclosed by brackets "[]" replaced with your own identifying 1N/A * information: Portions Copyright [yyyy] [name of copyright owner] 1N/A * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 1N/A * Use is subject to license terms. 1N/A/* make sure these values stay in sync with definitions in ilb.h! */ 1N/A * information whether we're interested in names or numerical information 1N/A * server status information 1N/A * macros to determine, and for some cases, set status of server 1N/A/* producers of these statuses are libilb and ilbd functions */ 1N/A /* that of the servers */ 1N/A /* not being used by a rule */ 1N/A/* Supported load balancing algorithm type */ 1N/A/* Supported load balancing method */ 1N/A * note: pointer to a non-existant struct 1N/A * Health check related information 1N/A/* HC state of a server */ 1N/A * Struct representing a server in a hc object 1N/A * hcs_rule_name: rule using this server 1N/A * hcs_hc_name: hc object this server is associated with 1N/A * hcs_IP: IP address of the server 1N/A * hcs_fail_cnt: number of fail hc probe 1N/A * hcs_status: hc status of the server 1N/A * hcs_rtt: (in microsec) smoothed average RTT to the server 1N/A * hcs_lasttime: last time hc test was done (as returned by time(2)) 1N/A * hcs_nexttime: next time hc test will be done (as returned by (time(2)) 1N/A/* Probe flags to be used in r_hcpflag in struct rule data. */ 1N/A * Struct representing a hc object 1N/A * hci_name: name of the hc object 1N/A * hci_test: hc test to be done, TCP, UDP, or user supplied path name 1N/A * hci_timeout: (in sec) test time out 1N/A * hci_interval: (in sec) test execution interval 1N/A * hci_def_ping: true if default ping is done; false otherwise 1N/A/* not all fields are valid in all calls where this is used */ 1N/A /* assigned by system, not user */ 1N/A * Struct to represent a server group. 1N/A * sgd_name: server group name 1N/A * sgd_srvcount: number of servers in the group (not used in sever group 1N/A * creation); filled in when used by call back function for 1N/A * ilb_walk_servergroups(). 1N/A * Struct to represent a NAT entry in kernel. 1N/A * nat_proto: transport protocol used in this NAT entry 1N/A * nat_out_global: IP address of client's request 1N/A * nat_out_global_port: port number of client's request 1N/A * nat_in_global: VIP of a rule for the NAT entry 1N/A * nat_in_global_port: port of a rule for the NAT entry 1N/A * nat_out_local: half NAT: IP address of client's request 1N/A * full NAT: NAT'ed IP addres of client' request 1N/A * nat_out_local_port: half NAT: port number of client's request 1N/A * full NAT: NAT'ed port number of client's request 1N/A * nat_in_local: IP address of back end server handling this request 1N/A * nat_in_local_port: port number in back end server handling thi request 1N/A * (*) IPv4 address is represented as IPv4 mapped IPv6 address. 1N/A * Struct to represet a persistent entry in kernel. 1N/A * rule_name: the name of rule for a persistent entry 1N/A * req_addr: the client's IP address (*) 1N/A * srv_addr: the server's IP address (*) handling the client's request 1N/A * (*) IPv4 address is represented as IPv4 mapped IPv6 address. 1N/A * Function prototype of the call back function of those walker functions. 1N/A * Note: the storage of the data item parameter (ilb_sg_data_t/ 1N/A * freed after calling the call back function. If the call back function 1N/A * needs to keep a copy of the data, it must copy the data content. 1N/A const char *,
void *);
1N/A * ilb_open creates a session handle that every caller into 1N/A * libilb needs to use 1N/A * relinquish the session handle 1N/A/* support and general functions */ 1N/A/* rule-related functions */ 1N/A/* servergroup functionality */ 1N/A const char *,
void *);
1N/A const char *,
void *);
1N/A/* functions for individual servers */ 1N/A/* health check-related functions */ 1N/A const char *,
void *);
1N/A/* To show NAT table entries of ILB */ 1N/A/* To show persistent table entries of ILB */ 1N/A#
endif /* _LIBILB_H */