Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Maintaining Primary in the Replica Set

Received: by 10.204.156.199 with SMTP id y7mr2755529bkw.7.1335906994483;
        Tue, 01 May 2012 14:16:34 -0700 (PDT)
X-BeenThere: mongodb-user@googlegroups.com
Received: by 10.204.157.16 with SMTP id z16ls1916486bkw.9.gmail; Tue, 01 May
 2012 14:16:09 -0700 (PDT)
Received: by 10.204.149.210 with SMTP id u18mr876165bkv.1.1335906969859;
        Tue, 01 May 2012 14:16:09 -0700 (PDT)
Received: by 10.204.149.210 with SMTP id u18mr876164bkv.1.1335906969846;
        Tue, 01 May 2012 14:16:09 -0700 (PDT)
Return-Path: <scotthernan...@gmail.com>
Received: from mail-bk0-f44.google.com (mail-bk0-f44.google.com [209.85.214.44])
        by gmr-mx.google.com with ESMTPS id p5si7720936bks.1.2012.05.01.14.16.09
        (version=TLSv1/SSLv3 cipher=OTHER);
        Tue, 01 May 2012 14:16:09 -0700 (PDT)
Received-SPF: pass (google.com: domain of scotthernan...@gmail.com designates 209.85.214.44 as permitted sender) client-ip=209.85.214.44;
Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of scotthernan...@gmail.com designates 209.85.214.44 as permitted sender) smtp.mail=scotthernan...@gmail.com; dkim=pass header...@gmail.com
Received: by bkty8 with SMTP id y8so69643bkt.3
        for <mongodb-user@googlegroups.com>; Tue, 01 May 2012 14:16:09 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20120113;
        h=mime-version:in-reply-to:references:from:date:message-id:subject:to
         :content-type;
        bh=QsfTCT6v5SKC1vUkjPm6LJMJs9zEeAnZR031bI5j/pA=;
        b=VTvutiLimg3t09/9bFt+bWgOnFvIsiGV6rycX5Ceg5escVAhaNljZlOSuB/DBgbekX
         Rb90bHEWWZm0XmlkXlNLEf9Pvy80cnJZpmAokU1xXg0uflxtN4i+S6nKHJqoiwsEWX/Z
         uldyKZ7fon4fVfhMzOP6Yvp51eujGUm7n6kmtjh+Yot2zHNRovhASczw6ACZ22eeopxW
         a6I0JOedqIZy692cuKAWoY4crFSE/bhlfwu7IU+/DxzzXe4yIfF0w3e8GHGO10Em6vOw
         xMfwpvf/NMbmP4bQEumCYMudJ2Niw0pcPxcAUZh70m1zz1nOpoLp3tqkImQD+1XE5W3I
         seKw==
Received: by 10.204.155.137 with SMTP id s9mr8976949bkw.103.1335906969620;
 Tue, 01 May 2012 14:16:09 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.204.119.210 with HTTP; Tue, 1 May 2012 14:15:49 -0700 (PDT)
In-Reply-To: <33a0b096-0573-4ca1-8202-90b84d3be...@fv28g2000vbb.googlegroups.com>
References: <33a0b096-0573-4ca1-8202-90b84d3be...@fv28g2000vbb.googlegroups.com>
From: Scott Hernandez <scotthernan...@gmail.com>
Date: Tue, 1 May 2012 14:15:49 -0700
Message-ID: <CALOM=qhHA5grmcmFjCp+0a9ox+ps=PNDbBL=S=UK92=RUtr...@mail.gmail.com>
Subject: Re: [mongodb-user] Maintaining Primary in the Replica Set
To: mongodb-user@googlegroups.com
Content-Type: text/plain; charset=UTF-8

The way to do this is with the priority option:
http://www.mongodb.org/display/DOCS/Replica+Set+Configuration#ReplicaSetConfiguration-AdvancedConfigOptionalArguments

On Tue, May 1, 2012 at 2:13 PM, bichonfrise74 <bichonfris...@gmail.com> wrote:
> I have 3 nodes; one primary (A), and 2 secondaries (B, C).
>
> I like to make A to be primary all the time because I like to increase
> the oplog size. I tried to do this:
>
> On B and C, I ran this:
>> rs.freeze(600)
>
> On A, I did this:
> $ sudo /etc/init.d/mongodb restart
>
> Then on B and C, I do this:
>> db.adminCommand({replSetFreeze: 0})
>
> I get inconsistent result where A is becoming secondary. Is this the
> right way to do it?
> So, my question is how do you tell server A to be primary temporary
> for the time being, and B and C to be secondary.
>
> --
> You received this message because you are subscribed to the Google Groups "mongodb-user" group.
> To post to this group, send email to mongodb-user@googlegroups.com.
> To unsubscribe from this group, send email to mongodb-user+unsubscribe@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/mongodb-user?hl=en.
>