corosync 3.1.7
Macros | Functions
totemconfig.c File Reference
#include <config.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <errno.h>
#include <unistd.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <ifaddrs.h>
#include <netdb.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <sys/param.h>
#include <sys/utsname.h>
#include <corosync/swab.h>
#include <qb/qblist.h>
#include <qb/qbdefs.h>
#include <libknet.h>
#include <corosync/totem/totem.h>
#include <corosync/logsys.h>
#include <corosync/icmap.h>
#include "util.h"
#include "totemconfig.h"
Include dependency graph for totemconfig.c:

Go to the source code of this file.

Macros

#define TOKEN_RETRANSMITS_BEFORE_LOSS_CONST   4
 
#define TOKEN_TIMEOUT   3000
 
#define TOKEN_WARNING   75
 
#define TOKEN_COEFFICIENT   650
 
#define JOIN_TIMEOUT   50
 
#define MERGE_TIMEOUT   200
 
#define DOWNCHECK_TIMEOUT   1000
 
#define FAIL_TO_RECV_CONST   2500
 
#define SEQNO_UNCHANGED_CONST   30
 
#define MINIMUM_TIMEOUT   (int)(1000/HZ)*3
 
#define MINIMUM_TIMEOUT_HOLD   (int)(MINIMUM_TIMEOUT * 0.8 - (1000/HZ))
 
#define MAX_NETWORK_DELAY   50
 
#define WINDOW_SIZE   50
 
#define MAX_MESSAGES   17
 
#define MISS_COUNT_CONST   5
 
#define BLOCK_UNLISTED_IPS   1
 
#define CANCEL_TOKEN_HOLD_ON_RETRANSMIT   0
 
#define UDP_NETMTU   1500
 
#define KNET_PING_INTERVAL   1000
 
#define KNET_PING_TIMEOUT   2000
 
#define KNET_PING_PRECISION   2048
 
#define KNET_PONG_COUNT   2
 
#define KNET_PMTUD_INTERVAL   30
 
#define KNET_MTU   0
 
#define KNET_DEFAULT_TRANSPORT   KNET_TRANSPORT_UDP
 
#define DEFAULT_PORT   5405
 

Functions

void totem_volatile_config_read (struct totem_config *totem_config, icmap_map_t temp_map, const char *deleted_key)
 
int totem_volatile_config_validate (struct totem_config *totem_config, icmap_map_t temp_map, const char **error_string)
 
int totem_config_read (struct totem_config *totem_config, const char **error_string, uint64_t *warnings)
 
int totem_config_validate (struct totem_config *totem_config, const char **error_string)
 
int totem_config_keyread (struct totem_config *totem_config, icmap_map_t map, const char **error_string)
 
int totem_reread_crypto_config (struct totem_config *totem_config, icmap_map_t map, const char **error_string)
 
int totemconfig_configure_new_params (struct totem_config *totem_config, icmap_map_t map, const char **error_string)
 
void totemconfig_commit_new_params (struct totem_config *totem_config, icmap_map_t map)
 

Macro Definition Documentation

◆ BLOCK_UNLISTED_IPS

#define BLOCK_UNLISTED_IPS   1

Definition at line 83 of file totemconfig.c.

◆ CANCEL_TOKEN_HOLD_ON_RETRANSMIT

#define CANCEL_TOKEN_HOLD_ON_RETRANSMIT   0

Definition at line 84 of file totemconfig.c.

◆ DEFAULT_PORT

#define DEFAULT_PORT   5405

Definition at line 97 of file totemconfig.c.

◆ DOWNCHECK_TIMEOUT

#define DOWNCHECK_TIMEOUT   1000

Definition at line 74 of file totemconfig.c.

◆ FAIL_TO_RECV_CONST

#define FAIL_TO_RECV_CONST   2500

Definition at line 75 of file totemconfig.c.

◆ JOIN_TIMEOUT

#define JOIN_TIMEOUT   50

Definition at line 72 of file totemconfig.c.

◆ KNET_DEFAULT_TRANSPORT

#define KNET_DEFAULT_TRANSPORT   KNET_TRANSPORT_UDP

Definition at line 95 of file totemconfig.c.

◆ KNET_MTU

#define KNET_MTU   0

Definition at line 94 of file totemconfig.c.

◆ KNET_PING_INTERVAL

#define KNET_PING_INTERVAL   1000

Definition at line 89 of file totemconfig.c.

◆ KNET_PING_PRECISION

#define KNET_PING_PRECISION   2048

Definition at line 91 of file totemconfig.c.

◆ KNET_PING_TIMEOUT

#define KNET_PING_TIMEOUT   2000

Definition at line 90 of file totemconfig.c.

◆ KNET_PMTUD_INTERVAL

#define KNET_PMTUD_INTERVAL   30

Definition at line 93 of file totemconfig.c.

◆ KNET_PONG_COUNT

#define KNET_PONG_COUNT   2

Definition at line 92 of file totemconfig.c.

◆ MAX_MESSAGES

#define MAX_MESSAGES   17

Definition at line 81 of file totemconfig.c.

◆ MAX_NETWORK_DELAY

#define MAX_NETWORK_DELAY   50

Definition at line 79 of file totemconfig.c.

◆ MERGE_TIMEOUT

#define MERGE_TIMEOUT   200

Definition at line 73 of file totemconfig.c.

◆ MINIMUM_TIMEOUT

#define MINIMUM_TIMEOUT   (int)(1000/HZ)*3

Definition at line 77 of file totemconfig.c.

◆ MINIMUM_TIMEOUT_HOLD

#define MINIMUM_TIMEOUT_HOLD   (int)(MINIMUM_TIMEOUT * 0.8 - (1000/HZ))

Definition at line 78 of file totemconfig.c.

◆ MISS_COUNT_CONST

#define MISS_COUNT_CONST   5

Definition at line 82 of file totemconfig.c.

◆ SEQNO_UNCHANGED_CONST

#define SEQNO_UNCHANGED_CONST   30

Definition at line 76 of file totemconfig.c.

◆ TOKEN_COEFFICIENT

#define TOKEN_COEFFICIENT   650

Definition at line 71 of file totemconfig.c.

◆ TOKEN_RETRANSMITS_BEFORE_LOSS_CONST

#define TOKEN_RETRANSMITS_BEFORE_LOSS_CONST   4

Definition at line 68 of file totemconfig.c.

◆ TOKEN_TIMEOUT

#define TOKEN_TIMEOUT   3000

Definition at line 69 of file totemconfig.c.

◆ TOKEN_WARNING

#define TOKEN_WARNING   75

Definition at line 70 of file totemconfig.c.

◆ UDP_NETMTU

#define UDP_NETMTU   1500

Definition at line 86 of file totemconfig.c.

◆ WINDOW_SIZE

#define WINDOW_SIZE   50

Definition at line 80 of file totemconfig.c.

Function Documentation

◆ totem_config_keyread()

int totem_config_keyread ( struct totem_config totem_config,
icmap_map_t  map,
const char **  error_string 
)

◆ totem_config_read()

int totem_config_read ( struct totem_config totem_config,
const char **  error_string,
uint64_t *  warnings 
)

◆ totem_config_validate()

int totem_config_validate ( struct totem_config totem_config,
const char **  error_string 
)

◆ totem_reread_crypto_config()

int totem_reread_crypto_config ( struct totem_config totem_config,
icmap_map_t  map,
const char **  error_string 
)

Definition at line 2289 of file totemconfig.c.

◆ totem_volatile_config_read()

void totem_volatile_config_read ( struct totem_config totem_config,
icmap_map_t  temp_map,
const char *  deleted_key 
)

Definition at line 311 of file totemconfig.c.

◆ totem_volatile_config_validate()

int totem_volatile_config_validate ( struct totem_config totem_config,
icmap_map_t  temp_map,
const char **  error_string 
)

◆ totemconfig_commit_new_params()

void totemconfig_commit_new_params ( struct totem_config totem_config,
icmap_map_t  map 
)

Definition at line 2417 of file totemconfig.c.

References INTERFACE_MAX, and totem_config::interfaces.

Referenced by main_iface_change_fn().

◆ totemconfig_configure_new_params()

int totemconfig_configure_new_params ( struct totem_config totem_config,
icmap_map_t  map,
const char **  error_string 
)

Definition at line 2394 of file totemconfig.c.