diff options
| -rw-r--r-- | cli/src/cli.h | 2 | ||||
| -rw-r--r-- | doc/examples/protocol-client.vol | 4 | ||||
| -rw-r--r-- | doc/examples/protocol-server.vol | 4 | ||||
| -rw-r--r-- | doc/examples/replicate.vol | 12 | ||||
| -rw-r--r-- | doc/examples/stripe.vol | 12 | ||||
| -rw-r--r-- | doc/examples/unify.vol | 16 | ||||
| -rw-r--r-- | doc/glusterd.vol | 3 | ||||
| -rw-r--r-- | doc/glusterfs-volgen.8 | 2 | ||||
| -rw-r--r-- | doc/glusterfs.vol.sample | 4 | ||||
| -rw-r--r-- | doc/glusterfsd.vol.sample | 4 | ||||
| -rw-r--r-- | doc/mount.glusterfs.8 | 5 | ||||
| -rw-r--r-- | doc/user-guide/user-guide.info | 12 | ||||
| -rw-r--r-- | doc/user-guide/user-guide.texi | 12 | ||||
| -rw-r--r-- | extras/volgen/CreateVolfile.py | 4 | ||||
| -rw-r--r-- | glusterfsd/src/glusterfsd-mgmt.c | 2 | ||||
| -rw-r--r-- | libglusterfs/src/globals.h | 2 | ||||
| -rw-r--r-- | rpc/rpc-lib/src/rpcsvc.h | 2 | ||||
| -rw-r--r-- | rpc/rpc-transport/rdma/src/rdma.h | 4 | ||||
| -rw-r--r-- | rpc/rpc-transport/socket/src/socket.h | 3 | ||||
| -rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-handler.c | 4 | ||||
| -rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-pmap.c | 4 | ||||
| -rw-r--r-- | xlators/mgmt/glusterd/src/glusterd.h | 2 | ||||
| -rw-r--r-- | xlators/mgmt/glusterd/src/glusterd3_1-mops.c | 2 | ||||
| -rwxr-xr-x | xlators/mount/fuse/utils/mount_glusterfs.in | 7 | 
24 files changed, 59 insertions, 69 deletions
diff --git a/cli/src/cli.h b/cli/src/cli.h index f3ea92828..2ef31b229 100644 --- a/cli/src/cli.h +++ b/cli/src/cli.h @@ -30,7 +30,7 @@  #include "protocol-common.h"  #define DEFAULT_EVENT_POOL_SIZE            16384 -#define CLI_GLUSTERD_PORT                   6969 +#define CLI_GLUSTERD_PORT                  24007  #define CLI_DEFAULT_CONN_TIMEOUT             120  #define CLI_DEFAULT_CMD_TIMEOUT              120 diff --git a/doc/examples/protocol-client.vol b/doc/examples/protocol-client.vol index 43108f2c2..43c43e02d 100644 --- a/doc/examples/protocol-client.vol +++ b/doc/examples/protocol-client.vol @@ -3,14 +3,14 @@ volume client    option transport-type tcp     # for TCP/IP transport  # option transport-type ib-sdp  # for Infiniband transport    option remote-host 192.168.1.10      # IP address of the remote brick -# option transport.socket.remote-port 6996              # default server port is 6996 +# option transport.socket.remote-port 24016                # option transport-type ib-verbs # for Infiniband verbs transport  # option transport.ib-verbs.work-request-send-size  1048576  # option transport.ib-verbs.work-request-send-count 16  # option transport.ib-verbs.work-request-recv-size  1048576  # option transport.ib-verbs.work-request-recv-count 16 -# option transport.ib-verbs.remote-port 6996              # default server port is 6996 +# option transport.ib-verbs.remote-port 24016                  option remote-subvolume brick        # name of the remote volume  # option transport-timeout 30          # default value is 120seconds  diff --git a/doc/examples/protocol-server.vol b/doc/examples/protocol-server.vol index 88477511f..e8e4a4643 100644 --- a/doc/examples/protocol-server.vol +++ b/doc/examples/protocol-server.vol @@ -9,14 +9,14 @@ end-volume  volume server    type protocol/server    option transport-type tcp      # For TCP/IP transport -# option transport.socket.listen-port 6996              # Default is 6996 +# option transport.socket.listen-port 24016                # option transport-type ib-verbs # For Infiniband Verbs transport  # option transport.ib-verbs.work-request-send-size  131072  # option transport.ib-verbs.work-request-send-count 64  # option transport.ib-verbs.work-request-recv-size  131072  # option transport.ib-verbs.work-request-recv-count 64 -# option transport.ib-verbs.listen-port 6996              # Default is 6996 +# option transport.ib-verbs.listen-port 24016                # option bind-address 192.168.1.10     # Default is to listen on all interfaces  # option client-volume-filename /etc/glusterfs/glusterfs-client.vol diff --git a/doc/examples/replicate.vol b/doc/examples/replicate.vol index 8c9541444..333ba7de1 100644 --- a/doc/examples/replicate.vol +++ b/doc/examples/replicate.vol @@ -23,7 +23,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp                      # For TCP/IP transport -  option transport.socket.listen-port 6996       # Default is 6996 +  option transport.socket.listen-port 24016         # option client-volume-filename /etc/glusterfs/glusterfs-client.vol    subvolumes brick1    option auth.addr.brick1.allow * 		# access to "brick" volume @@ -49,7 +49,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp                  # For TCP/IP transport -  option transport.socket.listen-port 6997   # Default is 6996 +  option transport.socket.listen-port 24017       subvolumes brick2    option auth.addr.brick2.allow * # Allow access to "brick" volume  end-volume @@ -75,7 +75,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp                 # For TCP/IP transport -  option transport.socket.listen-port 6998  # Default is 6996 +  option transport.socket.listen-port 24018      subvolumes brick3    option auth.addr.brick3.allow * 		# access to "brick" volume  end-volume @@ -90,7 +90,7 @@ volume client1    type protocol/client    option transport-type tcp     # for TCP/IP transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6996              # default server port is 6996 +  option transport.socket.remote-port 24016                  option remote-subvolume brick1        # name of the remote volume  end-volume @@ -99,7 +99,7 @@ volume client2    type protocol/client    option transport-type tcp     # for TCP/IP transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6997              # default server port is 6996 +  option transport.socket.remote-port 24017                  option remote-subvolume brick2        # name of the remote volume  end-volume @@ -107,7 +107,7 @@ volume client3    type protocol/client    option transport-type tcp     # for TCP/IP transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6998              # default server port is 6996 +  option transport.socket.remote-port 24018                  option remote-subvolume brick3        # name of the remote volume  end-volume diff --git a/doc/examples/stripe.vol b/doc/examples/stripe.vol index ea24cf860..6055b66b9 100644 --- a/doc/examples/stripe.vol +++ b/doc/examples/stripe.vol @@ -24,7 +24,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6996              # Default is 6996 +  option transport.socket.listen-port 24016                # option client-volume-filename /etc/glusterfs/glusterfs-client.vol    subvolumes brick1    option auth.addr.brick1.allow * 		# access to "brick" volume @@ -50,7 +50,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6997              # Default is 6996 +  option transport.socket.listen-port 24017                  subvolumes brick2    option auth.addr.brick2.allow * # Allow access to "brick" volume  end-volume @@ -76,7 +76,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6998              # Default is 6996 +  option transport.socket.listen-port 24018                  subvolumes brick3    option auth.addr.brick3.allow * 		# access to "brick" volume  end-volume @@ -91,7 +91,7 @@ volume client1    type protocol/client    option transport-type tcp     # for TCP/IP transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6996              # default server port is 6996 +  option transport.socket.remote-port 24016                  option remote-subvolume brick1        # name of the remote volume  end-volume @@ -100,7 +100,7 @@ volume client2    type protocol/client    option transport-type tcp     # for TCP/IP transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6997              # default server port is 6996 +  option transport.socket.remote-port 24017                  option remote-subvolume brick2        # name of the remote volume  end-volume @@ -108,7 +108,7 @@ volume client3    type protocol/client    option transport-type tcp     # for TCP/IP transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6998              # default server port is 6996 +  option transport.socket.remote-port 24018                  option remote-subvolume brick3        # name of the remote volume  end-volume diff --git a/doc/examples/unify.vol b/doc/examples/unify.vol index 4f7415a23..3fb7e8320 100644 --- a/doc/examples/unify.vol +++ b/doc/examples/unify.vol @@ -24,7 +24,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6996              # Default is 6996 +  option transport.socket.listen-port 24016                # option client-volume-filename /etc/glusterfs/glusterfs-client.vol    subvolumes brick1    option auth.addr.brick1.allow * 		# access to "brick" volume @@ -50,7 +50,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6997              # Default is 6996 +  option transport.socket.listen-port 24017                  subvolumes brick2    option auth.addr.brick2.allow * # Allow access to "brick" volume  end-volume @@ -76,7 +76,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6998              # Default is 6996 +  option transport.socket.listen-port 24018                  subvolumes brick3    option auth.addr.brick3.allow * 		# access to "brick" volume  end-volume @@ -93,7 +93,7 @@ end-volume  volume server    type protocol/server    option transport-type tcp     # For TCP/IP transport -  option transport.socket.listen-port 6999              # Default is 6996 +  option transport.socket.listen-port 24019                  subvolumes brick-ns    option auth.addr.brick-ns.allow * 		# access to "brick" volume  end-volume @@ -109,7 +109,7 @@ volume client1    option transport-type tcp     # for TCP/IP transport  # option transport-type ib-sdp  # for Infiniband transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6996              # default server port is 6996 +  option transport.socket.remote-port 24016                  option remote-subvolume brick1        # name of the remote volume  end-volume @@ -119,7 +119,7 @@ volume client2    option transport-type tcp     # for TCP/IP transport  # option transport-type ib-sdp  # for Infiniband transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6997              # default server port is 6996 +  option transport.socket.remote-port 24017                  option remote-subvolume brick2        # name of the remote volume  end-volume @@ -128,7 +128,7 @@ volume client3    option transport-type tcp     # for TCP/IP transport  # option transport-type ib-sdp  # for Infiniband transport    option remote-host 127.0.0.1      # IP address of the remote brick -  option transport.socket.remote-port 6998              # default server port is 6996 +  option transport.socket.remote-port 24018                  option remote-subvolume brick3        # name of the remote volume  end-volume @@ -138,7 +138,7 @@ volume client-ns    option transport-type tcp     # for TCP/IP transport  # option transport-type ib-sdp  # for Infiniband transport    option remote-host 127.0.0.1         # IP address of the remote brick -  option transport.socket.remote-port 6999              # default server port is 6996 +  option transport.socket.remote-port 24019                  option remote-subvolume brick-ns     # name of the remote volume  end-volume diff --git a/doc/glusterd.vol b/doc/glusterd.vol index b96cbe8ea..4e43fb0da 100644 --- a/doc/glusterd.vol +++ b/doc/glusterd.vol @@ -2,10 +2,7 @@ volume management      type mgmt/glusterd      option working-directory /etc/glusterd      option transport-type socket,rdma -    option transport.socket.listen-port 6969 -    option transport.rdma.listen-port 6968      option transport.socket.keepalive-time 10      option transport.socket.keepalive-interval 2 -    # option listen-port 6969  end-volume diff --git a/doc/glusterfs-volgen.8 b/doc/glusterfs-volgen.8 index f185e9aed..a47873783 100644 --- a/doc/glusterfs-volgen.8 +++ b/doc/glusterfs-volgen.8 @@ -55,7 +55,7 @@ together like 'tcp,ib-verbs'. [default is 'tcp']  .TP  \fB\-p \-\-port\fR=PORT  The port number to use in volume files. -[default is 6996 for tcp, 6997 for ib-verbs] +[default is 24007 for tcp, (24007 + 1) for ib-verbs]  .TP  \fB\-a \-\-auth\fR=AUTH_PARAMS  Authentication parameters (comma seperated) to use in server volume. diff --git a/doc/glusterfs.vol.sample b/doc/glusterfs.vol.sample index e126f66b3..3b1f18517 100644 --- a/doc/glusterfs.vol.sample +++ b/doc/glusterfs.vol.sample @@ -21,10 +21,10 @@ volume client  # option transport-type unix  # option transport-type ib-sdp    option remote-host 127.0.0.1         # IP address of the remote brick -# option transport.socket.remote-port 6996              # default server port is 6996 +# option transport.socket.remote-port 24016                # option transport-type ib-verbs -# option transport.ib-verbs.remote-port 6996              # default server port is 6996 +# option transport.ib-verbs.remote-port 24016                # option transport.ib-verbs.work-request-send-size  1048576  # option transport.ib-verbs.work-request-send-count 16  # option transport.ib-verbs.work-request-recv-size  1048576 diff --git a/doc/glusterfsd.vol.sample b/doc/glusterfsd.vol.sample index b6d8a1580..e91df3290 100644 --- a/doc/glusterfsd.vol.sample +++ b/doc/glusterfsd.vol.sample @@ -28,11 +28,11 @@ volume server  # option transport-type unix  # option transport-type ib-sdp  # option transport.socket.bind-address 192.168.1.10     # Default is to listen on all interfaces -# option transport.socket.listen-port 6996              # Default is 6996 +# option transport.socket.listen-port 24016                # option transport-type ib-verbs  # option transport.ib-verbs.bind-address 192.168.1.10     # Default is to listen on all interfaces -# option transport.ib-verbs.listen-port 6996              # Default is 6996 +# option transport.ib-verbs.listen-port 24016                # option transport.ib-verbs.work-request-send-size  131072  # option transport.ib-verbs.work-request-send-count 64  # option transport.ib-verbs.work-request-recv-size  131072 diff --git a/doc/mount.glusterfs.8 b/doc/mount.glusterfs.8 index 7be1f0c78..aced363f7 100644 --- a/doc/mount.glusterfs.8 +++ b/doc/mount.glusterfs.8 @@ -22,7 +22,7 @@  mount.glusterfs - script to mount native GlusterFS volume  .SH SYNOPSIS  .B mount -t glusterfs -.I [-o <options>] <volumeserver>:<volumeid/volumeport> <mountpoint> +.I [-o <options>] <volumeserver>:<volumeid> <mountpoint>  .TP  .B mount -t glusterfs  .I [-o <options>] <path/to/volumefile> <mountpoint> @@ -56,9 +56,6 @@ Mount the filesystem read-only  \fBvolfile\-id=\fRKEY  Volume key or name of the volume file to be fetched from server  .TP -\fBserver\-port=\fRPORT -Port number of volfile server [default: 6996] -.TP  \fBtransport=\fRTRANSPORT-TYPE  Transport type to get volume file from server [default: socket]  .TP diff --git a/doc/user-guide/user-guide.info b/doc/user-guide/user-guide.info index 94a24c01d..6ba883ea0 100644 --- a/doc/user-guide/user-guide.info +++ b/doc/user-guide/user-guide.info @@ -906,7 +906,7 @@ and the client.  `non-blocking-connect [no|off|on|yes] (on)'       Whether to make the connection attempt asynchronous. -`remote-port <n> (6996)' +`remote-port <n> (24007)'       Server port to connect to.    `remote-host <hostname> *' @@ -920,7 +920,7 @@ and the client.       The local interface on which the server should listen to requests.       Default is to listen on all interfaces. -`listen-port <n> (6996)' +`listen-port <n> (24007)'       The local port to listen on.  4.2.1.2 IB-SDP @@ -951,7 +951,7 @@ always best to use `ib-verbs'. Use `ib-sdp' only if you cannot get  `non-blocking-connect [no|off|on|yes] (on)'       Whether to make the connection attempt asynchronous. -`remote-port <n> (6996)' +`remote-port <n> (24007)'       Server port to connect to.    `remote-host <hostname> *' @@ -965,7 +965,7 @@ always best to use `ib-verbs'. Use `ib-sdp' only if you cannot get       The local interface on which the server should listen to requests.       Default is to listen on all interfaces. -`listen-port <n> (6996)' +`listen-port <n> (24007)'       The local port to listen on.     The following options are common to both the client and server @@ -2037,11 +2037,11 @@ it means the GlusterFS mount did not succeed. Try running GlusterFS in  connections and firewall settings. To check if the server is reachable,  try: -     telnet IP-ADDRESS 6996 +     telnet IP-ADDRESS 24007     If the server is accessible, your `telnet' command should connect and  block. If not you will see an error message such as `telnet: Unable to -connect to remote host: Connection refused'. 6996 is the default +connect to remote host: Connection refused'. 24007 is the default  GlusterFS port. If you have changed it, then use the corresponding port  instead. diff --git a/doc/user-guide/user-guide.texi b/doc/user-guide/user-guide.texi index 9dce15be4..025a92d89 100644 --- a/doc/user-guide/user-guide.texi +++ b/doc/user-guide/user-guide.texi @@ -924,7 +924,7 @@ The @acronym{TCP} client module accepts the following options:  @table @code  @item non-blocking-connect [no|off|on|yes] (on)  Whether to make the connection attempt asynchronous. -@item remote-port <n> (6996) +@item remote-port <n> (24007)  Server port to connect to.  @cindex DNS round robin  @item remote-host <hostname> * @@ -941,7 +941,7 @@ The @acronym{TCP} server module accepts the following options:  @item bind-address <address> (0.0.0.0)  The local interface on which the server should listen to requests. Default is to  listen on all interfaces. -@item listen-port <n> (6996) +@item listen-port <n> (24007)  The local port to listen on.  @end table  @end cartouche @@ -978,7 +978,7 @@ The @command{ib-verbs} client module accepts the following options:  @table @code  @item non-blocking-connect [no|off|on|yes] (on)  Whether to make the connection attempt asynchronous. -@item remote-port <n> (6996) +@item remote-port <n> (24007)  Server port to connect to.  @cindex DNS round robin  @item remote-host <hostname> * @@ -995,7 +995,7 @@ The @command{ib-verbs} server module accepts the following options:  @item bind-address <address> (0.0.0.0)  The local interface on which the server should listen to requests. Default is to  listen on all interfaces. -@item listen-port <n> (6996) +@item listen-port <n> (24007)  The local port to listen on.  @end table  @end cartouche @@ -2102,12 +2102,12 @@ connections and firewall settings. To check if the server is reachable,  try:  @example -telnet IP-ADDRESS 6996 +telnet IP-ADDRESS 24007  @end example  If the server is accessible, your `telnet' command should connect and  block. If not you will see an error message such as @command{telnet: Unable to -connect to remote host: Connection refused}. 6996 is the default +connect to remote host: Connection refused}. 24007 is the default  GlusterFS port. If you have changed it, then use the corresponding  port instead. diff --git a/extras/volgen/CreateVolfile.py b/extras/volgen/CreateVolfile.py index c8143a03a..2f548d7c7 100644 --- a/extras/volgen/CreateVolfile.py +++ b/extras/volgen/CreateVolfile.py @@ -45,8 +45,8 @@ class CreateVolfile:              self.gfs_port    = options.port              self.gfs_ib_port = options.port + 1          else: -            self.gfs_port    = 6969 -            self.gfs_ib_port = 6970 +            self.gfs_port    = 24007 +            self.gfs_ib_port = 24008      def create_pmap_mount_volfile (self): diff --git a/glusterfsd/src/glusterfsd-mgmt.c b/glusterfsd/src/glusterfsd-mgmt.c index dc17a2f24..c857ffedc 100644 --- a/glusterfsd/src/glusterfsd-mgmt.c +++ b/glusterfsd/src/glusterfsd-mgmt.c @@ -474,7 +474,7 @@ glusterfs_mgmt_init (glusterfs_ctx_t *ctx)          struct rpc_clnt_config  rpc_cfg = {0,};          dict_t                  *options = NULL;          int                     ret = -1; -        int                     port = 6969; +        int                     port = GF_DEFAULT_BASE_PORT;          char                    *host = NULL;          cmd_args = &ctx->cmd_args; diff --git a/libglusterfs/src/globals.h b/libglusterfs/src/globals.h index 3f0edde97..762438eca 100644 --- a/libglusterfs/src/globals.h +++ b/libglusterfs/src/globals.h @@ -20,6 +20,8 @@  #ifndef _GLOBALS_H  #define _GLOBALS_H +#define GF_DEFAULT_BASE_PORT 24007 +  /* This corresponds to the max 16 number of group IDs that are sent through an   * RPC request. Since NFS is the only one going to set this, we can be safe   * in keeping this size hardcoded. diff --git a/rpc/rpc-lib/src/rpcsvc.h b/rpc/rpc-lib/src/rpcsvc.h index fca7d047a..98de7fcae 100644 --- a/rpc/rpc-lib/src/rpcsvc.h +++ b/rpc/rpc-lib/src/rpcsvc.h @@ -50,7 +50,7 @@  #define RPCSVC_THREAD_STACK_SIZE ((size_t)(1024 * GF_UNIT_KB))  #define RPCSVC_FRAGHDR_SIZE  4       /* 4-byte RPC fragment header size */ -#define RPCSVC_DEFAULT_LISTEN_PORT      6996 +#define RPCSVC_DEFAULT_LISTEN_PORT      GF_DEFAULT_BASE_PORT  #define RPCSVC_DEFAULT_MEMFACTOR        15  #define RPCSVC_EVENTPOOL_SIZE_MULT      1024  #define RPCSVC_POOLCOUNT_MULT           35 diff --git a/rpc/rpc-transport/rdma/src/rdma.h b/rpc/rpc-transport/rdma/src/rdma.h index 97cfd0461..a3ab8dcbe 100644 --- a/rpc/rpc-transport/rdma/src/rdma.h +++ b/rpc/rpc-transport/rdma/src/rdma.h @@ -40,8 +40,8 @@  #include <infiniband/verbs.h>  /* FIXME: give appropriate values to these macros */ -#define GF_DEFAULT_RDMA_LISTEN_PORT 6968 -#define RDMA_MAX_SEGMENTS           8    +#define GF_DEFAULT_RDMA_LISTEN_PORT (GF_DEFAULT_BASE_PORT + 1) +#define RDMA_MAX_SEGMENTS           8  #define RDMA_MAX_HEADER_SIZE        (sizeof (rdma_header_t)                 \                                       + RDMA_MAX_SEGMENTS                    \                                       * sizeof (rdma_read_chunk_t)) diff --git a/rpc/rpc-transport/socket/src/socket.h b/rpc/rpc-transport/socket/src/socket.h index f54b64c2a..c43c5576c 100644 --- a/rpc/rpc-transport/socket/src/socket.h +++ b/rpc/rpc-transport/socket/src/socket.h @@ -31,12 +31,13 @@  #include "logging.h"  #include "dict.h"  #include "mem-pool.h" +#include "globals.h"  #ifndef MAX_IOVEC  #define MAX_IOVEC 16  #endif /* MAX_IOVEC */ -#define GF_DEFAULT_SOCKET_LISTEN_PORT 6969 +#define GF_DEFAULT_SOCKET_LISTEN_PORT  GF_DEFAULT_BASE_PORT  #define RPC_MAX_FRAGMENT_SIZE 0x7fffffff diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c index e22f0e403..7e5cddac8 100644 --- a/xlators/mgmt/glusterd/src/glusterd-handler.c +++ b/xlators/mgmt/glusterd/src/glusterd-handler.c @@ -77,7 +77,7 @@ glusterd_handle_friend_req (rpcsvc_request_t *req, uuid_t  uuid,          uuid_unparse (uuid, uuid_str);          uuid_parse (uuid_str, friend_uuid);          if (!port) -                port = 6969; // TODO: use define values. +                port = GF_DEFAULT_BASE_PORT;          ret = glusterd_remote_hostname_get (req, rhost, sizeof (rhost));          ret = glusterd_friend_find (uuid, rhost, &peerinfo); @@ -156,7 +156,7 @@ glusterd_handle_unfriend_req (rpcsvc_request_t *req, uuid_t  uuid,          glusterd_friend_req_ctx_t       *ctx = NULL;          if (!port) -                port = 6969; //TODO: use define'd macro +                port = GF_DEFAULT_BASE_PORT;          ret = glusterd_friend_find (uuid, hostname, &peerinfo); diff --git a/xlators/mgmt/glusterd/src/glusterd-pmap.c b/xlators/mgmt/glusterd/src/glusterd-pmap.c index 3ea09aad9..67d10bfa6 100644 --- a/xlators/mgmt/glusterd/src/glusterd-pmap.c +++ b/xlators/mgmt/glusterd/src/glusterd-pmap.c @@ -78,8 +78,8 @@ pmap_registry_new (void)                          pmap->ports[i].type = GF_PMAP_PORT_FOREIGN;          } -        pmap->base_port = 6971; /* 6969 default for tcp, 6970 for IB */ -        pmap->last_alloc = 6971; +        pmap->base_port = GF_DEFAULT_BASE_PORT + 2; +        pmap->last_alloc = GF_DEFAULT_BASE_PORT + 2;          return pmap;  } diff --git a/xlators/mgmt/glusterd/src/glusterd.h b/xlators/mgmt/glusterd/src/glusterd.h index ac9837601..7763962cd 100644 --- a/xlators/mgmt/glusterd/src/glusterd.h +++ b/xlators/mgmt/glusterd/src/glusterd.h @@ -193,7 +193,7 @@ enum glusterd_vol_comp_status_ {  };  #define GLUSTERD_DEFAULT_WORKDIR "/etc/glusterd" -#define GLUSTERD_DEFAULT_PORT   6969 +#define GLUSTERD_DEFAULT_PORT    GF_DEFAULT_BASE_PORT  #define GLUSTERD_INFO_FILE      "glusterd.info"  #define GLUSTERD_VOLUME_DIR_PREFIX "vols"  #define GLUSTERD_PEER_DIR_PREFIX "peers" diff --git a/xlators/mgmt/glusterd/src/glusterd3_1-mops.c b/xlators/mgmt/glusterd/src/glusterd3_1-mops.c index 858eb33f9..cc2f84d38 100644 --- a/xlators/mgmt/glusterd/src/glusterd3_1-mops.c +++ b/xlators/mgmt/glusterd/src/glusterd3_1-mops.c @@ -757,7 +757,7 @@ glusterd3_1_probe (call_frame_t *frame, xlator_t *this,                  goto out;          ret = dict_get_int32 (dict, "port", &port);          if (ret) -                port = 6969; +                port = GF_DEFAULT_BASE_PORT;          ret = glusterd_friend_find (NULL, hostname, &peerinfo); diff --git a/xlators/mount/fuse/utils/mount_glusterfs.in b/xlators/mount/fuse/utils/mount_glusterfs.in index e1acb6eb4..473ecace9 100755 --- a/xlators/mount/fuse/utils/mount_glusterfs.in +++ b/xlators/mount/fuse/utils/mount_glusterfs.in @@ -82,12 +82,10 @@ start_glusterfs ()  	if [ -n "$transport" ]; then   	    cmd_line=$(echo "$cmd_line \  --volfile-server=$server_ip \ ---volfile-server-port=$server_port \  --volfile-server-transport=$transport");  	else  	    cmd_line=$(echo "$cmd_line \  --volfile-server=$server_ip \ ---volfile-server-port=$server_port");  	fi      else  	cmd_line=$(echo "$cmd_line --volfile=$volfile_loc"); @@ -175,11 +173,6 @@ main ()      [ -r "$volfile_loc" ] || {  	server_ip=$(echo "$volfile_loc" | sed -n 's/\([^\:]*\).*/\1/p'); -	server_port=$(echo "$volfile_loc" | sed -n 's/.*:\([^ ]*\).*/\1/p'); -	[ -n "$server_port" ] || { -	    server_port="6996"; -	} -  	volfile_loc="";      }      # following line is product of love towards sed  | 
