summaryrefslogtreecommitdiffstats
path: root/glusterfsd/src/glusterfsd.h
blob: c0789b6d202c63a5b3d251db6bdaa93782c6bc7d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*
   Copyright (c) 2006-2010 Gluster, Inc. <http://www.gluster.com>
   This file is part of GlusterFS.

   GlusterFS is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published
   by the Free Software Foundation; either version 3 of the License,
   or (at your option) any later version.

   GlusterFS is distributed in the hope that it will be useful, but
   WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with this program.  If not, see
   <http://www.gnu.org/licenses/>.
*/

#ifndef __GLUSTERFSD_H__
#define __GLUSTERFSD_H__

#ifndef _CONFIG_H
#define _CONFIG_H
#include "config.h"
#endif

#include "glusterfsd-common.h"

#define DEFAULT_GLUSTERD_VOLFILE              CONFDIR "/glusterd.vol"
#define DEFAULT_CLIENT_VOLFILE                CONFDIR "/glusterfs.vol"
#define DEFAULT_SERVER_VOLFILE                CONFDIR "/glusterfsd.vol"
#define DEFAULT_LOG_FILE_DIRECTORY            DATADIR "/log/glusterfs"
#define DEFAULT_LOG_LEVEL                     GF_LOG_NORMAL

#define DEFAULT_EVENT_POOL_SIZE            16384

#define ARGP_LOG_LEVEL_NONE_OPTION        "NONE"
#define ARGP_LOG_LEVEL_TRACE_OPTION       "TRACE"
#define ARGP_LOG_LEVEL_CRITICAL_OPTION    "CRITICAL"
#define ARGP_LOG_LEVEL_ERROR_OPTION       "ERROR"
#define ARGP_LOG_LEVEL_WARNING_OPTION     "WARNING"
#define ARGP_LOG_LEVEL_NORMAL_OPTION      "NORMAL"
#define ARGP_LOG_LEVEL_DEBUG_OPTION       "DEBUG"

#define ENABLE_NO_DAEMON_MODE     1
#define ENABLE_DEBUG_MODE         1

enum argp_option_keys {
	ARGP_VOLFILE_SERVER_KEY = 's',
	ARGP_VOLUME_FILE_KEY = 'f',
	ARGP_LOG_LEVEL_KEY = 'L',
	ARGP_LOG_FILE_KEY = 'l',
	ARGP_VOLFILE_SERVER_PORT_KEY = 131,
	ARGP_VOLFILE_SERVER_TRANSPORT_KEY = 132,
	ARGP_PID_FILE_KEY = 'p',
	ARGP_NO_DAEMON_KEY = 'N',
	ARGP_RUN_ID_KEY = 'r',
	ARGP_DEBUG_KEY = 133,
	ARGP_ENTRY_TIMEOUT_KEY = 135,
	ARGP_ATTRIBUTE_TIMEOUT_KEY = 136,
	ARGP_VOLUME_NAME_KEY = 137,
	ARGP_XLATOR_OPTION_KEY = 138,
	ARGP_DIRECT_IO_MODE_KEY = 139,
#ifdef GF_DARWIN_HOST_OS
	ARGP_NON_LOCAL_KEY = 140,
#endif /* DARWIN */
	ARGP_VOLFILE_ID_KEY = 143,
        ARGP_VOLFILE_CHECK_KEY = 144,
        ARGP_VOLFILE_MAX_FETCH_ATTEMPTS = 145,
        ARGP_LOG_SERVER_KEY = 146,
        ARGP_LOG_SERVER_PORT_KEY = 147,
        ARGP_READ_ONLY_KEY = 148,
        ARGP_MAC_COMPAT_KEY = 149,
        ARGP_DUMP_FUSE_KEY = 150,
        ARGP_BRICK_NAME_KEY = 151,
        ARGP_BRICK_PORT_KEY = 152,
};

int glusterfs_mgmt_pmap_signout (glusterfs_ctx_t *ctx);
int glusterfs_mgmt_pmap_signin (glusterfs_ctx_t *ctx);
int glusterfs_volfile_fetch (glusterfs_ctx_t *ctx);


#endif /* __GLUSTERFSD_H__ */