You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by hdev ml <hd...@gmail.com> on 2013/10/28 20:07:43 UTC

HBase Replication Questions

Hello all,

I have a couple of questions for HBase.

1. Is there any way to find out by how much time the replication is lagging
on the peer cluster or even primary cluster is ok.
2. Say replication is going on for some time for a table and then you
restore a snapshot on the Primary. Would replication catch up with the
restore snapshot? Or do I have to treat that as replicating from scratch,
meaning

   1. disable peer
   2. restore snapshot on primary
   3. copyTable upto disable timestamp
   4. enable peer


Any help is appreciated.

Thanks

Harshad

Re: HBase Replication Questions

Posted by hdev ml <hd...@gmail.com>.
Thanks Ted. Will take a look at it.


On Mon, Oct 28, 2013 at 3:33 PM, Ted Yu <yu...@gmail.com> wrote:

> Please see also 'Replication Metrics' at the bottom of
> http://hbase.apache.org/replication.html
>
>
> On Mon, Oct 28, 2013 at 3:23 PM, hdev ml <hd...@gmail.com> wrote:
>
> > Thanks Demai. Need to find out how to access HBase metrics.
> >
> > But thanks for your insights.
> > Harshad
> >
> >
> > On Mon, Oct 28, 2013 at 2:45 PM, Demai Ni <ni...@gmail.com> wrote:
> >
> > > 1)  you can use replication metrics info such as:ageOfLastShippedOp,
> > > timeStampsOfLastShippedOp, sizeOfLogQueue ageOfLastAppliedOp, and
> > > timeStampsOfLastAppliedOp to figure out the lag.
> > > 2) with my best knowledge, the replication won't be together with
> > snapshot.
> > > That is the peers won't know there is a restore occurred on primary.
> So a
> > > user must take care it manually.   the VerifyReplication tool may be
> > > helpful to identify which data (boundary by timestamps) is mismatch, so
> > the
> > > copyTable doesn't have to copy the whole table
> > >
> > > Demai
> > >
> > > Demai
> > >
> > >
> > > On Mon, Oct 28, 2013 at 12:07 PM, hdev ml <hd...@gmail.com> wrote:
> > >
> > > > Hello all,
> > > >
> > > > I have a couple of questions for HBase.
> > > >
> > > > 1. Is there any way to find out by how much time the replication is
> > > lagging
> > > > on the peer cluster or even primary cluster is ok.
> > > > 2. Say replication is going on for some time for a table and then you
> > > > restore a snapshot on the Primary. Would replication catch up with
> the
> > > > restore snapshot? Or do I have to treat that as replicating from
> > scratch,
> > > > meaning
> > > >
> > > >    1. disable peer
> > > >    2. restore snapshot on primary
> > > >    3. copyTable upto disable timestamp
> > > >    4. enable peer
> > > >
> > > >
> > > > Any help is appreciated.
> > > >
> > > > Thanks
> > > >
> > > > Harshad
> > > >
> > >
> >
>

Re: HBase Replication Questions

Posted by Ted Yu <yu...@gmail.com>.
Please see also 'Replication Metrics' at the bottom of
http://hbase.apache.org/replication.html


On Mon, Oct 28, 2013 at 3:23 PM, hdev ml <hd...@gmail.com> wrote:

> Thanks Demai. Need to find out how to access HBase metrics.
>
> But thanks for your insights.
> Harshad
>
>
> On Mon, Oct 28, 2013 at 2:45 PM, Demai Ni <ni...@gmail.com> wrote:
>
> > 1)  you can use replication metrics info such as:ageOfLastShippedOp,
> > timeStampsOfLastShippedOp, sizeOfLogQueue ageOfLastAppliedOp, and
> > timeStampsOfLastAppliedOp to figure out the lag.
> > 2) with my best knowledge, the replication won't be together with
> snapshot.
> > That is the peers won't know there is a restore occurred on primary. So a
> > user must take care it manually.   the VerifyReplication tool may be
> > helpful to identify which data (boundary by timestamps) is mismatch, so
> the
> > copyTable doesn't have to copy the whole table
> >
> > Demai
> >
> > Demai
> >
> >
> > On Mon, Oct 28, 2013 at 12:07 PM, hdev ml <hd...@gmail.com> wrote:
> >
> > > Hello all,
> > >
> > > I have a couple of questions for HBase.
> > >
> > > 1. Is there any way to find out by how much time the replication is
> > lagging
> > > on the peer cluster or even primary cluster is ok.
> > > 2. Say replication is going on for some time for a table and then you
> > > restore a snapshot on the Primary. Would replication catch up with the
> > > restore snapshot? Or do I have to treat that as replicating from
> scratch,
> > > meaning
> > >
> > >    1. disable peer
> > >    2. restore snapshot on primary
> > >    3. copyTable upto disable timestamp
> > >    4. enable peer
> > >
> > >
> > > Any help is appreciated.
> > >
> > > Thanks
> > >
> > > Harshad
> > >
> >
>

Re: HBase Replication Questions

Posted by hdev ml <hd...@gmail.com>.
Thanks Demai. Need to find out how to access HBase metrics.

But thanks for your insights.
Harshad


On Mon, Oct 28, 2013 at 2:45 PM, Demai Ni <ni...@gmail.com> wrote:

> 1)  you can use replication metrics info such as:ageOfLastShippedOp,
> timeStampsOfLastShippedOp, sizeOfLogQueue ageOfLastAppliedOp, and
> timeStampsOfLastAppliedOp to figure out the lag.
> 2) with my best knowledge, the replication won't be together with snapshot.
> That is the peers won't know there is a restore occurred on primary. So a
> user must take care it manually.   the VerifyReplication tool may be
> helpful to identify which data (boundary by timestamps) is mismatch, so the
> copyTable doesn't have to copy the whole table
>
> Demai
>
> Demai
>
>
> On Mon, Oct 28, 2013 at 12:07 PM, hdev ml <hd...@gmail.com> wrote:
>
> > Hello all,
> >
> > I have a couple of questions for HBase.
> >
> > 1. Is there any way to find out by how much time the replication is
> lagging
> > on the peer cluster or even primary cluster is ok.
> > 2. Say replication is going on for some time for a table and then you
> > restore a snapshot on the Primary. Would replication catch up with the
> > restore snapshot? Or do I have to treat that as replicating from scratch,
> > meaning
> >
> >    1. disable peer
> >    2. restore snapshot on primary
> >    3. copyTable upto disable timestamp
> >    4. enable peer
> >
> >
> > Any help is appreciated.
> >
> > Thanks
> >
> > Harshad
> >
>

Re: HBase Replication Questions

Posted by Demai Ni <ni...@gmail.com>.
1)  you can use replication metrics info such as:ageOfLastShippedOp,
timeStampsOfLastShippedOp, sizeOfLogQueue ageOfLastAppliedOp, and
timeStampsOfLastAppliedOp to figure out the lag.
2) with my best knowledge, the replication won't be together with snapshot.
That is the peers won't know there is a restore occurred on primary. So a
user must take care it manually.   the VerifyReplication tool may be
helpful to identify which data (boundary by timestamps) is mismatch, so the
copyTable doesn't have to copy the whole table

Demai

Demai


On Mon, Oct 28, 2013 at 12:07 PM, hdev ml <hd...@gmail.com> wrote:

> Hello all,
>
> I have a couple of questions for HBase.
>
> 1. Is there any way to find out by how much time the replication is lagging
> on the peer cluster or even primary cluster is ok.
> 2. Say replication is going on for some time for a table and then you
> restore a snapshot on the Primary. Would replication catch up with the
> restore snapshot? Or do I have to treat that as replicating from scratch,
> meaning
>
>    1. disable peer
>    2. restore snapshot on primary
>    3. copyTable upto disable timestamp
>    4. enable peer
>
>
> Any help is appreciated.
>
> Thanks
>
> Harshad
>