Skip to content

config: isolated mode for an instance #4632

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2 tasks
Totktonada opened this issue Nov 8, 2024 · 0 comments · May be fixed by #5136
Open
2 tasks

config: isolated mode for an instance #4632

Totktonada opened this issue Nov 8, 2024 · 0 comments · May be fixed by #5136
Assignees
Labels
3.3 config server [area] Task relates to Tarantool's server (core) functionality

Comments

@Totktonada
Copy link
Member

Totktonada commented Nov 8, 2024

Related dev. issue(s): tarantool/tarantool#10796

Product: Tarantool
Since: 3.3.0
Audience/target: application developers, administrators
Root document:

Details

The option is to temporary isolate an instance to perform replicaset repairing activities: debug a problem on the isolated instance (without affecting the non-isolated part) or extract some data from the isolated instance and apply them on the non-isolated part of the replicaset.

groups:
  g:
    replicasets:
      r:
        instances:
          i-001: {}
          i-002: {}
          i-003: {}
          i-004:
            isolated: true

In this mode the instance doesn't perform processing of iproto requests, doesn't perform background data modifications and refuses to accept updates from other replicaset members. Also, other replicaset members don't replicate data from the isolated instance.

Technically speaking, when the option is enabled, the following actions are performed:

  1. iproto stops listening for new connections.
  2. iproto drops all the current connections.
  3. The instance goes to read-only mode.
  4. The instance is disconnected from all the replication upstreams.
  5. Other replicaset members exclude the isolated instance from the replication upstreams.

One new startup constraint is added in the isolated mode:

  1. The instance can't be bootstrapped (a local snapshot is required to start).

Definition of done

  • Describe the new option in the configuration reference
  • Verify whether anything else should be updated in the documentation
@Totktonada Totktonada added the server [area] Task relates to Tarantool's server (core) functionality label Nov 8, 2024
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 10, 2024
This commit just adds the option into the cluster configuration schema.
Next commits will add the relevant logic.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 10, 2024
This commit just adds the option into the cluster configuration schema.
Next commits will add the relevant logic.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 11, 2024
This commit just adds the option into the cluster configuration schema.
Next commits will add the relevant logic.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 11, 2024
This commit just adds the option into the cluster configuration schema.
Next commits will add the relevant logic.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 11, 2024
In the isolated mode an instance refuses to fetch any data from other
replicaset members. An attempt to bootstrap a database on such an
instance would produce its own database (for example, it assigns its own
replicaset UUID).

Unlikely a user wants to place two instances into the same replicaset in
the configuration and get two different databases.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 11, 2024
In the isolated mode an instance refuses to fetch any data from other
replicaset members. An attempt to bootstrap a database on such an
instance would produce its own database (for example, it assigns its own
replicaset UUID).

Unlikely a user wants to place two instances into the same replicaset in
the configuration and get two different databases.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 12, 2024
The isolated instance shouldn't produce new transactions, including ones
from a background fiber started by an application or a role. So, the
isolated instance forcefully goes to the read-only mode disregarding any
other configuration options.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 13, 2024
An isolated instance shouldn't process user traffic. This commit adds a
logic to the isolated mode that stop listening for new connections and
drop existing connections in iproto.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 15, 2024
The isolated mode can be enabled to stop data modifications on the given
instance, including ones from the replication. It may help to debug a
problem or extract some needed data.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 15, 2024
The isolated instance goes to RO and drops iproto connections -- it
should effectively stop replication from it. There is no sense to retry
an attempt to connect to it and flood logs with errors. Let's just
remove the isolated instance from the upstreams list.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 15, 2024
This way it is harder to overlook that the instance is isolated. It is
likely important information for a person who performs administration
tasks.

Closes tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 18, 2024
This commit just adds the option into the cluster configuration schema.
Next commits will add the relevant logic.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 18, 2024
This commit just adds the option into the cluster configuration schema.
Next commits will add the relevant logic.

Part of #10796

NO_DOC=tarantool/doc#4632
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 18, 2024
In the isolated mode an instance refuses to fetch any data from other
replicaset members. An attempt to bootstrap a database on such an
instance would produce its own database (for example, it assigns its own
replicaset UUID).

Unlikely a user wants to place two instances into the same replicaset in
the configuration and get two different databases.

Part of tarantool#10776

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 18, 2024
In the isolated mode an instance refuses to fetch any data from other
replicaset members. An attempt to bootstrap a database on such an
instance would produce its own database (for example, it assigns its own
replicaset UUID).

Unlikely a user wants to place two instances into the same replicaset in
the configuration and get two different databases.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 18, 2024
In the isolated mode an instance refuses to fetch any data from other
replicaset members. An attempt to bootstrap a database on such an
instance would produce its own database (for example, it assigns its own
replicaset UUID).

Unlikely a user wants to place two instances into the same replicaset in
the configuration and get two different databases.

Part of #10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 18, 2024
The isolated instance shouldn't produce new transactions, including ones
from a background fiber started by an application or a role. So, the
isolated instance forcefully goes to the read-only mode disregarding any
other configuration options.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 20, 2024
The isolated mode can be enabled to stop data modifications on the given
instance, including ones from the replication. It may help to debug a
problem or extract some needed data.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 20, 2024
The isolated instance goes to RO and drops iproto connections; thus, the
replication from it is effectively stopped. There is no sense to retry
an attempt to connect to it and flood logs with errors. Let's just
remove the isolated instance from the upstreams list.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 20, 2024
An isolated instance shouldn't process user traffic. This commit adds a
logic to the isolated mode that stop listening for new connections and
drop existing connections in iproto.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 21, 2024
The isolated instance shouldn't produce new transactions, including ones
from a background fiber started by an application or a role. So, the
isolated instance forcefully goes to the read-only mode disregarding any
other configuration options.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 21, 2024
The isolated instance shouldn't produce new transactions, including ones
from a background fiber started by an application or a role. So, the
isolated instance forcefully goes to the read-only mode disregarding any
other configuration options.

Part of #10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 21, 2024
An isolated instance shouldn't process user traffic. This commit adds a
logic to the isolated mode that stop listening for new connections and
drop existing connections in iproto.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 24, 2024
An isolated instance shouldn't process user traffic. This commit adds a
logic to the isolated mode that stop listening for new connections and
drop existing connections in iproto.

Part of #10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 24, 2024
The isolated mode can be enabled to stop data modifications on the given
instance, including ones from the replication. It may help to debug a
problem or extract some needed data.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 24, 2024
The isolated instance goes to RO and drops iproto connections; thus, the
replication from it is effectively stopped. There is no sense to retry
an attempt to connect to it and flood logs with errors. Let's just
remove the isolated instance from the upstreams list.

Part of tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 24, 2024
The isolated mode can be enabled to stop data modifications on the given
instance, including ones from the replication. It may help to debug a
problem or extract some needed data.

Part of #10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 24, 2024
The isolated instance goes to RO and drops iproto connections; thus, the
replication from it is effectively stopped. There is no sense to retry
an attempt to connect to it and flood logs with errors. Let's just
remove the isolated instance from the upstreams list.

Part of #10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to Totktonada/tarantool that referenced this issue Nov 24, 2024
This way it is harder to overlook that the instance is isolated. It is
likely important information for a person who performs administration
tasks.

Closes tarantool#10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
Totktonada added a commit to tarantool/tarantool that referenced this issue Nov 24, 2024
This way it is harder to overlook that the instance is isolated. It is
likely important information for a person who performs administration
tasks.

Closes #10796

NO_DOC=tarantool/doc#4632
NO_CHANGELOG=added together with the configuration option
@Totktonada Totktonada changed the title [WIP] config: isolated mode for an instance config: isolated mode for an instance Nov 24, 2024
@p7nov p7nov self-assigned this Dec 3, 2024
@p7nov p7nov removed their assignment Jan 27, 2025
@AArdeev AArdeev self-assigned this May 26, 2025
AArdeev added a commit that referenced this issue May 27, 2025
The ```isolated:true``` option moves the instance to RO mode
In this mode, various debugging & maintanance operations can be performed

Fixes #4632
@AArdeev AArdeev linked a pull request May 27, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.3 config server [area] Task relates to Tarantool's server (core) functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants