diff options
Diffstat (limited to 'glusterfsd/src')
| -rw-r--r-- | glusterfsd/src/glusterfsd.c | 10 | ||||
| -rw-r--r-- | glusterfsd/src/glusterfsd.h | 2 | 
2 files changed, 12 insertions, 0 deletions
diff --git a/glusterfsd/src/glusterfsd.c b/glusterfsd/src/glusterfsd.c index fa4e1a0054f..cf486d84f7e 100644 --- a/glusterfsd/src/glusterfsd.c +++ b/glusterfsd/src/glusterfsd.c @@ -163,6 +163,8 @@ static struct argp_option gf_options[] = {          {"attribute-timeout", ARGP_ATTRIBUTE_TIMEOUT_KEY, "SECONDS", 0,           "Set attribute timeout to SECONDS for inodes in fuse kernel module "           "[default: 1]"}, +        {"dump-fuse", ARGP_DUMP_FUSE_KEY, "PATH", 0, +         "Dump fuse traffic to PATH"},          {"volfile-check", ARGP_VOLFILE_CHECK_KEY, 0, 0,           "Enable strict volume file checking"},          {0, 0, 0, 0, "Miscellaneous Options:"}, @@ -338,6 +340,10 @@ _add_fuse_mount (xlator_t *graph)                  ret = dict_set_int32 (top->options, ZR_STRICT_VOLFILE_CHECK,                                        cmd_args->volfile_check); +        if (cmd_args->dump_fuse) +                ret = dict_set_static_ptr (top->options, ZR_DUMP_FUSE, +                                           cmd_args->dump_fuse); +  #ifdef GF_DARWIN_HOST_OS          /* On Darwin machines, O_APPEND is not handled,           * which may corrupt the data @@ -1001,6 +1007,10 @@ parse_opts (int key, char *arg, struct argp_state *state)                  cmd_args->mount_point = gf_strdup (arg);                  break; + +        case ARGP_DUMP_FUSE_KEY: +                cmd_args->dump_fuse = gf_strdup (arg); +                break;          }          return 0; diff --git a/glusterfsd/src/glusterfsd.h b/glusterfsd/src/glusterfsd.h index ec068ec00c2..929e27d7037 100644 --- a/glusterfsd/src/glusterfsd.h +++ b/glusterfsd/src/glusterfsd.h @@ -51,6 +51,7 @@  #define ZR_ENTRY_TIMEOUT_OPT    "entry-timeout"  #define ZR_DIRECT_IO_OPT        "direct-io-mode"  #define ZR_STRICT_VOLFILE_CHECK "strict-volfile-check" +#define ZR_DUMP_FUSE            "dump-fuse"  enum argp_option_keys {  	ARGP_VOLFILE_SERVER_KEY = 's',  @@ -79,6 +80,7 @@ enum argp_option_keys {          ARGP_LOG_SERVER_PORT_KEY = 147,          ARGP_READ_ONLY_KEY = 148,          ARGP_MAC_COMPAT_KEY = 149, +        ARGP_DUMP_FUSE_KEY = 150,  };  /* Moved here from fetch-spec.h */  | 
