~ubuntu-branches/ubuntu/vivid/ctdb/vivid-proposed

« back to all changes in this revision

Viewing changes to server/ctdb_daemon.c

  • Committer: Bazaar Package Importer
  • Author(s): Mathieu Parent
  • Date: 2010-02-10 19:39:13 UTC
  • mfrom: (1.2.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20100210193913-c2kyhrx49cj64z72
Tags: 1.0.111.really.1.0.108-1
* Back to 1.0.108 which works better with samba 3.4.x and 3.5.0
  (See <http://lists.alioth.debian.org/pipermail/pkg-samba-maint/
  2010-February/009100.html>)
* Cheery pick some commits from 1.0.108-3 to 1.0.111-1

Show diffs side-by-side

added added

removed removed

Lines of Context:
354
354
                return;
355
355
        }
356
356
 
357
 
        if (ctdb_db->unhealthy_reason) {
358
 
                /*
359
 
                 * this is just a warning, as the tdb should be empty anyway,
360
 
                 * and only persistent databases can be unhealthy, which doesn't
361
 
                 * use this code patch
362
 
                 */
363
 
                DEBUG(DEBUG_WARNING,("warn: db(%s) unhealty in daemon_request_call_from_client(): %s\n",
364
 
                                     ctdb_db->db_name, ctdb_db->unhealthy_reason));
365
 
        }
366
 
 
367
357
        key.dptr = c->data;
368
358
        key.dsize = c->keylen;
369
359
 
730
720
 
731
721
        DEBUG(DEBUG_ERR, ("Starting CTDBD as pid : %u\n", ctdbd_pid));
732
722
 
733
 
        ctdb_high_priority(ctdb);
 
723
        if (ctdb->do_setsched) {
 
724
                /* try to set us up as realtime */
 
725
                ctdb_set_scheduler(ctdb);
 
726
        }
734
727
 
735
728
        /* ensure the socket is deleted on exit of the daemon */
736
729
        domain_socket_name = talloc_strdup(talloc_autofree_context(), ctdb->daemon.name);
771
764
                ctdb_fatal(ctdb, "transport failed to initialise");
772
765
        }
773
766
 
774
 
        /* attach to existing databases */
775
 
        if (ctdb_attach_databases(ctdb) != 0) {
776
 
                ctdb_fatal(ctdb, "Failed to attach to databases\n");
 
767
        /* attach to any existing persistent databases */
 
768
        if (ctdb_attach_persistent(ctdb) != 0) {
 
769
                ctdb_fatal(ctdb, "Failed to attach to persistent databases\n");         
777
770
        }
778
771
 
779
772
        /* start frozen, then let the first election sort things out */
815
808
                }
816
809
        }
817
810
 
818
 
        ctdb_lockdown_memory(ctdb);
819
811
          
820
812
        /* go into a wait loop to allow other nodes to complete */
821
813
        event_loop_wait(ctdb->ev);