~ubuntu-branches/ubuntu/wily/glusterfs/wily

« back to all changes in this revision

Viewing changes to xlators/nfs/server/src/nfs.c

  • Committer: Bazaar Package Importer
  • Author(s): Patrick Matthäi
  • Date: 2011-03-15 21:14:50 UTC
  • mfrom: (1.3.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20110315211450-5iekpirgkdntccne
Tags: 3.1.3-1
* New upstream release.
  - glusterfs-volgen and glusterfs-defrag have been removed.
* Suggest nfs-common with the glusterfs-server for native NFS support.
  Closes: #614988
* Migrate to dh_python2.
  Closes: #616826

Show diffs side-by-side

added added

removed removed

Lines of Context:
113
113
                }
114
114
 
115
115
                prog = version->init (this);
 
116
                if (!prog) {
 
117
                        ret = -1;
 
118
                        goto err;
 
119
                }
116
120
                prog->actorxl = this;
117
121
                version->program = prog;
118
 
                if (!prog) {
119
 
                        ret = -1;
120
 
                        goto err;
121
 
                }
122
 
 
123
122
                if (nfs->override_portnum)
124
123
                        prog->progport = nfs->override_portnum;
125
124
                gf_log (GF_NFS, GF_LOG_DEBUG, "Starting program: %s",
206
205
        LOCK (&nfs->svinitlock);
207
206
        {
208
207
                for (;x < nfs->allsubvols; ++x) {
 
208
                        if (nfs->initedxl[x] == xl) {
 
209
                                gf_log (GF_NFS, GF_LOG_DEBUG,
 
210
                                        "Volume already started %s",
 
211
                                        xl->name);
 
212
                                break;
 
213
                        }
 
214
 
209
215
                        if (nfs->initedxl[x] == NULL) {
210
216
                                nfs->initedxl[x] = xl;
211
217
                                ++nfs->upsubvols;
235
241
                goto err;
236
242
        }
237
243
 
 
244
        nfs_subvolume_set_started (this->private, ((xlator_t *)cookie));
238
245
        gf_log (GF_NFS, GF_LOG_TRACE, "Started %s", ((xlator_t *)cookie)->name);
239
246
err:
240
247
        return 0;
258
265
                goto err;
259
266
        }
260
267
 
261
 
        nfs_subvolume_set_started (nfsx->private, xl);
262
268
        ret = nfs_inode_loc_fill (xl->itable->root, &rootloc);
263
269
        if (ret == -1) {
264
270
                gf_log (GF_NFS, GF_LOG_CRITICAL, "Failed to init root loc");
938
944
                         "Please consult gluster-users list before using this "
939
945
                         "option."
940
946
        },
 
947
        { .key  = {"nfs3.*.disable"},
 
948
          .type = GF_OPTION_TYPE_BOOL,
 
949
          .description = "This option is used to start or stop NFS server"
 
950
                         "for individual volume."
 
951
        },
941
952
        { .key  = {NULL} },
942
953
};
943
954