pacemaker  2.1.0-7c3f660
Scalable High-Availability cluster resource manager
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
options.c File Reference
#include <crm_internal.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <crm/crm.h>
Include dependency graph for options.c:

Go to the source code of this file.

Macros

#define _GNU_SOURCE
 

Functions

void pcmk__cli_option_cleanup ()
 
void pcmk__set_cli_options (const char *short_options, const char *app_usage, pcmk__cli_option_t *long_options, const char *app_desc)
 
int pcmk__next_cli_option (int argc, char **argv, int *index, const char **longname)
 
void pcmk__cli_help (char cmd, crm_exit_t exit_code)
 
const char * pcmk__env_option (const char *option)
 
void pcmk__set_env_option (const char *option, const char *value)
 Set or unset a Pacemaker environment variable option. More...
 
bool pcmk__env_option_enabled (const char *daemon, const char *option)
 
bool pcmk__valid_interval_spec (const char *value)
 
bool pcmk__valid_boolean (const char *value)
 
bool pcmk__valid_number (const char *value)
 
bool pcmk__valid_positive_number (const char *value)
 
bool pcmk__valid_quorum (const char *value)
 
bool pcmk__valid_script (const char *value)
 
bool pcmk__valid_utilization (const char *value)
 
const char * pcmk__cluster_option (GHashTable *options, pcmk__cluster_option_t *option_list, int len, const char *name)
 
void pcmk__print_option_metadata (const char *name, const char *version, const char *desc_short, const char *desc_long, pcmk__cluster_option_t *option_list, int len)
 
void pcmk__validate_cluster_options (GHashTable *options, pcmk__cluster_option_t *option_list, int len)
 

Macro Definition Documentation

#define _GNU_SOURCE

Definition at line 11 of file options.c.

Function Documentation

void pcmk__cli_help ( char  cmd,
crm_exit_t  exit_code 
)

Definition at line 192 of file options.c.

void pcmk__cli_option_cleanup ( void  )

Definition at line 39 of file options.c.

const char* pcmk__cluster_option ( GHashTable *  options,
pcmk__cluster_option_t option_list,
int  len,
const char *  name 
)

Definition at line 537 of file options.c.

const char* pcmk__env_option ( const char *  option)

Definition at line 285 of file options.c.

bool pcmk__env_option_enabled ( const char *  daemon,
const char *  option 
)

Definition at line 355 of file options.c.

int pcmk__next_cli_option ( int  argc,
char **  argv,
int *  index,
const char **  longname 
)

Definition at line 147 of file options.c.

void pcmk__print_option_metadata ( const char *  name,
const char *  version,
const char *  desc_short,
const char *  desc_long,
pcmk__cluster_option_t option_list,
int  len 
)

Definition at line 556 of file options.c.

void pcmk__set_cli_options ( const char *  short_options,
const char *  app_usage,
pcmk__cli_option_t long_options,
const char *  app_desc 
)

Definition at line 105 of file options.c.

void pcmk__set_env_option ( const char *  option,
const char *  value 
)

Set or unset a Pacemaker environment variable option.

Set an environment variable option with both a PCMK_ and (for backward compatibility) HA_ prefix.

Parameters
[in]optionEnvironment variable name (without prefix)
[in]valueNew value (or NULL to unset)

Definition at line 318 of file options.c.

bool pcmk__valid_boolean ( const char *  value)

Definition at line 375 of file options.c.

bool pcmk__valid_interval_spec ( const char *  value)

Definition at line 368 of file options.c.

bool pcmk__valid_number ( const char *  value)

Definition at line 383 of file options.c.

bool pcmk__valid_positive_number ( const char *  value)

Definition at line 397 of file options.c.

bool pcmk__valid_quorum ( const char *  value)

Definition at line 406 of file options.c.

bool pcmk__valid_script ( const char *  value)

Definition at line 412 of file options.c.

bool pcmk__valid_utilization ( const char *  value)

Definition at line 439 of file options.c.

void pcmk__validate_cluster_options ( GHashTable *  options,
pcmk__cluster_option_t option_list,
int  len 
)

Definition at line 594 of file options.c.