834ef79509
The content was moved over from the Keycloak Benchmark subproject. Closes #24844 Signed-off-by: Alexander Schwartz <aschwart@redhat.com> Co-authored-by: Pedro Ruivo <pruivo@redhat.com> Co-authored-by: Michal Hajas <mhajas@redhat.com> Co-authored-by: Kamesh Akella <kakella@redhat.com> Co-authored-by: Ryan Emerson <remerson@redhat.com> Co-authored-by: Anna Manukyan <amanukya@redhat.com> Co-authored-by: Thomas Darimont <thomas.darimont@googlemail.com> Co-authored-by: Stian Thorgersen <stian@redhat.com> Co-authored-by: Thomas Darimont <thomas.darimont@googlemail.com> Co-authored-by: AndyMunro <amunro@redhat.com>
99 lines
2 KiB
Text
99 lines
2 KiB
Text
. Disable the replication from {stale-site} site to the {keep-site} site by running the following command.
|
|
It prevents the clear request to reach the {keep-site} site and delete all the correct cached data.
|
|
+
|
|
.Command:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
site take-offline --all-caches --site={keep-site-name}
|
|
----
|
|
+
|
|
.Output:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
{
|
|
"offlineClientSessions" : "ok",
|
|
"authenticationSessions" : "ok",
|
|
"sessions" : "ok",
|
|
"clientSessions" : "ok",
|
|
"work" : "ok",
|
|
"offlineSessions" : "ok",
|
|
"loginFailures" : "ok",
|
|
"actionTokens" : "ok"
|
|
}
|
|
----
|
|
|
|
. Check the replication status is `offline`.
|
|
+
|
|
.Command:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
site status --all-caches --site={keep-site-name}
|
|
----
|
|
+
|
|
.Output:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
{
|
|
"status" : "offline"
|
|
}
|
|
----
|
|
+
|
|
If the status is not `offline`, repeat the previous step.
|
|
+
|
|
WARNING: Make sure the replication is `offline` otherwise the clear data will clear both sites.
|
|
|
|
. Clear all the cached data in {stale-site} site using the following commands:
|
|
+
|
|
.Command:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
clearcache actionTokens
|
|
clearcache authenticationSessions
|
|
clearcache clientSessions
|
|
clearcache loginFailures
|
|
clearcache offlineClientSessions
|
|
clearcache offlineSessions
|
|
clearcache sessions
|
|
clearcache work
|
|
----
|
|
+
|
|
These commands do not print any output.
|
|
|
|
. Re-enable the cross-site replication from {stale-site} site to the {keep-site} site.
|
|
+
|
|
.Command:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
site bring-online --all-caches --site={keep-site-name}
|
|
----
|
|
+
|
|
.Output:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
{
|
|
"offlineClientSessions" : "ok",
|
|
"authenticationSessions" : "ok",
|
|
"sessions" : "ok",
|
|
"clientSessions" : "ok",
|
|
"work" : "ok",
|
|
"offlineSessions" : "ok",
|
|
"loginFailures" : "ok",
|
|
"actionTokens" : "ok"
|
|
}
|
|
----
|
|
|
|
. Check the replication status is `online`.
|
|
+
|
|
.Command:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
site status --all-caches --site={keep-site-name}
|
|
----
|
|
+
|
|
.Output:
|
|
[source,bash,subs="+attributes"]
|
|
----
|
|
{
|
|
"status" : "online"
|
|
}
|
|
----
|