Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 9AD31200CA3 for ; Wed, 3 May 2017 04:32:05 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 993AE160BAC; Wed, 3 May 2017 02:32:05 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 43647160B9D for ; Wed, 3 May 2017 04:32:04 +0200 (CEST) Received: (qmail 89598 invoked by uid 500); 3 May 2017 02:32:02 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 89586 invoked by uid 99); 3 May 2017 02:32:02 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 May 2017 02:32:02 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 451F31A088C for ; Wed, 3 May 2017 02:32:02 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.396 X-Spam-Level: X-Spam-Status: No, score=-0.396 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.796, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id jTlczOSlfghM for ; Wed, 3 May 2017 02:31:59 +0000 (UTC) Received: from mail-pg0-f47.google.com (mail-pg0-f47.google.com [74.125.83.47]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 50DCD5F3BB for ; Wed, 3 May 2017 02:31:59 +0000 (UTC) Received: by mail-pg0-f47.google.com with SMTP id o3so65278512pgn.2 for ; Tue, 02 May 2017 19:31:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:message-id:mime-version:subject:date:in-reply-to:cc:to :references; bh=9mMc0PiSrcu35gB/ZsB1Vnt/XMBBagQ7iWtQc/iB6XY=; b=R0wApef6mUQhBpdznWb2e/4tHLESjnKPs4nBUjEKg/vH6EQxx3BCBePciz/cx2P4xO aM8+U3JYVXgfoHGXm+o5rwFA0iighNOfjeSYmHezv1V8a9VRV2uwPJAVHued725xxx5o g6I+efVTQtXJ5JRamjaWf3/hk4nKt99Nbx7wCZTY0LBi9Lx8UknTIk6Vlg5r/PnEe9DY 6H9ndpVgiA33ko77qayx2lr0xtPZuVuvgUoerM8LwzEc74J0Bh57nF/6MAFIY9/zltvC s1+zTjjiEkmk/gzJ6j5UpP1J5iVMrT1olWs9GEh4yV1KoMxSoNBwnMvx47tcjHkoqDOo dwGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:message-id:mime-version:subject:date :in-reply-to:cc:to:references; bh=9mMc0PiSrcu35gB/ZsB1Vnt/XMBBagQ7iWtQc/iB6XY=; b=GzU0b1gfGWdcSSgrMhETJ/6mW0YQoVog2ieJHdwMSWWNVqwyNzfGhkHArV6nJwY2YE IhEX80uJHVM+HwL4NYlIuf2qan9aRiY3VDKvCQJ3zimE+TRpM7jzgcCH9TiK0FOtX7eS NmtnmwIoKOkCmkr17UeMKJsBs1Y1qImLoWYfLLPqbfj0VVUbTOvhcjn+GqJJm3kObFud xtkaGg5ILy3wichckfIhnXu1k2Di3GJHFWQchmSdNV23U3jFnKxfv+O28O6JNiLKpX/M +8jBd4ntellnp8qc/saZCIPUXHpila09FnjCGrMuqORNCVWZV0+9fAtF40Vjv/5vaMwD wc4Q== X-Gm-Message-State: AN3rC/6wi1rHClfgX+e7R+h+qRTtfAWaUDcZUsQoDvLzsdVhrb50H8l5 jVRzzyzWLtnsPQ== X-Received: by 10.99.127.70 with SMTP id p6mr37013542pgn.169.1493778711919; Tue, 02 May 2017 19:31:51 -0700 (PDT) Received: from [192.168.1.190] ([47.144.154.121]) by smtp.gmail.com with ESMTPSA id s83sm1165554pfa.128.2017.05.02.19.31.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 02 May 2017 19:31:50 -0700 (PDT) From: Jon Haddad Message-Id: <226FDF38-CE20-4449-800F-806979760A0C@gmail.com> Content-Type: multipart/alternative; boundary="Apple-Mail=_2943BF07-42F3-44E0-B63B-A52B83E66811" Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: Service discovery in the Cassandra cluster Date: Tue, 2 May 2017 19:31:49 -0700 In-Reply-To: Cc: Steve Robenalt , user@cassandra.apache.org To: Roman Naumenko References: <7D0490C5-0A17-4B51-BC53-67C0D629E119@sproutling.com> <882B490C-9C01-409B-869F-78C049D33A63@gmail.com> <5FE7174C-0132-4C0D-A53B-4A724B53A534@gmail.com> <7FA3DA8D-AC3F-4509-A6C1-CFC5BBA9ABA6@sproutling.com> <4018DCF8-AD25-43B3-B459-C84900F5AF2A@gmail.com> X-Mailer: Apple Mail (2.3273) archived-at: Wed, 03 May 2017 02:32:05 -0000 --Apple-Mail=_2943BF07-42F3-44E0-B63B-A52B83E66811 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 You=E2=80=99re free to supply your own Seed Provider. The Seed provider = that comes with cassandra needs hard coded IPs, but there=E2=80=99s no = reason why it has to be that way. =20 There=E2=80=99s a handful of ideas here: = https://issues.apache.org/jira/browse/CASSANDRA-12627 = Feel free to experiment, and good luck. > On May 2, 2017, at 6:48 PM, Roman Naumenko = wrote: >=20 > Service discovery (aka "note some IPs") should be part of the cluster = bootstrapping and management. >=20 > See for example how elastic is doing this. Or consul. Its pretty = standard practice these days. >=20 > -- > Roman >=20 > On Tue, May 2, 2017 at 5:08 PM Steve Robenalt > wrote: > Hi Roman, >=20 > I'm assuming you were intending your first statement to be in jest, = but it's really not that hard to startup a Cassandra cluster. The = defaults are pretty usable, so if all you want to do is set the IPs and = start it up, the cluster probably will just take care of everything = else. >=20 > So I jest a little bit too. It's normally desirable to set up storage = properly for your database, and there's a few options for which you = might want to change the defaults, such as the snitch.=20 >=20 > Still, if that means you only need to take note of of a couple of IPs = and designate them as seeds so your cluster can mostly manage itself, = you can say that's sad, but I'd say it's a small price to pay for all = that you don't have to do. >=20 > Steve >=20 > On Mon, May 1, 2017 at 4:55 PM, Roman Naumenko > wrote: > Lol yeah, why=20 > I guess I run some ec2 instances, drop some cassandra deb packages on = 'em - the thing will figure out how to run... >=20 > Also, how would you get "initial state of the cluster" if the = cluster... is being initialized?=20 > Or that's easy, according to the docs - just hardcode some seed IPs = into each node, lol >=20 > It's all kinda funny, but in a sad way. >=20 > On Mon, May 1, 2017 at 4:45 PM, Jon Haddad > wrote: > Why do you have to figure out what=E2=80=99s up w/ them by accident? = You=E2=80=99ve gotten all the information you need. Seeds are used to = get the initial state of the cluster and as an optimization to spread = gossip faster. That=E2=80=99s it. =20 >=20 >=20 >=20 >> On May 1, 2017, at 4:37 PM, Roman Naumenko > wrote: >>=20 >> Well, I guess I have to figure out what=E2=80=99s up with = IPs/hostnames by experiment. >> Information about service discovery is practically absent. >> Not to mention all important details about fqdns/hostnames, automatic = replacing seed nodes or what not.=20 >>=20 >> =E2=80=94 >> Roman >>=20 >>> On May 1, 2017, at 4:14 PM, Jon Haddad > wrote: >>>=20 >>> The in-tree docs do not mention this anywhere, and even have some of = the answers you=E2=80=99re asking: >>>=20 >>> = https://cassandra.apache.org/doc/latest/faq/index.html?highlight=3Dseed#wh= at-are-seeds = >>>=20 >>> The DataStax docs are maintained outside of the project, you=E2=80=99l= l have to ask them why they=E2=80=99re wrong or misleading. >>>=20 >>> Jon >>>=20 >>>> On May 1, 2017, at 4:10 PM, Roman Naumenko > wrote: >>>>=20 >>>> The docs mention IP addresses everywhere. >>>>=20 >>>> = http://docs.datastax.com/en/archived/cassandra/2.0/cassandra/operations/op= s_replace_seed_node.html = >>>> Promote an existing node to a seed node by adding its IP address to = -seeds list and remove (demote) the IP address of the dead seed node = from the cassandra.yaml file for each node in the cluster. >>>>=20 >>>> = http://docs.datastax.com/en/archived/cassandra/2.0/cassandra/operations/op= s_replace_node_t.html = >>>> Note the Address of the dead node; it is used in step 5. >>>>=20 >>>> = http://docs.datastax.com/en/cassandra/2.1/cassandra/initialize/initializeS= ingleDS.html = >>>>> Properties to set: >>>>> num_tokens: recommended value: 256 >>>>> -seeds: internal IP address of each seed node >>>>=20 >>>> I saw also hostnames mentioned few times, but it just makes it even = more confusing. >>>>=20 >>>> =E2=80=94 >>>> Roman >>>>=20 >>>>> On May 1, 2017, at 3:50 PM, Jon Haddad > wrote: >>>>>=20 >>>>> Sure, you could use DNS. Where does it say IP addresses are a = requirement? >>>>>=20 >>>>>> On May 1, 2017, at 1:36 PM, Roman Naumenko > wrote: >>>>>>=20 >>>>>> If I understand how Cassandra nodes work, they must contain a = list of seed=E2=80=99s IP addressed in config file. >>>>>>=20 >>>>>> This requirement makes cluster setup unnecessarily complicated. = Is it possible to use DNS name for seed nodes? >>>>>>=20 >>>>>> Thanks, >>>>>>=20 >>>>>> =E2=80=94 >>>>>> Roman >>>>>> = --------------------------------------------------------------------- >>>>>> To unsubscribe, e-mail: user-unsubscribe@cassandra.apache.org = >>>>>> For additional commands, e-mail: user-help@cassandra.apache.org = >>>>>>=20 >>>>>=20 >>>>=20 >>>=20 >>=20 >=20 >=20 >=20 >=20 >=20 > --=20 > Steve Robenalt > Software Architect, HighWire Press, Inc. >=20 > www.highwire.org | Los Gatos, CA| Belfast, = NI| Brighton, UK > = >=20 > HighWire Summer Publishers' Meeting, London, June 12-13 = > STM Annual US Conference, April 25-27: Michiel Klein Swormink and = Jennifer Chang are representing HighWire = > 2017 CSE Annual Meeting: John Sack is presenting on topic of Piracy, = May 23 > SSP Annual Meeting, May 31-June 2: Visit HighWire on Booth #101A = >=20 >=20 > =20 >=20 --Apple-Mail=_2943BF07-42F3-44E0-B63B-A52B83E66811 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8
You=E2=80=99re free to supply your own Seed = Provider.  The Seed provider that comes with cassandra needs hard = coded IPs, but there=E2=80=99s no reason why it has to be that way. =  

There=E2=80= =99s a handful of ideas here: https://issues.apache.org/jira/browse/CASSANDRA-12627
=

Feel free to = experiment, and good luck.

On = May 2, 2017, at 6:48 PM, Roman Naumenko <roman@sproutling.com> wrote:

Service discovery (aka "note some IPs") should be part of the = cluster bootstrapping and management.

See for example how elastic is doing = this. Or consul. Its pretty standard practice these days.

--
Roman

On Tue, May 2, 2017 at 5:08 PM = Steve Robenalt <srobenalt@highwire.org> wrote:
Hi = Roman,

I'm assuming = you were intending your first statement to be in jest, but it's really = not that hard to startup a Cassandra cluster. The defaults are pretty = usable, so if all you want to do is set the IPs and start it up, the = cluster probably will just take care of everything else.

So I jest a little bit = too. It's normally desirable to set up storage properly for your = database, and there's a few options for which you might want to change = the defaults, such as the snitch. 

Still, if that means you only need to = take note of of a couple of IPs and designate them as seeds so your = cluster can mostly manage itself, you can say that's sad, but I'd say = it's a small price to pay for all that you don't have to do.

Steve

On Mon, May 1, 2017 at 4:55 PM, Roman Naumenko = <roman@sproutling.com> = wrote:
Lol = yeah, why 
I guess I run some ec2 instances, drop = some cassandra deb packages on 'em - the thing will figure out how to = run...

Also, how = would you get "initial state of the cluster" if the cluster... is being = initialized? 
Or that's easy, according to the = docs - just hardcode some seed IPs into each node, lol

It's all kinda funny, = but in a sad way.

On Mon, May 1, 2017 at 4:45 PM, = Jon Haddad <jonathan.haddad@gmail.com> wrote:
Why do you = have to figure out what=E2=80=99s up w/ them by accident?  You=E2=80=99= ve gotten all the information you need.  Seeds are used to get the = initial state of the cluster and as an optimization to spread gossip = faster.  That=E2=80=99s it.  


On May = 1, 2017, at 4:37 PM, Roman Naumenko <roman@sproutling.com> wrote:

Well, I guess = I have to figure out what=E2=80=99s up with IPs/hostnames by = experiment.
Information about service discovery is = practically absent.
Not to mention all important = details about fqdns/hostnames, automatic replacing seed nodes or what = not. 

=E2=80=94
Roman

On May 1, 2017, at 4:14 PM, Jon Haddad <jonathan.haddad@gmail.com> wrote:

The in-tree = docs do not mention this anywhere, and even have some of the answers = you=E2=80=99re asking:


The DataStax docs are maintained outside of the project, = you=E2=80=99ll have to ask them why they=E2=80=99re wrong or = misleading.

Jon

On May = 1, 2017, at 4:10 PM, Roman Naumenko <roman@sproutling.com> wrote:

The docs = mention IP addresses everywhere.

Promote an existing node to a seed node by adding its IP = address to -seeds list and remove (demote) the IP address of the dead = seed node from the cassandra.yaml file for each node in the = cluster.

Note the Address of the dead node; it is used in step = 5.

Properties to set:
num_tokens: recommended value: 256
-seeds:= internal IP address of each seed node

I saw also hostnames mentioned few times, but it just makes it = even more confusing.

=E2=80=94
Roman

On May = 1, 2017, at 3:50 PM, Jon Haddad <jonathan.haddad@gmail.com> wrote:

Sure, you could = use DNS.  Where does it say IP addresses are a requirement?

On May 1, = 2017, at 1:36 PM, Roman Naumenko <roman@sproutling.com> wrote:

If I understand how Cassandra nodes work, they must contain a = list of seed=E2=80=99s IP addressed in config file.

This requirement makes cluster setup unnecessarily = complicated. Is it possible to use DNS name for seed nodes?

Thanks,

=E2=80=94Roman
---------------------------------------------------------------= ------
To unsubscribe, e-mail: user-unsubscribe@cassandra.apache.org
For = additional commands, e-mail: user-help@cassandra.apache.org











= --Apple-Mail=_2943BF07-42F3-44E0-B63B-A52B83E66811--