Re: Keyspace Clone in Existing Cluster

2019-10-30 Thread Paul Carlucci
When in doubt, repair.  Nodetool snapshot won't be perfectly consistent
across all the nodes anyway since you're snapshotting on each node
individually.

On Tue, Oct 29, 2019, 8:31 PM Ankit Gadhiya  wrote:

> Thanks Paul. This is interesting.
> So, anything I need to do after cp? - nodetool repair?
> Also I am assuming I need to be doing this exercise on all the nodes of
> the cluster - right?
> Any suggestion to automate this or do it just from a single node?
>
>
> — Ankit Gadhiya
>
> On Tue, Oct 29, 2019 at 11:21 PM Paul Carlucci 
> wrote:
>
>> Straight up Unix cp command, make sure you're in the right directory.  If
>> you try to use schema.cql then you're going to have to massage it somewhat
>> due to keyspace name differences and schema changes over time.  You'll see
>> what I mean if you've got some.
>>
>> It goes without saying that you're gonna want to try this in non-prod
>> first.  On a positive note you'll be learning some stuff they don't quite
>> teach in Datastax Academy!
>>
>> On Tue, Oct 29, 2019, 8:39 AM Ankit Gadhiya 
>> wrote:
>>
>>> Thanks Paul.
>>>
>>> Copy SSTable - How? Using SSTableLoader or some other mechanism.
>>>
>>>
>>> *Thanks & Regards,*
>>> *Ankit Gadhiya*
>>>
>>>
>>>
>>> On Tue, Oct 29, 2019 at 11:36 AM Paul Carlucci 
>>> wrote:
>>>
>>>> Copy the schema from your source keyspace to your new target keyspace,
>>>> nodetool snapshot on your source keyspace, copy the SSTable files over, do
>>>> a rolling bounce, repair, enjoy.  In my experience a rolling bounce is
>>>> easier than a nodetool refresh.
>>>>
>>>> It's either that or just copy it with Spark.
>>>>
>>>> On Tue, Oct 29, 2019, 11:19 AM Ankit Gadhiya 
>>>> wrote:
>>>>
>>>>> Thanks Alex. So How do I copy SSTables from 1.0 to 2.0? (Same
>>>>> SSTableLoader or any other approach?)
>>>>> Also since I've multi-node cluster - I'll have to do this on every
>>>>> single node - is there any tool or better way to execute this just from a
>>>>> single node?
>>>>>
>>>>> *Thanks & Regards,*
>>>>> *Ankit Gadhiya*
>>>>>
>>>>>
>>>>>
>>>>> On Tue, Oct 29, 2019 at 11:16 AM Alex Ott  wrote:
>>>>>
>>>>>> You can create all tables in new keyspace, copy SSTables from 1.0 to
>>>>>> 2.0 tables & use nodetool refresh on tables in KS 2.0 to say Cassandra
>>>>>> about them.
>>>>>>
>>>>>> On Tue, Oct 29, 2019 at 4:10 PM Ankit Gadhiya 
>>>>>> wrote:
>>>>>>
>>>>>>> Hello Folks,
>>>>>>>
>>>>>>> Greetings!.
>>>>>>>
>>>>>>> I've a requirement in my project to setup Blue-Green deployment for
>>>>>>> Cassandra. E.x. Say My current active schema (application pointing to) 
>>>>>>> is
>>>>>>> Keyspace V1.0 and for my next release I want to setup Keysapce 2.0 (with
>>>>>>> some structural changes) and all testing/validation would happen on it 
>>>>>>> and
>>>>>>> once successful , App would switch connection to keyspace 2.0 - This 
>>>>>>> would
>>>>>>> be generic release deployment for our project.
>>>>>>>
>>>>>>> One of the approach we thought of would be to Create keyspace 2.0 as
>>>>>>> clone from Keyspace 1.0 including data using sstableloader but this 
>>>>>>> would
>>>>>>> be time consuming, also being a multi-node cluster (6+6 in each DC) - it
>>>>>>> wouldn't be very feasible to do this manually on all the nodes for 
>>>>>>> multiple
>>>>>>> tables part of that keyspace. Was wondering if we have any other 
>>>>>>> creative
>>>>>>> way to suffice this requirement.
>>>>>>>
>>>>>>> Appreciate your time on this.
>>>>>>>
>>>>>>>
>>>>>>> *Thanks & Regards,*
>>>>>>> *Ankit Gadhiya*
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> --
>>>>>> With best wishes,Alex Ott
>>>>>> http://alexott.net/
>>>>>> Twitter: alexott_en (English), alexott (Russian)
>>>>>>
>>>>> --
> *Thanks & Regards,*
> *Ankit Gadhiya*
>
>


Re: Keyspace Clone in Existing Cluster

2019-10-29 Thread Paul Carlucci
Straight up Unix cp command, make sure you're in the right directory.  If
you try to use schema.cql then you're going to have to massage it somewhat
due to keyspace name differences and schema changes over time.  You'll see
what I mean if you've got some.

It goes without saying that you're gonna want to try this in non-prod
first.  On a positive note you'll be learning some stuff they don't quite
teach in Datastax Academy!

On Tue, Oct 29, 2019, 8:39 AM Ankit Gadhiya  wrote:

> Thanks Paul.
>
> Copy SSTable - How? Using SSTableLoader or some other mechanism.
>
>
> *Thanks & Regards,*
> *Ankit Gadhiya*
>
>
>
> On Tue, Oct 29, 2019 at 11:36 AM Paul Carlucci 
> wrote:
>
>> Copy the schema from your source keyspace to your new target keyspace,
>> nodetool snapshot on your source keyspace, copy the SSTable files over, do
>> a rolling bounce, repair, enjoy.  In my experience a rolling bounce is
>> easier than a nodetool refresh.
>>
>> It's either that or just copy it with Spark.
>>
>> On Tue, Oct 29, 2019, 11:19 AM Ankit Gadhiya 
>> wrote:
>>
>>> Thanks Alex. So How do I copy SSTables from 1.0 to 2.0? (Same
>>> SSTableLoader or any other approach?)
>>> Also since I've multi-node cluster - I'll have to do this on every
>>> single node - is there any tool or better way to execute this just from a
>>> single node?
>>>
>>> *Thanks & Regards,*
>>> *Ankit Gadhiya*
>>>
>>>
>>>
>>> On Tue, Oct 29, 2019 at 11:16 AM Alex Ott  wrote:
>>>
>>>> You can create all tables in new keyspace, copy SSTables from 1.0 to
>>>> 2.0 tables & use nodetool refresh on tables in KS 2.0 to say Cassandra
>>>> about them.
>>>>
>>>> On Tue, Oct 29, 2019 at 4:10 PM Ankit Gadhiya 
>>>> wrote:
>>>>
>>>>> Hello Folks,
>>>>>
>>>>> Greetings!.
>>>>>
>>>>> I've a requirement in my project to setup Blue-Green deployment for
>>>>> Cassandra. E.x. Say My current active schema (application pointing to) is
>>>>> Keyspace V1.0 and for my next release I want to setup Keysapce 2.0 (with
>>>>> some structural changes) and all testing/validation would happen on it and
>>>>> once successful , App would switch connection to keyspace 2.0 - This would
>>>>> be generic release deployment for our project.
>>>>>
>>>>> One of the approach we thought of would be to Create keyspace 2.0 as
>>>>> clone from Keyspace 1.0 including data using sstableloader but this would
>>>>> be time consuming, also being a multi-node cluster (6+6 in each DC) - it
>>>>> wouldn't be very feasible to do this manually on all the nodes for 
>>>>> multiple
>>>>> tables part of that keyspace. Was wondering if we have any other creative
>>>>> way to suffice this requirement.
>>>>>
>>>>> Appreciate your time on this.
>>>>>
>>>>>
>>>>> *Thanks & Regards,*
>>>>> *Ankit Gadhiya*
>>>>>
>>>>>
>>>>
>>>> --
>>>> With best wishes,Alex Ott
>>>> http://alexott.net/
>>>> Twitter: alexott_en (English), alexott (Russian)
>>>>
>>>


Re: Keyspace Clone in Existing Cluster

2019-10-29 Thread Paul Carlucci
Copy the schema from your source keyspace to your new target keyspace,
nodetool snapshot on your source keyspace, copy the SSTable files over, do
a rolling bounce, repair, enjoy.  In my experience a rolling bounce is
easier than a nodetool refresh.

It's either that or just copy it with Spark.

On Tue, Oct 29, 2019, 11:19 AM Ankit Gadhiya  wrote:

> Thanks Alex. So How do I copy SSTables from 1.0 to 2.0? (Same
> SSTableLoader or any other approach?)
> Also since I've multi-node cluster - I'll have to do this on every single
> node - is there any tool or better way to execute this just from a single
> node?
>
> *Thanks & Regards,*
> *Ankit Gadhiya*
>
>
>
> On Tue, Oct 29, 2019 at 11:16 AM Alex Ott  wrote:
>
>> You can create all tables in new keyspace, copy SSTables from 1.0 to 2.0
>> tables & use nodetool refresh on tables in KS 2.0 to say Cassandra about
>> them.
>>
>> On Tue, Oct 29, 2019 at 4:10 PM Ankit Gadhiya 
>> wrote:
>>
>>> Hello Folks,
>>>
>>> Greetings!.
>>>
>>> I've a requirement in my project to setup Blue-Green deployment for
>>> Cassandra. E.x. Say My current active schema (application pointing to) is
>>> Keyspace V1.0 and for my next release I want to setup Keysapce 2.0 (with
>>> some structural changes) and all testing/validation would happen on it and
>>> once successful , App would switch connection to keyspace 2.0 - This would
>>> be generic release deployment for our project.
>>>
>>> One of the approach we thought of would be to Create keyspace 2.0 as
>>> clone from Keyspace 1.0 including data using sstableloader but this would
>>> be time consuming, also being a multi-node cluster (6+6 in each DC) - it
>>> wouldn't be very feasible to do this manually on all the nodes for multiple
>>> tables part of that keyspace. Was wondering if we have any other creative
>>> way to suffice this requirement.
>>>
>>> Appreciate your time on this.
>>>
>>>
>>> *Thanks & Regards,*
>>> *Ankit Gadhiya*
>>>
>>>
>>
>> --
>> With best wishes,Alex Ott
>> http://alexott.net/
>> Twitter: alexott_en (English), alexott (Russian)
>>
>


Re: Dse keypsaces in apache cluster

2019-07-24 Thread Paul Carlucci
I only did in-place conversions from DSE to Apache Cassandra, but after
altering the replication scheme I later dropped those keyspaces after the
fact.  You can keep them there on Apache, they'll just be fallow and taking
up space.  Not even that much space anyway.  Don't forget to change the
authenticator, authorizer, and role manager.  It will fail to even start if
you don't.

On Wed, Jul 24, 2019, 6:45 PM Rahul Reddy  wrote:

> This is temporary migration
> stratergy
>
> On Wed, Jul 24, 2019, 6:22 PM Jonathan Koppenhofer 
> wrote:
>
>> To clarify... you have 2 datacenters with Datastax, and you want to
>> expand to a third DC with Opensource Cassandra? Is this a temporary
>> migration strategy? I would not want to run in this state for very long.
>>
>> For Datastax, you should reach out to their support for questions.
>> However, speaking from experience, these are required and will be created
>> upon restart of DSE nodes. Even worse, they use custom replication
>> strategies (EverywhereStrategy), that will prevent open source from
>> working, or the nodes from even starting. You can update EverywhereStrategy
>> to Network topology strategy, but be forewarned it will reset back to
>> EverywhereStrategy when you simply restart a Datastax node.
>>
>> Long story short, use Datastax support for info on their product, and be
>> very careful. Also note I don't have specific experience with your exact
>> scenario.
>>
>> (My experience with Datastax is version 4.6-5.0)
>>
>> On Wed, Jul 24, 2019, 10:34 AM Rahul Reddy 
>> wrote:
>>
>>> Hello,
>>>
>>> I have 2 data centers with dse Cassandra added new DC with apache
>>> Cassandra . Dse_perf,dse_systen,dse_security,dse_leases keypsaces created
>>> as well . Can we delete them ?
>>>
>>