Json insertion into scylla table

I am trying to insert json data into my scylla table but it is vomiting an error the commnd given isInsert into students json '{"lastname" :"Roy", "firstname" :"Kumar", "id" :2} `;And the error is Syntax exception : line 1:33 missing ' (' at' 'Any one please help me in this issue how to resolve?...Read more

scylla-server is failing to start

After installing scylla server its failing to start with following error message,Jun 04 07:07:56 localhost.localdomain scylla[29145]: Scylla version 2.3.5-0.20190417.0e0f9143c starting ...Jun 04 07:07:56 localhost.localdomain scylla[29145]: [shard 0] init - Only 476 MiB per shard; this is below the recommended minimum of 1 GiB/shard; terminating.Configure more memory (--memory option) or decrease shard count (--smp option).Jun 04 07:07:56 localhost.localdomain scylla[29145]: [shard 0] seastar - Exiting on unhandled exception: std::runtime_err...Read more

change TokenRange on Scylla

I have a keyspace nba with replication factor 2 (I know, it should be 3 but I cannot change it currently).My scylla DB is 3 nodes (P1, P2 and P3).I did nodetool describering nba and saw that each tokenRange is either written on P3 or replicated on P3. Therefore, my node P3 contains every data, is full and cannot run anymore.(both decribering and the check of the size confirm that)Is there a way to change that distribution and get a more even one?EDIT : Yes, I changed my RF from 3 to 2...Read more

scylla - Error while dropping column from a table with secondary index (Scylladb)

While dropping a column from a table that contains secondary index I get the following error. I am using ScyllaDB version 3.0.4.[Invalid query] message="Cannot drop column name on base table warehouse.myuser with materialized views"Below are the example commandscreate table myuser (id int primary key, name text, email text);create index on myuser(email);alter table myuser drop name;I can successfully run the above statements in Apache Cassandra....Read more

scylla - How can I fix this bug with ScyllaDB?

I'm trying to work through the ScyllaDB tutorial series here: https://www.scylladb.com/2017/11/30/mutant-monitoring-system-day-1/I've got a Docker container running (on Windows, using Powershell) and have cloned their repo, and run it with Docker Compose:PS C:\repos\scylla-code-samples\mms> docker-compose up -dmms_scylla-node3_1 is up-to-datemms_scylla-node2_1 is up-to-dateCreating mms_scylla-node1_1 ... doneTrying to check its status with the nodetool returns a container restarting error:PS C:\repos\scylla-code-samples\mms> docker exec -...Read more

scylla - Why the key prefix optimization doesn't work with secondary index on a clustering column?

Scylla DB implements, so-called "key prefix optimization" for secondary indexes, which eliminates filtering if a part of the primary key is specified. E.g. it's possible to execute SELECT * FROM A WHERE a = 'a' AND b = 'a' AND d = 'a'; on table A.CREATE TABLE A ( a text, b text, c text, d text, PRIMARY KEY(a,b,c));CREATE INDEX A_index ON A (d);But it doesn't work if A.d is a clustering column. E.g. as in table B below.CREATE TABLE B ( a text, b text, c text, d text, PRIMARY KEY(a,b,c,d));CREATE INDEX B_index ON B (...Read more

scylla - Table's mean_partition_size shows wrong, extremely high values

I have a table in scylla, call it 'tablex', in keyspace 'keyspacey', now, I load the data from it into Spark, and I have observed a very large number of partitions, digging in the code I saw it uses mean_partition_size, it could be seen using the query:SELECT range_start, range_end, partitions_count, mean_partition_size FROM system.size_estimates WHERE keyspace_name = 'keyspacey' AND table_name = 'tablex';tablex has 586 rows every one consists of timestamp, text, text, bigint.Running the query above, I got 256 rows, all having partition_count=1...Read more

scylla - does Scylladb require as much memory as the data set?

Looking at how Scylla is described on compose.com it says: Scylla requires fast IO and as much RAM as the total data size. Yet looking at the published architecture it would seem that it doesn't need as much RAM as the total data size as it flushes to disk: Scylla persists data on disk. Writes to Scylla are initially accumulated in RAM in memtables, which at some point get flushed to an sstable on disk and removed from RAM.It seems traditional for projects that are touting extreme performance to not mention any tweaks needed to get that pe...Read more

Scylla db json support for insert with DEFAULT UNSET directive not working

I am trying the following insert statement with DEFAULT UNSET directive, but I get syntax error in the statement. I am using scylla 2.3.1. I tried to the syntax in Apache Cassandra and DSE. It works there.CREATE TABLE user (id int primary key, name text, email text)INSERT INTO user JSON '{"id": 1, "name": "Sam"}' DEFAULT UNSETFollowing statement works in scylla.INSERT INTO user JSON '{"id": 1, "name": "Sam"}';I have turned on experimental flag in the scylla.yaml to activate json support....Read more

Can I safely restore a Scylla backup from 1.6 in scylla 2.0 or 2.1

I'm reading the documentation on Scylla's upgrade procedures (reading the dochttp://docs.scylladb.com/upgrade/upgrade-guide-from-2.0-to-2.1-ubuntu/ for example), and I'm seeing the standard "Stair-Step" path is required from 1.6->2.0->2.1, etc. As a general question, if I have a backup from an older version of scylla 1.6 (or 1.4 or 1.5), is can I load that into a newer release and the data be migrated automatically? Is there a manual process or a tool that I can use?Or is the only way to get data from 1.6 to 2.1 to load data into a 1.6 databa...Read more