Re: Timeout for only one keyspace in cluster

2018-07-18 Thread wxn...@zjqunshuo.com
Your partition key is foreignid. You may have a large partition. Why not use 
foreignid+timebucket as partition key?
 
From: learner dba
Date: 2018-07-19 01:48
To: User cassandra.apache.org
Subject: Timeout for only one keyspace in cluster
Hi,

We have a cluster with multiple keyspaces. All queries are performing good but 
write operation on few tables in one specific keyspace gets write timeout. 
Table has counter column and counter update query times out always. Any idea?

CREATE TABLE x.y (
foreignid uuid,
timebucket text,
key text,
timevalue int,
value counter,
PRIMARY KEY (foreignid, timebucket, key, timevalue)
) WITH CLUSTERING ORDER BY (timebucket ASC, key ASC, timevalue ASC)
AND bloom_filter_fp_chance = 0.01
AND caching = {'keys': 'ALL', 'rows_per_partition': 'NONE'}
AND comment = ''
AND compaction = {'class': 
'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy', 
'max_threshold': '32', 'min_threshold': '4'}
AND compression = {'chunk_length_in_kb': '64', 'class': 
'org.apache.cassandra.io.compress.LZ4Compressor'}
AND crc_check_chance = 1.0
AND dclocal_read_repair_chance = 0.1
AND default_time_to_live = 0
AND gc_grace_seconds = 864000
AND max_index_interval = 2048
AND memtable_flush_period_in_ms = 0
AND min_index_interval = 128
AND read_repair_chance = 0.0
AND speculative_retry = '99PERCENTILE';

Query and Error:

UPDATE x.y SET value = value + 1 where foreignid = ? AND timebucket = ? AND key 
= ? AND timevalue = ?, err = {s:\"gocql: no response 
received from cassandra within timeout period
I verified CL=local_serialWe had been working on this issue for many days; any 
help will be much appreciated.



Timeout for only one keyspace in cluster

2018-07-18 Thread learner dba
Hi,
We have a cluster with multiple keyspaces. All queries are performing good but 
write operation on few tables in one specific keyspace gets write timeout. 
Table has counter column and counter update query times out always. Any idea?

CREATE TABLE x.y (

    foreignid uuid,

    timebucket text,

    key text,

    timevalue int,

    value counter,

    PRIMARY KEY (foreignid, timebucket, key, timevalue)

) WITH CLUSTERING ORDER BY (timebucket ASC, key ASC, timevalue ASC)

    AND bloom_filter_fp_chance = 0.01

    AND caching = {'keys': 'ALL', 'rows_per_partition': 'NONE'}

    AND comment = ''

    AND compaction = {'class': 
'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy', 
'max_threshold': '32', 'min_threshold': '4'}

    AND compression = {'chunk_length_in_kb': '64', 'class': 
'org.apache.cassandra.io.compress.LZ4Compressor'}

    AND crc_check_chance = 1.0

    AND dclocal_read_repair_chance = 0.1

    AND default_time_to_live = 0

    AND gc_grace_seconds = 864000

    AND max_index_interval = 2048

    AND memtable_flush_period_in_ms = 0

    AND min_index_interval = 128

    AND read_repair_chance = 0.0

    AND speculative_retry = '99PERCENTILE';

Query and Error:
UPDATE x.y SET value = value + 1 where foreignid = ? AND timebucket = ? AND key 
= ? AND timevalue = ?, err = {s:\"gocql: no response 
received from cassandra within timeout period
I verified CL=local_serialWe had been working on this issue for many days; any 
help will be much appreciated.



IllegalArgumentException while saving RDD to cassandra using Spark Cassandra Connector

2018-07-18 Thread M Singh
Hi Cassandra/Spark experts:
I am working with on a project to save Spark dataframe to cassandra and am 
getting an exception regarding row size not valid (see below). I tried to trace 
the code in the connector and it appears that the row size (3 below) is 
different from the column count (which turns out be 1).  I am trying to follow 
the example from 
https://github.com/datastax/spark-cassandra-connector/blob/master/doc/2_loading.md
 with customer having two more fields than just the id as mentioned in the 
example.  In case of the example I think it will work because it has only 1 
column (customer_id) but I need to save additional fields.  I've tried 
searching but have not found any resolution to this.
I am using Spark 2.3.0 and spark-cassandra-connector:2.3.0-s_2.11.
Just a little background - I tried saving the dataframe to cassandra and it 
works.  However, it is very slow.  So I am trying to see if using 
repartitionByCassandraReplica will make it faster.  I've tried various 
combinations of batch rows size, concurrent writers, etc on data frame and it 
is still very slow.  Therefore I am looking at using 
repartitionByCassandraReplica before trying to save it to the cassandra table.  
If there are other options to make saving dataframe to cassandra faster, please 
let me know.
Here is my scenario:
Cassandra table in keyspace test - create table customer ( customer_id text 
primary key, order integer, value integer);Spark shell commands:   import 
com.datastax.spark.connector._  import org.apache.spark.sql.cassandra._  case 
class Customer(customer_id:String, order_id:Int, value:Int)
  val customers = 
Seq(Customer("1",1,1),Customer("2",2,2)).toDF("customer_id","order_id","value") 
 val customersRdd = 
customers.rdd.repartitionByCassandraReplica("test","customers")  
customersRdd.saveToCassandra("test","customer")

At this point I get an exception :
java.lang.IllegalArgumentException: requirement failed: Invalid row size: 3 
instead of 1. at scala.Predef$.require(Predef.scala:224) at 
com.datastax.spark.connector.writer.SqlRowWriter.readColumnValues(SqlRowWriter.scala:23)
 at 
com.datastax.spark.connector.writer.SqlRowWriter.readColumnValues(SqlRowWriter.scala:12)
 at 
com.datastax.spark.connector.writer.BoundStatementBuilder.bind(BoundStatementBuilder.scala:99)
 at 
com.datastax.spark.connector.rdd.partitioner.TokenGenerator.getPartitionKeyBufferFor(TokenGenerator.scala:38)
 at 
com.datastax.spark.connector.rdd.partitioner.ReplicaPartitioner.getPartition(ReplicaPartitioner.scala:70)
 at 
org.apache.spark.shuffle.sort.BypassMergeSortShuffleWriter.write(BypassMergeSortShuffleWriter.java:151)
 at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:96) 
at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:53) 
at org.apache.spark.scheduler.Task.run(Task.scala:108) at 
org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:335) at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) 
at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) 
at java.lang.Thread.run(Thread.java:745)18/07/18 10:27:51 ERROR Executor: 
Exception in task 1.0 in stage 6.0 (TID 4)java.lang.IllegalArgumentException: 
requirement failed: Invalid row size: 3 instead of 1.
Thanks for your help.


Re: concurrent_compactors via JMX

2018-07-18 Thread Riccardo Ferrari
Chris,

Thank you for mbean reference.

On Wed, Jul 18, 2018 at 6:26 PM, Riccardo Ferrari 
wrote:

> Alain, thank you for email. I really really appreciate it!
>
> I am actually trying to remove the disk io from the suspect list, thus I'm
> want to reduce the number of concurrent compactors. I'll give thorughput a
> shot.
> No, I don't have a long list of pending compactions, however my instances
> are still on magnetic drivers and can't really afford high number of
> compactors.
>
> We started to have slow downs and most likely we were undersized, new
> features are coming in and I want to be ready for them.
> *About the issue:*
>
>
>- High system load on cassanda nodes. This means top saying 6.0/12.0
>on a 4 vcpu instance (!)
>
>
>- CPU is high:
>  - Dynatrace says 50%
>  - top easily goes to 80%
>   - Network around 30Mb (according to Dynatrace)
>   - Disks:
>  - ~40 iops
>  - high latency: ~20ms (min 8 max 50!)
>  - negligible iowait
>  - testing an empty instance with fio I get 1200 r_iops / 400
>  w_iops
>
>
>- Clients timeout
>   - mostly when reading
>   - few cases when writing
>- Slowly growing number of "All time blocked of Native T-R"
>   - small numbers: hundreds vs millions of successfully serverd
>   requests
>
> The system:
>
>- Cassandra 3.0.6
>   - most tables on LCS
>  - frequent r/w pattern
>   - few tables with DTCS
>  - need to upgrade to 3.0.8 for TWCS
>  - mostly TS data, stream write / batch read
>   - All our keyspaces have RF: 3
>
>
>- All nodes on the same AZ
>- m1.xlarge
>- 4x420 drives (emphemerial storage) configured in striping (raid0)
>   - 4 vcpu
>   - 15GB ram
>- workload:
>   - Java applications;
>  - Mostly feeding cassandra writing data coming in
>  - Apache Spark applications:
>  - batch processes to read and write back to C* or other systems
>  - not co-located
>
> So far my effort was put into growing the ring to better distribute the
> load and decrease the pressure, including:
>
>- Increasing the node number from 3 to 5 (6th node joining)
>- jvm memory "optimization":
>- heaps were set by default script to something bit smaller that 4GB
>   with CMS gc
>   - gc pressure was high / long gc pauses
>  - clients were suffering of read timeouts
>   - increased the heap still using CMS:
>  - very long GC pauses
>  - not much tuning around CMS
>  - switched to G1 and forced 6/7GB heap on each node using almost
>   suggested settings
>   - much more stable
> - generally < 300ms
>  - I still have long pauses from time to time (mostly around
>  1200ms, sometimes on some nodes 3000)
>
> *Thinking out loud:*
> Things are much better, however I still see a high cpu usage specially
> when Spark kicks even though spark jobs are very small in terms of
> resources (single worker with very limited parallelism).
>
> On LCS tables cfstats reports single digit read latencies and generally
> 0.X write latencies (as per today).
> On DTCS tables I have 0.x ms write latency but still double digit read
> latency, but I guess I should spend some time to tune that or upgrade and
> move away from DTCS :(
> Yes, Saprk reads mostly from DTCS tables
>
> Still is kinda common to to have dropped READ, HINT and MUTATION.
>
>- not on all nodes
>- this generally happen on node restart
>
>
> On a side note I tried to install libjemalloc1 from Ubuntu repo (mixed
> 14.04 and 16.04) with terrible results, much slower instance startup and
> responsiveness, how could that be?
>
> Once everything will be stabilized I'll prepare our move to vpc and
> possibly upgrade to i3 instance, any comment on the hardware side?  is
> 4cores still a reasonble hardware?
>
> Best,
>
> On Tue, Jul 17, 2018 at 9:18 PM, Alain RODRIGUEZ 
> wrote:
>
>> Hello Riccardo,
>>
>> I noticed I have been writing a novel to answer a simple couple of
>> questions again ¯\_(ツ)_/¯. So here is a short answer in the case that's
>> what you were looking for :). Also, there is a warning that it might be
>> counter-productive and stress the cluster even more to increase the
>> compaction throughput. There is more information below ('about the issue').
>>
>> *tl;dr*:
>>
>> What about using 'nodetool setcompactionthroughput XX' instead. It
>> should available there.
>>
>> In the same way 'nodetool getcompactionthroughput' gives you the current
>> value. Be aware that this change done through JMX/nodetool is *not* 
>> permanent.
>> You still need to update the cassandra.yaml file.
>>
>> If you really want to use the MBean through JMX, because using 'nodetool'
>> is too easy (or for any other reason :p):
>>
>> Mbean: org.apache.cassandra.service.StorageServiceMBean
>> Attribute: CompactionThroughputMbPerSec
>>
>> *Long story* with the "how to" since I 

Re: concurrent_compactors via JMX

2018-07-18 Thread Riccardo Ferrari
Alain, thank you for email. I really really appreciate it!

I am actually trying to remove the disk io from the suspect list, thus I'm
want to reduce the number of concurrent compactors. I'll give thorughput a
shot.
No, I don't have a long list of pending compactions, however my instances
are still on magnetic drivers and can't really afford high number of
compactors.

We started to have slow downs and most likely we were undersized, new
features are coming in and I want to be ready for them.
*About the issue:*


   - High system load on cassanda nodes. This means top saying 6.0/12.0 on
   a 4 vcpu instance (!)


   - CPU is high:
 - Dynatrace says 50%
 - top easily goes to 80%
  - Network around 30Mb (according to Dynatrace)
  - Disks:
 - ~40 iops
 - high latency: ~20ms (min 8 max 50!)
 - negligible iowait
 - testing an empty instance with fio I get 1200 r_iops / 400 w_iops


   - Clients timeout
  - mostly when reading
  - few cases when writing
   - Slowly growing number of "All time blocked of Native T-R"
  - small numbers: hundreds vs millions of successfully serverd requests

The system:

   - Cassandra 3.0.6
  - most tables on LCS
 - frequent r/w pattern
  - few tables with DTCS
 - need to upgrade to 3.0.8 for TWCS
 - mostly TS data, stream write / batch read
  - All our keyspaces have RF: 3


   - All nodes on the same AZ
   - m1.xlarge
   - 4x420 drives (emphemerial storage) configured in striping (raid0)
  - 4 vcpu
  - 15GB ram
   - workload:
  - Java applications;
 - Mostly feeding cassandra writing data coming in
 - Apache Spark applications:
 - batch processes to read and write back to C* or other systems
 - not co-located

So far my effort was put into growing the ring to better distribute the
load and decrease the pressure, including:

   - Increasing the node number from 3 to 5 (6th node joining)
   - jvm memory "optimization":
   - heaps were set by default script to something bit smaller that 4GB
  with CMS gc
  - gc pressure was high / long gc pauses
 - clients were suffering of read timeouts
  - increased the heap still using CMS:
 - very long GC pauses
 - not much tuning around CMS
 - switched to G1 and forced 6/7GB heap on each node using almost
  suggested settings
  - much more stable
- generally < 300ms
 - I still have long pauses from time to time (mostly around
 1200ms, sometimes on some nodes 3000)

*Thinking out loud:*
Things are much better, however I still see a high cpu usage specially when
Spark kicks even though spark jobs are very small in terms of resources
(single worker with very limited parallelism).

On LCS tables cfstats reports single digit read latencies and generally 0.X
write latencies (as per today).
On DTCS tables I have 0.x ms write latency but still double digit read
latency, but I guess I should spend some time to tune that or upgrade and
move away from DTCS :(
Yes, Saprk reads mostly from DTCS tables

Still is kinda common to to have dropped READ, HINT and MUTATION.

   - not on all nodes
   - this generally happen on node restart


On a side note I tried to install libjemalloc1 from Ubuntu repo (mixed
14.04 and 16.04) with terrible results, much slower instance startup and
responsiveness, how could that be?

Once everything will be stabilized I'll prepare our move to vpc and
possibly upgrade to i3 instance, any comment on the hardware side?  is
4cores still a reasonble hardware?

Best,

On Tue, Jul 17, 2018 at 9:18 PM, Alain RODRIGUEZ  wrote:

> Hello Riccardo,
>
> I noticed I have been writing a novel to answer a simple couple of
> questions again ¯\_(ツ)_/¯. So here is a short answer in the case that's
> what you were looking for :). Also, there is a warning that it might be
> counter-productive and stress the cluster even more to increase the
> compaction throughput. There is more information below ('about the issue').
>
> *tl;dr*:
>
> What about using 'nodetool setcompactionthroughput XX' instead. It should
> available there.
>
> In the same way 'nodetool getcompactionthroughput' gives you the current
> value. Be aware that this change done through JMX/nodetool is *not* permanent.
> You still need to update the cassandra.yaml file.
>
> If you really want to use the MBean through JMX, because using 'nodetool'
> is too easy (or for any other reason :p):
>
> Mbean: org.apache.cassandra.service.StorageServiceMBean
> Attribute: CompactionThroughputMbPerSec
>
> *Long story* with the "how to" since I went through this search myself, I
> did not know where this MBean was.
>
> Can someone point me to the right mbean?
>> I can not really find good docs about mbeans (or tools ...)
>
>
> I am not sure about the doc, but you can use jmxterm (
> http://wiki.cyclopsgroup.org/jmxterm/download.html).
>
> To replace the doc I use CCM 

Re: apache cassandra development process and future

2018-07-18 Thread Rahul Singh
YgaByte!!! <— another Cassandra “compliant" DB - not sure if they forked C* 
or wrote Cassandra in go. ;)
https://github.com/YugaByte/yugabyte-db

Datastax is Cassandra compliant — and can use the same sstables at least until 
6.0 (which uses a patched version of  “4.0” which is 2-5x faster) — and has the 
same actual tools that are in the OS version.

Here are some signals from the big players that are understanding it’s power 
and need.

1. Azure CosmosDB has a C* compliant API - seems like Managed C* under the 
hood. They used ElasticSearch to run their Azure Search …
2. Oracle now has a Datastax offering
3. Mesosphere offers supported versions of Cassandra and Datastax
4. Kubernetes and related purveyors use Cassandra as prime example as a part of 
a Kubernetes backed cloud agnostic orchestration framework
5. What Alain mentioned earlier.


--
Rahul Singh
rahul.si...@anant.us

Anant Corporation
On Jul 18, 2018, 9:35 AM -0400, Alain RODRIGUEZ , wrote:
> Hello,
>
> It's a complex topic that has already been extensively discussed (at least 
> for the part about Datastax). I am sharing my personal understanding, from 
> what I read in the mailing list mostly:
>
> > Recently Cassandra eco system became very fragmented
>
> I would not put Scylladb in the same 'eco system' than Apache Cassandra. I 
> believed it is inspired by Cassandra and claim to be compatible with it up to 
> a certain point, but it's not the same software, thus not the same users and 
> community.
>
> About Datastax, I think they will give you a better idea of their position by 
> themselves here or through their support. I believe they also communicated 
> about it already. But in any case, I see Datastax more in the same 'eco 
> system' than Scylladb. Datastax uses a patched/forked version of Cassandra (+ 
> some other tools integrated with Cassandra and support). Plus it goes both 
> ways, Datastax greatly contributed to making Cassandra what it is now and 
> relies on it (or use to do so at least). I don't think that's the case for 
> Scylladb I don't see that much interest in connection/exchanges with 
> Scylladb, I mean no more than exchanging about DynamoDB for example. We can 
> make standards, compatibles features, compare performances, etc, but it's not 
> the same code base.
>
> > Since Datastax used to be the major participant to Cassandra
> > development and now it looks it goes on is own way, what is going to
> > be with the Apache Cassandra?
>
> Well, this is a fair point, that was discussed in the past, but to make it 
> short, Apache Cassandra is not dead or anything close. There is a lot of 
> activity. Some people are stepping out, other stepping in, and other 
> companies and individual are actively contributing to Cassandra. A version 
> 4.0 of Cassandra is being actively worked on at the moment. If these topics 
> are of interest, you might want to join the "Cassandra dev" mailing list 
> (http://cassandra.apache.org/community/).
>
> > If there are any other active participants in development?
>
> Yes, directly or by open sourcing internal tools quite a few companies have 
> contributed and continue to contribute to the Apache Cassandra ecosystem. I 
> invite you to have a look directly at this dev mailing list and check 
> people's email, profiles or companies. Check the Jira as well :). I am not 
> into doing this kind of stuff that much myself, I am not following this 
> closely but I can name for sure Apple, Netflix, The Last Pickle (my company), 
> Instaclustr I believe as well and many others that I am sorry not to name 
> here.
>
> Some people are working on Apache Cassandra for years and are around to help 
> regularly, they changed company but are still working on Cassandra, or even 
> changed company to work more with Apache Cassandra in some cases.
>
> > I'm also interested which distribution is the most popular at the
> > moment in production?
>
> I would say now you should start with C*3.0.last or C* 3.11.last. It seems to 
> be the general consensus in the mailing list lately.
> For Scylladb and Datastax I don't know about the version to use. You should 
> ask them directly.
>
> C*heers,
> ---
> Alain Rodriguez - @arodream - al...@thelastpickle.com
> France / Spain
>
> The Last Pickle - Apache Cassandra Consulting
> http://www.thelastpickle.com
>
> > 2018-07-18 12:39 GMT+01:00 Vitaliy Semochkin :
> > > Hi,
> > >
> > > Recently Cassandra eco system became very fragmented:
> > >
> > > Scylladb provides solution based on Cassandra wire protocol claiming
> > > it is 10 times faster than Cassandra.
> > >
> > > Datastax provides it's own solution called DSE claiming it is twice
> > > faster than Cassandra.
> > > Also their site says "DataStax no longer supports the DataStax
> > > Community version of Apache Cassandra™ or the DataStax Distribution of
> > > Apache Cassandra™.
> > > Is their new software incompatible with Cassandra?
> > > Since Datastax used to be the major participant 

Re: concurrent_compactors via JMX

2018-07-18 Thread Chris Lohfink
Refer to Alains email but to strictly answer the question of increasing 
concurrent_compactors via jmx:

There are two attributes you can increase that would set the maximum number of 
concurrent compactions.

org.apache.cassandra.db:type=CompactionManager,name=MaximumCompactorThreads  -> 
6
org.apache.cassandra.db:type=CompactionManager,name=CoreCompactorThreads -> 6

Would set it to 6. To decrease them you will want to go opposite order (core 
than max). Just increasing the number of concurrent compactors doesnt mean that 
all of them will be utilized though.

Chris

> On Jul 17, 2018, at 12:18 PM, Alain RODRIGUEZ  wrote:
> 
> Hello Riccardo,
> 
> I noticed I have been writing a novel to answer a simple couple of questions 
> again ¯\_(ツ)_/¯. So here is a short answer in the case that's what you were 
> looking for :). Also, there is a warning that it might be counter-productive 
> and stress the cluster even more to increase the compaction throughput. There 
> is more information below ('about the issue').
> 
> tl;dr: 
> 
> What about using 'nodetool setcompactionthroughput XX' instead. It should 
> available there.
> 
> In the same way 'nodetool getcompactionthroughput' gives you the current 
> value. Be aware that this change done through JMX/nodetool is not permanent. 
> You still need to update the cassandra.yaml file.
> 
> If you really want to use the MBean through JMX, because using 'nodetool' is 
> too easy (or for any other reason :p):
> 
> Mbean: org.apache.cassandra.service.StorageServiceMBean
> Attribute: CompactionThroughputMbPerSec
> 
> Long story with the "how to" since I went through this search myself, I did 
> not know where this MBean was.
> 
> Can someone point me to the right mbean? 
> I can not really find good docs about mbeans (or tools ...) 
> 
> I am not sure about the doc, but you can use jmxterm 
> (http://wiki.cyclopsgroup.org/jmxterm/download.html 
> ).
> 
> To replace the doc I use CCM (https://github.com/riptano/ccm 
> ) + jconsole to find the mbeans locally:
> 
> * Add loopback addresses for ccm (see the readme file)
> * then, create the cluster: * 'ccm create Cassandra-3-0-6 -v 3.0.6 -n 3 -s'
> * Start jconsole using the right pid: 'jconsole $(ccm node1 show | grep pid | 
> cut -d "=" -f 2)'
> * Explore MBeans, try to guess where this could be (and discover other funny 
> stuff in there :)).
> 
> I must admit I did not find it this way using C*3.0.6 and jconsole. 
> I looked at the code, I locally used C*3.0.6 and ran 'grep -RiI 
> CompactionThroughput' with this result: 
> https://gist.github.com/arodrime/f9591e4bdd2b1367a496447cdd959006 
> 
> 
> With this I could find the right MBean, the only code documentation that is 
> always up to date is the code itself I am afraid:
> 
> './src/java/org/apache/cassandra/service/StorageServiceMBean.java:public 
> void setCompactionThroughputMbPerSec(int value);' 
> 
> Note that the research in the code also leads to nodetool ;-).
> 
> I could finally find the MBean in the 'jconsole' too: 
> https://cdn.pbrd.co/images/HuUya3x.png 
>  (not sure how long this link will 
> live).
> 
> jconsole also allows you to see what attributes it is possible to set or not.
> 
> You can now find any other MBean you would need I hope :).
> 
> 
> see if it helps when the system is under stress
> 
> About the issue
> 
> You don't exactly say what you are observing, what is that "stress"? How is 
> it impacting the cluster?
> 
> I ask because I am afraid this change might not help and even be 
> counter-productive. Even though having SSTables nicely compacted make a huge 
> difference at the read time, if that's already the case for you and the data 
> is already nicely compacted, doing this change won't help. It might even make 
> things slightly worse if the current bottleneck is the disk IO during a 
> stress period as the compactors would increase their disk read throughput, 
> thus maybe fight with the read requests for disk throughput.
> 
> If you have a similar number of sstables on all nodes, not many compactions 
> pending (nodetool netstats -H) and read operations are hitting a small number 
> sstables (nodetool tablehistogram) then you probably don't need to increase 
> the compaction speed.
> 
> Let's say that the compaction throughput is not often the cause of stress 
> during peak hours nor a direct way to make things 'faster'. Generally when 
> compaction goes wrong, the number of sstables goes through the roof. If you 
> have a chart showing the number sstables, you can see this really well.
> 
> Of course, if you feel you are in this case, increasing the compaction 
> throughput will definitely help if the cluster also has spared disk 
> throughput.
> 
> To check what's wrong, if you believe it's something different, here are some 
> useful 

Re: apache cassandra development process and future

2018-07-18 Thread Jeff Jirsa
There are 4+ implementations of CQL in addition to Apache Cassandra - the
ones I can think of off the top of my head include DSE, Yugabyte, CosmosDB,
and Scylla.

You'll want to define "popular". If by popular you mean "which
implementation of CQL has the most installed servers", nobody knows for
sure, but I would GUESS that it's either Apache Cassandra or CosmosDB
potentially second (though it's hard to be sure how many of them use the
CQL layer) in 1/2, DSE in third, and everyone else far, far, far behind
(multiple orders of magnitude). If you mean popular as in "who shows up in
news articles", well, that tends to favor people who have marketing
budgets, which isn't going to be Apache Cassandra.

The new DSE appears to be compatible with Cassandra, but you'd have to ask
Datastax whether or not it's drop-in compatible (in the past it was, I
suspect it still is).

There continues to be active development on the project, much of it driven
by large users rather than commercial vendors - this has the advantage that
feature development tends to be focused around things people actually need,
not things companies are likely to want to sell. Companies like Netflix,
Instagram, and Uber all presented talks at the past NGCC (Next Generation
Cassandra Conference) on features that matter to them, and we saw talks
from Instaclustr (hosted cassandra-as-a-service) and Yahoo-JP on some
current issues they see/face, so there continues to be an active community.

I'm not personally worried about Cassandra's future path - the footprint is
solid (and growing), the community doesn't have a loud advocate, but the
active contributions are there.

- Jeff



On Wed, Jul 18, 2018 at 4:39 AM, Vitaliy Semochkin 
wrote:

> Hi,
>
> Recently Cassandra eco system became very fragmented:
>
> Scylladb provides solution based on Cassandra wire protocol claiming
> it is 10 times faster than Cassandra.
>
> Datastax provides it's own solution called DSE claiming it is twice
> faster than Cassandra.
> Also their site says "DataStax no longer supports the DataStax
> Community version of Apache Cassandra™ or the DataStax Distribution of
> Apache Cassandra™.
> Is their new software incompatible with Cassandra?
> Since Datastax used to be the major participant to Cassandra
> development and now it looks it goes on is own way, what is going to
> be with the Apache Cassandra?
> If there are any other active participants in development?
>
> I'm also interested which distribution is the most popular at the
> moment in production?
>
> Best Regards,
> Vitaliy
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


Re: apache cassandra development process and future

2018-07-18 Thread Alain RODRIGUEZ
Hello,

It's a complex topic that has already been extensively discussed (at least
for the part about Datastax). I am sharing my personal understanding, from
what I read in the mailing list mostly:

Recently Cassandra eco system became very fragmented
>

I would not put Scylladb in the same 'eco system' than Apache Cassandra. I
believed it is inspired by Cassandra and claim to be compatible with it up
to a certain point, but it's not the same software, thus not the same users
and community.

About Datastax, I think they will give you a better idea of their position
by themselves here or through their support. I believe they also
communicated about it already. But in any case, I see Datastax more in the
same 'eco system' than Scylladb. Datastax uses a patched/forked version of
Cassandra (+ some other tools integrated with Cassandra and support). Plus
it goes both ways, Datastax greatly contributed to making Cassandra what it
is now and relies on it (or use to do so at least). I don't think that's
the case for Scylladb I don't see that much interest in
connection/exchanges with Scylladb, I mean no more than exchanging about
DynamoDB for example. We can make standards, compatibles features, compare
performances, etc, but it's not the same code base.

Since Datastax used to be the major participant to Cassandra
> development and now it looks it goes on is own way, what is going to
> be with the Apache Cassandra?
>

Well, this is a fair point, that was discussed in the past, but to make it
short, Apache Cassandra is not dead or anything close. There is a lot of
activity. Some people are stepping out, other stepping in, and other
companies and individual are actively contributing to Cassandra. A version
4.0 of Cassandra is being actively worked on at the moment. If these topics
are of interest, you might want to join the "Cassandra dev" mailing list (
http://cassandra.apache.org/community/).

If there are any other active participants in development?
>

Yes, directly or by open sourcing internal tools quite a few companies have
contributed and continue to contribute to the Apache Cassandra ecosystem. I
invite you to have a look directly at this dev mailing list and check
people's email, profiles or companies. Check the Jira as well :). I am not
into doing this kind of stuff that much myself, I am not following this
closely but I can name for sure Apple, Netflix, The Last Pickle (my
company), Instaclustr I believe as well and many others that I am sorry not
to name here.

Some people are working on Apache Cassandra for years and are around to
help regularly, they changed company but are still working on Cassandra, or
even changed company to work more with Apache Cassandra in some cases.

I'm also interested which distribution is the most popular at the
> moment in production?


I would say now you should start with C*3.0.last or C* 3.11.last. It seems
to be the general consensus in the mailing list lately.
For Scylladb and Datastax I don't know about the version to use. You should
ask them directly.

C*heers,
---
Alain Rodriguez - @arodream - al...@thelastpickle.com
France / Spain

The Last Pickle - Apache Cassandra Consulting
http://www.thelastpickle.com

2018-07-18 12:39 GMT+01:00 Vitaliy Semochkin :

> Hi,
>
> Recently Cassandra eco system became very fragmented:
>
> Scylladb provides solution based on Cassandra wire protocol claiming
> it is 10 times faster than Cassandra.
>
> Datastax provides it's own solution called DSE claiming it is twice
> faster than Cassandra.
> Also their site says "DataStax no longer supports the DataStax
> Community version of Apache Cassandra™ or the DataStax Distribution of
> Apache Cassandra™.
> Is their new software incompatible with Cassandra?
> Since Datastax used to be the major participant to Cassandra
> development and now it looks it goes on is own way, what is going to
> be with the Apache Cassandra?
> If there are any other active participants in development?
>
> I'm also interested which distribution is the most popular at the
> moment in production?
>
> Best Regards,
> Vitaliy
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


Re: System auth empty, how to populate it

2018-07-18 Thread Thomas Lété
Oh man you just saved me ^^

I missed your link, I had just removed the users table, not the others… Now 
they are gone and the password auth is working great !

Thanks a lot everyone for your help !!! :-)

> Le 18 juil. 2018 à 13:33, Sam Tunnicliffe  a écrit :
> 
> The salted hash being different is fine, the bcrypt library generates a 
> random 128 bit salt when encrypting a new password. The salt is then encoded 
> in the hashed string so you'd expect a different salted_hash each time a 
> given plaintext string is encoded.
> 
> I inserted exactly that data into a clean system, then switched it to use 
> PasswordAuthenticator and I can login using the default credentials without 
> any issue. Did you also drop the legacy credentials table 
> (system_auth.credentials) as per the upgrade docs that I linked yesterday (in 
> NEWS.txt)? If you didn't, the authenticator will continue to read from the 
> old table (you don't need a restart after dropping, the switch will happen 
> immediately).
> 
> 
> 
> On 18 July 2018 at 12:12, Thomas Lété  > wrote:
> It’s my mail client that changed the quote mark, I didn’t see it, it’s just 
> an export of the data I get from DevCenter, the salted hash is not the same 
> as I saw in this guide : 
> https://support.datastax.com/hc/en-us/articles/207932926-FAQ-How-to-recover-from-a-lost-superuser-password
>  
> 
> But it should be correct as it was generated by Cassandra itself yesterday.
> 
> The export :
> cassandra@cqlsh> SELECT * from system_auth.roles;
> 
>  role  | can_login | is_superuser | member_of | salted_hash
> ---+---+--+---+--
>  cassandra |  True | True |  null | 
> $2a$10$7sXeNr3okw61oisR9pCyHeWEO3wPzx3w8r/LKwtDSW2Tt68f4KFmi
> 
>> Le 18 juil. 2018 à 12:26, Sam Tunnicliffe > > a écrit :
>> 
>> It may be an artifact of the email client, but that's not a valid INSERT 
>> statement - the closing quote on the password hash is U2019 (right side 
>> quotation mark) but the opening quote is U0027 (apostrophe) - which is what 
>> cqlsh expects. Can you just SELECT * from system_auth.roles and check that 
>> the salted_hash is correct?
>> 
>> On 18 July 2018 at 11:06, Thomas Lété > > wrote:
>> Yes it’s the config I’m using and I’m trying to add the Password Auth to :-)
>> 
>> Here is the content of the roles table :
>> 
>> INSERT INTO roles (role,can_login,is_superuser,member_of,salted_hash) VALUES 
>> ('cassandra',true,true,null,'$2a$10$7sXeNr3okw61oisR9pCyHeWEO3wPzx3w8r/LKwtDSW2Tt68f4KFmi’);
>> 
>> It seems correct but I’m not able to authenticate (using cqlsh v5.0.1 or 
>> DevCenter 1.6.0)
>> 
>> I’m starting to consider going from scratch and use the default config and 
>> check if it works...
>> 
>>> Le 18 juil. 2018 à 12:03, Sam Tunnicliffe >> > a écrit :
>>> 
>>> With that config you'll be using the default AllowAllAuthenticator, so I 
>>> assume you are able to connect cqlsh without any credentials? If so, can 
>>> you verify the contents of the system_auth.roles table? It should contain 
>>> only the cassandra user.
>>> 
>>> On 18 July 2018 at 08:02, Thomas Lété >> > wrote:
>>> I’m using the default ones, the commented parts are the one I use when I 
>>> try the PasswordAuthenticator :) (line 19 to 24)
>>> 
>>> > Le 18 juil. 2018 à 08:51, Horia Mocioi >> > > a écrit :
>>> > 
>>> > If this is the file that you are currently using...he first things that
>>> > I see is that you do not have any authenticator and role_manager:
>>> > 
>>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5 
>>> > 
>>> > 8c02ecf398/conf/cassandra.yaml#L103
>>> > 
>>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5 
>>> > 
>>> > 8c02ecf398/conf/cassandra.yaml#L123
>>> > 
>>> > On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
>>> >> Unfortunately, I’m not a java dev so I’m not able to create an
>>> >> authenticator…
>>> >> 
>>> >> I don’t like to do that usually but I share with you a gist of the
>>> >> config, it was generated by OpsCenter when it was free, I just
>>> >> updated it for Cassandra >= 3… Maybe you will see something :
>>> >> 
>>> >> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c 
>>> >> 
>>> >> 
>>> >>> Le 18 juil. 2018 à 00:28, Horia Mocioi >> >>> >
>>> >>> a écrit :
>>> >>> 
>>> >>> Cassandra allows to use custom authenticators so I would create a
>>> >>> 

apache cassandra development process and future

2018-07-18 Thread Vitaliy Semochkin
Hi,

Recently Cassandra eco system became very fragmented:

Scylladb provides solution based on Cassandra wire protocol claiming
it is 10 times faster than Cassandra.

Datastax provides it's own solution called DSE claiming it is twice
faster than Cassandra.
Also their site says "DataStax no longer supports the DataStax
Community version of Apache Cassandra™ or the DataStax Distribution of
Apache Cassandra™.
Is their new software incompatible with Cassandra?
Since Datastax used to be the major participant to Cassandra
development and now it looks it goes on is own way, what is going to
be with the Apache Cassandra?
If there are any other active participants in development?

I'm also interested which distribution is the most popular at the
moment in production?

Best Regards,
Vitaliy

-
To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
For additional commands, e-mail: user-h...@cassandra.apache.org



Re: System auth empty, how to populate it

2018-07-18 Thread Sam Tunnicliffe
The salted hash being different is fine, the bcrypt library generates a
random 128 bit salt when encrypting a new password. The salt is then
encoded in the hashed string so you'd expect a different salted_hash each
time a given plaintext string is encoded.

I inserted exactly that data into a clean system, then switched it to use
PasswordAuthenticator and I can login using the default credentials without
any issue. Did you also drop the legacy credentials table
(system_auth.credentials) as per the upgrade docs that I linked yesterday
(in NEWS.txt)? If you didn't, the authenticator will continue to read from
the old table (you don't need a restart after dropping, the switch will
happen immediately).



On 18 July 2018 at 12:12, Thomas Lété  wrote:

> It’s my mail client that changed the quote mark, I didn’t see it, it’s
> just an export of the data I get from DevCenter, the salted hash is not the
> same as I saw in this guide : https://support.datastax.
> com/hc/en-us/articles/207932926-FAQ-How-to-recover-
> from-a-lost-superuser-password
> But it should be correct as it was generated by Cassandra itself yesterday.
>
> The export :
> cassandra@cqlsh> SELECT * from system_auth.roles;
>
>  role  | can_login | is_superuser | member_of | salted_hash
> ---+---+--+---+-
> -
>  cassandra |  True | True |  null | $2a$10$
> 7sXeNr3okw61oisR9pCyHeWEO3wPzx3w8r/LKwtDSW2Tt68f4KFmi
>
> Le 18 juil. 2018 à 12:26, Sam Tunnicliffe  a écrit :
>
> It may be an artifact of the email client, but that's not a valid INSERT
> statement - the closing quote on the password hash is U2019 (right side
> quotation mark) but the opening quote is U0027 (apostrophe) - which is what
> cqlsh expects. Can you just SELECT * from system_auth.roles and check that
> the salted_hash is correct?
>
> On 18 July 2018 at 11:06, Thomas Lété  wrote:
>
>> Yes it’s the config I’m using and I’m trying to add the Password Auth to
>> :-)
>>
>> Here is the content of the roles table :
>>
>> INSERT INTO roles (role,can_login,is_superuser,member_of,salted_hash)
>> VALUES ('cassandra',true,true,null,'$2a$10$7sXeNr3okw61oisR9pCyHeWE
>> O3wPzx3w8r/LKwtDSW2Tt68f4KFmi’);
>>
>> It seems correct but I’m not able to authenticate (using cqlsh v5.0.1 or
>> DevCenter 1.6.0)
>>
>> I’m starting to consider going from scratch and use the default config
>> and check if it works...
>>
>> Le 18 juil. 2018 à 12:03, Sam Tunnicliffe  a écrit :
>>
>> With that config you'll be using the default AllowAllAuthenticator, so I
>> assume you are able to connect cqlsh without any credentials? If so, can
>> you verify the contents of the system_auth.roles table? It should contain
>> only the cassandra user.
>>
>> On 18 July 2018 at 08:02, Thomas Lété  wrote:
>>
>>> I’m using the default ones, the commented parts are the one I use when I
>>> try the PasswordAuthenticator :) (line 19 to 24)
>>>
>>> > Le 18 juil. 2018 à 08:51, Horia Mocioi  a
>>> écrit :
>>> >
>>> > If this is the file that you are currently using...he first things that
>>> > I see is that you do not have any authenticator and role_manager:
>>> >
>>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2
>>> 693e3e27fa5
>>> > 8c02ecf398/conf/cassandra.yaml#L103
>>> >
>>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2
>>> 693e3e27fa5
>>> > 8c02ecf398/conf/cassandra.yaml#L123
>>> >
>>> > On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
>>> >> Unfortunately, I’m not a java dev so I’m not able to create an
>>> >> authenticator…
>>> >>
>>> >> I don’t like to do that usually but I share with you a gist of the
>>> >> config, it was generated by OpsCenter when it was free, I just
>>> >> updated it for Cassandra >= 3… Maybe you will see something :
>>> >>
>>> >> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c
>>> >>
>>> >>> Le 18 juil. 2018 à 00:28, Horia Mocioi 
>>> >>> a écrit :
>>> >>>
>>> >>> Cassandra allows to use custom authenticators so I would create a
>>> >>> CustomPasswordAuthenticator. This would be a copy of the existing
>>> >>> PasswordAuthenticator. I would add several debugging info like:
>>> >>> provided username and password, the output of the checkpw function,
>>> >>> what cql statement is executed etc (any other info that would help
>>> >>> me to understand what is being executed in the authenticator).
>>> >>> From: Thomas Lété 
>>> >>> Sent: Tuesday, July 17, 2018 5:24:39 PM
>>> >>> To: user@cassandra.apache.org
>>> >>> Subject: Re: System auth empty, how to populate it
>>> >>>
>>> >>> Thanks for your reply,
>>> >>>
>>> >>> - I have not defined role_manager in the config
>>> >>> - I dropped the users table, it was present in the keyspace
>>> >>> - Cassandra then created a record in the roles table, yay !
>>> >>>
>>> >>> But when I do clash -u cassandra -p cassandra
>>> >>>
>>> >>> => Invalid credentials supplied.
>>> >>> Authentication error on host 

Re: System auth empty, how to populate it

2018-07-18 Thread Thomas Lété
It’s my mail client that changed the quote mark, I didn’t see it, it’s just an 
export of the data I get from DevCenter, the salted hash is not the same as I 
saw in this guide : 
https://support.datastax.com/hc/en-us/articles/207932926-FAQ-How-to-recover-from-a-lost-superuser-password
But it should be correct as it was generated by Cassandra itself yesterday.

The export :
cassandra@cqlsh> SELECT * from system_auth.roles;

 role  | can_login | is_superuser | member_of | salted_hash
---+---+--+---+--
 cassandra |  True | True |  null | 
$2a$10$7sXeNr3okw61oisR9pCyHeWEO3wPzx3w8r/LKwtDSW2Tt68f4KFmi

> Le 18 juil. 2018 à 12:26, Sam Tunnicliffe  a écrit :
> 
> It may be an artifact of the email client, but that's not a valid INSERT 
> statement - the closing quote on the password hash is U2019 (right side 
> quotation mark) but the opening quote is U0027 (apostrophe) - which is what 
> cqlsh expects. Can you just SELECT * from system_auth.roles and check that 
> the salted_hash is correct?
> 
> On 18 July 2018 at 11:06, Thomas Lété  > wrote:
> Yes it’s the config I’m using and I’m trying to add the Password Auth to :-)
> 
> Here is the content of the roles table :
> 
> INSERT INTO roles (role,can_login,is_superuser,member_of,salted_hash) VALUES 
> ('cassandra',true,true,null,'$2a$10$7sXeNr3okw61oisR9pCyHeWEO3wPzx3w8r/LKwtDSW2Tt68f4KFmi’);
> 
> It seems correct but I’m not able to authenticate (using cqlsh v5.0.1 or 
> DevCenter 1.6.0)
> 
> I’m starting to consider going from scratch and use the default config and 
> check if it works...
> 
>> Le 18 juil. 2018 à 12:03, Sam Tunnicliffe > > a écrit :
>> 
>> With that config you'll be using the default AllowAllAuthenticator, so I 
>> assume you are able to connect cqlsh without any credentials? If so, can you 
>> verify the contents of the system_auth.roles table? It should contain only 
>> the cassandra user.
>> 
>> On 18 July 2018 at 08:02, Thomas Lété > > wrote:
>> I’m using the default ones, the commented parts are the one I use when I try 
>> the PasswordAuthenticator :) (line 19 to 24)
>> 
>> > Le 18 juil. 2018 à 08:51, Horia Mocioi > > > a écrit :
>> > 
>> > If this is the file that you are currently using...he first things that
>> > I see is that you do not have any authenticator and role_manager:
>> > 
>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5 
>> > 
>> > 8c02ecf398/conf/cassandra.yaml#L103
>> > 
>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5 
>> > 
>> > 8c02ecf398/conf/cassandra.yaml#L123
>> > 
>> > On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
>> >> Unfortunately, I’m not a java dev so I’m not able to create an
>> >> authenticator…
>> >> 
>> >> I don’t like to do that usually but I share with you a gist of the
>> >> config, it was generated by OpsCenter when it was free, I just
>> >> updated it for Cassandra >= 3… Maybe you will see something :
>> >> 
>> >> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c 
>> >> 
>> >> 
>> >>> Le 18 juil. 2018 à 00:28, Horia Mocioi > >>> >
>> >>> a écrit :
>> >>> 
>> >>> Cassandra allows to use custom authenticators so I would create a
>> >>> CustomPasswordAuthenticator. This would be a copy of the existing
>> >>> PasswordAuthenticator. I would add several debugging info like:
>> >>> provided username and password, the output of the checkpw function,
>> >>> what cql statement is executed etc (any other info that would help
>> >>> me to understand what is being executed in the authenticator).
>> >>> From: Thomas Lété > >>> >
>> >>> Sent: Tuesday, July 17, 2018 5:24:39 PM
>> >>> To: user@cassandra.apache.org 
>> >>> Subject: Re: System auth empty, how to populate it
>> >>>  
>> >>> Thanks for your reply,
>> >>> 
>> >>> - I have not defined role_manager in the config
>> >>> - I dropped the users table, it was present in the keyspace
>> >>> - Cassandra then created a record in the roles table, yay !
>> >>> 
>> >>> But when I do clash -u cassandra -p cassandra
>> >>> 
>> >>> => Invalid credentials supplied.
>> >>> Authentication error on host xx: Provided username cassandra
>> >>> and/or password are incorrect
>> >>> 
>> >>> I already repaired system_auth a few times, nothing help...
>> >>> 
>>  Le 17 juil. 2018 à 16:47, Sam Tunnicliffe >  > a
>>  écrit :
>>  
>>  The default superuser is only created at startup if 3 conditions
>>  are met:
>> 

Re: System auth empty, how to populate it

2018-07-18 Thread Sam Tunnicliffe
It may be an artifact of the email client, but that's not a valid INSERT
statement - the closing quote on the password hash is U2019 (right side
quotation mark) but the opening quote is U0027 (apostrophe) - which is what
cqlsh expects. Can you just SELECT * from system_auth.roles and check that
the salted_hash is correct?

On 18 July 2018 at 11:06, Thomas Lété  wrote:

> Yes it’s the config I’m using and I’m trying to add the Password Auth to
> :-)
>
> Here is the content of the roles table :
>
> INSERT INTO roles (role,can_login,is_superuser,member_of,salted_hash)
> VALUES ('cassandra',true,true,null,'$2a$10$7sXeNr3okw61oisR9pCyHeWEO3wPzx
> 3w8r/LKwtDSW2Tt68f4KFmi’);
>
> It seems correct but I’m not able to authenticate (using cqlsh v5.0.1 or
> DevCenter 1.6.0)
>
> I’m starting to consider going from scratch and use the default config and
> check if it works...
>
> Le 18 juil. 2018 à 12:03, Sam Tunnicliffe  a écrit :
>
> With that config you'll be using the default AllowAllAuthenticator, so I
> assume you are able to connect cqlsh without any credentials? If so, can
> you verify the contents of the system_auth.roles table? It should contain
> only the cassandra user.
>
> On 18 July 2018 at 08:02, Thomas Lété  wrote:
>
>> I’m using the default ones, the commented parts are the one I use when I
>> try the PasswordAuthenticator :) (line 19 to 24)
>>
>> > Le 18 juil. 2018 à 08:51, Horia Mocioi  a
>> écrit :
>> >
>> > If this is the file that you are currently using...he first things that
>> > I see is that you do not have any authenticator and role_manager:
>> >
>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
>> > 8c02ecf398/conf/cassandra.yaml#L103
>> >
>> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
>> > 8c02ecf398/conf/cassandra.yaml#L123
>> >
>> > On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
>> >> Unfortunately, I’m not a java dev so I’m not able to create an
>> >> authenticator…
>> >>
>> >> I don’t like to do that usually but I share with you a gist of the
>> >> config, it was generated by OpsCenter when it was free, I just
>> >> updated it for Cassandra >= 3… Maybe you will see something :
>> >>
>> >> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c
>> >>
>> >>> Le 18 juil. 2018 à 00:28, Horia Mocioi 
>> >>> a écrit :
>> >>>
>> >>> Cassandra allows to use custom authenticators so I would create a
>> >>> CustomPasswordAuthenticator. This would be a copy of the existing
>> >>> PasswordAuthenticator. I would add several debugging info like:
>> >>> provided username and password, the output of the checkpw function,
>> >>> what cql statement is executed etc (any other info that would help
>> >>> me to understand what is being executed in the authenticator).
>> >>> From: Thomas Lété 
>> >>> Sent: Tuesday, July 17, 2018 5:24:39 PM
>> >>> To: user@cassandra.apache.org
>> >>> Subject: Re: System auth empty, how to populate it
>> >>>
>> >>> Thanks for your reply,
>> >>>
>> >>> - I have not defined role_manager in the config
>> >>> - I dropped the users table, it was present in the keyspace
>> >>> - Cassandra then created a record in the roles table, yay !
>> >>>
>> >>> But when I do clash -u cassandra -p cassandra
>> >>>
>> >>> => Invalid credentials supplied.
>> >>> Authentication error on host xx: Provided username cassandra
>> >>> and/or password are incorrect
>> >>>
>> >>> I already repaired system_auth a few times, nothing help...
>> >>>
>>  Le 17 juil. 2018 à 16:47, Sam Tunnicliffe  a
>>  écrit :
>> 
>>  The default superuser is only created at startup if 3 conditions
>>  are met:
>> 
>>  i) The default role manager is configured. In cassandra.yaml, you
>>  should see "role_manager: CassandraRoleManager". This is also the
>>  default value, so unless you're explicitly using a custom role
>>  manager it should be good.
>>  ii) The system_auth.users table (legacy, pre-2.2) should not be
>>  present. Present means present in the schema, not on disk. Unlike
>>  most system tables, this table is droppable (in fact this is a
>>  necessary step in upgrading from earlier versions).
>>  iii) There should be no preexisting roles present in the
>>  system_auth.roles table. This is verified with a regular query,
>>  so you must either use CQL to delete existing roles, or remove
>>  the data directories and commit logs on *all* nodes.
>> 
>>  Even if these three conditions are met, but the default user
>>  isn't being created the manual insert that Horia suggested should
>>  work. If system_auth.roles table exists and you are able to
>>  perform the insert, I'm very surprised when you say it's empty
>>  after you issue the insert. If you check again and it turns out
>>  the manual insert is working as expected, you need to make sure
>>  that the legacy tables have been dropped from schema (assuming
>>  you upgraded from a 

Re: System auth empty, how to populate it

2018-07-18 Thread Thomas Lété
Yes it’s the config I’m using and I’m trying to add the Password Auth to :-)

Here is the content of the roles table :

INSERT INTO roles (role,can_login,is_superuser,member_of,salted_hash) VALUES 
('cassandra',true,true,null,'$2a$10$7sXeNr3okw61oisR9pCyHeWEO3wPzx3w8r/LKwtDSW2Tt68f4KFmi’);

It seems correct but I’m not able to authenticate (using cqlsh v5.0.1 or 
DevCenter 1.6.0)

I’m starting to consider going from scratch and use the default config and 
check if it works...

> Le 18 juil. 2018 à 12:03, Sam Tunnicliffe  a écrit :
> 
> With that config you'll be using the default AllowAllAuthenticator, so I 
> assume you are able to connect cqlsh without any credentials? If so, can you 
> verify the contents of the system_auth.roles table? It should contain only 
> the cassandra user.
> 
> On 18 July 2018 at 08:02, Thomas Lété  > wrote:
> I’m using the default ones, the commented parts are the one I use when I try 
> the PasswordAuthenticator :) (line 19 to 24)
> 
> > Le 18 juil. 2018 à 08:51, Horia Mocioi  > > a écrit :
> > 
> > If this is the file that you are currently using...he first things that
> > I see is that you do not have any authenticator and role_manager:
> > 
> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5 
> > 
> > 8c02ecf398/conf/cassandra.yaml#L103
> > 
> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5 
> > 
> > 8c02ecf398/conf/cassandra.yaml#L123
> > 
> > On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
> >> Unfortunately, I’m not a java dev so I’m not able to create an
> >> authenticator…
> >> 
> >> I don’t like to do that usually but I share with you a gist of the
> >> config, it was generated by OpsCenter when it was free, I just
> >> updated it for Cassandra >= 3… Maybe you will see something :
> >> 
> >> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c 
> >> 
> >> 
> >>> Le 18 juil. 2018 à 00:28, Horia Mocioi  >>> >
> >>> a écrit :
> >>> 
> >>> Cassandra allows to use custom authenticators so I would create a
> >>> CustomPasswordAuthenticator. This would be a copy of the existing
> >>> PasswordAuthenticator. I would add several debugging info like:
> >>> provided username and password, the output of the checkpw function,
> >>> what cql statement is executed etc (any other info that would help
> >>> me to understand what is being executed in the authenticator).
> >>> From: Thomas Lété  >>> >
> >>> Sent: Tuesday, July 17, 2018 5:24:39 PM
> >>> To: user@cassandra.apache.org 
> >>> Subject: Re: System auth empty, how to populate it
> >>>  
> >>> Thanks for your reply,
> >>> 
> >>> - I have not defined role_manager in the config
> >>> - I dropped the users table, it was present in the keyspace
> >>> - Cassandra then created a record in the roles table, yay !
> >>> 
> >>> But when I do clash -u cassandra -p cassandra
> >>> 
> >>> => Invalid credentials supplied.
> >>> Authentication error on host xx: Provided username cassandra
> >>> and/or password are incorrect
> >>> 
> >>> I already repaired system_auth a few times, nothing help...
> >>> 
>  Le 17 juil. 2018 à 16:47, Sam Tunnicliffe   > a
>  écrit :
>  
>  The default superuser is only created at startup if 3 conditions
>  are met:
>  
>  i) The default role manager is configured. In cassandra.yaml, you
>  should see "role_manager: CassandraRoleManager". This is also the
>  default value, so unless you're explicitly using a custom role
>  manager it should be good. 
>  ii) The system_auth.users table (legacy, pre-2.2) should not be
>  present. Present means present in the schema, not on disk. Unlike
>  most system tables, this table is droppable (in fact this is a
>  necessary step in upgrading from earlier versions).  
>  iii) There should be no preexisting roles present in the
>  system_auth.roles table. This is verified with a regular query,
>  so you must either use CQL to delete existing roles, or remove
>  the data directories and commit logs on *all* nodes.
>  
>  Even if these three conditions are met, but the default user
>  isn't being created the manual insert that Horia suggested should
>  work. If system_auth.roles table exists and you are able to
>  perform the insert, I'm very surprised when you say it's empty
>  after you issue the insert. If you check again and it turns out
>  the manual insert is working as expected, you need to make sure
>  that the legacy tables have been dropped from schema (assuming
>  you upgraded from a pre-3.0 

Re: System auth empty, how to populate it

2018-07-18 Thread Sam Tunnicliffe
With that config you'll be using the default AllowAllAuthenticator, so I
assume you are able to connect cqlsh without any credentials? If so, can
you verify the contents of the system_auth.roles table? It should contain
only the cassandra user.

On 18 July 2018 at 08:02, Thomas Lété  wrote:

> I’m using the default ones, the commented parts are the one I use when I
> try the PasswordAuthenticator :) (line 19 to 24)
>
> > Le 18 juil. 2018 à 08:51, Horia Mocioi  a
> écrit :
> >
> > If this is the file that you are currently using...he first things that
> > I see is that you do not have any authenticator and role_manager:
> >
> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
> > 8c02ecf398/conf/cassandra.yaml#L103
> >
> > https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
> > 8c02ecf398/conf/cassandra.yaml#L123
> >
> > On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
> >> Unfortunately, I’m not a java dev so I’m not able to create an
> >> authenticator…
> >>
> >> I don’t like to do that usually but I share with you a gist of the
> >> config, it was generated by OpsCenter when it was free, I just
> >> updated it for Cassandra >= 3… Maybe you will see something :
> >>
> >> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c
> >>
> >>> Le 18 juil. 2018 à 00:28, Horia Mocioi 
> >>> a écrit :
> >>>
> >>> Cassandra allows to use custom authenticators so I would create a
> >>> CustomPasswordAuthenticator. This would be a copy of the existing
> >>> PasswordAuthenticator. I would add several debugging info like:
> >>> provided username and password, the output of the checkpw function,
> >>> what cql statement is executed etc (any other info that would help
> >>> me to understand what is being executed in the authenticator).
> >>> From: Thomas Lété 
> >>> Sent: Tuesday, July 17, 2018 5:24:39 PM
> >>> To: user@cassandra.apache.org
> >>> Subject: Re: System auth empty, how to populate it
> >>>
> >>> Thanks for your reply,
> >>>
> >>> - I have not defined role_manager in the config
> >>> - I dropped the users table, it was present in the keyspace
> >>> - Cassandra then created a record in the roles table, yay !
> >>>
> >>> But when I do clash -u cassandra -p cassandra
> >>>
> >>> => Invalid credentials supplied.
> >>> Authentication error on host xx: Provided username cassandra
> >>> and/or password are incorrect
> >>>
> >>> I already repaired system_auth a few times, nothing help...
> >>>
>  Le 17 juil. 2018 à 16:47, Sam Tunnicliffe  a
>  écrit :
> 
>  The default superuser is only created at startup if 3 conditions
>  are met:
> 
>  i) The default role manager is configured. In cassandra.yaml, you
>  should see "role_manager: CassandraRoleManager". This is also the
>  default value, so unless you're explicitly using a custom role
>  manager it should be good.
>  ii) The system_auth.users table (legacy, pre-2.2) should not be
>  present. Present means present in the schema, not on disk. Unlike
>  most system tables, this table is droppable (in fact this is a
>  necessary step in upgrading from earlier versions).
>  iii) There should be no preexisting roles present in the
>  system_auth.roles table. This is verified with a regular query,
>  so you must either use CQL to delete existing roles, or remove
>  the data directories and commit logs on *all* nodes.
> 
>  Even if these three conditions are met, but the default user
>  isn't being created the manual insert that Horia suggested should
>  work. If system_auth.roles table exists and you are able to
>  perform the insert, I'm very surprised when you say it's empty
>  after you issue the insert. If you check again and it turns out
>  the manual insert is working as expected, you need to make sure
>  that the legacy tables have been dropped from schema (assuming
>  you upgraded from a pre-3.0 version at some point). If the legacy
>  tables are still present, the authenticator will continue to read
>  from them and so would be ignoring the new entry in the roles
>  table. (see: https://github.com/apache/cassandra/blob/cassandra-3
>  .11.2/NEWS.txt#L619-L640)
> 
> 
>  On 17 July 2018 at 15:18, Thomas Lété  w
>  rote:
>  Yes I did that multiple time, always following the same procedure
>  : stop Cassandra, on all nodes, remove data, update config then
>  restart nodes one by one…
> 
>  I really don’t understand when I could have done wrong...
> 
> > Le 17 juil. 2018 à 16:15, Simon Fontana Oscarsson   a.oscars...@ericsson.com> a écrit :
> >
> > This is very strange behavior if Cassandra won't recreate the
>  cassandra user when you delete the folder.
> > So just to make sure, you are stopping Cassandra on all nodes
>  and deleting the data directory?
> >
> > --
> > SIMON FONTANA OSCARSSON
> > Software 

how to fix too many native-transport-blocked?

2018-07-18 Thread onmstester onmstester
Hi , On a cluster with 10 nodes, Out of 20K/seconds Native-Transports, 
200/seconds of them blocked. They are mostly small single writes. Also I'm 
expriencing random read delays, which i suspect the filled native queue. On all 
nodes, cpu usage is less than 20 percent, and there is no problem in memory and 
disk usage so far. I'm going to fix all native blocks . I'm aware of two 
parameters to tune it: native_transport_max_threads 
max_queued_native_transport_requests I think that i should increase 
native_transport_max_threads until native blocks be 0 on each node and also i 
would monitor the impact on cpu and ram usage. The reason to increase only 
native_transport_max_threads and not changing 
max_queued_native_transport_requests is that read requests need to be processed 
quickly instead of waiting in any queue. Is this a good approach to tune 
cassandra cluster? Should i care for 0 native blocks or its normal in heavy 
write scenario? Thanks in advance Sent using Zoho Mail

RE: How to connect a Cassandra database to Microsoft Power BI ?

2018-07-18 Thread VAN HOLLEBEKE Emeric (SAFRAN CERAMICS)
Okay thank you,
Can you send me a link to download the connector ?
Thank you very much.

Emeric.

De : Justin Cameron [mailto:jus...@instaclustr.com]
Envoyé : mercredi 18 juillet 2018 09:35
À : user@cassandra.apache.org
Objet : Re: How to connect a Cassandra database to Microsoft Power BI ?

Hi Emeric,

Cassandra itself does not offer an ODBC compatible interface.

Spark offers ODBC/JDBC connectivity via Spark SQL, and you can connect this to 
Cassandra using the Spark-Cassandra connector. You'll need to keep in mind that 
Cassandra's data model requirements are very different and limited compared to 
those of relational databases, so you'll still be limited in terms of the types 
of queries you can execute if you care about the performance impacts on 
Cassandra.

There are also several third-party ODBC drivers for Cassandra that translate 
the ODBC interface to something that is Cassandra-compatible, however I have 
not personally used them so I cannot speak to their effectiveness.

Cheers,
Justin

On Wed, 18 Jul 2018 at 16:59 VAN HOLLEBEKE Emeric (SAFRAN CERAMICS) 
mailto:emeric.van-holleb...@safrangroup.com>>
 wrote:
Hi list,

I created a Power BI file which regroups several databases, and I have to 
connect a Cassandra V3 database to Power BI.
Can someone explain me how can I do that ?
I have seen on Internet that is needed an ODBC driver, is there other solutions 
to connect them ?

Any suggestion much appreciated, best.

Thank you,

Emeric VAN HOLLEBEKE.

#
" Ce courriel et les documents qui lui sont joints peuvent contenir des 
informations confidentielles, être soumis aux règlementations relatives au 
contrôle des exportations ou ayant un caractère privé. S'ils ne vous sont pas 
destinés, nous vous signalons qu'il est strictement interdit de les divulguer, 
de les reproduire ou d'en utiliser de quelque manière que ce soit le contenu. 
Toute exportation ou réexportation non autorisée est interdite Si ce message 
vous a été transmis par erreur, merci d'en informer l'expéditeur et de 
supprimer immédiatement de votre système informatique ce courriel ainsi que 
tous les documents qui y sont attachés."
**
" This e-mail and any attached documents may contain confidential or 
proprietary information and may be subject to export control laws and 
regulations. If you are not the intended recipient, you are notified that any 
dissemination, copying of this e-mail and any attachments thereto or use of 
their contents by any means whatsoever is strictly prohibited. Unauthorized 
export or re-export is prohibited. If you have received this e-mail in error, 
please advise the sender immediately and delete this e-mail and all attached 
documents from your computer system."
#
--
Justin Cameron
Senior Software Engineer

[https://cdn2.hubspot.net/hubfs/2549680/Instaclustr-Navy-logo-new.png]

This email has been sent on behalf of Instaclustr Pty. Limited (Australia) and 
Instaclustr Inc (USA).

This email and any attachments may contain confidential and legally privileged 
information.  If you are not the intended recipient, do not copy or disclose 
its content, but please reply to this email immediately and highlight the error 
to the sender and then immediately delete the message.

#
" Ce courriel et les documents qui lui sont joints peuvent contenir des 
informations confidentielles, être soumis aux règlementations relatives au 
contrôle des exportations ou ayant un caractère privé. S'ils ne vous sont pas 
destinés, nous vous signalons qu'il est strictement interdit de les divulguer, 
de les reproduire ou d'en utiliser de quelque manière que ce soit le contenu. 
Toute exportation ou réexportation non autorisée est interdite Si ce message 
vous a été transmis par erreur, merci d'en informer l'expéditeur et de 
supprimer immédiatement de votre système informatique ce courriel ainsi que 
tous les documents qui y sont attachés."
**
" This e-mail and any attached documents may contain confidential or 
proprietary information and may be subject to export control laws and 
regulations. If you are not the intended recipient, you are notified that any 
dissemination, copying of this e-mail and any attachments thereto or use of 
their contents by any means whatsoever is strictly prohibited. Unauthorized 
export or re-export is prohibited. If you have received this e-mail in error, 
please advise the sender immediately and delete this e-mail and all attached 
documents from your computer system."
#


Re: How to connect a Cassandra database to Microsoft Power BI ?

2018-07-18 Thread Justin Cameron
Hi Emeric,

Cassandra itself does not offer an ODBC compatible interface.

Spark offers ODBC/JDBC connectivity via Spark SQL, and you can connect this
to Cassandra using the Spark-Cassandra connector. You'll need to keep in
mind that Cassandra's data model requirements are very different and
limited compared to those of relational databases, so you'll still be
limited in terms of the types of queries you can execute if you care about
the performance impacts on Cassandra.

There are also several third-party ODBC drivers for Cassandra that
translate the ODBC interface to something that is Cassandra-compatible,
however I have not personally used them so I cannot speak to their
effectiveness.

Cheers,
Justin

On Wed, 18 Jul 2018 at 16:59 VAN HOLLEBEKE Emeric (SAFRAN CERAMICS) <
emeric.van-holleb...@safrangroup.com> wrote:

> Hi list,
>
>
>
> I created a Power BI file which regroups several databases, and I have to
> connect a Cassandra V3 database to Power BI.
>
> Can someone explain me how can I do that ?
>
> I have seen on Internet that is needed an ODBC driver, is there other
> solutions to connect them ?
>
>
>
> Any suggestion much appreciated, best.
>
>
>
> Thank you,
>
>
>
> Emeric VAN HOLLEBEKE.
>
>
> #
> " Ce courriel et les documents qui lui sont joints peuvent contenir des
> informations confidentielles, être soumis aux règlementations relatives au
> contrôle des exportations ou ayant un caractère privé. S'ils ne vous sont
> pas destinés, nous vous signalons qu'il est strictement interdit de les
> divulguer, de les reproduire ou d'en utiliser de quelque manière que ce
> soit le contenu. Toute exportation ou réexportation non autorisée est
> interdite Si ce message vous a été transmis par erreur, merci d'en informer
> l'expéditeur et de supprimer immédiatement de votre système informatique ce
> courriel ainsi que tous les documents qui y sont attachés."
> **
> " This e-mail and any attached documents may contain confidential or
> proprietary information and may be subject to export control laws and
> regulations. If you are not the intended recipient, you are notified that
> any dissemination, copying of this e-mail and any attachments thereto or
> use of their contents by any means whatsoever is strictly prohibited.
> Unauthorized export or re-export is prohibited. If you have received this
> e-mail in error, please advise the sender immediately and delete this
> e-mail and all attached documents from your computer system."
> #
>
-- 


*Justin Cameron*Senior Software Engineer





This email has been sent on behalf of Instaclustr Pty. Limited (Australia)
and Instaclustr Inc (USA).

This email and any attachments may contain confidential and legally
privileged information.  If you are not the intended recipient, do not copy
or disclose its content, but please reply to this email immediately and
highlight the error to the sender and then immediately delete the message.


Re: System auth empty, how to populate it

2018-07-18 Thread Thomas Lété
I’m using the default ones, the commented parts are the one I use when I try 
the PasswordAuthenticator :) (line 19 to 24)

> Le 18 juil. 2018 à 08:51, Horia Mocioi  a écrit :
> 
> If this is the file that you are currently using...he first things that
> I see is that you do not have any authenticator and role_manager:
> 
> https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
> 8c02ecf398/conf/cassandra.yaml#L103
> 
> https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
> 8c02ecf398/conf/cassandra.yaml#L123
> 
> On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
>> Unfortunately, I’m not a java dev so I’m not able to create an
>> authenticator…
>> 
>> I don’t like to do that usually but I share with you a gist of the
>> config, it was generated by OpsCenter when it was free, I just
>> updated it for Cassandra >= 3… Maybe you will see something :
>> 
>> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c
>> 
>>> Le 18 juil. 2018 à 00:28, Horia Mocioi 
>>> a écrit :
>>> 
>>> Cassandra allows to use custom authenticators so I would create a
>>> CustomPasswordAuthenticator. This would be a copy of the existing
>>> PasswordAuthenticator. I would add several debugging info like:
>>> provided username and password, the output of the checkpw function,
>>> what cql statement is executed etc (any other info that would help
>>> me to understand what is being executed in the authenticator).
>>> From: Thomas Lété 
>>> Sent: Tuesday, July 17, 2018 5:24:39 PM
>>> To: user@cassandra.apache.org
>>> Subject: Re: System auth empty, how to populate it
>>>  
>>> Thanks for your reply,
>>> 
>>> - I have not defined role_manager in the config
>>> - I dropped the users table, it was present in the keyspace
>>> - Cassandra then created a record in the roles table, yay !
>>> 
>>> But when I do clash -u cassandra -p cassandra
>>> 
>>> => Invalid credentials supplied.
>>> Authentication error on host xx: Provided username cassandra
>>> and/or password are incorrect
>>> 
>>> I already repaired system_auth a few times, nothing help...
>>> 
 Le 17 juil. 2018 à 16:47, Sam Tunnicliffe  a
 écrit :
 
 The default superuser is only created at startup if 3 conditions
 are met:
 
 i) The default role manager is configured. In cassandra.yaml, you
 should see "role_manager: CassandraRoleManager". This is also the
 default value, so unless you're explicitly using a custom role
 manager it should be good. 
 ii) The system_auth.users table (legacy, pre-2.2) should not be
 present. Present means present in the schema, not on disk. Unlike
 most system tables, this table is droppable (in fact this is a
 necessary step in upgrading from earlier versions).  
 iii) There should be no preexisting roles present in the
 system_auth.roles table. This is verified with a regular query,
 so you must either use CQL to delete existing roles, or remove
 the data directories and commit logs on *all* nodes.
 
 Even if these three conditions are met, but the default user
 isn't being created the manual insert that Horia suggested should
 work. If system_auth.roles table exists and you are able to
 perform the insert, I'm very surprised when you say it's empty
 after you issue the insert. If you check again and it turns out
 the manual insert is working as expected, you need to make sure
 that the legacy tables have been dropped from schema (assuming
 you upgraded from a pre-3.0 version at some point). If the legacy
 tables are still present, the authenticator will continue to read
 from them and so would be ignoring the new entry in the roles
 table. (see: https://github.com/apache/cassandra/blob/cassandra-3
 .11.2/NEWS.txt#L619-L640) 
 
 
 On 17 July 2018 at 15:18, Thomas Lété  w
 rote:
 Yes I did that multiple time, always following the same procedure
 : stop Cassandra, on all nodes, remove data, update config then
 restart nodes one by one…
 
 I really don’t understand when I could have done wrong...
 
> Le 17 juil. 2018 à 16:15, Simon Fontana Oscarsson >>> a.oscars...@ericsson.com> a écrit :
>  
> This is very strange behavior if Cassandra won't recreate the
 cassandra user when you delete the folder.
> So just to make sure, you are stopping Cassandra on all nodes
 and deleting the data directory?
>  
> -- 
> SIMON FONTANA OSCARSSON
> Software Developer
>  
> Ericsson
> Ölandsgatan 1
> 37133 Karlskrona, Sweden
>  simon.fontana.oscars...@ericsson.com
>  www.ericsson.com
>  
> On tis, 2018-07-17 at 16:01 +0200, Thomas Lété wrote:
>> It’s empty...
>>  
>>>  
>>> Le 17 juil. 2018 à 15:59, Horia Mocioi >>> .com> a écrit :
>>>  
>>> Could you also send the output of "select * from
 system_auth.roles"?
>>> (you will need to change authenticator to

How to connect a Cassandra database to Microsoft Power BI ?

2018-07-18 Thread VAN HOLLEBEKE Emeric (SAFRAN CERAMICS)
Hi list,

I created a Power BI file which regroups several databases, and I have to 
connect a Cassandra V3 database to Power BI.
Can someone explain me how can I do that ?
I have seen on Internet that is needed an ODBC driver, is there other solutions 
to connect them ?

Any suggestion much appreciated, best.

Thank you,

Emeric VAN HOLLEBEKE.

#
" Ce courriel et les documents qui lui sont joints peuvent contenir des 
informations confidentielles, être soumis aux règlementations relatives au 
contrôle des exportations ou ayant un caractère privé. S'ils ne vous sont pas 
destinés, nous vous signalons qu'il est strictement interdit de les divulguer, 
de les reproduire ou d'en utiliser de quelque manière que ce soit le contenu. 
Toute exportation ou réexportation non autorisée est interdite Si ce message 
vous a été transmis par erreur, merci d'en informer l'expéditeur et de 
supprimer immédiatement de votre système informatique ce courriel ainsi que 
tous les documents qui y sont attachés."
**
" This e-mail and any attached documents may contain confidential or 
proprietary information and may be subject to export control laws and 
regulations. If you are not the intended recipient, you are notified that any 
dissemination, copying of this e-mail and any attachments thereto or use of 
their contents by any means whatsoever is strictly prohibited. Unauthorized 
export or re-export is prohibited. If you have received this e-mail in error, 
please advise the sender immediately and delete this e-mail and all attached 
documents from your computer system."
#


Re: System auth empty, how to populate it

2018-07-18 Thread Horia Mocioi
If this is the file that you are currently using...he first things that
I see is that you do not have any authenticator and role_manager:

https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
8c02ecf398/conf/cassandra.yaml#L103

https://github.com/apache/cassandra/blob/1d506f9d09c880ff2b2693e3e27fa5
8c02ecf398/conf/cassandra.yaml#L123

On ons, 2018-07-18 at 08:33 +0200, Thomas Lété wrote:
> Unfortunately, I’m not a java dev so I’m not able to create an
> authenticator…
> 
> I don’t like to do that usually but I share with you a gist of the
> config, it was generated by OpsCenter when it was free, I just
> updated it for Cassandra >= 3… Maybe you will see something :
> 
> https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c
> 
> > Le 18 juil. 2018 à 00:28, Horia Mocioi 
> > a écrit :
> > 
> > Cassandra allows to use custom authenticators so I would create a
> > CustomPasswordAuthenticator. This would be a copy of the existing
> > PasswordAuthenticator. I would add several debugging info like:
> > provided username and password, the output of the checkpw function,
> > what cql statement is executed etc (any other info that would help
> > me to understand what is being executed in the authenticator).
> > From: Thomas Lété 
> > Sent: Tuesday, July 17, 2018 5:24:39 PM
> > To: user@cassandra.apache.org
> > Subject: Re: System auth empty, how to populate it
> >  
> > Thanks for your reply,
> > 
> > - I have not defined role_manager in the config
> > - I dropped the users table, it was present in the keyspace
> > - Cassandra then created a record in the roles table, yay !
> > 
> > But when I do clash -u cassandra -p cassandra
> > 
> > => Invalid credentials supplied.
> > Authentication error on host xx: Provided username cassandra
> > and/or password are incorrect
> > 
> > I already repaired system_auth a few times, nothing help...
> > 
> > > Le 17 juil. 2018 à 16:47, Sam Tunnicliffe  a
> > > écrit :
> > > 
> > > The default superuser is only created at startup if 3 conditions
> > > are met:
> > > 
> > > i) The default role manager is configured. In cassandra.yaml, you
> > > should see "role_manager: CassandraRoleManager". This is also the
> > > default value, so unless you're explicitly using a custom role
> > > manager it should be good. 
> > > ii) The system_auth.users table (legacy, pre-2.2) should not be
> > > present. Present means present in the schema, not on disk. Unlike
> > > most system tables, this table is droppable (in fact this is a
> > > necessary step in upgrading from earlier versions).  
> > > iii) There should be no preexisting roles present in the
> > > system_auth.roles table. This is verified with a regular query,
> > > so you must either use CQL to delete existing roles, or remove
> > > the data directories and commit logs on *all* nodes.
> > > 
> > > Even if these three conditions are met, but the default user
> > > isn't being created the manual insert that Horia suggested should
> > > work. If system_auth.roles table exists and you are able to
> > > perform the insert, I'm very surprised when you say it's empty
> > > after you issue the insert. If you check again and it turns out
> > > the manual insert is working as expected, you need to make sure
> > > that the legacy tables have been dropped from schema (assuming
> > > you upgraded from a pre-3.0 version at some point). If the legacy
> > > tables are still present, the authenticator will continue to read
> > > from them and so would be ignoring the new entry in the roles
> > > table. (see: https://github.com/apache/cassandra/blob/cassandra-3
> > > .11.2/NEWS.txt#L619-L640) 
> > > 
> > > 
> > > On 17 July 2018 at 15:18, Thomas Lété  w
> > > rote:
> > > Yes I did that multiple time, always following the same procedure
> > > : stop Cassandra, on all nodes, remove data, update config then
> > > restart nodes one by one…
> > > 
> > > I really don’t understand when I could have done wrong...
> > > 
> > > > Le 17 juil. 2018 à 16:15, Simon Fontana Oscarsson  > > a.oscars...@ericsson.com> a écrit :
> > > > 
> > > > This is very strange behavior if Cassandra won't recreate the
> > > cassandra user when you delete the folder.
> > > > So just to make sure, you are stopping Cassandra on all nodes
> > > and deleting the data directory?
> > > > 
> > > > -- 
> > > > SIMON FONTANA OSCARSSON
> > > > Software Developer
> > > > 
> > > > Ericsson
> > > > Ölandsgatan 1
> > > > 37133 Karlskrona, Sweden
> > > > simon.fontana.oscars...@ericsson.com
> > > > www.ericsson.com
> > > > 
> > > > On tis, 2018-07-17 at 16:01 +0200, Thomas Lété wrote:
> > > >> It’s empty...
> > > >> 
> > > >>> 
> > > >>> Le 17 juil. 2018 à 15:59, Horia Mocioi  > > .com> a écrit :
> > > >>> 
> > > >>> Could you also send the output of "select * from
> > > system_auth.roles"?
> > > >>> (you will need to change authenticator to
> > > AllowAllAuthenticator and
> > > >>> authorizer to AllowAllAuthorizer) 
> > > >>> 
> > > >>> On tis, 2018-07-17 at 15:43 

Re: System auth empty, how to populate it

2018-07-18 Thread Thomas Lété
Unfortunately, I’m not a java dev so I’m not able to create an authenticator…

I don’t like to do that usually but I share with you a gist of the config, it 
was generated by OpsCenter when it was free, I just updated it for Cassandra >= 
3… Maybe you will see something :

https://gist.github.com/bistory/ececc0bef7627f39a21e4e8f0c8d841c

> Le 18 juil. 2018 à 00:28, Horia Mocioi  a écrit :
> 
> Cassandra allows to use custom authenticators so I would create a 
> CustomPasswordAuthenticator. This would be a copy of the existing 
> PasswordAuthenticator. I would add several debugging info like: provided 
> username and password, the output of the checkpw function, what cql statement 
> is executed etc (any other info that would help me to understand what is 
> being executed in the authenticator).
> From: Thomas Lété 
> Sent: Tuesday, July 17, 2018 5:24:39 PM
> To: user@cassandra.apache.org
> Subject: Re: System auth empty, how to populate it
>  
> Thanks for your reply,
> 
> - I have not defined role_manager in the config
> - I dropped the users table, it was present in the keyspace
> - Cassandra then created a record in the roles table, yay !
> 
> But when I do clash -u cassandra -p cassandra
> 
> => Invalid credentials supplied.
> Authentication error on host xx: Provided username cassandra and/or 
> password are incorrect
> 
> I already repaired system_auth a few times, nothing help...
> 
>> Le 17 juil. 2018 à 16:47, Sam Tunnicliffe > > a écrit :
>> 
>> The default superuser is only created at startup if 3 conditions are met:
>> 
>> i) The default role manager is configured. In cassandra.yaml, you should see 
>> "role_manager: CassandraRoleManager". This is also the default value, so 
>> unless you're explicitly using a custom role manager it should be good. 
>> ii) The system_auth.users table (legacy, pre-2.2) should not be present. 
>> Present means present in the schema, not on disk. Unlike most system tables, 
>> this table is droppable (in fact this is a necessary step in upgrading from 
>> earlier versions).  
>> iii) There should be no preexisting roles present in the system_auth.roles 
>> table. This is verified with a regular query, so you must either use CQL to 
>> delete existing roles, or remove the data directories and commit logs on 
>> *all* nodes.
>> 
>> Even if these three conditions are met, but the default user isn't being 
>> created the manual insert that Horia suggested should work. If 
>> system_auth.roles table exists and you are able to perform the insert, I'm 
>> very surprised when you say it's empty after you issue the insert. If you 
>> check again and it turns out the manual insert is working as expected, you 
>> need to make sure that the legacy tables have been dropped from schema 
>> (assuming you upgraded from a pre-3.0 version at some point). If the legacy 
>> tables are still present, the authenticator will continue to read from them 
>> and so would be ignoring the new entry in the roles table. (see: 
>> https://github.com/apache/cassandra/blob/cassandra-3.11.2/NEWS.txt#L619-L640 
>> )
>>  
>> 
>> 
>> On 17 July 2018 at 15:18, Thomas Lété > > wrote:
>> Yes I did that multiple time, always following the same procedure : stop 
>> Cassandra, on all nodes, remove data, update config then restart nodes one 
>> by one…
>> 
>> I really don’t understand when I could have done wrong...
>> 
>> > Le 17 juil. 2018 à 16:15, Simon Fontana Oscarsson 
>> > > > > a écrit :
>> > 
>> > This is very strange behavior if Cassandra won't recreate the cassandra 
>> > user when you delete the folder.
>> > So just to make sure, you are stopping Cassandra on all nodes and deleting 
>> > the data directory?
>> > 
>> > -- 
>> > SIMON FONTANA OSCARSSON
>> > Software Developer
>> > 
>> > Ericsson
>> > Ölandsgatan 1
>> > 37133 Karlskrona, Sweden
>> > simon.fontana.oscars...@ericsson.com 
>> > 
>> > www.ericsson.com 
>> > 
>> > On tis, 2018-07-17 at 16:01 +0200, Thomas Lété wrote:
>> >> It’s empty...
>> >> 
>> >>> 
>> >>> Le 17 juil. 2018 à 15:59, Horia Mocioi > >>> > a écrit :
>> >>> 
>> >>> Could you also send the output of "select * from system_auth.roles"?
>> >>> (you will need to change authenticator to AllowAllAuthenticator and
>> >>> authorizer to AllowAllAuthorizer) 
>> >>> 
>> >>> On tis, 2018-07-17 at 15:43 +0200, Thomas Lété wrote:
>>  
>>  Ok I tried that, nothing better (I already tried dropping the entire
>>  system_auth folder that way, same result)
>>  
>>  When I open the log, I found nothing about « Password » and when I
>>  search for « roles », I only find that :
>>  
>>  DEBUG [main] 2018-07-17 15:37:39,420
>>  CompactionStrategyManager.java:380 - Recreating