Issue with cache-group

Issue Report

Documentation specifies:

subspace-farmer cluster --nats-server nats://<NATS_IP>:4222 \
    controller \
        --cache-group group1 \
        --base-path /path/to/controller-dir \
        --node-rpc-url ws://<NODE_IP>:<NODE_PORT>

I have defined on Portainer Stacks:
Cache:

     command:
      [
        "cluster",
        "--nats-server", "nats_prec:4222",
        "cache",
        #"--cache-group group_prec",
        "path=/cache,size=200GB"
      ]

Controller:

      [
        "cluster",
        "--nats-server", "nats_prec:4222",
        "controller",
        #"--cache-group group_prec",
        "--base-path", "/controller",
        "--node-rpc-url", "ws://ss_pnode:9944"      ]

If I try to enable this --cache-group option, then I am getting error - what I missed?

error: unexpected argument '--cache-group group' found
  tip: a similar argument exists: '--cache-group'
  tip: to pass '--cache-group group' as a value, use '-- --cache-group group'
Usage: subspace-farmer cluster --nats-servers <NATS_SERVERS> controller --cache-group <CACHE_GROUP> [-- <ADDITIONAL_COMPONENTS>...]
For more information, try '--help'.

Environment

  • **Operating System: Ubuntu (VM)
  • **Pulsar/Advanced CLI/Docker: Docker - Swarm

Problem

Docker container crashing if trying to use --cache-group option

Status update.

I do have two servers with two NAT, Cache and Controller instances without this -cache-group option. Cache sync at least on one server seems to go well (other is quite slow), but plotting is not yet really started. So only Node is shared between these two servers (connected via 10gbit LAN). But it looks that my setup works reasonable ok.

Correct syntax is this:

  "–cache-group", "group_prec”,

As you can see with other options, key and value are in separate strings. It is not the same as running it in CLI directly where space is all you need.

Does the cluster cache download as much space as it is given? Or if I give 500G of chain history data, it will only download 120G of data?

It downloads the history within the constraints of the available cache size. If history is just 120G it will download 120G and stop there. If history is 600G, it’ll only download 500G instead because that is your limit.

OK, thanks for your guidance. :heart:

subspace-farmer cluster --nats-server nats://<NATS_IP>:4222
cache
path=/path/to/cache01,size=200G
path=/path/to/cache02,size=200G


I would like to ask, when my cache component is planned with two spaces, do these two spaces contain the same cache data, or is the cache data evenly distributed between the two spaces?


Can cache data from one cluster be copied to another cluster?

Please don’t post multiple unrelated questions in existing unrelated threads.
Create your own thread and post a question there.