From ae6e73f4d2a9fba6ccef42d49d70d8bbd7cba84a Mon Sep 17 00:00:00 2001 From: Shehjar Tikoo Date: Fri, 26 Nov 2010 00:45:50 +0000 Subject: nfs: Start nfs process even if portmap registration fails It helps to have the process be listed in ps ax|grep output so that user can get the path to the log from the listed command line and check what the problem is. Signed-off-by: Shehjar Tikoo Signed-off-by: Anand V. Avati BUG: 2093 (volumes cannot start when one node in a replicated setup is down) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2093 --- xlators/nfs/server/src/nfs.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'xlators/nfs/server/src/nfs.c') diff --git a/xlators/nfs/server/src/nfs.c b/xlators/nfs/server/src/nfs.c index 001df8eeb..3291858ef 100644 --- a/xlators/nfs/server/src/nfs.c +++ b/xlators/nfs/server/src/nfs.c @@ -641,15 +641,18 @@ init (xlator_t *this) { ret = nfs_init_versions (nfs, this); if (ret == -1) { - gf_log (GF_NFS, GF_LOG_CRITICAL, "Failed to initialize " + gf_log (GF_NFS, GF_LOG_ERROR, "Failed to initialize " "protocols"); + /* Do not return an error on this. If we dont return + * an error, the process keeps running and it helps + * to point out where the log is by doing ps ax|grep gluster. + */ + ret = 0; goto err; } - ret = 0; + gf_log (GF_NFS, GF_LOG_INFO, "NFS service started"); err: - if (ret == 0) - gf_log (GF_NFS, GF_LOG_INFO, "NFS service started"); return ret; } -- cgit