diff --git a/umn/source/_static/images/en-us_image_0000001148443450.png b/umn/source/_static/images/en-us_image_0000001148443450.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148443450.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148443456.png b/umn/source/_static/images/en-us_image_0000001148443456.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148443456.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148443458.png b/umn/source/_static/images/en-us_image_0000001148443458.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148443458.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148443460.png b/umn/source/_static/images/en-us_image_0000001148443460.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148443460.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148443514.png b/umn/source/_static/images/en-us_image_0000001148443514.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148443514.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148603242.png b/umn/source/_static/images/en-us_image_0000001148603242.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148603242.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148603244.png b/umn/source/_static/images/en-us_image_0000001148603244.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148603244.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148603246.png b/umn/source/_static/images/en-us_image_0000001148603246.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148603246.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148603248.png b/umn/source/_static/images/en-us_image_0000001148603248.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148603248.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148603250.png b/umn/source/_static/images/en-us_image_0000001148603250.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148603250.png differ diff --git a/umn/source/_static/images/en-us_image_0000001148670664.png b/umn/source/_static/images/en-us_image_0000001148670664.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001148670664.png differ diff --git a/umn/source/_static/images/en-us_image_0000001187846598.png b/umn/source/_static/images/en-us_image_0000001187846598.png new file mode 100644 index 0000000..1cf674a Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001187846598.png differ diff --git a/umn/source/_static/images/en-us_image_0000001188005622.png b/umn/source/_static/images/en-us_image_0000001188005622.png new file mode 100644 index 0000000..1cf674a Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001188005622.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194403147.png b/umn/source/_static/images/en-us_image_0000001194403147.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194403147.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194403149.png b/umn/source/_static/images/en-us_image_0000001194403149.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194403149.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194403151.png b/umn/source/_static/images/en-us_image_0000001194403151.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194403151.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194403153.png b/umn/source/_static/images/en-us_image_0000001194403153.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194403153.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194403155.png b/umn/source/_static/images/en-us_image_0000001194403155.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194403155.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194403157.png b/umn/source/_static/images/en-us_image_0000001194403157.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194403157.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194522775.png b/umn/source/_static/images/en-us_image_0000001194522775.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194522775.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194522893.png b/umn/source/_static/images/en-us_image_0000001194522893.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194522893.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523039.png b/umn/source/_static/images/en-us_image_0000001194523039.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523039.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523041.png b/umn/source/_static/images/en-us_image_0000001194523041.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523041.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523043.png b/umn/source/_static/images/en-us_image_0000001194523043.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523043.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523045.png b/umn/source/_static/images/en-us_image_0000001194523045.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523045.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523047.png b/umn/source/_static/images/en-us_image_0000001194523047.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523047.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523049.png b/umn/source/_static/images/en-us_image_0000001194523049.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523049.png differ diff --git a/umn/source/_static/images/en-us_image_0000001194523107.png b/umn/source/_static/images/en-us_image_0000001194523107.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001194523107.png differ diff --git a/umn/source/_static/images/en-us_image_0000001195353813.png b/umn/source/_static/images/en-us_image_0000001195353813.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001195353813.png differ diff --git a/umn/source/_static/images/en-us_image_0000001196623620.png b/umn/source/_static/images/en-us_image_0000001196623620.png new file mode 100644 index 0000000..c68de2c Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001196623620.png differ diff --git a/umn/source/_static/images/en-us_image_0000001196710703.png b/umn/source/_static/images/en-us_image_0000001196710703.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001196710703.png differ diff --git a/umn/source/_static/images/en-us_image_0000001206970621.png b/umn/source/_static/images/en-us_image_0000001206970621.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001206970621.png differ diff --git a/umn/source/_static/images/en-us_image_0000001214124082.png b/umn/source/_static/images/en-us_image_0000001214124082.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001214124082.png differ diff --git a/umn/source/_static/images/en-us_image_0000001233126245.png b/umn/source/_static/images/en-us_image_0000001233126245.png new file mode 100644 index 0000000..f68fc07 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001233126245.png differ diff --git a/umn/source/_static/images/en-us_image_0000001241411631.png b/umn/source/_static/images/en-us_image_0000001241411631.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001241411631.png differ diff --git a/umn/source/_static/images/en-us_image_0000001241691605.png b/umn/source/_static/images/en-us_image_0000001241691605.png new file mode 100644 index 0000000..eee1eda Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001241691605.png differ diff --git a/umn/source/_static/images/en-us_image_0000001256735725.png b/umn/source/_static/images/en-us_image_0000001256735725.png new file mode 100644 index 0000000..780afc2 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001256735725.png differ diff --git a/umn/source/_static/images/en-us_image_0000001280621500.png b/umn/source/_static/images/en-us_image_0000001280621500.png new file mode 100644 index 0000000..b4a3084 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001280621500.png differ diff --git a/umn/source/_static/images/en-us_image_0000001321666164.png b/umn/source/_static/images/en-us_image_0000001321666164.png new file mode 100644 index 0000000..f7a4774 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001321666164.png differ diff --git a/umn/source/_static/images/en-us_image_0000001322339434.png b/umn/source/_static/images/en-us_image_0000001322339434.png new file mode 100644 index 0000000..47e0c26 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0000001322339434.png differ diff --git a/umn/source/_static/images/en-us_image_0148195246.png b/umn/source/_static/images/en-us_image_0148195246.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0148195246.png differ diff --git a/umn/source/_static/images/en-us_image_0148195318.png b/umn/source/_static/images/en-us_image_0148195318.png new file mode 100644 index 0000000..d157759 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0148195318.png differ diff --git a/umn/source/_static/images/en-us_image_0227732778.png b/umn/source/_static/images/en-us_image_0227732778.png new file mode 100644 index 0000000..478a552 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0227732778.png differ diff --git a/umn/source/_static/images/en-us_image_0266235315.png b/umn/source/_static/images/en-us_image_0266235315.png new file mode 100644 index 0000000..75cfb5f Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235315.png differ diff --git a/umn/source/_static/images/en-us_image_0266235321.png b/umn/source/_static/images/en-us_image_0266235321.png new file mode 100644 index 0000000..acef64d Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235321.png differ diff --git a/umn/source/_static/images/en-us_image_0266235346.png b/umn/source/_static/images/en-us_image_0266235346.png new file mode 100644 index 0000000..a43d234 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235346.png differ diff --git a/umn/source/_static/images/en-us_image_0266235352.png b/umn/source/_static/images/en-us_image_0266235352.png new file mode 100644 index 0000000..c1c05d4 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235352.png differ diff --git a/umn/source/_static/images/en-us_image_0266235362.png b/umn/source/_static/images/en-us_image_0266235362.png new file mode 100644 index 0000000..0eed9cc Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235362.png differ diff --git a/umn/source/_static/images/en-us_image_0266235373.png b/umn/source/_static/images/en-us_image_0266235373.png new file mode 100644 index 0000000..aba6f06 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235373.png differ diff --git a/umn/source/_static/images/en-us_image_0266235394.png b/umn/source/_static/images/en-us_image_0266235394.png new file mode 100644 index 0000000..19e1df2 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235394.png differ diff --git a/umn/source/_static/images/en-us_image_0266235403.png b/umn/source/_static/images/en-us_image_0266235403.png new file mode 100644 index 0000000..24952ad Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235403.png differ diff --git a/umn/source/_static/images/en-us_image_0266235405.png b/umn/source/_static/images/en-us_image_0266235405.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235405.png differ diff --git a/umn/source/_static/images/en-us_image_0266235412.png b/umn/source/_static/images/en-us_image_0266235412.png new file mode 100644 index 0000000..1909444 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235412.png differ diff --git a/umn/source/_static/images/en-us_image_0266235430.png b/umn/source/_static/images/en-us_image_0266235430.png new file mode 100644 index 0000000..f00ca75 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235430.png differ diff --git a/umn/source/_static/images/en-us_image_0266235441.png b/umn/source/_static/images/en-us_image_0266235441.png new file mode 100644 index 0000000..e519a50 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235441.png differ diff --git a/umn/source/_static/images/en-us_image_0266235448.png b/umn/source/_static/images/en-us_image_0266235448.png new file mode 100644 index 0000000..2afed19 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235448.png differ diff --git a/umn/source/_static/images/en-us_image_0266235461.jpg b/umn/source/_static/images/en-us_image_0266235461.jpg new file mode 100644 index 0000000..76e70fb Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235461.jpg differ diff --git a/umn/source/_static/images/en-us_image_0266235508.png b/umn/source/_static/images/en-us_image_0266235508.png new file mode 100644 index 0000000..99460f8 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235508.png differ diff --git a/umn/source/_static/images/en-us_image_0266235565.jpg b/umn/source/_static/images/en-us_image_0266235565.jpg new file mode 100644 index 0000000..30be576 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235565.jpg differ diff --git a/umn/source/_static/images/en-us_image_0266235581.jpg b/umn/source/_static/images/en-us_image_0266235581.jpg new file mode 100644 index 0000000..a386f23 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235581.jpg differ diff --git a/umn/source/_static/images/en-us_image_0266235582.png b/umn/source/_static/images/en-us_image_0266235582.png new file mode 100644 index 0000000..0eed9cc Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266235582.png differ diff --git a/umn/source/_static/images/en-us_image_0266315615.png b/umn/source/_static/images/en-us_image_0266315615.png new file mode 100644 index 0000000..eaf1388 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266315615.png differ diff --git a/umn/source/_static/images/en-us_image_0266315616.png b/umn/source/_static/images/en-us_image_0266315616.png new file mode 100644 index 0000000..9a8b78f Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266315616.png differ diff --git a/umn/source/_static/images/en-us_image_0266315617.png b/umn/source/_static/images/en-us_image_0266315617.png new file mode 100644 index 0000000..6a22ba6 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266315617.png differ diff --git a/umn/source/_static/images/en-us_image_0266315618.png b/umn/source/_static/images/en-us_image_0266315618.png new file mode 100644 index 0000000..a223f37 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266315618.png differ diff --git a/umn/source/_static/images/en-us_image_0266315619.png b/umn/source/_static/images/en-us_image_0266315619.png new file mode 100644 index 0000000..7a0824d Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266315619.png differ diff --git a/umn/source/_static/images/en-us_image_0266316213.png b/umn/source/_static/images/en-us_image_0266316213.png new file mode 100644 index 0000000..eee7b71 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266316213.png differ diff --git a/umn/source/_static/images/en-us_image_0266316214.jpg b/umn/source/_static/images/en-us_image_0266316214.jpg new file mode 100644 index 0000000..be12692 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266316214.jpg differ diff --git a/umn/source/_static/images/en-us_image_0266322522.jpg b/umn/source/_static/images/en-us_image_0266322522.jpg new file mode 100644 index 0000000..faa63ba Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266322522.jpg differ diff --git a/umn/source/_static/images/en-us_image_0266322523.png b/umn/source/_static/images/en-us_image_0266322523.png new file mode 100644 index 0000000..1536f73 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0266322523.png differ diff --git a/umn/source/_static/images/en-us_image_0270432745.png b/umn/source/_static/images/en-us_image_0270432745.png new file mode 100644 index 0000000..464ba68 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0270432745.png differ diff --git a/umn/source/_static/images/en-us_image_0277578727.png b/umn/source/_static/images/en-us_image_0277578727.png new file mode 100644 index 0000000..7a1e280 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0277578727.png differ diff --git a/umn/source/_static/images/en-us_image_0277697231.png b/umn/source/_static/images/en-us_image_0277697231.png new file mode 100644 index 0000000..cc0f8af Binary files /dev/null and b/umn/source/_static/images/en-us_image_0277697231.png differ diff --git a/umn/source/_static/images/en-us_image_0277697263.png b/umn/source/_static/images/en-us_image_0277697263.png new file mode 100644 index 0000000..b563af6 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0277697263.png differ diff --git a/umn/source/_static/images/en-us_image_0277837533.png b/umn/source/_static/images/en-us_image_0277837533.png new file mode 100644 index 0000000..d9ca4cd Binary files /dev/null and b/umn/source/_static/images/en-us_image_0277837533.png differ diff --git a/umn/source/_static/images/en-us_image_0281049655.png b/umn/source/_static/images/en-us_image_0281049655.png new file mode 100644 index 0000000..aa141e3 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0281049655.png differ diff --git a/umn/source/_static/images/en-us_image_0296784660.png b/umn/source/_static/images/en-us_image_0296784660.png new file mode 100644 index 0000000..842ce3a Binary files /dev/null and b/umn/source/_static/images/en-us_image_0296784660.png differ diff --git a/umn/source/_static/images/en-us_image_0296786164.png b/umn/source/_static/images/en-us_image_0296786164.png new file mode 100644 index 0000000..0b64d91 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0296786164.png differ diff --git a/umn/source/_static/images/en-us_image_0296786822.png b/umn/source/_static/images/en-us_image_0296786822.png new file mode 100644 index 0000000..c16d404 Binary files /dev/null and b/umn/source/_static/images/en-us_image_0296786822.png differ diff --git a/umn/source/auditing/index.rst b/umn/source/auditing/index.rst new file mode 100644 index 0000000..8fba7a7 --- /dev/null +++ b/umn/source/auditing/index.rst @@ -0,0 +1,16 @@ +:original_name: dcs-ug-0326017.html + +.. _dcs-ug-0326017: + +Auditing +======== + +- :ref:`Operations That Can Be Recorded by CTS ` +- :ref:`Viewing Traces on the CTS Console ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + operations_that_can_be_recorded_by_cts + viewing_traces_on_the_cts_console diff --git a/umn/source/auditing/operations_that_can_be_recorded_by_cts.rst b/umn/source/auditing/operations_that_can_be_recorded_by_cts.rst new file mode 100644 index 0000000..443f4b7 --- /dev/null +++ b/umn/source/auditing/operations_that_can_be_recorded_by_cts.rst @@ -0,0 +1,72 @@ +:original_name: dcs-ug-0326018.html + +.. _dcs-ug-0326018: + +Operations That Can Be Recorded by CTS +====================================== + +With CTS, you can query, audit, and review operations performed on cloud resources. Traces include the operation requests sent using the management console or open APIs as well as the results of these requests. + +The following lists the DCS operations that can be recorded by CTS. + +.. table:: **Table 1** DCS operations that can be recorded by CTS + + +--------------------------------------------------------+---------------+--------------------------------------+ + | Operation | Resource Type | Trace Name | + +========================================================+===============+======================================+ + | Creating an instance | DCS | createDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting an instance creation request | DCS | submitCreateDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Deleting multiple instances | DCS | batchDeleteDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Deleting an instance | DCS | deleteDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Modifying instance information | DCS | modifyDCSInstanceInfo | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Modifying instance configurations | DCS | modifyDCSInstanceConfig | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Changing instance password | DCS | modifyDCSInstancePassword | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Restarting an instance | DCS | restartDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting an instance restarting request | DCS | submitRestartDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Starting an instance | DCS | startDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting an instance starting request | DCS | submitStartDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Clearing instance data | DCS | flushDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Restarting instances in batches | DCS | batchRestartDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting a request to restart instances in batches | DCS | submitBatchRestartDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Starting multiple instances | DCS | batchStartDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting a request to start instances in batches | DCS | submitBatchStartDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Restoring instance data | DCS | restoreDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting a request to restore instance data | DCS | submitRestoreDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Backing up instance data | DCS | backupDCSInstance | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting a request to back up instance data | DCS | submitBackupDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Deleting instance backup files | DCS | deleteInstanceBackupFile | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Deleting background tasks | DCS | deleteDCSInstanceJobRecord | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Modifying instance specifications | DCS | modifySpecification | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting a request to modify instance specifications | DCS | submitModifySpecificationRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Creating an instance subscription order | DCS | createInstanceOrder | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Switching between master and standby nodes | DCS | masterStandbySwitchover | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Resetting instance password | DCS | resetDCSInstancePassword | + +--------------------------------------------------------+---------------+--------------------------------------+ + | Submitting a request to clear instance data | DCS | submitFlushDCSInstanceRequest | + +--------------------------------------------------------+---------------+--------------------------------------+ diff --git a/umn/source/auditing/viewing_traces_on_the_cts_console.rst b/umn/source/auditing/viewing_traces_on_the_cts_console.rst new file mode 100644 index 0000000..8f1fc99 --- /dev/null +++ b/umn/source/auditing/viewing_traces_on_the_cts_console.rst @@ -0,0 +1,62 @@ +:original_name: dcs-ug-0312047.html + +.. _dcs-ug-0312047: + +Viewing Traces on the CTS Console +================================= + +After CTS is enabled, the tracker starts recording operations on cloud resources. Operation records for the last seven days can be viewed on the CTS console. This section describes how to query operation records of the last seven days on the CTS console. + +Procedure +--------- + +#. Log in to the management console. + +#. Click |image1| in the upper left corner of the management console and select a region and a project. + + .. note:: + + Select the same region as your application service. + +#. Click **Service List** and choose **Management & Deployment** > **Cloud Trace Service**. + +#. In the navigation pane, click **Trace List**. + +#. Specify the filters used for querying traces. The following filters are available: + + - **Search By**: + + Select an option from the drop-down list. Select **DCS** from the **Trace Source** drop-down list. + + When you select **Trace name**, you also need to select a specific trace name. + + When you select **Resource ID**, you also need to select a specific resource ID. + + When you select **Resource name**, you also need to select a specific resource name. + + - **Operator**: Select a specific operator (a user other than tenant). + + - **Trace Status**: Available options include **All trace status**, **normal**, **warning**, and **incident**. You can select only one of them. + + - Start time and end time: You can specify the time period in which to query traces. + +#. Click |image2| on the left of a trace to expand its details, as shown in :ref:`Figure 1 `. + + .. _dcs-ug-0312047__en-us_topic_0148195282_fig16275142414395: + + .. figure:: /_static/images/en-us_image_0266235352.png + :alt: **Figure 1** Expanding trace details + + **Figure 1** Expanding trace details + +#. Click **View Trace** in the **Operation** column. In the dialog box shown in :ref:`Figure 2 `, the trace structure details are displayed. + + .. _dcs-ug-0312047__en-us_topic_0148195282_fig6764226461: + + .. figure:: /_static/images/en-us_image_0266235315.png + :alt: **Figure 2** Viewing traces + + **Figure 2** Viewing traces + +.. |image1| image:: /_static/images/en-us_image_0266235405.png +.. |image2| image:: /_static/images/en-us_image_0266235373.png diff --git a/umn/source/change_history.rst b/umn/source/change_history.rst new file mode 100644 index 0000000..dbc1a17 --- /dev/null +++ b/umn/source/change_history.rst @@ -0,0 +1,167 @@ +:original_name: dcs-ug-0326026.html + +.. _dcs-ug-0326026: + +Change History +============== + ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| Released On | What's New | ++===================================+===================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================+ +| 2022-08-29 | Modified the following content: | +| | | +| | Added description about security groups and whitelist configuration in sections :ref:`Creating a DCS Redis Instance `, :ref:`Security Group Configurations `, :ref:`What Should I Do If an Error Is Returned When I Use the Jedis Connection Pool? `, :ref:`How Do I Troubleshoot Redis Connection Failures? `, and :ref:`Why Aren't Security Groups Configured for DCS Redis 4.0 and 5.0 Instances? ` | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2022-08-09 | Modified the following content: | +| | | +| | - Added the 512 GB specifications of DCS Redis 3.0 instances in sections :ref:`Proxy Cluster Redis ` and :ref:`Redis 3.0 Instance Specifications `. | +| | - Added the impact of specification modification on some instances, in section :ref:`Modifying DCS Instance Specifications `. | +| | - Optimized description about modifying configurations in sections :ref:`Viewing Details of a DCS Instance `, :ref:`Restarting DCS Instances `, :ref:`Modifying Configuration Parameters `, :ref:`Viewing Redis Slow Logs `, :ref:`Manually Backing Up a DCS Instance `, and :ref:`Configuring Alarm Rules for Critical Metrics `. | +| | - Added section :ref:`Managing IP Address Whitelist `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2022-07-13 | Modified the following content: | +| | | +| | Added description about system resources and modified the procedure for enabling auto backup in section :ref:`Creating a DCS Redis Instance `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2022-04-11 | Modified the following content: | +| | | +| | Added description about accessing an instance in different languages. For details, see :ref:`Accessing an Instance `. | +| | | +| | Added section :ref:`Managing Shards and Replicas `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2021-06-30 | Modified the following content: | +| | | +| | - Optimized the procedure for creating an OBS bucket in section :ref:`Importing Backup Files from an OBS Bucket `. | +| | - Updated the commands supported and disabled by Web CLI in section :ref:`Web CLI Commands `. | +| | - Added the following FAQs: | +| | | +| | - :ref:`Why Aren't Security Groups Configured for DCS Redis 4.0 and 5.0 Instances? ` | +| | - :ref:`Can I Obtain the Addresses of the Nodes in a Cluster DCS Redis Instance? ` | +| | - :ref:`Does DCS for Redis Provide Backend Management Software? ` | +| | - :ref:`Why Is "Error in execution" Returned When I Access Redis? ` | +| | - :ref:`Monitoring and Alarm ` | +| | - :ref:`Online Migration with Rump ` | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2020-11-20 | Modified the following content: | +| | | +| | - Modified the description and specifications of DCS for Redis 3.0 in section :ref:`What Is DCS? ` | +| | - Modified the commands disabled in Proxy Cluster instances in section :ref:`Redis 3.0 Instance Specifications `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2021-07-13 | Modified the following content: | +| | | +| | Added detailed description about permissions management in sections :ref:`Permissions Management ` and :ref:`Permissions Management `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2020-10-13 | Modified the following content: | +| | | +| | - Added support for renaming critical commands of DCS Redis 4.0 and 5.0 instances. For details, see :ref:`Command Renaming `. | +| | - Added the cache analysis function. For details, see :ref:`Cache Analysis `. | +| | - Added the slow log function. For details, see :ref:`Viewing Redis Slow Logs `. | +| | - Added the run log function. For details, see :ref:`Viewing Redis Run Logs `. | +| | - Added cluster instance metrics in section :ref:`DCS Metrics `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2020-09-30 | Modified the following content: | +| | | +| | - Added description about DCS Redis 4.0 and 5.0 instances in section :ref:`What Is DCS? ` | +| | - Added typical application scenarios in section :ref:`Application Scenarios `. | +| | - Added section :ref:`DCS Instance Types ` to describe the architectures of single-node, master/standby, Proxy Cluster, and Redis Cluster instances. | +| | - Added section :ref:`HA and DR Policies ` to describe the disaster recovery strategies of DCS. | +| | - Added description about the specifications of DCS Redis 4.0 and 5.0 instances, QPS of DCS Redis 3.0 instances, and 1024 GB Proxy Cluster DCS Redis 3.0 instances in section :ref:`DCS Instance Specifications `. | +| | - Added section :ref:`Comparing DCS and Open-Source Cache Services `. | +| | - Added section :ref:`Comparing Redis Versions ` to compare DCS for Redis 3.0, 4.0, and 5.0. | +| | - Added description about command compatibility of DCS Redis 4.0 and 5.0 instances in section :ref:`Command Compatibility `. | +| | - Added section :ref:`Basic Concepts ` to describe the basic concepts of DCS. | +| | - Added the description about OBS in section :ref:`Related Services `. | +| | - Added section :ref:`Identifying Requirements `. | +| | - Modified description about the process for creating instances and added description about creating DCS Redis 4.0 and 5.0 instances in section :ref:`Creating a DCS Redis Instance `. | +| | - Added the description about the sold-out tip for the AZ parameter in section :ref:`Creating a DCS Redis Instance `. | +| | - Modified descriptions in sections :ref:`Accessing a DCS Redis Instance Through redis-cli ` and :ref:`Jedis `. | +| | - Added section :ref:`Accessing a DCS Redis 4.0 or 5.0 Instance on the Console `. | +| | - Added description about DCS Redis 4.0 and 5.0 instances in section :ref:`Viewing Details of a DCS Instance `. | +| | - Optimized the classification of operations in chapter :ref:`Operation Guide `. | +| | - Added notes on changing the DCS instance specifications in section :ref:`Modifying DCS Instance Specifications `. | +| | - Added section :ref:`Performing a Master/Standby Switchover for a DCS Instance `. | +| | - Added section :ref:`Clearing DCS Instance Data ` to describe how to clear data of DCS Redis 4.0 and 5.0 instances. | +| | - Added section :ref:`Exporting DCS Instance List `. | +| | - Added section :ref:`Viewing Data Storage Statistics of a DCS Redis 3.0 Proxy Cluster Instance `. | +| | - Added section :ref:`Downloading a Backup File `. | +| | - Added section :ref:`Migrating Data with DCS `. | +| | - Added section :ref:`DCS Instance Passwords ` to describe the password used for connecting to DCS instances. | +| | - Added metrics of DCS Redis 4.0 and 5.0 instances in section :ref:`DCS Metrics `. | +| | - Added section :ref:`Auditing ` to describe the DCS operations that can be recorded by CTS. | +| | - Modified the structure of FAQs and added new FAQs in chapter :ref:`FAQs `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2020-07-17 | Modified the following content: | +| | | +| | - Added a note in section :ref:`Accessing a DCS Redis Instance Through redis-cli ` to advise against hard-coding plaintext passwords in the code. | +| | - Added an explanation of the **SYS.DCS** namespace and optimized the table layout in section :ref:`DCS Metrics `. | +| | - Updated the picture that demonstrates viewing instance metrics in section :ref:`Configuring Alarm Rules for Critical Metrics `. | +| | - Optimized the description about CIDR blocks for cross-VPC access and added the table caption in FAQ :ref:`Does DCS Support Cross-VPC Access? ` | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2020-05-30 | Modified the following content: | +| | | +| | - Changed the cluster instance type to Proxy Cluster in section :ref:`What Is DCS? ` | +| | - Removed description about creating multiple instances in batches and modified password complexity requirements in section :ref:`Creating a DCS Redis Instance `. | +| | - Removed the instance topology parameter in section :ref:`Viewing Details of a DCS Instance `. | +| | - Changed the default value of the **reserved-memory-percent** parameter to **0** and added a note clarifying that the configuration parameters supported by single-node and master/standby instances are different in section :ref:`Modifying Configuration Parameters `. | +| | - Modified the special characters that the passwords cannot contain in section :ref:`Changing Instance Passwords `. | +| | - Removed the section which describes the function of viewing data storage statics of a Proxy Cluster instance. | +| | - Added a note clarifying that the backup policy function is not supported by single-node instances in section :ref:`Configuring a Backup Policy `. | +| | - Removed Redis Server and Proxy metrics from section :ref:`Monitoring `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2020-03-25 | Modified the following content: | +| | | +| | - Changed the cluster instance type to Proxy Cluster in section :ref:`What Is DCS? ` | +| | - Modified the lists of supported and disabled Redis commands in section :ref:`Command Compatibility `. | +| | - Added the assured/maximum bandwidth parameter in section :ref:`DCS Instance Specifications `. | +| | - Moved the metrics originally described in section :ref:`Related Services ` to section :ref:`DCS Metrics ` and updated the metrics supported by Cloud Eye. | +| | - Modified instance creation parameters in :ref:`Creating a DCS Redis Instance ` according to DCS console upgrade and parameter modifications. | +| | - Modified instance details parameters in section :ref:`Viewing Details of a DCS Instance ` according to DCS console upgrade and parameter modifications. | +| | - Modified instance configuration parameters in section :ref:`Modifying Configuration Parameters `. | +| | - Removed the function of stopping instances. | +| | - Added description about restrictions of starting instances in section :ref:`Starting DCS Instances `. | +| | - Changed parameter **Time Window** to **Maintenance** in section :ref:`Modifying Maintenance Time Window `. | +| | - Modified description about configuring instance backup policies in section :ref:`Configuring a Backup Policy `. | +| | - Added chapter :ref:`Monitoring `, updated metrics supported by Cloud Eye, and added description about operations of viewing monitoring data and setting alarm rules. | +| | - Changed the supported number of DBs for single-node and master/standby instances in section :ref:`Does DCS for Redis Support Multiple Databases? ` | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2019-04-12 | Accepted in OTC-4.0/Agile-04.2019. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2019-03-30 | Modified the following content: | +| | | +| | - Removed support for creating DCS instances with the specification of 1 GB in sections :ref:`DCS Instance Specifications ` and :ref:`Creating a DCS Redis Instance `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2018-09-05 | Modified the following content: | +| | | +| | - Opened certain Redis cluster commands. For details about compatibility with DCS commands, see :ref:`Command Compatibility `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2018-03-16 | Added the following content: | +| | | +| | - Added the procedure for using a Redis Java (Jedis) client to access a DCS instance. For details, see :ref:`Accessing a DCS Redis Instance Through redis-cli `. | +| | - Added descriptions about the Redis-specific parameter **notify-keyspace-events**, and deleted descriptions about the Redis-specific parameter **maxclients**. For details, see :ref:`Modifying Configuration Parameters `. | +| | - Added the procedures for modifying the time window and security group of a DCS instance. For details, see :ref:`Modifying Maintenance Time Window ` and :ref:`Modifying the Security Group `. | +| | - Added :ref:`Does DCS Support Cross-VPC Access? ` in chapter :ref:`FAQs `. | +| | | +| | Modified the following content: | +| | | +| | - Changed instance password complexity rules. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2017-11-08 | Added the following content: | +| | | +| | - Provided support for DCS instances in cluster mode. | +| | - Added sections :ref:`Modifying DCS Instance Specifications ` and :ref:`Backing Up and Restoring DCS Instances `. | +| | - Added the **Time Window** parameter. | +| | - Added section :ref:`Preparing the Environment `. | +| | | +| | - Added some FAQs in chapter :ref:`FAQs `. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2017-05-30 | Added the following content: | +| | | +| | - Added descriptions about batch deletion of DCS instances. | +| | - Added descriptions about the Redis-specific parameter **latency-monitor-threshold**. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2017-04-28 | Added the following content: | +| | | +| | - Added descriptions of DCS metrics monitored by Cloud Eye. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| 2017-04-05 | This issue is the first official release. | ++-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ diff --git a/umn/source/faqs/client_and_network_connection/does_dcs_support_cross-vpc_access.rst b/umn/source/faqs/client_and_network_connection/does_dcs_support_cross-vpc_access.rst new file mode 100644 index 0000000..91684bb --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/does_dcs_support_cross-vpc_access.rst @@ -0,0 +1,38 @@ +:original_name: en-us_topic_0100698850.html + +.. _en-us_topic_0100698850: + +Does DCS Support Cross-VPC Access? +================================== + +Cross-VPC means the client and the instance are not in the same VPC. + +Generally, VPCs are isolated from each other and ECSs cannot access DCS instances that belong to a different VPC from these ECSs. + +However, by establishing VPC peering connections between VPCs, ECSs can access single-node and master/standby DCS instances across VPCs. + +When using VPC peering connections to access DCS instances across VPCs, adhere to the rules listed in the following table. + +.. table:: **Table 1** Client CIDR block constraints + + +-----------------------------------+-------------------------------------+ + | CIDR Blocks of DCS Instances | CIDR Blocks Not Allowed for Clients | + +===================================+=====================================+ + | 172.16.0.0/12 to 172.16.0.0/24 | 192.168.1.0/24 | + | | | + | | 192.168.2.0/24 | + | | | + | | 192.168.3.0/24 | + +-----------------------------------+-------------------------------------+ + | 192.168.0.0/16 to 192.168.0.0/24 | 172.31.1.0/24 | + | | | + | 10.0.0.0/8 to 10.0.0.0/24 | 172.31.2.0/24 | + | | | + | | 172.31.3.0/24 | + +-----------------------------------+-------------------------------------+ + +For more information about VPC peering connection, see "VPC Peering Connection" in the *Virtual Private Cloud User Guide*. + +.. important:: + + Cluster DCS Redis instances do not support cross-VPC access. ECSs in a VPC cannot access cluster DCS instances in another VPC by using VPC peering connections. diff --git a/umn/source/faqs/client_and_network_connection/does_dcs_support_public_access.rst b/umn/source/faqs/client_and_network_connection/does_dcs_support_public_access.rst new file mode 100644 index 0000000..1b51d97 --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/does_dcs_support_public_access.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730001.html + +.. _dcs-faq-0730001: + +Does DCS Support Public Access? +=============================== + +No. DCS instances cannot be access at their EIPs over public networks. To ensure security, the ECS that serves as a client and the DCS instance that the client will access must belong to the same VPC. + +In the application development and debugging phase, you can also use an SSH agent to access DCS instances in the local environment. diff --git a/umn/source/faqs/client_and_network_connection/how_do_i_access_a_dcs_redis_instance_through_redis_desktop_manager.rst b/umn/source/faqs/client_and_network_connection/how_do_i_access_a_dcs_redis_instance_through_redis_desktop_manager.rst new file mode 100644 index 0000000..e07fc0b --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/how_do_i_access_a_dcs_redis_instance_through_redis_desktop_manager.rst @@ -0,0 +1,24 @@ +:original_name: dcs-faq-0730008.html + +.. _dcs-faq-0730008: + +How Do I Access a DCS Redis Instance Through Redis Desktop Manager? +=================================================================== + +You can access a DCS Redis instance through the Redis Desktop Manager within a VPC. + +#. Enter the address, port number (6379), and authentication password of the DCS instance you want to access. + +#. Click **Test Connection**. + + The system displays a success message if the connection is successful. + + + .. figure:: /_static/images/en-us_image_0266315618.png + :alt: **Figure 1** Accessing a DCS Redis instance through Redis Desktop Manager over the intranet + + **Figure 1** Accessing a DCS Redis instance through Redis Desktop Manager over the intranet + + .. note:: + + When accessing a cluster DCS instance, the Redis command is run properly, but an error message may display on the left because DCS clusters are based on Codis, which differs from the native Redis in terms of the **INFO** command output. diff --git a/umn/source/faqs/client_and_network_connection/how_do_i_troubleshoot_redis_connection_failures.rst b/umn/source/faqs/client_and_network_connection/how_do_i_troubleshoot_redis_connection_failures.rst new file mode 100644 index 0000000..685b9e2 --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/how_do_i_troubleshoot_redis_connection_failures.rst @@ -0,0 +1,50 @@ +:original_name: dcs-faq-0730010.html + +.. _dcs-faq-0730010: + +How Do I Troubleshoot Redis Connection Failures? +================================================ + +**Preliminary checks:** + +- Check the connection address. + + Obtain the connection address from the instance basic information page on the DCS console. + +- Check the instance password. + + If the instance password is incorrect, the port can still be accessed but the authentication will fail. + +- Check the port. + + Port 6379 is the default port used in intra-VPC access to a DCS Redis instance. + +- Check if the maximum bandwidth has been reached. + + If the bandwidth reaches the maximum bandwidth for the corresponding instance specifications, Redis connections may time out. + +- For a DCS Redis 3.0 instance, check the inbound access rules of the security group. + + Intra-VPC access: If the Redis client and the Redis instance are bound with different security groups, allow inbound access over port 6379 for the security group of the instance. + + For details, see :ref:`Security Group Configurations `. + +- For a DCS Redis 4.0 or 5.0 instance, check the whitelist configuration. + + If the instance has a whitelist, ensure that the client IP address is included in the whitelist. Otherwise, the connection will fail. + + For details, see :ref:`Managing IP Address Whitelist `. + + If the client IP address has changed, add the new IP address to the whitelist. + +- Check the configuration parameter **notify-keyspace-events**. + + Set **notify-keyspace-events** to **Egx**. + +**Further checks:** + +- Jedis connection pool error + +- Error "Read timed out" or "Could not get a resource from the pool" + + Check if the **KEYS** command has been used. This command consumes a lot of resources and can easily block Redis. Instead, use the **SCAN** command and avoid executing the command frequently. diff --git a/umn/source/faqs/client_and_network_connection/index.rst b/umn/source/faqs/client_and_network_connection/index.rst new file mode 100644 index 0000000..e14c5fe --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/index.rst @@ -0,0 +1,34 @@ +:original_name: dcs-faq-0326020.html + +.. _dcs-faq-0326020: + +Client and Network Connection +============================= + +- :ref:`Security Group Configurations ` +- :ref:`Does DCS Support Public Access? ` +- :ref:`Does DCS Support Cross-VPC Access? ` +- :ref:`What Should I Do If Access to DCS Fails After Server Disconnects? ` +- :ref:`Why Do Requests Sometimes Time Out in Clients? ` +- :ref:`What Should I Do If an Error Is Returned When I Use the Jedis Connection Pool? ` +- :ref:`Why Is "ERR unknown command" Displayed When I Access a DCS Redis Instance Through a Redis Client? ` +- :ref:`How Do I Access a DCS Redis Instance Through Redis Desktop Manager? ` +- :ref:`What If "ERR Unsupported CONFIG subcommand" is Displayed in SpringCloud? ` +- :ref:`How Do I Troubleshoot Redis Connection Failures? ` +- :ref:`What Should Be Noted When Using Redis for Pub/Sub? ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + security_group_configurations + does_dcs_support_public_access + does_dcs_support_cross-vpc_access + what_should_i_do_if_access_to_dcs_fails_after_server_disconnects + why_do_requests_sometimes_time_out_in_clients + what_should_i_do_if_an_error_is_returned_when_i_use_the_jedis_connection_pool + why_is_err_unknown_command_displayed_when_i_access_a_dcs_redis_instance_through_a_redis_client + how_do_i_access_a_dcs_redis_instance_through_redis_desktop_manager + what_if_err_unsupported_config_subcommand_is_displayed_in_springcloud + how_do_i_troubleshoot_redis_connection_failures + what_should_be_noted_when_using_redis_for_pub_sub diff --git a/umn/source/faqs/client_and_network_connection/security_group_configurations.rst b/umn/source/faqs/client_and_network_connection/security_group_configurations.rst new file mode 100644 index 0000000..cb8b24e --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/security_group_configurations.rst @@ -0,0 +1,53 @@ +:original_name: en-us_topic_0090662012.html + +.. _en-us_topic_0090662012: + +Security Group Configurations +============================= + +DCS Redis 3.0/4.0/5.0 instances are deployed in different modes. Therefore, the access control method varies. + +- To control access to DCS Redis 3.0 instances, you can use security groups. Whitelists are not supported. Security group operations are described in this section. +- To control access to DCS Redis 4.0/5.0 instances, you can use whitelists. Security groups are not supported. Whitelist operations are described in :ref:`Managing IP Address Whitelist `. + +This section describes how to configure a security group for accessing a DCS instance **within a VPC**. + +Intra-VPC Access to DCS Redis 3.0 Instances +------------------------------------------- + +An ECS can communicate with a DCS instance if they belong to the same VPC and security group rules are configured correctly. + +In addition, you must configure correct rules for the security groups of both the ECS and DCS instance so that you can access the instance through your client. + +- If the ECS and DCS instance are configured with the same security group, network access in the group is not restricted by default. +- If the ECS and DCS instance are configured with different security groups, add security group rules to ensure that the ECS and DCS instance can access each other. + + .. note:: + + - Suppose that the ECS on which the client runs belongs to security group **sg-ECS**, and the DCS instance that the client will access belongs to security group **sg-DCS**. + - Suppose that the port number of the DCS service is 6379. + - The remote end is a security group or an IP address. + + #. Configuring security group for the ECS. + + Add the following outbound rule to allow the ECS to access the DCS instance. Skip this rule if there are no restrictions on the outbound traffic. + + + .. figure:: /_static/images/en-us_image_0277697231.png + :alt: **Figure 1** Security group rules allowing the ECS to access the DCS instance + + **Figure 1** Security group rules allowing the ECS to access the DCS instance + + #. Configuring security group for the DCS instance. + + To ensure that your client can access the DCS instance, add the following inbound rule to the security group configured for the DCS instance: + + + .. figure:: /_static/images/en-us_image_0277697263.png + :alt: **Figure 2** Security group rules making the DCS instance accessible to the ECS + + **Figure 2** Security group rules making the DCS instance accessible to the ECS + + .. important:: + + For the source IP address, use the specified IP address of the DCS instance. Avoid using **0.0.0.0/0** to prevent ECSs bound with the same security group from being attacked by Redis vulnerability exploits. diff --git a/umn/source/faqs/client_and_network_connection/what_if_err_unsupported_config_subcommand_is_displayed_in_springcloud.rst b/umn/source/faqs/client_and_network_connection/what_if_err_unsupported_config_subcommand_is_displayed_in_springcloud.rst new file mode 100644 index 0000000..722fbfd --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/what_if_err_unsupported_config_subcommand_is_displayed_in_springcloud.rst @@ -0,0 +1,40 @@ +:original_name: dcs-faq-0730009.html + +.. _dcs-faq-0730009: + +What If "ERR Unsupported CONFIG subcommand" is Displayed in SpringCloud? +======================================================================== + +By using DCS Redis instances, Spring Session can implement session sharing. When interconnecting with Spring Cloud, the following error information is displayed: + + +.. figure:: /_static/images/en-us_image_0266315619.png + :alt: **Figure 1** Spring Cloud error information + + **Figure 1** Spring Cloud error information + +For security purposes, DCS does not support the **CONFIG** command initiated by a client. You need to perform the following steps: + +#. On the DCS console, set the value of the **notify-keyspace-event** parameter to **Egx** for a DCS Redis instance. + +#. Add the following content to the XML configuration file of the Spring framework: + + + +#. Modify the related Spring code. Enable the **ConfigureRedisAction.NO_OP** bean component to forbid a client to invoke the **CONFIG** command. + + @Bean + + public static ConfigureRedisAction configureRedisAction() { + + return ConfigureRedisAction.NO_OP; + + } + +For more information, see the `Spring Session Documentation `__. + +.. important:: + + Session sharing is supported only by **single-node** and **master/standby** DCS Redis instances, but not by cluster DCS Redis instances. diff --git a/umn/source/faqs/client_and_network_connection/what_should_be_noted_when_using_redis_for_pub_sub.rst b/umn/source/faqs/client_and_network_connection/what_should_be_noted_when_using_redis_for_pub_sub.rst new file mode 100644 index 0000000..983ae15 --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/what_should_be_noted_when_using_redis_for_pub_sub.rst @@ -0,0 +1,20 @@ +:original_name: dcs-faq-0730011.html + +.. _dcs-faq-0730011: + +What Should Be Noted When Using Redis for Pub/Sub? +================================================== + +Pay attention to the following issues when using Redis for pub/sub: + +- Your client must process messages in a timely manner. + + Your client subscribes to a channel. If it does not receive messages in a timely manner, DCS instance messages may be overstocked. If the size of accumulated messages reaches the threshold (32 MB by default) or remains at a certain level (8 MB by default) for a certain period of time (1 minute by default), your client will be automatically disconnected to prevent server memory exhaustion. + +- Your client must support connection re-establishment in case of disconnection. + + In the event of a disconnection, you need to run the **subscribe** or **psubscribe** command on your client to subscribe to a channel again. Otherwise, your client cannot receive messages. + +- Do not use pub/sub in scenarios with high message reliability requirements. + + The Redis pub/sub is not a reliable messaging system. Messages that are not retrieved will be discarded when your client is disconnected or a master/standby switchover occurs. diff --git a/umn/source/faqs/client_and_network_connection/what_should_i_do_if_access_to_dcs_fails_after_server_disconnects.rst b/umn/source/faqs/client_and_network_connection/what_should_i_do_if_access_to_dcs_fails_after_server_disconnects.rst new file mode 100644 index 0000000..02ec792 --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/what_should_i_do_if_access_to_dcs_fails_after_server_disconnects.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730004.html + +.. _dcs-faq-0730004: + +What Should I Do If Access to DCS Fails After Server Disconnects? +================================================================= + +Analysis: If persistent connections ("pconnect" in Redis terminology) or connection pooling is used and connections are closed after being used for connecting to DCS instances, errors will be returned at attempts to reuse the connections. + +Solution: When using pconnect or connection pooling, do not close the connection after the end of a request. If the connection is dropped, re-establish it. diff --git a/umn/source/faqs/client_and_network_connection/what_should_i_do_if_an_error_is_returned_when_i_use_the_jedis_connection_pool.rst b/umn/source/faqs/client_and_network_connection/what_should_i_do_if_an_error_is_returned_when_i_use_the_jedis_connection_pool.rst new file mode 100644 index 0000000..7b916ba --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/what_should_i_do_if_an_error_is_returned_when_i_use_the_jedis_connection_pool.rst @@ -0,0 +1,85 @@ +:original_name: dcs-faq-0730006.html + +.. _dcs-faq-0730006: + +What Should I Do If an Error Is Returned When I Use the Jedis Connection Pool? +============================================================================== + +The error message that will possibly be displayed when you use the Jedis connection pool is as follows: + +.. code-block:: + + redis.clients.jedis.exceptions.JedisConnectionException: Could not get a resource from the pool + +If this error message is displayed, check whether your instance is running properly. If it is running properly, perform the following checks: + +#. Network + + a. Check the IP address configurations. + + Check whether the IP address configured on the Jedis client is the same as the subnet address configured for your DCS instance. + + b. Test the network. + + Use the ping command and telnet on the client to test the network. + + - If the network cannot be pinged: + + For intra-VPC access to a DCS Redis 3.0 instance, ensure that the client and your DCS instance belong to the same VPC and security group, or the security group of your DCS instance allows access through port 6379. For details, see :ref:`Security Group Configurations `. + + - If the IP address can be pinged but telnet failed, restart your instance. If the problem persists after the restart, contact technical support. + +#. Check the number of connections. + + Check whether the number of established network connections exceeds the upper limit configured for the Jedis connection pool. If the number of established connections approaches the configured upper limit, restart the DCS service and check whether the problem persists. If the number of established connections is far below the upper limit, continue with the following checks. + + In Unix or Linux, run the following command to query the number of established network connections: + + **netstat -an \| grep 6379 \| grep ESTABLISHED \| wc -l** + + In Windows, run the following command to query the number of established network connections: + + **netstat -an \| find "6379" \| find "ESTABLISHED" /C** + +#. Check the JedisPool code. + + If the number of established connections approaches the upper limit, determine whether the problem is caused by service concurrency or incorrect usage of JedisPool. + + When using JedisPool, you must call **jedisPool.returnResource()** or **jedis.close()** (recommended) to release the resources after you call **jedisPool.getResource()**. + +#. Check the number of TIME_WAIT connections. + + Run the **ss -s** command to check whether there are too many **TIME_WAIT** connections on the client. + + |image1| + + If there are too many **TIME_WAIT** connections, modify the kernel parameters by running the **/etc/sysctl.conf** command as follows: + + .. code-block:: + + ##Uses cookies to prevent some SYN flood attacks when the SYN waiting queue overflows. + net.ipv4.tcp_syncookies = 1 + ##Reuses TIME_WAIT sockets for new TCP connections. + net.ipv4.tcp_tw_reuse = 1 + ##Enables quick reclamation of TIME_WAIT sockets in TCP connections. + net.ipv4.tcp_tw_recycle = 1 + ##Modifies the default timeout time of the system. + net.ipv4.tcp_fin_timeout = 30 + + After the modification, run the **/sbin/sysctl -p** command for the modification to take effect. + +#. If the problem persists after you perform the preceding checks, perform the following steps. + + Capture packets and send packet files along with the time and description of the exception to technical support for analysis. + + Run the following command to capture packets: + + **tcpdump -i eth0 tcp and port 6379 -n -nn -s 74 -w dump.pcap** + + In Windows, you can also install the Wireshark tool to capture packets. + + .. note:: + + Replace the NIC name to the actual one. + +.. |image1| image:: /_static/images/en-us_image_0266315615.png diff --git a/umn/source/faqs/client_and_network_connection/why_do_requests_sometimes_time_out_in_clients.rst b/umn/source/faqs/client_and_network_connection/why_do_requests_sometimes_time_out_in_clients.rst new file mode 100644 index 0000000..80e1f1e --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/why_do_requests_sometimes_time_out_in_clients.rst @@ -0,0 +1,12 @@ +:original_name: dcs-faq-0730005.html + +.. _dcs-faq-0730005: + +Why Do Requests Sometimes Time Out in Clients? +============================================== + +Occasional timeout errors are normal because of network connectivity and client timeout configurations. + +You are advised to include reconnection operations into your service code to avoid service failure if a single request fails. + +If timeout errors occur frequently, contact O&M personnel. diff --git a/umn/source/faqs/client_and_network_connection/why_is_err_unknown_command_displayed_when_i_access_a_dcs_redis_instance_through_a_redis_client.rst b/umn/source/faqs/client_and_network_connection/why_is_err_unknown_command_displayed_when_i_access_a_dcs_redis_instance_through_a_redis_client.rst new file mode 100644 index 0000000..3625a92 --- /dev/null +++ b/umn/source/faqs/client_and_network_connection/why_is_err_unknown_command_displayed_when_i_access_a_dcs_redis_instance_through_a_redis_client.rst @@ -0,0 +1,27 @@ +:original_name: dcs-faq-0730007.html + +.. _dcs-faq-0730007: + +Why Is "ERR unknown command" Displayed When I Access a DCS Redis Instance Through a Redis Client? +================================================================================================= + +The possible causes are as follows: + +#. The command is spelled incorrectly. + + As shown in the following figure, the error message is returned because the correct command for deleting a string should be **del**. + + |image1| + +#. A command available in a higher Redis version is run in a lower Redis version. + + As shown in the following figure, the error message is returned because a stream command (available in Redis 5.0) is run in Redis 3.0. + + |image2| + +#. Some commands are disabled. + + DCS Redis instance interfaces are fully compatible with the open-source Redis in terms of data access. However, for ease of use and security purposes, some operations cannot be initiated through Redis clients. For details about disabled commands, see :ref:`Command Compatibility `. + +.. |image1| image:: /_static/images/en-us_image_0266315616.png +.. |image2| image:: /_static/images/en-us_image_0266315617.png diff --git a/umn/source/faqs/data_backup,_export,_and_migration/can_i_export_backup_data_of_dcs_redis_instances_to_rdb_files_using_the_console.rst b/umn/source/faqs/data_backup,_export,_and_migration/can_i_export_backup_data_of_dcs_redis_instances_to_rdb_files_using_the_console.rst new file mode 100644 index 0000000..3d49618 --- /dev/null +++ b/umn/source/faqs/data_backup,_export,_and_migration/can_i_export_backup_data_of_dcs_redis_instances_to_rdb_files_using_the_console.rst @@ -0,0 +1,16 @@ +:original_name: dcs-faq-0730054.html + +.. _dcs-faq-0730054: + +Can I Export Backup Data of DCS Redis Instances to RDB Files Using the Console? +=============================================================================== + +- Redis 3.0 + + No. On the console, backup data of a DCS Redis 3.0 instance can be exported only to AOF files. To export data to RDB files, run the following command in redis-cli: + + **redis-cli -h {redis_address} -p 6379 [-a password] --rdb {output.rdb}** + +- Redis 4.0 and 5.0 + + Yes. Backup data of a DCS Redis 4.0 or 5.0 instance is exported from the console to RDB files. You cannot use redis-cli to export such data to RDB files. diff --git a/umn/source/faqs/data_backup,_export,_and_migration/does_dcs_support_data_persistence.rst b/umn/source/faqs/data_backup,_export,_and_migration/does_dcs_support_data_persistence.rst new file mode 100644 index 0000000..6b9f30d --- /dev/null +++ b/umn/source/faqs/data_backup,_export,_and_migration/does_dcs_support_data_persistence.rst @@ -0,0 +1,11 @@ +:original_name: dcs-faq-0730057.html + +.. _dcs-faq-0730057: + +Does DCS Support Data Persistence? +================================== + +DCS Redis instances: + +- Single-node: Not supported +- Master/Standby and cluster: Supported diff --git a/umn/source/faqs/data_backup,_export,_and_migration/how_do_i_export_dcs_redis_instance_data.rst b/umn/source/faqs/data_backup,_export,_and_migration/how_do_i_export_dcs_redis_instance_data.rst new file mode 100644 index 0000000..13bf40d --- /dev/null +++ b/umn/source/faqs/data_backup,_export,_and_migration/how_do_i_export_dcs_redis_instance_data.rst @@ -0,0 +1,27 @@ +:original_name: dcs-faq-0730053.html + +.. _dcs-faq-0730053: + +How Do I Export DCS Redis Instance Data? +======================================== + +- For master/standby or cluster instances: + + Perform the following operations to export the data: + + #. On the **Backups & Restorations** page, view the backup records. + #. If there are no backup records, create a backup manually and download the backup file as prompted. + + .. note:: + + If your DCS instances were created a long time ago, the versions of these instances may not be advanced enough to support some new functions (such as backup and restoration). You can contact technical support to upgrade your DCS instances. After the upgrade, you can back up and restore your instances. + +- For single-node instances: + + Single-node instances do not support the backup function. You can use redis-cli to export RDB files. This operation depends on **SYNC** command. + + - If the instance allows the **SYNC** command (such as a Redis 3.0 single-node instance), run the following command to export the instance data: + + **redis-cli -h {source_redis_address} -p 6379 [-a password] --rdb {output.rdb}** + + - If the instance does not allow the **SYNC** command (such as a Redis 4.0 or 5.0 single-node instance), migrate the instance data to a master/standby instance and export the data by using the backup function. diff --git a/umn/source/faqs/data_backup,_export,_and_migration/index.rst b/umn/source/faqs/data_backup,_export,_and_migration/index.rst new file mode 100644 index 0000000..4762ac6 --- /dev/null +++ b/umn/source/faqs/data_backup,_export,_and_migration/index.rst @@ -0,0 +1,20 @@ +:original_name: dcs-faq-0326024.html + +.. _dcs-faq-0326024: + +Data Backup, Export, and Migration +================================== + +- :ref:`How Do I Export DCS Redis Instance Data? ` +- :ref:`Can I Export Backup Data of DCS Redis Instances to RDB Files Using the Console? ` +- :ref:`Does DCS Support Data Persistence? ` +- :ref:`Online Migration with Rump ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + how_do_i_export_dcs_redis_instance_data + can_i_export_backup_data_of_dcs_redis_instances_to_rdb_files_using_the_console + does_dcs_support_data_persistence + online_migration_with_rump diff --git a/umn/source/faqs/data_backup,_export,_and_migration/online_migration_with_rump.rst b/umn/source/faqs/data_backup,_export,_and_migration/online_migration_with_rump.rst new file mode 100644 index 0000000..e4298b9 --- /dev/null +++ b/umn/source/faqs/data_backup,_export,_and_migration/online_migration_with_rump.rst @@ -0,0 +1,72 @@ +:original_name: dcs-migration-090626001.html + +.. _dcs-migration-090626001: + +Online Migration with Rump +========================== + +Background +---------- + +`Rump `__ is an open-source tool designed for migrating Redis data online. It supports migration between DBs of the same instance and between DBs of different instances. + +Migration Principles +-------------------- + +Rump uses the **SCAN** command to acquire keys and the **DUMP**/**RESTORE** command to get or set values. + +Featuring time complexity O(1), **SCAN** is capable of quickly getting all keys. **DUMP**/**RESTORE** is used to read/write values independent from the key type. + +Rump brings the following benefits: + +- The **SCAN** command replaces the **KEYS** command to avoid blocking Redis. +- Any type of data can be migrated. +- **SCAN** and **DUMP**/**RESTORE** operations are pipelined, improving the network efficiency during data migration. +- No temporary file is involved, saving disk space. +- Buffered channels are used to optimize performance of the source server. + +.. important:: + + #. To cluster DCS instances, you cannot use Rump. Instead, use redis-port or redis-cli. + #. To prevent migration command resolution errors, do not include special characters (#@:) in the instance password. + #. Stop the service before migrating data. If data is kept being written in during the migration, some keys might be lost. + +Step 1: Installing Rump +----------------------- + +#. Download `Rump (release version) `__. + + On 64-bit Linux, run the following command: + + **wget https://github.com/stickermule/rump/releases/download/0.0.3/rump-0.0.3-linux-amd64;** + +#. After decompression, run the following commands to add the execution permission: + + **mv rump-0.0.3-linux-amd64 rump;** + + **chmod +x rump;** + +Step 2: Migrating Data +---------------------- + +**rump** **-from** {*source_redis_address*} **-to** {*target_redis_address*} + +Parameter/Option description: + +- *{source_redis_address}* + + Source Redis instance address, in the format of redis://[user:password@]host:port/db. **[user:password@]** is optional. If the instance is accessed in password-protected mode, you must specify the password in the RFC 3986 format. **user** can be omitted, but the colon (:) cannot be omitted. For example, the address may be **redis://:mypassword@192.168.0.45:6379/1**. + + **db** is the sequence number of the database. If it is not specified, the default value is 0. + +- {*target_redis_address*} + + Address of the target Redis instance, in the same format as the source. + + In the following example, data in DB0 of the source Redis is migrated to the target Redis whose connection address is 192.168.0.153. **\*****\*** stands for the password. + + .. code-block:: console + + [root@ecs ~]# ./rump -from redis://127.0.0.1:6379/0 -to redis://:******@192.168.0.153:6379/0 + .Sync done. + [root@ecs ~]# diff --git a/umn/source/faqs/index.rst b/umn/source/faqs/index.rst new file mode 100644 index 0000000..1fe02c2 --- /dev/null +++ b/umn/source/faqs/index.rst @@ -0,0 +1,26 @@ +:original_name: dcs-faq-0326019.html + +.. _dcs-faq-0326019: + +FAQs +==== + +- :ref:`Client and Network Connection ` +- :ref:`Redis Usage ` +- :ref:`Redis Commands ` +- :ref:`Instance Scaling and Upgrade ` +- :ref:`Monitoring and Alarm ` +- :ref:`Data Backup, Export, and Migration ` +- :ref:`Master/Standby Switchover ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + client_and_network_connection/index + redis_usage/index + redis_commands/index + instance_scaling_and_upgrade/index + monitoring_and_alarm/index + data_backup,_export,_and_migration/index + master_standby_switchover/index diff --git a/umn/source/faqs/instance_scaling_and_upgrade/are_instance_resources_affected_during_specification_modification.rst b/umn/source/faqs/instance_scaling_and_upgrade/are_instance_resources_affected_during_specification_modification.rst new file mode 100644 index 0000000..bde94bf --- /dev/null +++ b/umn/source/faqs/instance_scaling_and_upgrade/are_instance_resources_affected_during_specification_modification.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730045.html + +.. _dcs-faq-0730045: + +Are Instance Resources Affected During Specification Modification? +================================================================== + +No. Specification modifications can take place while the instance is running and do not affect any other resources. diff --git a/umn/source/faqs/instance_scaling_and_upgrade/are_services_interrupted_during_specification_modification.rst b/umn/source/faqs/instance_scaling_and_upgrade/are_services_interrupted_during_specification_modification.rst new file mode 100644 index 0000000..d9f5bb7 --- /dev/null +++ b/umn/source/faqs/instance_scaling_and_upgrade/are_services_interrupted_during_specification_modification.rst @@ -0,0 +1,38 @@ +:original_name: dcs-faq-0730047.html + +.. _dcs-faq-0730047: + +Are Services Interrupted During Specification Modification? +=========================================================== + +You are advised to change the instance specifications during off-peak hours because specification modification has the following impacts: + +- **Impact of instance type changes:** + + - From single-node to master/standby for a DCS Redis 3.0 instance: + + The instance cannot be connected for several seconds and remains read-only for about 1 minute. + + - From master/standby to Proxy Cluster for a DCS Redis 3.0 instance: + + The instance cannot be connected and remains read-only for 5 to 30 minutes. + +- **Impact of capacity expansion and reduction:** + + - Single-node and master/standby + + The DCS Redis 3.0, 4.0, or 5.0 instance cannot be connected for several seconds and remains read-only for about 1 minute. + + For capacity expansion, only the memory of the instance is expanded. The CPU processing capability is not improved. + + Data of single-node instances may not be retained because they do not support data persistence. After the scaling, check whether the data is complete and import data if required. + + - Proxy Cluster + + The instance can be connected, but the CPU will be occupied and the latency will increase during data migration. During capacity expansion, new Redis Server nodes are added, and data is automatically balanced to the new nodes. + + - Redis Cluster + + The instance can be connected, but the CPU usage and latency will increase during data migration. During capacity expansion, new Redis Server nodes are added, and data is automatically balanced to the new nodes. + + - Backup records created before the capacity change cannot be restored. diff --git a/umn/source/faqs/instance_scaling_and_upgrade/are_services_interrupted_if_maintenance_is_performed_during_the_maintenance_time_window.rst b/umn/source/faqs/instance_scaling_and_upgrade/are_services_interrupted_if_maintenance_is_performed_during_the_maintenance_time_window.rst new file mode 100644 index 0000000..5e6aed8 --- /dev/null +++ b/umn/source/faqs/instance_scaling_and_upgrade/are_services_interrupted_if_maintenance_is_performed_during_the_maintenance_time_window.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730044.html + +.. _dcs-faq-0730044: + +Are Services Interrupted If Maintenance is Performed During the Maintenance Time Window? +======================================================================================== + +O&M personnel will contact you before performing maintenance during the maintenance time window, informing you of the operations and their impacts. You do not need to worry about instance running exceptions. diff --git a/umn/source/faqs/instance_scaling_and_upgrade/can_dcs_redis_instances_be_upgraded,_for_example,_from_redis_3.0_to_redis_4.0_or_5.0.rst b/umn/source/faqs/instance_scaling_and_upgrade/can_dcs_redis_instances_be_upgraded,_for_example,_from_redis_3.0_to_redis_4.0_or_5.0.rst new file mode 100644 index 0000000..2d2fff7 --- /dev/null +++ b/umn/source/faqs/instance_scaling_and_upgrade/can_dcs_redis_instances_be_upgraded,_for_example,_from_redis_3.0_to_redis_4.0_or_5.0.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730043.html + +.. _dcs-faq-0730043: + +Can DCS Redis Instances Be Upgraded, for Example, from Redis 3.0 to Redis 4.0 or 5.0? +===================================================================================== + +No. Different Redis versions use different underlying architectures. The Redis version used by a DCS instance cannot be changed once the instance is created. However, you will be informed of any defects or problems found in Redis. + +If your service requires the features of higher Redis versions, create a DCS Redis instance of a higher version and then migrate data from the original instance to the new one. For details on how to migrate data, see :ref:`Migrating Data with DCS `. diff --git a/umn/source/faqs/instance_scaling_and_upgrade/index.rst b/umn/source/faqs/instance_scaling_and_upgrade/index.rst new file mode 100644 index 0000000..e417e59 --- /dev/null +++ b/umn/source/faqs/instance_scaling_and_upgrade/index.rst @@ -0,0 +1,22 @@ +:original_name: dcs-faq-0326022.html + +.. _dcs-faq-0326022: + +Instance Scaling and Upgrade +============================ + +- :ref:`Can DCS Redis Instances Be Upgraded, for Example, from Redis 3.0 to Redis 4.0 or 5.0? ` +- :ref:`Are Services Interrupted If Maintenance is Performed During the Maintenance Time Window? ` +- :ref:`Are Instance Resources Affected During Specification Modification? ` +- :ref:`Are Services Interrupted During Specification Modification? ` +- :ref:`Why Can't I Modify Specifications for a DCS Redis Instance? ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + can_dcs_redis_instances_be_upgraded,_for_example,_from_redis_3.0_to_redis_4.0_or_5.0 + are_services_interrupted_if_maintenance_is_performed_during_the_maintenance_time_window + are_instance_resources_affected_during_specification_modification + are_services_interrupted_during_specification_modification + why_cant_i_modify_specifications_for_a_dcs_redis_instance diff --git a/umn/source/faqs/instance_scaling_and_upgrade/why_cant_i_modify_specifications_for_a_dcs_redis_instance.rst b/umn/source/faqs/instance_scaling_and_upgrade/why_cant_i_modify_specifications_for_a_dcs_redis_instance.rst new file mode 100644 index 0000000..c4401f5 --- /dev/null +++ b/umn/source/faqs/instance_scaling_and_upgrade/why_cant_i_modify_specifications_for_a_dcs_redis_instance.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730048.html + +.. _dcs-faq-0730048: + +Why Can't I Modify Specifications for a DCS Redis Instance? +=========================================================== + +Specifications of a DCS instance cannot be modified if another task of the instance is still running. For example, you cannot delete or scale up an instance while it is being restarted. Likewise, you cannot delete an instance while it is being scaled up. + +If the specification modification fails, try again later. If it fails again, contact technical support. diff --git a/umn/source/faqs/master_standby_switchover/does_the_client_need_to_switch_the_connection_address_after_a_master_standby_switchover.rst b/umn/source/faqs/master_standby_switchover/does_the_client_need_to_switch_the_connection_address_after_a_master_standby_switchover.rst new file mode 100644 index 0000000..2628dde --- /dev/null +++ b/umn/source/faqs/master_standby_switchover/does_the_client_need_to_switch_the_connection_address_after_a_master_standby_switchover.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730060.html + +.. _dcs-faq-0730060: + +Does the Client Need to Switch the Connection Address After a Master/Standby Switchover? +======================================================================================== + +No. If the master fails, the standby node will be promoted to master and takes the original IP address. diff --git a/umn/source/faqs/master_standby_switchover/how_does_master_standby_switchover_affect_services.rst b/umn/source/faqs/master_standby_switchover/how_does_master_standby_switchover_affect_services.rst new file mode 100644 index 0000000..65490e9 --- /dev/null +++ b/umn/source/faqs/master_standby_switchover/how_does_master_standby_switchover_affect_services.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730059.html + +.. _dcs-faq-0730059: + +How Does Master/Standby Switchover Affect Services? +=================================================== + +If a fault occurs in a master/standby or cluster DCS instance, a failover is triggered automatically. Services may be interrupted for less than half a minute during exception detection and failover. diff --git a/umn/source/faqs/master_standby_switchover/how_does_redis_master_standby_replication_work.rst b/umn/source/faqs/master_standby_switchover/how_does_redis_master_standby_replication_work.rst new file mode 100644 index 0000000..d172642 --- /dev/null +++ b/umn/source/faqs/master_standby_switchover/how_does_redis_master_standby_replication_work.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730061.html + +.. _dcs-faq-0730061: + +How Does Redis Master/Standby Replication Work? +=============================================== + +Redis master/standby instances are also called master/slave instances. Generally, updates to the master cache node are automatically and asynchronously replicated to the standby cache node. This means that data in the standby cache node may not always be consistent with data in the master cache node. The inconsistency is typically seen when the I/O write speed of the master node is faster than the synchronization speed of the standby node or a network latency occurs between the master and standby nodes. If a failover happens when some data is not yet replicated to the standby node, such data may be lost after the failover. diff --git a/umn/source/faqs/master_standby_switchover/index.rst b/umn/source/faqs/master_standby_switchover/index.rst new file mode 100644 index 0000000..3811a8d --- /dev/null +++ b/umn/source/faqs/master_standby_switchover/index.rst @@ -0,0 +1,20 @@ +:original_name: dcs-faq-191204001.html + +.. _dcs-faq-191204001: + +Master/Standby Switchover +========================= + +- :ref:`When Does a Master/Standby Switchover Occur? ` +- :ref:`How Does Master/Standby Switchover Affect Services? ` +- :ref:`Does the Client Need to Switch the Connection Address After a Master/Standby Switchover? ` +- :ref:`How Does Redis Master/Standby Replication Work? ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + when_does_a_master_standby_switchover_occur + how_does_master_standby_switchover_affect_services + does_the_client_need_to_switch_the_connection_address_after_a_master_standby_switchover + how_does_redis_master_standby_replication_work diff --git a/umn/source/faqs/master_standby_switchover/when_does_a_master_standby_switchover_occur.rst b/umn/source/faqs/master_standby_switchover/when_does_a_master_standby_switchover_occur.rst new file mode 100644 index 0000000..72b888d --- /dev/null +++ b/umn/source/faqs/master_standby_switchover/when_does_a_master_standby_switchover_occur.rst @@ -0,0 +1,18 @@ +:original_name: dcs-faq-0730058.html + +.. _dcs-faq-0730058: + +When Does a Master/Standby Switchover Occur? +============================================ + +A master/standby switchover may occur in the following scenarios: + +- A master/standby switchover operation is initiated on the DCS Console. + +- If the master node of a master/standby instance fails, a master/standby switchover will be triggered. + + For example, running commands that consume a lot of resources, such as **KEYS** commands, will cause CPU usage to spike and as result triggers a master/standby switchover. + +- If you restart a master/standby instance on the DCS console, a master/standby switchover will be triggered. + +After a master/standby switchover occurs, you will receive a notification. Check whether the client services are running properly. If not, check whether the TCP connection is normal and whether it can be re-established after the master/standby switchover to restore the services. diff --git a/umn/source/faqs/monitoring_and_alarm/does_redis_support_command_audits.rst b/umn/source/faqs/monitoring_and_alarm/does_redis_support_command_audits.rst new file mode 100644 index 0000000..9541bae --- /dev/null +++ b/umn/source/faqs/monitoring_and_alarm/does_redis_support_command_audits.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730049.html + +.. _dcs-faq-0730049: + +Does Redis Support Command Audits? +================================== + +No. To ensure high-performance reads and writes, Redis does not audit commands. Commands are not printed. diff --git a/umn/source/faqs/monitoring_and_alarm/index.rst b/umn/source/faqs/monitoring_and_alarm/index.rst new file mode 100644 index 0000000..f06db85 --- /dev/null +++ b/umn/source/faqs/monitoring_and_alarm/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-faq-0326023.html + +.. _dcs-faq-0326023: + +Monitoring and Alarm +==================== + +- :ref:`Does Redis Support Command Audits? ` +- :ref:`What Should I Do If the Monitoring Data of a DCS Redis Instance Is Abnormal? ` +- :ref:`Why Is Used Memory Greater Than Available Memory? ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + does_redis_support_command_audits + what_should_i_do_if_the_monitoring_data_of_a_dcs_redis_instance_is_abnormal + why_is_used_memory_greater_than_available_memory diff --git a/umn/source/faqs/monitoring_and_alarm/what_should_i_do_if_the_monitoring_data_of_a_dcs_redis_instance_is_abnormal.rst b/umn/source/faqs/monitoring_and_alarm/what_should_i_do_if_the_monitoring_data_of_a_dcs_redis_instance_is_abnormal.rst new file mode 100644 index 0000000..a2348e6 --- /dev/null +++ b/umn/source/faqs/monitoring_and_alarm/what_should_i_do_if_the_monitoring_data_of_a_dcs_redis_instance_is_abnormal.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730050.html + +.. _dcs-faq-0730050: + +What Should I Do If the Monitoring Data of a DCS Redis Instance Is Abnormal? +============================================================================ + +If you have any doubt on the monitoring data of a DCS Redis instance, you can access the instance through redis-cli and run the **INFO ALL** command to view the metrics. For details about the output of the **INFO ALL** command, see http://www.redis.io/commands/info. diff --git a/umn/source/faqs/monitoring_and_alarm/why_is_used_memory_greater_than_available_memory.rst b/umn/source/faqs/monitoring_and_alarm/why_is_used_memory_greater_than_available_memory.rst new file mode 100644 index 0000000..84c7711 --- /dev/null +++ b/umn/source/faqs/monitoring_and_alarm/why_is_used_memory_greater_than_available_memory.rst @@ -0,0 +1,14 @@ +:original_name: dcs-faq-0730052.html + +.. _dcs-faq-0730052: + +Why Is Used Memory Greater Than Available Memory? +================================================= + +For single-node and master/standby DCS instances, the used instance memory is measured by the Redis-server process. For cluster DCS instances, the used cluster memory is the sum of used memory of all shards in the cluster. + +Due to the internal implementation of the open-source redis-server, the used instance memory is normally slightly higher than the available instance memory. + +**Why is used_memory higher than max_memory?** + +Redis allocates memory using zmalloc. It does not check whether used_memory exceeds max_memory every time the memory is allocated. Instead, it checks whether the current used_memory exceeds max_memory at the beginning of a periodic task or command processing. If used_memory exceeds max_memory, eviction is triggered. Therefore, the restrictions of the max_memory policy are not implemented in real time or rigidly. A case in which the used_memory is greater than the max_memory may occur occasionally. diff --git a/umn/source/faqs/redis_commands/does_dcs_for_redis_support_the_incr_and_expire_commands.rst b/umn/source/faqs/redis_commands/does_dcs_for_redis_support_the_incr_and_expire_commands.rst new file mode 100644 index 0000000..e7c0646 --- /dev/null +++ b/umn/source/faqs/redis_commands/does_dcs_for_redis_support_the_incr_and_expire_commands.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730039.html + +.. _dcs-faq-0730039: + +Does DCS for Redis Support the INCR and EXPIRE Commands? +======================================================== + +Yes. For more information about Redis command compatibility, see :ref:`Command Compatibility `. diff --git a/umn/source/faqs/redis_commands/how_do_i_clear_redis_data.rst b/umn/source/faqs/redis_commands/how_do_i_clear_redis_data.rst new file mode 100644 index 0000000..d56c9cc --- /dev/null +++ b/umn/source/faqs/redis_commands/how_do_i_clear_redis_data.rst @@ -0,0 +1,28 @@ +:original_name: dcs-faq-0730036.html + +.. _dcs-faq-0730036: + +How Do I Clear Redis Data? +========================== + +**Exercise caution when clearing data.** + +- Redis 3.0 + + Data of a DCS Redis 3.0 instance cannot be cleared on the console, and can only be cleared by the **FLUSHDB** or **FLUSHALL** command in redis-cli. + + Run the **FLUSHALL** command to clear all the data in the instance. + + Run the **FLUSHDB** command to clear the data in the currently selected DB. + +- Redis 4.0 and 5.0 + + To clear data of a DCS Redis 4.0 or 5.0 instance, you can run the **FLUSHDB** or **FLUSHALL** command in redis-cli, use the data clearing function on the DCS console, or run the **FLUSHDB** command on Web CLI. + + To clear data of a Redis Cluster instance, run the **FLUSHDB** or **FLUSHALL** command on every shard of the instance. Otherwise, data may not be completely cleared. + + .. note:: + + - Currently, only DCS Redis 4.0 and 5.0 instances support data clearing by using the DCS console and by running the **FLUSHDB** command on Web CLI. + - When you run the **FLUSHDB** command on Web CLI, only one shard is cleared at a time. If there are multiple shards, connect to and run the **FLUSHDB** command on each master node. + - Redis Cluster data cannot be cleared by using Web CLI. diff --git a/umn/source/faqs/redis_commands/index.rst b/umn/source/faqs/redis_commands/index.rst new file mode 100644 index 0000000..d346efe --- /dev/null +++ b/umn/source/faqs/redis_commands/index.rst @@ -0,0 +1,22 @@ +:original_name: dcs-faq-190921003.html + +.. _dcs-faq-190921003: + +Redis Commands +============== + +- :ref:`How Do I Clear Redis Data? ` +- :ref:`Does DCS for Redis Support the INCR and EXPIRE Commands? ` +- :ref:`Why Do I Fail to Execute Some Redis Commands? ` +- :ref:`Why Does a Redis Command Fail to Take Effect? ` +- :ref:`Is There a Time Limit on Executing Redis Commands? What Will Happen If a Command Times Out? ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + how_do_i_clear_redis_data + does_dcs_for_redis_support_the_incr_and_expire_commands + why_do_i_fail_to_execute_some_redis_commands + why_does_a_redis_command_fail_to_take_effect + is_there_a_time_limit_on_executing_redis_commands_what_will_happen_if_a_command_times_out diff --git a/umn/source/faqs/redis_commands/is_there_a_time_limit_on_executing_redis_commands_what_will_happen_if_a_command_times_out.rst b/umn/source/faqs/redis_commands/is_there_a_time_limit_on_executing_redis_commands_what_will_happen_if_a_command_times_out.rst new file mode 100644 index 0000000..105cbf2 --- /dev/null +++ b/umn/source/faqs/redis_commands/is_there_a_time_limit_on_executing_redis_commands_what_will_happen_if_a_command_times_out.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730042.html + +.. _dcs-faq-0730042: + +Is There a Time Limit on Executing Redis Commands? What Will Happen If a Command Times Out? +=========================================================================================== + +The time limit for executing a Redis command is 1 minute. This limit cannot be configured. After the execution of a command times out, your client will be automatically disconnected. diff --git a/umn/source/faqs/redis_commands/why_do_i_fail_to_execute_some_redis_commands.rst b/umn/source/faqs/redis_commands/why_do_i_fail_to_execute_some_redis_commands.rst new file mode 100644 index 0000000..21d15df --- /dev/null +++ b/umn/source/faqs/redis_commands/why_do_i_fail_to_execute_some_redis_commands.rst @@ -0,0 +1,22 @@ +:original_name: dcs-faq-0730040.html + +.. _dcs-faq-0730040: + +Why Do I Fail to Execute Some Redis Commands? +============================================= + +Possible causes include the following: + +- The command is incorrect. + +- The command is disabled in DCS. + + For security purposes, some Redis commands are disabled in DCS. For details about disabled and restricted Redis commands, see :ref:`Command Compatibility `. + +- The LUA script fails to be executed. + + For example, the error message "ERR unknown command 'EVAL'" indicates that your DCS Redis instance is of a lower version that does not support the LUA script. In this case, contact technical support for the instance to be upgraded. + +- The **CLIENT SETNAME** and **CLIENT GETNAME** commands fail to be executed. + + This is because the DCS Redis instance is of a lower version that does not support these commands. In this case, contact technical support for the instance to be upgraded. diff --git a/umn/source/faqs/redis_commands/why_does_a_redis_command_fail_to_take_effect.rst b/umn/source/faqs/redis_commands/why_does_a_redis_command_fail_to_take_effect.rst new file mode 100644 index 0000000..bf496bd --- /dev/null +++ b/umn/source/faqs/redis_commands/why_does_a_redis_command_fail_to_take_effect.rst @@ -0,0 +1,31 @@ +:original_name: dcs-faq-0730041.html + +.. _dcs-faq-0730041: + +Why Does a Redis Command Fail to Take Effect? +============================================= + +Run the command in redis-cli to check whether the command takes effect. + +The following describes two scenarios: + +- Scenario 1: Set and query the value of a key to check whether the **SET** and **GET** commands work. + + The **SET** command is used to set the string value. If the value is not changed, run the following commands in redis-cli to access the instance: + + |image1| + +- Scenario 2: If the timeout set using the **EXPIRE** command is incorrect, perform the following operations: + + Set the timeout to 10 seconds and run the **TTL** command to view the remaining time. As shown in the following example, the remaining time is 7 seconds. + + |image2| + +.. note:: + + Redis clients (including redis-cli, Jedis clients, and Python clients) communicate with Redis server using a binary protocol. + + If Redis commands are run properly in redis-cli, the problem may lie in the service code. In this case, create logs in the code for further analysis. + +.. |image1| image:: /_static/images/en-us_image_0266322522.jpg +.. |image2| image:: /_static/images/en-us_image_0266322523.png diff --git a/umn/source/faqs/redis_usage/can_i_change_the_vpc_and_subnet_for_a_dcs_redis_instance.rst b/umn/source/faqs/redis_usage/can_i_change_the_vpc_and_subnet_for_a_dcs_redis_instance.rst new file mode 100644 index 0000000..2e91f24 --- /dev/null +++ b/umn/source/faqs/redis_usage/can_i_change_the_vpc_and_subnet_for_a_dcs_redis_instance.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730013.html + +.. _dcs-faq-0730013: + +Can I Change the VPC and Subnet for a DCS Redis Instance? +========================================================= + +No. Once an instance is created, its VPC and subnet cannot be changed. If you want to use a different set of VPC and subnet, create a same instance and specify a desired set of VPC and subnet. After the new instance is created, you can migrate data from the old instance to the new instance by following the :ref:`data migration instructions `. diff --git a/umn/source/faqs/redis_usage/can_i_customize_or_change_the_port_for_accessing_a_dcs_instance.rst b/umn/source/faqs/redis_usage/can_i_customize_or_change_the_port_for_accessing_a_dcs_instance.rst new file mode 100644 index 0000000..24417d3 --- /dev/null +++ b/umn/source/faqs/redis_usage/can_i_customize_or_change_the_port_for_accessing_a_dcs_instance.rst @@ -0,0 +1,18 @@ +:original_name: dcs-faq-0730026.html + +.. _dcs-faq-0730026: + +Can I Customize or Change the Port for Accessing a DCS Instance? +================================================================ + +You cannot customize or change the port for accessing a DCS Redis 3.0 instance. You can customize and change the port for accessing a DCS Redis 4.0 or 5.0 instance. + +- Redis 3.0 + + Use port 6379 for intra-VPC access. + +- Redis 4.0 and Redis 5.0 + + You can specify a port (ranging from 1 to 65535) or use the default port (6379) for accessing a DCS Redis 4.0 or 5.0 instance. If no port is specified, the default port will be used. + +If the instance and the client use different security groups, you must configure access rules for the security groups, allowing access through the specified port. For details, see :ref:`Security Group Configurations `. diff --git a/umn/source/faqs/redis_usage/can_i_modify_the_connection_addresses_for_accessing_a_dcs_instance.rst b/umn/source/faqs/redis_usage/can_i_modify_the_connection_addresses_for_accessing_a_dcs_instance.rst new file mode 100644 index 0000000..c9e2885 --- /dev/null +++ b/umn/source/faqs/redis_usage/can_i_modify_the_connection_addresses_for_accessing_a_dcs_instance.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730027.html + +.. _dcs-faq-0730027: + +Can I Modify the Connection Addresses for Accessing a DCS Instance? +=================================================================== + +After a DCS instance is created, its intra-VPC connection addresses cannot be modified. + +For details about accessing DCS instances through clients, see :ref:`Accessing a DCS Redis Instance Through redis-cli `. diff --git a/umn/source/faqs/redis_usage/can_i_obtain_the_addresses_of_the_nodes_in_a_cluster_dcs_redis_instance.rst b/umn/source/faqs/redis_usage/can_i_obtain_the_addresses_of_the_nodes_in_a_cluster_dcs_redis_instance.rst new file mode 100644 index 0000000..d56b11b --- /dev/null +++ b/umn/source/faqs/redis_usage/can_i_obtain_the_addresses_of_the_nodes_in_a_cluster_dcs_redis_instance.rst @@ -0,0 +1,18 @@ +:original_name: dcs-faq-0730017.html + +.. _dcs-faq-0730017: + +Can I Obtain the Addresses of the Nodes in a Cluster DCS Redis Instance? +======================================================================== + +Cluster DCS Redis 3.0 instances (Proxy Cluster type) are used in the same way that you use single-node or master/standby instances. You do not need to know the backend node addresses. + +For a cluster DCS Redis 4.0 or 5.0 instance (Redis Cluster type), run the **CLUSTER NODES** command to obtain node addresses: + +**redis-cli -h {redis_address} -p {redis_port} -a {redis_password} cluster nodes** + +In the output similar to the following, obtain the IP addresses and port numbers of all the master nodes. + +|image1| + +.. |image1| image:: /_static/images/en-us_image_0266316213.png diff --git a/umn/source/faqs/redis_usage/can_i_recover_data_from_deleted_dcs_instances.rst b/umn/source/faqs/redis_usage/can_i_recover_data_from_deleted_dcs_instances.rst new file mode 100644 index 0000000..435ac46 --- /dev/null +++ b/umn/source/faqs/redis_usage/can_i_recover_data_from_deleted_dcs_instances.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730034.html + +.. _dcs-faq-0730034: + +Can I Recover Data from Deleted DCS Instances? +============================================== + +If a DCS instance is automatically deleted or manually deleted through the Redis client, its data cannot be retrieved. If you have backed up the instance, you can restore its data from the backup. However, the restoration will overwrite the data written in during the period from the backup and the restoration. + +By default, data is not evicted from DCS instances. You can modify the instance configuration parameters to adjust the eviction policy so that the instance can evict key values. diff --git a/umn/source/faqs/redis_usage/do_dcs_redis_instances_limit_the_size_of_a_key_or_value.rst b/umn/source/faqs/redis_usage/do_dcs_redis_instances_limit_the_size_of_a_key_or_value.rst new file mode 100644 index 0000000..c34872c --- /dev/null +++ b/umn/source/faqs/redis_usage/do_dcs_redis_instances_limit_the_size_of_a_key_or_value.rst @@ -0,0 +1,18 @@ +:original_name: dcs-faq-0730015.html + +.. _dcs-faq-0730015: + +Do DCS Redis Instances Limit the Size of a Key or Value? +======================================================== + +- The maximum allowed size of a key is 512 MB. + + To reduce memory usage and facilitate key query, ensure that each key does not exceed 1 KB. + +- The maximum allowed size of a string is 512 MB. + +- The maximum allowed size of a Set, List, or Hash is 512 MB. + + In essence, a Set is a collection of Strings; a List is a list of Strings; a Hash contains mappings between string fields and string values. + +Prevent the client from constantly writing large values in Redis. Otherwise, network transmission efficiency will be lowered and the Redis server would take a longer time to process commands, resulting in higher latency. diff --git a/umn/source/faqs/redis_usage/does_dcs_for_redis_provide_backend_management_software.rst b/umn/source/faqs/redis_usage/does_dcs_for_redis_provide_backend_management_software.rst new file mode 100644 index 0000000..0c2bd2d --- /dev/null +++ b/umn/source/faqs/redis_usage/does_dcs_for_redis_provide_backend_management_software.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730032.html + +.. _dcs-faq-0730032: + +Does DCS for Redis Provide Backend Management Software? +======================================================= + +No. If you wish to query Redis configurations and usage information, use redis-cli. If you wish to monitor DCS Redis instance metrics, go to the Cloud Eye console. For details on how to configure and view the metrics, see :ref:`Monitoring `. diff --git a/umn/source/faqs/redis_usage/does_dcs_for_redis_support_multiple_databases.rst b/umn/source/faqs/redis_usage/does_dcs_for_redis_support_multiple_databases.rst new file mode 100644 index 0000000..ac527c4 --- /dev/null +++ b/umn/source/faqs/redis_usage/does_dcs_for_redis_support_multiple_databases.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730019.html + +.. _dcs-faq-0730019: + +Does DCS for Redis Support Multiple Databases? +============================================== + +Both single-node and master/standby DCS Redis instances support multiple databases. By default, single-node and master/standby DCS instances can read and write data in 256 databases (databases numbering 0-255). + +Cluster DCS instances do not support data read/write in multiple databases. diff --git a/umn/source/faqs/redis_usage/does_dcs_for_redis_support_redis_clusters.rst b/umn/source/faqs/redis_usage/does_dcs_for_redis_support_redis_clusters.rst new file mode 100644 index 0000000..9001646 --- /dev/null +++ b/umn/source/faqs/redis_usage/does_dcs_for_redis_support_redis_clusters.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730020.html + +.. _dcs-faq-0730020: + +Does DCS for Redis Support Redis Clusters? +========================================== + +Yes. DCS for Redis 4.0 and 5.0 support Redis Clusters. DCS for Redis 3.0 supports Proxy Clusters. diff --git a/umn/source/faqs/redis_usage/does_dcs_for_redis_support_sentinel.rst b/umn/source/faqs/redis_usage/does_dcs_for_redis_support_sentinel.rst new file mode 100644 index 0000000..c248cb5 --- /dev/null +++ b/umn/source/faqs/redis_usage/does_dcs_for_redis_support_sentinel.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730021.html + +.. _dcs-faq-0730021: + +Does DCS for Redis Support Sentinel? +==================================== + +Yes. Redis Sentinel is supported by DCS for Redis 4.0 and 5.0 and is enabled by default. Sentinel constantly checks if master and replica nodes are running properly. If the master is not running properly, Sentinel starts a failover process and promotes a replica to master. + +However, DCS for Redis 3.0 does not support Redis Sentinel. Instead, it uses keepalive to monitor master and replica nodes and to manage failovers. diff --git a/umn/source/faqs/redis_usage/does_dcs_support_cross-az_deployment.rst b/umn/source/faqs/redis_usage/does_dcs_support_cross-az_deployment.rst new file mode 100644 index 0000000..2fcab3b --- /dev/null +++ b/umn/source/faqs/redis_usage/does_dcs_support_cross-az_deployment.rst @@ -0,0 +1,11 @@ +:original_name: dcs-faq-0730029.html + +.. _dcs-faq-0730029: + +Does DCS Support Cross-AZ Deployment? +===================================== + +Master/Standby and cluster DCS Redis instances can be deployed across availability zones (AZs). + +- If instances nodes in an AZ are faulty, nodes in other AZs will not be affected. The standby node automatically becomes the master node to continue to operate, ensuring disaster recovery (DR). +- Cross-AZ deployment does not compromise the speed of data synchronization between the master and standby nodes. diff --git a/umn/source/faqs/redis_usage/index.rst b/umn/source/faqs/redis_usage/index.rst new file mode 100644 index 0000000..89c2248 --- /dev/null +++ b/umn/source/faqs/redis_usage/index.rst @@ -0,0 +1,54 @@ +:original_name: dcs-faq-0326021.html + +.. _dcs-faq-0326021: + +Redis Usage +=========== + +- :ref:`Why Is CPU Usage of a DCS Redis Instance 100%? ` +- :ref:`Can I Change the VPC and Subnet for a DCS Redis Instance? ` +- :ref:`Why Aren't Security Groups Configured for DCS Redis 4.0 and 5.0 Instances? ` +- :ref:`Do DCS Redis Instances Limit the Size of a Key or Value? ` +- :ref:`Can I Obtain the Addresses of the Nodes in a Cluster DCS Redis Instance? ` +- :ref:`Why Is Available Memory of a DCS Redis 3.0 Instance Smaller Than Instance Cache Size? ` +- :ref:`Does DCS for Redis Support Multiple Databases? ` +- :ref:`Does DCS for Redis Support Redis Clusters? ` +- :ref:`Does DCS for Redis Support Sentinel? ` +- :ref:`What Is the Default Data Eviction Policy? ` +- :ref:`What Should I Do If an Error Occurs in Redis Exporter? ` +- :ref:`Why Is Memory Usage More Than 100%? ` +- :ref:`Why Is Redisson Distributed Lock Not Supported by DCS Proxy Cluster Redis 3.0 Instances? ` +- :ref:`Can I Customize or Change the Port for Accessing a DCS Instance? ` +- :ref:`Can I Modify the Connection Addresses for Accessing a DCS Instance? ` +- :ref:`Does DCS Support Cross-AZ Deployment? ` +- :ref:`Why Does It Take a Long Time to Start a Cluster DCS Instance? ` +- :ref:`Does DCS for Redis Provide Backend Management Software? ` +- :ref:`Why Is Memory of a DCS Redis Instance Used Up by Just a Few Keys? ` +- :ref:`Can I Recover Data from Deleted DCS Instances? ` +- :ref:`Why Is "Error in execution" Returned When I Access Redis? ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + why_is_cpu_usage_of_a_dcs_redis_instance_100% + can_i_change_the_vpc_and_subnet_for_a_dcs_redis_instance + why_arent_security_groups_configured_for_dcs_redis_4.0_and_5.0_instances + do_dcs_redis_instances_limit_the_size_of_a_key_or_value + can_i_obtain_the_addresses_of_the_nodes_in_a_cluster_dcs_redis_instance + why_is_available_memory_of_a_dcs_redis_3.0_instance_smaller_than_instance_cache_size + does_dcs_for_redis_support_multiple_databases + does_dcs_for_redis_support_redis_clusters + does_dcs_for_redis_support_sentinel + what_is_the_default_data_eviction_policy + what_should_i_do_if_an_error_occurs_in_redis_exporter + why_is_memory_usage_more_than_100% + why_is_redisson_distributed_lock_not_supported_by_dcs_proxy_cluster_redis_3.0_instances + can_i_customize_or_change_the_port_for_accessing_a_dcs_instance + can_i_modify_the_connection_addresses_for_accessing_a_dcs_instance + does_dcs_support_cross-az_deployment + why_does_it_take_a_long_time_to_start_a_cluster_dcs_instance + does_dcs_for_redis_provide_backend_management_software + why_is_memory_of_a_dcs_redis_instance_used_up_by_just_a_few_keys + can_i_recover_data_from_deleted_dcs_instances + why_is_error_in_execution_returned_when_i_access_redis diff --git a/umn/source/faqs/redis_usage/what_is_the_default_data_eviction_policy.rst b/umn/source/faqs/redis_usage/what_is_the_default_data_eviction_policy.rst new file mode 100644 index 0000000..6b6915c --- /dev/null +++ b/umn/source/faqs/redis_usage/what_is_the_default_data_eviction_policy.rst @@ -0,0 +1,27 @@ +:original_name: dcs-faq-0730022.html + +.. _dcs-faq-0730022: + +What Is the Default Data Eviction Policy? +========================================= + +Data is evicted from cache based on a user-defined space limit in order to make space for new data. In the current versions of DCS, you can select an eviction policy. + +**noeviction** is the default eviction policy for single-node and master/standby DCS Redis instances. You can change the eviction policy by configuring the instance parameters on the DCS console. + +**volatile-lru** is the default eviction policy for cluster DCS Redis instances. To change the eviction policy for cluster instances, contact technical support. + +When **maxmemory** is reached, you can select one of the following eight eviction policies: + +- **noeviction**: When the memory limit is reached, DCS instances return errors to clients and no longer process write requests and other requests that could result in more memory to be used. However, **DEL** and a few more exception requests can continue to be processed. +- **allkeys-lru**: DCS instances try to evict the least recently used keys first, in order to make space for new data. +- **volatile-lru**: DCS instances try to evict the least recently used keys with an expire set first, in order to make space for new data. +- **allkeys-random**: DCS instances recycle random keys so that new data can be stored. +- **volatile-random**: DCS instances evict random keys with an expire set, in order to make space for new data. +- **volatile-ttl**: DCS instances evict keys with an expire set, and try to evict keys with a shorter time to live (TTL) first, in order to make space for new data. +- **allkeys-lfu**: DCS instances evict the least frequently used keys from all keys. +- **volatile-lfu**: DCS instances evict the least frequently used keys with an **expire** field from all keys. + +.. note:: + + If no key can be recycled, **volatile-lru**, **volatile-random**, and **volatile-ttl** are the same as **noeviction**. For details, see the description of **noeviction**. diff --git a/umn/source/faqs/redis_usage/what_should_i_do_if_an_error_occurs_in_redis_exporter.rst b/umn/source/faqs/redis_usage/what_should_i_do_if_an_error_occurs_in_redis_exporter.rst new file mode 100644 index 0000000..824309e --- /dev/null +++ b/umn/source/faqs/redis_usage/what_should_i_do_if_an_error_occurs_in_redis_exporter.rst @@ -0,0 +1,12 @@ +:original_name: dcs-faq-0730023.html + +.. _dcs-faq-0730023: + +What Should I Do If an Error Occurs in Redis Exporter? +====================================================== + +Start the Redis exporter using the CLI. Based on the output, check for errors and troubleshoot accordingly. + +|image1| + +.. |image1| image:: /_static/images/en-us_image_0266316214.jpg diff --git a/umn/source/faqs/redis_usage/why_arent_security_groups_configured_for_dcs_redis_4.0_and_5.0_instances.rst b/umn/source/faqs/redis_usage/why_arent_security_groups_configured_for_dcs_redis_4.0_and_5.0_instances.rst new file mode 100644 index 0000000..5b4a297 --- /dev/null +++ b/umn/source/faqs/redis_usage/why_arent_security_groups_configured_for_dcs_redis_4.0_and_5.0_instances.rst @@ -0,0 +1,12 @@ +:original_name: dcs-faq-0730014.html + +.. _dcs-faq-0730014: + +Why Aren't Security Groups Configured for DCS Redis 4.0 and 5.0 Instances? +========================================================================== + +Currently, DCS Redis 4.0 and Redis 5.0 instances use VPC endpoints and do not support security groups. You can configure whitelists instead. For details, see :ref:`Managing IP Address Whitelist `. + +To allow access only from specific IP addresses to a DCS Redis 4.0 or 5.0 instance, add the IP addresses to the instance whitelist. + +If no whitelists are added to the instance whitelist or the whitelist function is disabled, all IP addresses that can communicate with the VPC can access the instance. diff --git a/umn/source/faqs/redis_usage/why_does_it_take_a_long_time_to_start_a_cluster_dcs_instance.rst b/umn/source/faqs/redis_usage/why_does_it_take_a_long_time_to_start_a_cluster_dcs_instance.rst new file mode 100644 index 0000000..d0f5052 --- /dev/null +++ b/umn/source/faqs/redis_usage/why_does_it_take_a_long_time_to_start_a_cluster_dcs_instance.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730030.html + +.. _dcs-faq-0730030: + +Why Does It Take a Long Time to Start a Cluster DCS Instance? +============================================================= + +Possible cause: When a cluster instance is started, status and data are synchronized between the nodes of the instance. If a large amount of data is continuously written into the instance before the synchronization is complete, the synchronization will be prolonged and the instance remains in the **Starting** state. After the synchronization is complete, the instance enters the **Running** state. + +Solution: Start writing data to an instance only after the instance has been started. diff --git a/umn/source/faqs/redis_usage/why_is_available_memory_of_a_dcs_redis_3.0_instance_smaller_than_instance_cache_size.rst b/umn/source/faqs/redis_usage/why_is_available_memory_of_a_dcs_redis_3.0_instance_smaller_than_instance_cache_size.rst new file mode 100644 index 0000000..ff1b71f --- /dev/null +++ b/umn/source/faqs/redis_usage/why_is_available_memory_of_a_dcs_redis_3.0_instance_smaller_than_instance_cache_size.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730018.html + +.. _dcs-faq-0730018: + +Why Is Available Memory of a DCS Redis 3.0 Instance Smaller Than Instance Cache Size? +===================================================================================== + +DCS Redis 3.0 instances are deployed on VMs and some memory is reserved for system overheads. diff --git a/umn/source/faqs/redis_usage/why_is_cpu_usage_of_a_dcs_redis_instance_100%.rst b/umn/source/faqs/redis_usage/why_is_cpu_usage_of_a_dcs_redis_instance_100%.rst new file mode 100644 index 0000000..ce94f48 --- /dev/null +++ b/umn/source/faqs/redis_usage/why_is_cpu_usage_of_a_dcs_redis_instance_100%.rst @@ -0,0 +1,14 @@ +:original_name: dcs-faq-0730012.html + +.. _dcs-faq-0730012: + +Why Is CPU Usage of a DCS Redis Instance 100%? +============================================== + +- Possible cause 1: + + The service QPS is so high that the CPU usage spikes to 100%. + +- Possible cause 2: + + You have run commands that consume a lot of resources, such as **KEYS**. This will make CPU usage spike and can easily trigger a master/standby switchover. diff --git a/umn/source/faqs/redis_usage/why_is_error_in_execution_returned_when_i_access_redis.rst b/umn/source/faqs/redis_usage/why_is_error_in_execution_returned_when_i_access_redis.rst new file mode 100644 index 0000000..37a108c --- /dev/null +++ b/umn/source/faqs/redis_usage/why_is_error_in_execution_returned_when_i_access_redis.rst @@ -0,0 +1,12 @@ +:original_name: dcs-faq-210223001.html + +.. _dcs-faq-210223001: + +Why Is "Error in execution" Returned When I Access Redis? +========================================================= + +**Symptom**: "Error in execution; nested exception is io.lettuce.core.RedisCommandExecutionException: OOM command not allowed when used memory > 'maxmemory'" is returned during a Redis connection. + +**Analysis**: An out-of-memory (OOM) error indicates that the maximum memory is exceeded. In the error information, the "maxmemory" parameter indicates the maximum memory configured on the Redis server. + +If the memory usage of the Redis instance is less than 100%, the memory of the node where data is written may have reached the maximum limit. Connect to each node in the cluster by running **redis-cli -h -p 6379 -a -c --bigkeys**. When connecting to a replica node, run the **READONLY** command before running the **bigkeys** command. diff --git a/umn/source/faqs/redis_usage/why_is_memory_of_a_dcs_redis_instance_used_up_by_just_a_few_keys.rst b/umn/source/faqs/redis_usage/why_is_memory_of_a_dcs_redis_instance_used_up_by_just_a_few_keys.rst new file mode 100644 index 0000000..8d2f0ab --- /dev/null +++ b/umn/source/faqs/redis_usage/why_is_memory_of_a_dcs_redis_instance_used_up_by_just_a_few_keys.rst @@ -0,0 +1,10 @@ +:original_name: dcs-faq-0730033.html + +.. _dcs-faq-0730033: + +Why Is Memory of a DCS Redis Instance Used Up by Just a Few Keys? +================================================================= + +Possible cause: The output buffer may have occupied an excessive amount of memory. + +Solution: After connecting to the instance using redis-cli, run the **redis-cli --bigkeys** command to scan for big keys. Then, run the **info** command to check the output buffer size. diff --git a/umn/source/faqs/redis_usage/why_is_memory_usage_more_than_100%.rst b/umn/source/faqs/redis_usage/why_is_memory_usage_more_than_100%.rst new file mode 100644 index 0000000..8e2515d --- /dev/null +++ b/umn/source/faqs/redis_usage/why_is_memory_usage_more_than_100%.rst @@ -0,0 +1,8 @@ +:original_name: dcs-faq-0730024.html + +.. _dcs-faq-0730024: + +Why Is Memory Usage More Than 100%? +=================================== + +This is normal due to Redis functions (such as master/replica replication and lazyfree). When the memory becomes full, scale up the instance or remove unnecessary data. diff --git a/umn/source/faqs/redis_usage/why_is_redisson_distributed_lock_not_supported_by_dcs_proxy_cluster_redis_3.0_instances.rst b/umn/source/faqs/redis_usage/why_is_redisson_distributed_lock_not_supported_by_dcs_proxy_cluster_redis_3.0_instances.rst new file mode 100644 index 0000000..d89a1f7 --- /dev/null +++ b/umn/source/faqs/redis_usage/why_is_redisson_distributed_lock_not_supported_by_dcs_proxy_cluster_redis_3.0_instances.rst @@ -0,0 +1,16 @@ +:original_name: dcs-faq-0730025.html + +.. _dcs-faq-0730025: + +Why Is Redisson Distributed Lock Not Supported by DCS Proxy Cluster Redis 3.0 Instances? +======================================================================================== + +Redisson implements lock acquisition and unlocking in the following process: + +#. Redisson lock acquisition and unlocking are implemented by running Lua scripts. +#. During lock acquisition, the **EXISTS**, **HSET**, **PEXPIRE**, **HEXISTS**, **HINCRBY**, **PEXPIRE**, and **PTTL** commands must be executed in the Lua script. +#. During unlocking, the **EXISTS**, **PUBLISH**, **HEXISTS**, **PEXIPRE**, and **DEL** commands must be executed in the Lua script. + +In a proxy-based cluster, the proxy processes **PUBLISH** and **SUBSCRIBE** commands and forwards requests to the Redis server. The **PUBLISH** command cannot be executed in the Lua script. + +As a result, Proxy Cluster DCS Redis 3.0 instances do not support Redisson distributed locks. To use Redisson, resort to Redis 4.0 or 5.0 instead. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/c#.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/c#.rst new file mode 100644 index 0000000..fbe15a5 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/c#.rst @@ -0,0 +1,101 @@ +:original_name: dcs-ug-0312013.html + +.. _dcs-ug-0312013: + +C# +== + +Access a DCS Redis instance through C# Client StackExchange.Redis on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the GCC compilation environment has been installed on the ECS. + +Procedure +--------- + +#. .. _dcs-ug-0312013__en-us_topic_0148195355_li457118182512: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + + A Windows ECS is used as an example. + +#. Install Visual Studio Community 2017 on the ECS. + +#. Start Visual Studio 2017 and create a project. + + Set the project name to **redisdemo**. + +#. Install StackExchange.Redis by using the NuGet package manager of Visual Studio. + + Access the NuGet package manager console according to :ref:`Figure 1 `, and enter **Install-Package StackExchange.Redis -Version 2.2.79**. (The version number is optional). + + .. _dcs-ug-0312013__en-us_topic_0148195355_fig394516508313: + + .. figure:: /_static/images/en-us_image_0148195318.png + :alt: **Figure 1** Accessing the NuGet package manager console + + **Figure 1** Accessing the NuGet package manager console + +#. Write the following code, and use the String Set and Get methods to test the connection. + + .. code-block:: + + using System; + using StackExchange.Redis; + + namespace redisdemo + { + class Program + { + // redis config + private static ConfigurationOptions connDCS = ConfigurationOptions.Parse("10.10.38.233:6379,password=********,connectTimeout=2000"); + //the lock for singleton + private static readonly object Locker = new object(); + //singleton + private static ConnectionMultiplexer redisConn; + //singleton + public static ConnectionMultiplexer getRedisConn() + { + if (redisConn == null) + { + lock (Locker) + { + if (redisConn == null || !redisConn.IsConnected) + { + redisConn = ConnectionMultiplexer.Connect(connDCS); + } + } + } + return redisConn; + } + static void Main(string[] args) + { + redisConn = getRedisConn(); + var db = redisConn.GetDatabase(); + //set get + string strKey = "Hello"; + string strValue = "DCS for Redis!"; + Console.WriteLine( strKey + ", " + db.StringGet(strKey)); + + Console.ReadLine(); + } + } + } + + *10.10.38.233:6379* contains an example IP address/domain name and port number of the DCS Redis instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. ``********`` indicates the password used for logging in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + +#. Run the code. You have successfully accessed the instance if the following command output is displayed: + + .. code-block:: + + Hello, DCS for Redis! + + For more information about other commands of StackExchange.Redis, visit `StackExchange.Redis `__. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/clients_in_python.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/clients_in_python.rst new file mode 100644 index 0000000..04c718f --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/clients_in_python.rst @@ -0,0 +1,132 @@ +:original_name: dcs-ug-0312011.html + +.. _dcs-ug-0312011: + +Clients in Python +================= + +Access a DCS Redis instance through redis-py on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +.. note:: + + Use redis-py to connect to single-node, master/standby, and Proxy Cluster instances and redis-py-cluster to connect to Redis Cluster instances. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the Python compilation environment has been installed on the ECS. + +Procedure +--------- + +#. .. _dcs-ug-0312011__en-us_topic_0148195287_li450593110588: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + + The following uses CentOS as an example to describe how to access an instance using a Python client. + +#. Access the DCS Redis instance. + + If the system does not provide Python, run the following **yum** command to install it: + + **yum install python** + + .. note:: + + The Python version must be 3.6 or later. If the default Python version is earlier than 3.6, perform the following operations to change it: + + a. Run the **rm -rf python** command to delete the Python symbolic link. + b. Run the **ln -s python**\ *X.X.X* **python** command to create another Python link. In the command, *X.X.X* indicates the Python version number. + + - If the instance is a single-node, master/standby, or Proxy Cluster instance: + + a. Install Python and redis-py. + + #. If the system does not provide Python, run the following **yum** command to install it. + + #. Run the following command to download and decompress the redis-py package: + + **wget https://github.com/andymccurdy/redis-py/archive/master.zip** + + **unzip** **master.zip** + + #. Go to the directory where the decompressed redis-py package is saved, and install redis-py. + + **python setup.py install** + + After the installation, run the **python** command. redis-py have been successfully installed if the following command output is displayed: + + + .. figure:: /_static/images/en-us_image_0000001188005622.png + :alt: **Figure 1** Running the python command + + **Figure 1** Running the python command + + b. Use the redis-py client to connect to the instance. In the following steps, commands are executed in CLI mode. (Alternatively, write the commands into a Python script and then execute the script.) + + #. Run the **python** command to enter the CLI mode. You have entered CLI mode if the following command output is displayed: + + + .. figure:: /_static/images/en-us_image_0000001187846598.png + :alt: **Figure 2** Entering the CLI mode + + **Figure 2** Entering the CLI mode + + #. Run the following command to access the chosen DCS Redis instance: + + .. code-block:: + + r = redis.StrictRedis(host='XXX.XXX.XXX.XXX', port=6379, password='******'); + + *XXX.XXX.XXX.XXX* indicates the IP address/domain name of the DCS instance and **6379** is an example port number of the instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. ``******`` indicates the password used for logging in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + + You have successfully accessed the instance if the following command output is displayed. Enter commands to perform read and write operations on the database. + + + .. figure:: /_static/images/en-us_image_0000001233126245.png + :alt: **Figure 3** Redis connected successfully + + **Figure 3** Redis connected successfully + + - If the instance is a Redis Cluster instance: + + a. Install the redis-py-cluster client. + + #. Download the released version. + + **wget https://github.com/Grokzen/redis-py-cluster/releases/download/2.1.3/redis-py-cluster-2.1.3.tar.gz** + + #. Decompress the package. + + **tar -xvf** **redis-py-cluster-2.1.3.tar.gz** + + #. Go to the directory where the decompressed redis-py-cluster package is saved, and install redis-py-cluster. + + **python setup.py install** + + b. Access the DCS Redis instance by using redis-py-cluster. + + In the following steps, commands are executed in CLI mode. (Alternatively, write the commands into a Python script and then execute the script.) + + #. Run the **python** command to enter the CLI mode. + + #. Run the following command to access the chosen DCS Redis instance: + + .. code-block:: + + >>> from rediscluster import RedisCluster + + >>> startup_nodes = [{"host": "192.168.0.143", "port": "6379"}] + + >>> rc = RedisCluster(startup_nodes=startup_nodes, decode_responses=True) + + >>> rc.set("foo", "bar") + True + >>> print(rc.get("foo")) + 'bar' diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/go-redis.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/go-redis.rst new file mode 100644 index 0000000..47db697 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/go-redis.rst @@ -0,0 +1,92 @@ +:original_name: dcs-ug-211105001.html + +.. _dcs-ug-211105001: + +go-redis +======== + +Access a DCS Redis instance through go-redis on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. + +Procedure +--------- + +#. .. _dcs-ug-211105001__en-us_topic_0000001174913212_li457118182512: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + + A Windows ECS is used as an example. + +#. Install Visual Studio Community 2017 on the ECS. + +#. Start Visual Studio and create a project. The project name can be customized. In this example, the project name is set to **redisdemo**. + +#. Import the dependency package of go-redis and enter **go get github.com/go-redis/redis** on the terminal. + +#. Write the following code: + + .. code-block:: + + package main + + import ( + "fmt" + "github.com/go-redis/redis" + ) + + func main() { + // Single-node + rdb := redis.NewClient(&redis.Options{ + Addr: "host:port", + Password: "********", // no password set + DB: 0, // use default DB + }) + + val, err := rdb.Get("key").Result() + if err != nil { + if err == redis.Nil { + fmt.Println("key does not exists") + return + } + panic(err) + } + fmt.Println(val) + + //Cluster + rdbCluster := redis.NewClusterClient(&redis.ClusterOptions{ + Addrs: []string{"host:port"}, + Password: "********", + }) + val1, err1 := rdbCluster.Get("key").Result() + if err1 != nil { + if err == redis.Nil { + fmt.Println("key does not exists") + return + } + panic(err) + } + fmt.Println(val1) + } + + *host:port* are the IP address/domain name and port number of the DCS Redis instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. ``********`` indicates the password used to log in to the DCS Redis instance. This password is defined during DCS Redis instance creation. + +#. Run the **go build -o test main.go** command to package the code into an executable file, for example, **test**. + + .. caution:: + + To run the package in the Linux OS, set the following parameters before packaging: + + **set GOARCH=amd64** + + **set GOOS=linux** + +#. Run the **./test** command to access the DCS instance. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/hiredis_in_c++.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/hiredis_in_c++.rst new file mode 100644 index 0000000..73efbd0 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/hiredis_in_c++.rst @@ -0,0 +1,148 @@ +:original_name: dcs-ug-0312010.html + +.. _dcs-ug-0312010: + +hiredis in C++ +============== + +Access a DCS Redis instance through hiredis on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +.. note:: + + The operations described in this section apply only to single-node, master/standby, and Proxy Cluster instances. To use C++ to connect to a Redis Cluster instance, see the `C++ Redis client description `__. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the GCC compilation environment has been installed on the ECS. + +Procedure +--------- + +#. .. _dcs-ug-0312010__en-us_topic_0148195243_li1655151054317: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + + The following uses CentOS as an example to describe how to access an instance in C++. + +#. Install GCC, Make, and hiredis. + + If the system does not provide a compiling environment, run the following **yum** command to install the environment: + + **yum install gcc make** + +#. Run the following command to download and decompress the hiredis package: + + **wget https://github.com/redis/hiredis/archive/master.zip** + + **unzip** **master.zip** + +#. Go to the directory where the decompressed hiredis package is saved, and compile and install hiredis. + + **make** + + **make install** + +#. Access the DCS instance by using hiredis. + + The following describes connection and password authentication of hiredis. For more information on how to use hiredis, visit the Redis official website. + + a. Edit the sample code for connecting to a DCS instance, and then save the code and exit. + + **vim connRedis.c** + + Example: + + .. code-block:: + + #include + #include + #include + #include + int main(int argc, char **argv) { + unsigned int j; + redisContext *conn; + redisReply *reply; + if (argc < 3) { + printf("Usage: example {instance_ip_address} 6379 {password}\n"); + exit(0); + } + const char *hostname = argv[1]; + const int port = atoi(argv[2]); + const char *password = argv[3]; + struct timeval timeout = { 1, 500000 }; // 1.5 seconds + conn = redisConnectWithTimeout(hostname, port, timeout); + if (conn == NULL || conn->err) { + if (conn) { + printf("Connection error: %s\n", conn->errstr); + redisFree(conn); + } else { + printf("Connection error: can't allocate redis context\n"); + } + exit(1); + } + /* AUTH */ + reply = redisCommand(conn, "AUTH %s", password); + printf("AUTH: %s\n", reply->str); + freeReplyObject(reply); + + /* Set */ + reply = redisCommand(conn,"SET %s %s", "welcome", "Hello, DCS for Redis!"); + printf("SET: %s\n", reply->str); + freeReplyObject(reply); + + /* Get */ + reply = redisCommand(conn,"GET welcome"); + printf("GET welcome: %s\n", reply->str); + freeReplyObject(reply); + + /* Disconnects and frees the context */ + redisFree(conn); + return 0; + } + + b. Run the following command to compile the code: + + **gcc connRedis.c -o connRedis -I /usr/local/include/hiredis -lhiredis** + + If an error is reported, locate the directory where the **hiredis.h** file is saved and modify the compilation command. + + After the compilation, an executable **connRedis** file is obtained. + + c. Run the following command to access the chosen DCS Redis instance: + + **./connRedis** **{redis_ip_address}** **6379** **{password}** + + *{redis_instance_address}* indicates the IP address/domain name of DCS instance and **6379** is an example port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. *{password}* indicates the password used to log in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + + You have successfully accessed the instance if the following command output is displayed: + + .. code-block:: + + AUTH: OK + SET: OK + GET welcome: Hello, DCS for Redis! + + .. important:: + + If an error is reported, indicating that the hiredis library files cannot be found, run the following commands to copy related files to the system directories and add dynamic links: + + **mkdir /usr/lib/hiredis** + + **cp /usr/local/lib/libhiredis.so.0.13 /usr/lib/hiredis/** + + **mkdir /usr/include/hiredis** + + **cp /usr/local/include/hiredis/hiredis.h /usr/include/hiredis/** + + **echo '/usr/local/lib' >>;>>;/etc/ld.so.conf** + + **ldconfig** + + Replace the locations of the **so** and **.h** files with actual ones before running the commands. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/index.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/index.rst new file mode 100644 index 0000000..1dee7b4 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/index.rst @@ -0,0 +1,28 @@ +:original_name: dcs-ug-0512002.html + +.. _dcs-ug-0512002: + +Access in Different Languages +============================= + +- :ref:`Java ` +- :ref:`Lettuce Integration with Spring Boot ` +- :ref:`Clients in Python ` +- :ref:`go-redis ` +- :ref:`hiredis in C++ ` +- :ref:`C# ` +- :ref:`PHP ` +- :ref:`Node.js ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + java/index + lettuce_integration_with_spring_boot + clients_in_python + go-redis + hiredis_in_c++ + c# + php/index + node.js diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/index.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/index.rst new file mode 100644 index 0000000..0fb927d --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-ug-211105003.html + +.. _dcs-ug-211105003: + +Java +==== + +- :ref:`Jedis ` +- :ref:`Lettuce ` +- :ref:`Redisson ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + jedis + lettuce + redisson diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/jedis.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/jedis.rst new file mode 100644 index 0000000..e3ca2da --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/jedis.rst @@ -0,0 +1,188 @@ +:original_name: dcs-ug-0713005.html + +.. _dcs-ug-0713005: + +Jedis +===== + +Access a DCS Redis instance through Jedis on an ECS in the same VPC. For more information on how to use other Redis clients, visit https://redis.io/clients. + +.. note:: + + - If a password was set during DCS Redis instance creation, configure the password for connecting to Redis using a Jedis client. Do not hard code the plaintext password. + - When using JedisCluster to connect to a Redis Cluster DCS Redis 4.0 or 5.0 instance, the cluster topology is automatically refreshed. The client needs to reconnect to Redis by itself. + +Prerequisites +------------- + +- The DCS Redis instance you want to access is in the **Running** state. +- An ECS has been created. For more information on how to create ECSs, see the `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the Java compilation environment has been installed on the ECS. + +Procedure +--------- + +#. .. _dcs-ug-0713005__li695671074019: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS where you want to install Docker. + +#. Use Maven to add the following dependency to the **pom.xml** file: + + .. code-block:: + + + redis.clients + jedis + 4.1.1 + + +#. Access the DCS instance by using Jedis. + + Obtain the `source code `__ of the Jedis client. Use either of the following two methods to access a DCS Redis instance through Jedis: + + - Single Jedis connection + - Jedis pool + + Example code: + + a. Example of using Jedis to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with a single connection + + .. code-block:: + + // Creating a connection in password mode + String host = "192.168.0.150"; + int port = 6379; + String pwd = "passwd"; + + Jedis client = new Jedis(host, port); + client.auth(pwd); + client.connect(); + // Run the set command + String result = client.set("key-string", "Hello, Redis!"); + System.out.println( String.format("set instruction execution result:%s", result) ); + // Run the get command + String value = client.get("key-string"); + System.out.println( String.format("get command result:%s", value) ); + + // Creating a connection in password-free mode + String host = "192.168.0.150"; + int port = 6379; + + Jedis client = new Jedis(host, port); + client.connect(); + // Run the set command + String result = client.set("key-string", "Hello, Redis!"); + System.out.println( String.format("set command result:%s", result) ); + // Run the get command + String value = client.get("key-string"); + System.out.println( String.format("get command result:%s", value) ); + + *host* indicates the example IP address/domain name of DCS instance and *port* indicates the port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address and port as required. *pwd* indicates the password used for logging in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + + b. Example of using Jedis to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with connection pooling + + .. code-block:: + + // Generate configuration information of a Jedis pool + String ip = "192.168.0.150"; + int port = 6379; + String pwd = "passwd"; + GenericObjectPoolConfig config = new GenericObjectPoolConfig(); + config.setTestOnBorrow(false); + config.setTestOnReturn(false); + config.testWhileIdle(true); + config.setMaxTotal(100); + config.setMaxIdle(100); + config.setMaxWaitMillis(2000); + JedisPool pool = new JedisPool(config, ip, port, 100000, pwd);//Generate a Jedis pool when the application is being initialized + // Get a Jedis connection from the Jedis pool when a service operation occurs + Jedis client = pool.getResource(); + try { + // Run commands + String result = client.set("key-string", "Hello, Redis!"); + System.out.println( String.format("set command result:%s", result) ); + String value = client.get("key-string"); + System.out.println( String.format("get command result:%s", value) ); + } catch (Exception e) { + // TODO: handle exception + } finally { + // Return the Jedis connection to the Jedis connection pool after the client's request is processed + if (null != client) { + pool.returnResource(client); + } + } // end of try block + // Destroy the Jedis pool when the application is closed + pool.destroy(); + + // Configure the connection pool in the password-free mode + String ip = "192.168.0.150"; + int port = 6379; + GenericObjectPoolConfig config = new GenericObjectPoolConfig(); + config.setTestOnBorrow(false); + config.setTestOnReturn(false); + config.testWhileIdle(true); + config.setMaxTotal(100); + config.setMaxIdle(100); + config.setMaxWaitMillis(2000); + JedisPool pool = new JedisPool(config, ip, port, 100000);//Generate a JedisPool when the application is being initialized + // Get a Jedis connection from the Jedis pool when a service operation occurs + Jedis client = pool.getResource(); + try { + // Run commands + String result = client.set("key-string", "Hello, Redis!"); + System.out.println( String.format("set command result:%s", result) ); + String value = client.get("key-string"); + System.out.println( String.format("get command result:%s", value) ); + } catch (Exception e) { + // TODO: handle exception + } finally { + // Return the Jedis connection to the Jedis connection pool after the client's request is processed + if (null != client) { + pool.returnResource(client); + } + } // end of try block + // Destroy the Jedis pool when the application is closed + pool.destroy(); + + *ip* indicates the IP address/domain name of DCS instance and *port* indicates the port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address and port as required. *pwd* indicates the password used for logging in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + + Automatic reconnection is supported if the **testOnBorrow** parameter of the connection pool is enabled. When the service tries to obtain a Redis connection from the connection pool, the connection pool checks connections. After detecting a normal connection, the connection pool provides the connection to the service at the cost of performance. If you require high performance, do not enable this parameter and configure the upper-layer application for it to handle exceptions and retries. + + c. Example code for connecting to Redis Cluster using a single connection + + - With a password + + .. code-block:: + + //The following shows password-protected access. + int port = 6379; + String host = "192.168.144.37"; + //Create JedisCluster. + Set nodes = new HashSet(); + nodes.add(new HostAndPort(host, port)); + JedisCluster cluster = new JedisCluster(nodes, 5000, 3000, 10, "password", new JedisPoolConfig()); + cluster.set("key", "value"); + System.out.println("Connected to RedisCluster:" + cluster.get("key")); + cluster.close(); + + - Without a password + + .. code-block:: + + int port = 6379; + String host = "192.168.144.37"; + //Create JedisCluster. + Set nodes = new HashSet(); + nodes.add(new HostAndPort(host, port)); + JedisCluster cluster = new JedisCluster(nodes); + cluster.set("key", "value"); + System.out.println("Connected to RedisCluster:" + cluster.get("key")); + cluster.close(); + + *host* indicates the example IP address/domain name of DCS instance and *port* indicates the port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address and port as required. *{password}* indicates the password used to log in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + +#. Compile code according to the **readme** file in the source code of the Jedis client. Run the Jedis client to access the chosen DCS Redis instance. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/lettuce.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/lettuce.rst new file mode 100644 index 0000000..6057492 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/lettuce.rst @@ -0,0 +1,99 @@ +:original_name: dcs-ug-211011001.html + +.. _dcs-ug-211011001: + +Lettuce +======= + +Access a Redis Cluster instance through Lettuce on an ECS in the same VPC. For more information on how to use other Redis clients, visit https://redis.io/clients. + +.. note:: + + If a password was set during DCS Redis instance creation, configure the password for connecting to Redis using Lettuce. Do not hard code the plaintext password. + + To connect to a single-node, master/standby, or Proxy Cluster instance, use the RedisClient object of Lettuce. To connect to a Redis Cluster instance, use the RedisClusterClient object. + +Prerequisites +------------- + +- The DCS Redis instance you want to access is in the **Running** state. +- An ECS has been created. For more information on how to create ECSs, see the `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the Java compilation environment has been installed on the ECS. + +Procedure +--------- + +#. View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + +#. Use Maven to add the following dependency to the **pom.xml** file: + + .. code-block:: + + + io.lettuce + lettuce-core + 6.1.6.RELEASE + + +#. Use Lettuce (a Java client) to connect to the DCS instance. + + - Example of using Lettuce to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with a single connection + + .. code-block:: + + // password indicates the connection password. If there is no password, delete "password@". If there is a password and it contains special characters, conversion is required. + RedisClient redisClient = RedisClient.create("redis://password@host:port"); + StatefulRedisConnection connection = redisClient.connect(); + RedisCommands syncCommands = connection.sync(); + syncCommands.set("key", "value"); + System.out.println("Connected to Redis:" + syncCommands.get("key")); + // Close the connection. + connection.close(); + // Close the client. + redisClient.shutdown(); + + - Example of using Lettuce to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with connection pooling + + .. code-block:: + + // password indicates the connection password. If there is no password, delete "password@". If there is a password and it contains special characters, conversion is required. + RedisClient clusterClient = RedisClient.create("redis://password@host:port"); + GenericObjectPoolConfig> genericObjectPoolConfig = new GenericObjectPoolConfig(); + // Connection pool parameters + genericObjectPoolConfig.setMaxIdle(3); + genericObjectPoolConfig.setMinIdle(2); + genericObjectPoolConfig.setMaxTotal(3); + genericObjectPoolConfig.setMaxWaitMillis(-1); + GenericObjectPool> pool = ConnectionPoolSupport + .createGenericObjectPool(() -> clusterClient.connect(), genericObjectPoolConfig); + // Obtain a connection to perform operations. + try (StatefulRedisConnection con = pool.borrowObject()) { + RedisCommands sync = con.sync(); + sync.set("key", "value"); + System.out.println("Connected by pool:" + sync.get("key")); + } catch (Exception e) { + e.printStackTrace(); + }finally { + // Close the resources. + pool.close(); + clusterClient.shutdown(); + } + + - Example of using Lettuce to connect to a Redis Cluster + + .. code-block:: + + // password indicates the connection password. If there is no password, delete "password@". If there is a password and it contains special characters, conversion is required. + RedisClusterClient redisClient = RedisClusterClient.create("redis://password@host:port"); + StatefulRedisClusterConnection connection = redisClient.connect(); + RedisAdvancedClusterCommands syncCommands = connection.sync(); + syncCommands.set("key", "value"); + System.out.println("Connected to RedisCluster:"+syncCommands.get("key")); + // Close the connection. + connection.close(); + // Close the client. + redisClient.shutdown(); diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/redisson.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/redisson.rst new file mode 100644 index 0000000..d913a69 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/java/redisson.rst @@ -0,0 +1,230 @@ +:original_name: dcs-ug-211105004.html + +.. _dcs-ug-211105004: + +Redisson +======== + +Access a DCS Redis instance through Redisson on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +.. note:: + + - If a password was set during DCS Redis instance creation, configure the password for connecting to Redis using Redisson. Do not hard code the plaintext password. + - To connect to a single-node, master/standby, or Proxy Cluster instance, use the **useSingleServer** method of the **SingleServerConfig** object of Redisson. To connect to a Redis Cluster instance, use the **useClusterServers** method of the **ClusterServersConfig** object. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the Java compilation environment has been installed on the ECS. + +Procedure +--------- + +#. View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + +#. Use Maven to add the following dependency to the **pom.xml** file: + + .. code-block:: + + + org.redisson + redisson + 3.16.8 + + +#. Configure the connection pool. + + Recommended keepalive configurations: + + .. code-block:: + + # ping connection interval. Configuring this parameter will increase Redis load. Set a value based on the number of connections. The more the connections, the larger the value. Minimum value: 1000. If the number of active Redis connections exceeds 5000, do not set this parameter. + pingConnectionInterval: 3000 + + + The following is a configuration example for a single-node instance. (Set the timeout interval and connection pool size based on the site requirements. The following settings are examples only.) + + .. code-block:: + + redisson: + config: + singleServerConfig: + # Connection timeout, in milliseconds. + connectTimeout: 10000 + # Command waiting timeout, in milliseconds. + timeout: 3000 + # Number of retry times upon a command failure. + retryAttempts: 3 + # Interval for retrying sending commands, in milliseconds. + retryInterval: 1500 + # Minimum number of idle connections. + connectionMinimumIdleSize: 30 + # Connection pool size. + connectionPoolSize: 50 + # Redis database ID. + database: 0 + # DNS monitoring interval, in milliseconds. + dnsMonitoringInterval: 5000 + # ping connection interval. + pingConnectionInterval: 3000 + + + The following is a configuration example for a cluster instance. (Set the timeout interval and connection pool size based on the site requirements.) + + .. code-block:: + + redisson: + config: + clusterServersConfig: + # Idle connection timeout, in milliseconds. + idleConnectionTimeout: 100000 + # Connection timeout, in milliseconds. + connectTimeout: 10000 + # Command waiting timeout, in milliseconds. + timeout: 3000 + # Number of retry times upon a command failure. + retryAttempts: 3 + # Interval for retrying sending commands, in milliseconds. + retryInterval: 1500 + # Interval for reconnecting a replica node upon a failure. + failedSlaveReconnectionInterval: 3000 + # Interval for checking a replica node upon a failure. + failedSlaveCheckInterval: 60000 + # Maximum number of subscriptions per connection. + subscriptionsPerConnection: 5 + # Client name. + clientName: null + # Minimum number of idle pub/sub connections. + subscriptionConnectionMinimumIdleSize: 1 + # Pub/Sub connection pool size. + subscriptionConnectionPoolSize: 50 + # Minimum number of idle connections per replica node. + slaveConnectionMinimumIdleSize: 24 + # Connection pool size per replica node. + slaveConnectionPoolSize: 64 + # Minimum number of idle connections of the master node. + masterConnectionMinimumIdleSize: 24 + # Connection pool size of the master node. + masterConnectionPoolSize: 64 + # Master node status scan interval, in milliseconds. + scanInterval: 1000 + # ping connection interval. + pingConnectionInterval: 3000 + # Whether to keep the connection alive. + keepAlive: false + # The tcpNoDelay setting is enabled by default. + tcpNoDelay: false + +#. Access the DCS instance by using Redisson (a Java client). + + - Example of using Redisson to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with a single connection + + .. code-block:: + + Config config = new Config(); + SingleServerConfig singleServerConfig = config.useSingleServer(); + singleServerConfig.setAddress("redis://host:port"); + // singleServerConfig.setPassword("********"); + RedissonClient redisson = Redisson.create(config); + //Test concurrentMap. Data is synchronized to Redis when the put method is used. + ConcurrentMap map = redisson.getMap("FirstMap"); + map.put("wanger", "male"); + map.put("zhangsan", "nan"); + map.put("lisi", "female"); + ConcurrentMap resultMap = redisson.getMap("FirstMap"); + System.out.println("resultMap==" + resultMap.keySet()); + //Test Set + Set mySet = redisson.getSet("MySet"); + mySet.add("wanger"); + mySet.add("lisi"); + Set resultSet = redisson.getSet("MySet"); + System.out.println("resultSet===" + resultSet.size()); + //Test Queue + Queue myQueue = redisson.getQueue("FirstQueue"); + myQueue.add("wanger"); + myQueue.add("lili"); + myQueue.add("zhangsan"); + myQueue.peek(); + myQueue.poll(); + Queue resultQueue = redisson.getQueue("FirstQueue"); + System.out.println("resultQueue===" + resultQueue); + //Close the connection. + redisson.shutdown(); + + - Example of using Redisson to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with connection pooling + + .. code-block:: + + //1. Initialization + Config config = new Config(); + SingleServerConfig singleServerConfig = config.useSingleServer(); + singleServerConfig.setAddress("redis://host:6379"); + //Set the maximum number of connections in the connection pool of the master node to 500. + singleServerConfig.setConnectionPoolSize(500); + //The connections will be automatically closed and removed from the connection pool. The time unit is millisecond. + singleServerConfig.setIdleConnectionTimeout(10000); + RedissonClient redisson = Redisson.create(config); + //Test concurrentMap. Data is synchronized to Redis when the put method is used. + ConcurrentMap map = redisson.getMap("FirstMap"); + map.put("wanger", "male"); + map.put("zhangsan", "nan"); + map.put("lisi", "female"); + ConcurrentMap resultMap = redisson.getMap("FirstMap"); + System.out.println("resultMap==" + resultMap.keySet()); + //Test Set + Set mySet = redisson.getSet("MySet"); + mySet.add("wanger"); + mySet.add("lisi"); + Set resultSet = redisson.getSet("MySet"); + System.out.println("resultSet===" + resultSet.size()); + //Test Queue + Queue myQueue = redisson.getQueue("FirstQueue"); + myQueue.add("wanger"); + myQueue.add("lili"); + myQueue.add("zhangsan"); + myQueue.peek(); + myQueue.poll(); + Queue resultQueue = redisson.getQueue("FirstQueue"); + System.out.println("resultQueue===" + resultQueue); + //Close the connection. + redisson.shutdown(); + + - Example of using Redisson to connect to a Redis Cluster + + .. code-block:: + + Config config = new Config(); + ClusterServersConfig clusterServersConfig = config.useClusterServers(); + clusterServersConfig.addNodeAddress("redis://host:port"); + //Set a password. + // clusterServersConfig.setPassword("********"); + RedissonClient redisson = Redisson.create(config); + ConcurrentMap map = redisson.getMap("FirstMap"); + map.put("wanger", "male"); + map.put("zhangsan", "nan"); + map.put("lisi", "female"); + ConcurrentMap resultMap = redisson.getMap("FirstMap"); + System.out.println("resultMap==" + resultMap.keySet()); + //2. Test Set + Set mySet = redisson.getSet("MySet"); + mySet.add("wanger"); + mySet.add("lisi"); + Set resultSet = redisson.getSet("MySet"); + System.out.println("resultSet===" + resultSet.size()); + //3. Test Queue + Queue myQueue = redisson.getQueue("FirstQueue"); + myQueue.add("wanger"); + myQueue.add("lili"); + myQueue.add("zhangsan"); + myQueue.peek(); + myQueue.poll(); + Queue resultQueue = redisson.getQueue("FirstQueue"); + System.out.println("resultQueue===" + resultQueue); + //Close the connection. + redisson.shutdown(); diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/lettuce_integration_with_spring_boot.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/lettuce_integration_with_spring_boot.rst new file mode 100644 index 0000000..80e94ff --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/lettuce_integration_with_spring_boot.rst @@ -0,0 +1,369 @@ +:original_name: dcs-ug-211203001.html + +.. _dcs-ug-211203001: + +Lettuce Integration with Spring Boot +==================================== + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the Java compilation environment has been installed on the ECS. + +Procedure +--------- + +#. View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + +#. Use Maven to add the following dependency to the **pom.xml** file: + + .. note:: + + - Since Spring Boot 2.0, Lettuce is used as the default client for connections. + - Spring Boot 2.6.6 and Lettuce 6.1.8 are used. + + .. code-block:: + + + org.springframework.boot + spring-boot-starter-web + + + org.springframework.boot + spring-boot-starter-data-redis + + +#. Use Spring Boot integrated with Lettuce to connect to the instance. + + - Example of using Spring Boot and Lettuce to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with a single connection + + a. Add the Redis configuration to the **application.properties** configuration file. + + .. code-block:: + + spring.redis.host=host + spring.redis.database=0 + spring.redis.password=pwd + spring.redis.port=port + + b. Redis configuration class RedisConfiguration + + .. code-block:: + + @Bean + public RedisTemplate redisTemplate(LettuceConnectionFactory lettuceConnectionFactory) { + RedisTemplate template = new RedisTemplate<>(); + template.setConnectionFactory(lettuceConnectionFactory); + // Replace the default JdkSerializationRedisSerializer with Jackson2JsonRedisSerializer to serialize and deserialize the Redis value. + Jackson2JsonRedisSerializer jackson2JsonRedisSerializer = new Jackson2JsonRedisSerializer<>(Object.class); + ObjectMapper mapper = new ObjectMapper(); + mapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.ANY); + mapper.activateDefaultTyping(LaissezFaireSubTypeValidator.instance, + ObjectMapper.DefaultTyping.NON_FINAL, JsonTypeInfo.As.PROPERTY); + jackson2JsonRedisSerializer.setObjectMapper(mapper); + StringRedisSerializer stringRedisSerializer = new StringRedisSerializer(); + // String serialization of keys + template.setKeySerializer(stringRedisSerializer); + // String serialization of hash keys + template.setHashKeySerializer(stringRedisSerializer); + // Jackson serialization of values + template.setValueSerializer(jackson2JsonRedisSerializer); + // Jackson serialization of hash values + template.setHashValueSerializer(jackson2JsonRedisSerializer); + template.afterPropertiesSet(); + return template; + } + + c. Redis operation class RedisUtil + + .. code-block:: + + /** + * Obtain data from the cache. + * @param key + * @return value + */ + public Object get(String key){ + return key==null?null:redisTemplate.opsForValue().get(key); + } + + /** + * Write data to the cache. + * @param key + * @param value + * @return true (successful) false (failed) + */ + public boolean set(String key,Object value) { + try { + redisTemplate.opsForValue().set(key, value); + return true; + } catch (Exception e) { + e.printStackTrace(); + return false; + } + } + + d. Write the controller class for testing. + + .. code-block:: + + @RestController + public class HelloRedis { + @Autowired + RedisUtil redisUtil; + + + @RequestMapping("/setParams") + @ResponseBody + public String setParams(String name) { + redisUtil.set("name", name); + return "success"; + } + + @RequestMapping("/getParams") + @ResponseBody + public String getParams(String name) { + System.out.println("--------------" + name + "-------------"); + String retName = redisUtil.get(name) + ""; + return retName; + } + + } + + - Example of using Spring Boot and Lettuce to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance with connection pooling + + a. Add the following dependency in addition to the preceding Maven dependency: + + .. code-block:: + + + org.apache.commons + commons-pool2 + + + b. Add the Redis configuration to the **application.properties** configuration file. + + .. code-block:: + + spring.redis.host=host + spring.redis.database=0 + spring.redis.password=pwd + spring.redis.port=port + # Connection timeout. + spring.redis.timeout=1000 + # Maximum number of connections in the connection pool. A negative value indicates no limit. + spring.redis.lettuce.pool.max-active=50 + # Minimum number of idle connections in the connection pool. + spring.redis.lettuce.pool.min-idle=5 + # Maximum number of idle connections in the connection pool. + spring.redis.lettuce.pool.max-idle=50 + # Maximum time for waiting for connections in the connection pool. A negative value indicates no limit. + spring.redis.lettuce.pool.max-wait=5000 + # Interval for scheduling an eviction thread. + spring.redis.pool.time-between-eviction-runs-millis=2000 + + c. Redis connection configuration class RedisConfiguration + + .. code-block:: + + @Bean + public RedisTemplate redisTemplate(LettuceConnectionFactory lettuceConnectionFactory) { + lettuceConnectionFactory.setShareNativeConnection(false); + RedisTemplate template = new RedisTemplate<>(); + template.setConnectionFactory(lettuceConnectionFactory); + // Use Jackson2JsonRedisSerializer to replace the default JdkSerializationRedisSerializer to serialize and deserialize the Redis value. + Jackson2JsonRedisSerializer jackson2JsonRedisSerializer = new Jackson2JsonRedisSerializer<>(Object.class); + ObjectMapper mapper = new ObjectMapper(); + mapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.ANY); + mapper.activateDefaultTyping(LaissezFaireSubTypeValidator.instance, + ObjectMapper.DefaultTyping.NON_FINAL, JsonTypeInfo.As.PROPERTY); + jackson2JsonRedisSerializer.setObjectMapper(mapper); + StringRedisSerializer stringRedisSerializer = new StringRedisSerializer(); + // String serialization of keys + template.setKeySerializer(stringRedisSerializer); + // String serialization of hash keys + template.setHashKeySerializer(stringRedisSerializer); + // Jackson serialization of values + template.setValueSerializer(jackson2JsonRedisSerializer); + // Jackson serialization of hash values + template.setHashValueSerializer(jackson2JsonRedisSerializer); + template.afterPropertiesSet(); + return template; + } + + - Example code for using Spring Boot and Lettuce to connect to Redis Cluster using a single connection + + a. Add the Redis configuration to the **application.properties** configuration file. + + .. code-block:: + + spring.redis.cluster.nodes=host:port + spring.redis.cluster.max-redirects=3 + spring.redis.password= pwd + # Automated refresh interval + spring.redis.lettuce.cluster.refresh.period=60 + # Enable automated refresh + spring.redis.lettuce.cluster.refresh.adaptive=true + spring.redis.timeout=60 + + b. Redis configuration class RedisConfiguration (automated topology refresh must be enabled). + + .. code-block:: + + @Bean + public LettuceConnectionFactory lettuceConnectionFactory() { + String[] nodes = clusterNodes.split(","); + List listNodes = new ArrayList(); + for (String node : nodes) { + String[] ipAndPort = node.split(":"); + RedisNode redisNode = new RedisNode(ipAndPort[0], Integer.parseInt(ipAndPort[1])); + listNodes.add(redisNode); + } + RedisClusterConfiguration redisClusterConfiguration = new RedisClusterConfiguration(); + redisClusterConfiguration.setClusterNodes(listNodes); + redisClusterConfiguration.setPassword(password); + redisClusterConfiguration.setMaxRedirects(maxRedirects); + // Configure automated topology refresh. + ClusterTopologyRefreshOptions topologyRefreshOptions = ClusterTopologyRefreshOptions.builder() + .enablePeriodicRefresh(Duration.ofSeconds(period)) // Refresh the topology periodically. + .enableAllAdaptiveRefreshTriggers() // Refresh the topology based on events. + .build(); + + ClusterClientOptions clusterClientOptions = ClusterClientOptions.builder() + // Redis command execution timeout. Only when the command execution times out will a reconnection be triggered using the new topology. + .timeoutOptions(TimeoutOptions.enabled(Duration.ofSeconds(period))) + .topologyRefreshOptions(topologyRefreshOptions) + .build(); + LettuceClientConfiguration clientConfig = LettucePoolingClientConfiguration.builder() + .commandTimeout(Duration.ofSeconds(timeout)) + .readFrom(ReadFrom.REPLICA_PREFERRED) // Preferentially read data from the replicas. + .clientOptions(clusterClientOptions) + .build(); + LettuceConnectionFactory factory = new LettuceConnectionFactory(redisClusterConfiguration, clientConfig); + return factory; + } + + @Bean + public RedisTemplate redisTemplate(LettuceConnectionFactory lettuceConnectionFactory) { + RedisTemplate template = new RedisTemplate<>(); + template.setConnectionFactory(lettuceConnectionFactory); + // Use Jackson2JsonRedisSerializer to replace the default JdkSerializationRedisSerializer to serialize and deserialize the Redis value. + Jackson2JsonRedisSerializer jackson2JsonRedisSerializer = new Jackson2JsonRedisSerializer<>(Object.class); + ObjectMapper mapper = new ObjectMapper(); + mapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.ANY); + mapper.activateDefaultTyping(LaissezFaireSubTypeValidator.instance, + ObjectMapper.DefaultTyping.NON_FINAL, JsonTypeInfo.As.PROPERTY); + jackson2JsonRedisSerializer.setObjectMapper(mapper); + StringRedisSerializer stringRedisSerializer = new StringRedisSerializer(); + // String serialization of keys + template.setKeySerializer(stringRedisSerializer); + // String serialization of hash keys + template.setHashKeySerializer(stringRedisSerializer); + // Jackson serialization of values + template.setValueSerializer(jackson2JsonRedisSerializer); + // Jackson serialization of hash values + template.setHashValueSerializer(jackson2JsonRedisSerializer); + template.afterPropertiesSet(); + return template; + } + + - Example code for using Spring Boot and Lettuce to connect to Redis Cluster with connection pooling + + a. Add the Redis configuration to the **application.properties** configuration file. + + .. code-block:: + + spring.redis.cluster.nodes=host:port + spring.redis.cluster.max-redirects=3 + spring.redis.password=pwd + spring.redis.lettuce.cluster.refresh.period=60 + spring.redis.lettuce.cluster.refresh.adaptive=true + # Connection timeout. + spring.redis.timeout=60s + # Maximum number of connections in the connection pool. A negative value indicates no limit. + spring.redis.lettuce.pool.max-active=50 + # Minimum number of idle connections in the connection pool. + spring.redis.lettuce.pool.min-idle=5 + # Maximum number of idle connections in the connection pool. + spring.redis.lettuce.pool.max-idle=50 + # Maximum time for waiting for connections in the connection pool. A negative value indicates no limit. + spring.redis.lettuce.pool.max-wait=5000 + # Interval for scheduling an eviction thread. + spring.redis.lettuce.pool.time-between-eviction-runs=2000 + + b. Redis configuration class RedisConfiguration (automated topology refresh must be enabled). + + .. code-block:: + + @Bean + public LettuceConnectionFactory lettuceConnectionFactory() { + GenericObjectPoolConfig genericObjectPoolConfig = new GenericObjectPoolConfig(); + genericObjectPoolConfig.setMaxIdle(maxIdle); + genericObjectPoolConfig.setMinIdle(minIdle); + genericObjectPoolConfig.setMaxTotal(maxActive); + genericObjectPoolConfig.setMaxWait(Duration.ofMillis(maxWait)); + genericObjectPoolConfig.setTimeBetweenEvictionRuns(Duration.ofMillis(timeBetweenEvictionRunsMillis)); + String[] nodes = clusterNodes.split(","); + List listNodes = new ArrayList(); + for (String node : nodes) { + String[] ipAndPort = node.split(":"); + RedisNode redisNode = new RedisNode(ipAndPort[0], Integer.parseInt(ipAndPort[1])); + listNodes.add(redisNode); + } + RedisClusterConfiguration redisClusterConfiguration = new RedisClusterConfiguration(); + redisClusterConfiguration.setClusterNodes(listNodes); + redisClusterConfiguration.setPassword(password); + redisClusterConfiguration.setMaxRedirects(maxRedirects); + // Configure automated topology refresh. + ClusterTopologyRefreshOptions topologyRefreshOptions = ClusterTopologyRefreshOptions.builder() + .enablePeriodicRefresh(Duration.ofSeconds(period)) // Refresh the topology periodically. + .enableAllAdaptiveRefreshTriggers() // Refresh the topology based on events. + .build(); + + ClusterClientOptions clusterClientOptions = ClusterClientOptions.builder() + // Redis command execution timeout. Only when the command execution times out will a reconnection be triggered using the new topology. + .timeoutOptions(TimeoutOptions.enabled(Duration.ofSeconds(period))) + .topologyRefreshOptions(topologyRefreshOptions) + .build(); + LettuceClientConfiguration clientConfig = LettucePoolingClientConfiguration.builder() + .commandTimeout(Duration.ofSeconds(timeout)) + .poolConfig(genericObjectPoolConfig) + .readFrom(ReadFrom.REPLICA_PREFERRED) // Preferentially read data from the replicas. + .clientOptions(clusterClientOptions) + .build(); + LettuceConnectionFactory factory = new LettuceConnectionFactory(redisClusterConfiguration, clientConfig); + return factory; + } + + @Bean + public RedisTemplate redisTemplate(LettuceConnectionFactory lettuceConnectionFactory) { + lettuceConnectionFactory.setShareNativeConnection(false); + RedisTemplate template = new RedisTemplate<>(); + template.setConnectionFactory(lettuceConnectionFactory); + // Use Jackson2JsonRedisSerializer to replace the default JdkSerializationRedisSerializer to serialize and deserialize the Redis value. + Jackson2JsonRedisSerializer jackson2JsonRedisSerializer = new Jackson2JsonRedisSerializer<>(Object.class); + ObjectMapper mapper = new ObjectMapper(); + mapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.ANY); + mapper.activateDefaultTyping(LaissezFaireSubTypeValidator.instance, + ObjectMapper.DefaultTyping.NON_FINAL, JsonTypeInfo.As.PROPERTY); + jackson2JsonRedisSerializer.setObjectMapper(mapper); + StringRedisSerializer stringRedisSerializer = new StringRedisSerializer(); + // String serialization of keys + template.setKeySerializer(stringRedisSerializer); + // String serialization of hash keys + template.setHashKeySerializer(stringRedisSerializer); + // Jackson serialization of values + template.setValueSerializer(jackson2JsonRedisSerializer); + // Jackson serialization of hash values + template.setHashValueSerializer(jackson2JsonRedisSerializer); + template.afterPropertiesSet(); + return template; + } + + **host** is the IP address/domain name of the DCS instance, **port** is the port number of the DCS instance, and **pwd** is the password of the DCS instance. Specify these parameters as required before running the code. Connection pooling is recommended. Adjust parameters such as **TimeOut**, **MaxTotal** (maximum number of connections), **MinIdle** (minimum number of idle connections), **MaxIdle** (maximum number of idle connections), and **MaxWait** (maximum waiting time) based on service requirements. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/node.js.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/node.js.rst new file mode 100644 index 0000000..cf807ab --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/node.js.rst @@ -0,0 +1,170 @@ +:original_name: dcs-ug-0312012.html + +.. _dcs-ug-0312012: + +Node.js +======= + +Access a DCS Redis instance through Node.js on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +.. note:: + + The operations described in this section apply only to single-node, master/standby, and Proxy Cluster instances. To use Node.js to connect to a Redis Cluster instance, see `Node.js Redis client description `__. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the GCC compilation environment has been installed on the ECS. + +Procedure +--------- + +- **For client servers running Ubuntu (Debian series):** + +#. .. _dcs-ug-0312012__en-us_topic_0148195323_li5233248151213: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + +#. Install Node.js. + + **apt install nodejs-legacy** + + If the preceding command does not work, run the following commands: + + **wget https://nodejs.org/dist/v0.12.4/node-v0.12.4.tar.gz --no-check-certificate** + + **tar -xvf node-v4.28.5.tar.gz** + + **cd node-v4.28.5** + + **./configure** + + **make** + + **make install** + + .. note:: + + After the installation is complete, run the **node --version** command to query the Node.js version to check whether the installation is successful. + +#. Install the node package manager (npm). + + **apt install npm** + +#. Install the Redis client ioredis. + + **npm install ioredis** + +#. Edit the sample script for connecting to a DCS instance. + + Add the following content to the **ioredisdemo.js** script, including information about connection and data reading. + + .. code-block:: + + var Redis = require('ioredis'); + var redis = new Redis({ + port: 6379, // Redis port + host: '192.168.0.196', // Redis host + family: 4, // 4 (IPv4) or 6 (IPv6) + password: '******', + db: 0 + }); + redis.set('foo', 'bar'); + redis.get('foo', function (err, result) { + console.log(result); + }); + // Or using a promise if the last argument isn't a function + redis.get('foo').then(function (result) { + console.log(result); + }); + // Arguments to commands are flattened, so the following are the same: + redis.sadd('set', 1, 3, 5, 7); + redis.sadd('set', [1, 3, 5, 7]); + // All arguments are passed directly to the redis server: + redis.set('key', 100, 'EX', 10); + + *host* indicates the example IP address/domain name of DCS instance and *port* indicates the port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. ``******`` indicates the password used for logging in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + +#. Run the sample script to access the chosen DCS instance. + + **node ioredisdemo.js** + +- **For client servers running CentOS (Red Hat series):** + +#. .. _dcs-ug-0312012__en-us_topic_0148195323_li11511175651212: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + +#. Install Node.js. + + **yum install nodejs** + + If the preceding command does not work, run the following commands: + + **wget https://nodejs.org/dist/v0.12.4/node-v0.12.4.tar.gz --no-check-certificate** + + **tar -xvf node-v0.12.4.tar.gz** + + **cd node-v0.12.4** + + **./configure** + + **make** + + **make install** + + .. note:: + + After the installation is complete, run the **node --version** command to query the Node.js version to check whether the installation is successful. + +#. Install npm. + + **yum install npm** + +#. Install the Redis client ioredis. + + **npm install ioredis** + +#. Edit the sample script for connecting to a DCS instance. + + Add the following content to the **ioredisdemo.js** script, including information about connection and data reading. + + .. code-block:: + + var Redis = require('ioredis'); + var redis = new Redis({ + port: 6379, // Redis port + host: '192.168.0.196', // Redis host + family: 4, // 4 (IPv4) or 6 (IPv6) + password: '******', + db: 0 + }); + redis.set('foo', 'bar'); + redis.get('foo', function (err, result) { + console.log(result); + }); + // Or using a promise if the last argument isn't a function + redis.get('foo').then(function (result) { + console.log(result); + }); + // Arguments to commands are flattened, so the following are the same: + redis.sadd('set', 1, 3, 5, 7); + redis.sadd('set', [1, 3, 5, 7]); + // All arguments are passed directly to the redis server: + redis.set('key', 100, 'EX', 10); + + *host* indicates the example IP address/domain name of DCS instance and *port* indicates the port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. ``******`` indicates the password used for logging in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. + +#. Run the sample script to access the chosen DCS instance. + + **node ioredisdemo.js** diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/index.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/index.rst new file mode 100644 index 0000000..e8070e1 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/index.rst @@ -0,0 +1,16 @@ +:original_name: dcs-ug-211202001.html + +.. _dcs-ug-211202001: + +PHP +=== + +- :ref:`phpredis ` +- :ref:`Predis ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + phpredis + predis diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/phpredis.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/phpredis.rst new file mode 100644 index 0000000..268960d --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/phpredis.rst @@ -0,0 +1,127 @@ +:original_name: dcs-ug-0312009.html + +.. _dcs-ug-0312009: + +phpredis +======== + +Access a DCS Redis instance through phpredis on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +.. note:: + + The operations described in this section apply only to single-node, master/standby, and Proxy Cluster instances. To use phpredis to connect to a Redis Cluster instance, see the `phpredis description `__. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the GCC compilation environment has been installed on the ECS. + +Procedure +--------- + +#. .. _dcs-ug-0312009__en-us_topic_0148195315_li8233164074413: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + + The following uses CentOS as an example to describe how to access an instance through phpredis. + +#. Install GCC-C++ and Make compilation components. + + **yum install gcc-c++ make** + +#. Install the PHP development package and CLI tool. + + Run the following **yum** command to install the PHP development package: + + **yum install php-devel php-common php-cli** + + After the installation is complete, run the following command to query the PHP version and check whether the installation is successful: + + **php --version** + +#. Install the phpredis client. + + a. Download the source phpredis package. + + **wget http://pecl.php.net/get/redis-5.3.7.tgz** + + This version is used as an example. To download phpredis clients of other versions, visit the Redis or PHP official website. + + b. Decompress the source phpredis package. + + **tar -zxvf redis-5.3.7.tgz** + + **cd redis-5.3.7** + + c. Command before compilation. + + **phpize** + + d. Configure the **php-config** file. + + **./configure --with-php-config=/usr/bin/php-config** + + The location of the file varies depending on the OS and PHP installation mode. You are advised to locate the directory where the file is saved before the configuration. + + **find / -name php-config** + + e. Compile and install the phpredis client. + + **make && make install** + + f. After the installation, add the **extension** configuration in the **php.ini** file to reference the Redis module. + + **vim /etc/php.ini** + + Add the following configuration: + + .. code-block:: + + extension = "/usr/lib64/php/modules/redis.so" + + .. note:: + + The **redis.so** file may be saved in a different directory from **php.ini**. Run the following command to locate the directory: + + **find / -name php.ini** + + g. Save the configuration and exit. Then, run the following command to check whether the extension takes effect: + + **php -m \|grep redis** + + If the command output contains **redis**, the phpredis client environment has been set up. + +#. Access the DCS instance by using phpredis. + + a. Edit a **redis.php** file. + + .. code-block:: + + connect($redis_host, $redis_port) == false) { + die($redis->getLastError()); + } + if ($redis->auth($user_pwd) == false) { + die($redis->getLastError()); + } + if ($redis->set("welcome", "Hello, DCS for Redis!") == false) { + die($redis->getLastError()); + } + $value = $redis->get("welcome"); + echo $value; + $redis->close(); + ?> + + *{redis_instance_address}* indicates the IP address/domain name of DCS instance and *6379* is an example port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. *{password}* indicates the password used to log in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. If password-free access is enabled, shield the **if** statement for password authentication. + + b. Run the **php redis.php** command to access the DCS instance. diff --git a/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/predis.rst b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/predis.rst new file mode 100644 index 0000000..1347fb5 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/access_in_different_languages/php/predis.rst @@ -0,0 +1,92 @@ +:original_name: dcs-ug-211202002.html + +.. _dcs-ug-211202002: + +Predis +====== + +Access a DCS Redis instance through Predis on an ECS in the same VPC. For more information about how to use other Redis clients, visit `the Redis official website `__. + +Prerequisites +------------- + +- A DCS Redis instance has been created and is in the **Running** state. +- An ECS has been created. For details about how to create an ECS, see `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the PHP compilation environment has been installed on the ECS. + +Procedure +--------- + +#. .. _dcs-ug-211202002__en-us_topic_0000001184480402_li1655151054317: + + View the IP address/domain name and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Log in to the ECS. + +#. Install the PHP development package and CLI tool. Run the following **yum** command: + + **yum install php-devel php-common php-cli** + +#. After the installation is complete, check the version number to ensure that the installation is successful. + + **php --version** + +#. Download the Predis package to the **/usr/share/php** directory. + + a. Run the following command to download the Predis source file: + + **wget https://github.com/predis/predis/archive/refs/tags/v1.1.10.tar.gz** + + .. note:: + + This version is used as an example. To download Predis clients of other versions, visit the Redis or PHP official website. + + b. Run the following commands to decompress the source Predis package: + + **tar -zxvf predis-1.1.10.tar.gz** + + c. Rename the decompressed Predis directory **predis** and move it to **/usr/share/php/**. + + **mv predis-1.1.10 predis** + +#. Edit a file used to connect to Redis. + + - Example of using **redis.php** to connect to a single-node, master/standby, or Proxy Cluster DCS Redis instance: + + .. code-block:: + + 'tcp' , + 'host' => '{redis_instance_address}' , + 'port' => {port} , + 'password' => '{password}' + ]); + $client->set('foo', 'bar'); + $value = $client->get('foo'); + echo $value; + ?> + + - Example code for using **redis-cluster.php** to connect to Redis Cluster: + + .. code-block:: + + 'redis'); + $client = new Predis\Client($servers, $options); + $client->set('foo', 'bar'); + $value = $client->get('foo'); + echo $value; + ?> + + *{redis_instance_address}* indicates the actual IP address or domain name of the DCS instance and *{port}* is the actual port number of DCS instance. For details about how to obtain the IP address/domain name and port, see :ref:`1 `. Change the IP address/domain name and port as required. *{password}* indicates the password used to log in to the chosen DCS Redis instance. This password is defined during DCS Redis instance creation. If password-free access is required, delete the line that contains "password". + +#. Run the **php redis.php** command to access the DCS instance. diff --git a/umn/source/getting_started/accessing_an_instance/accessing_a_dcs_redis_4.0_or_5.0_instance_on_the_console.rst b/umn/source/getting_started/accessing_an_instance/accessing_a_dcs_redis_4.0_or_5.0_instance_on_the_console.rst new file mode 100644 index 0000000..fb0fe9f --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/accessing_a_dcs_redis_4.0_or_5.0_instance_on_the_console.rst @@ -0,0 +1,30 @@ +:original_name: dcs-ug-0312008.html + +.. _dcs-ug-0312008: + +Accessing a DCS Redis 4.0 or 5.0 Instance on the Console +======================================================== + +Access a DCS Redis instance through Web CLI. This function is supported only by DCS Redis 4.0 and 5.0 instances, and not by DCS Redis 3.0 instances. + +.. note:: + + - Do not enter sensitive information in Web CLI to avoid disclosure. + - Keys and values cannot contain spaces. + - If the value is empty, **nil** is returned after the **GET** command is executed. + +Prerequisites +------------- + +The DCS Redis 4.0 or 5.0 instance you want to access through Web CLI is in the **Running** state. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. In the row containing the desired instance, choose **More** > **Connect to Redis** to go to the Web CLI login page. +#. Enter the password of the DCS instance. On Web CLI, select the current Redis database, enter a Redis command in the command box, and press **Enter**. + +.. |image1| image:: /_static/images/en-us_image_0000001194522775.png diff --git a/umn/source/getting_started/accessing_an_instance/accessing_a_dcs_redis_instance_through_redis-cli.rst b/umn/source/getting_started/accessing_an_instance/accessing_a_dcs_redis_instance_through_redis-cli.rst new file mode 100644 index 0000000..5a7915d --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/accessing_a_dcs_redis_instance_through_redis-cli.rst @@ -0,0 +1,144 @@ +:original_name: dcs-ug-0326009.html + +.. _dcs-ug-0326009: + +Accessing a DCS Redis Instance Through redis-cli +================================================ + +Access a DCS Redis instance through redis-cli on an ECS in the same VPC. For more information on how to use other Redis clients, visit https://redis.io/clients. + +.. note:: + + - Redis 3.0 does not support port customization and allows only port 6379. For Redis 4.0 and 5.0, you can specify a port or use the default port 6379. The following uses the default port 6379. If you have specified a port, replace 6379 with the actual port. + + - **When connecting to a Redis Cluster instance, ensure that** **-c** **is added to the command.** Otherwise, the connection will fail. + + - Run the following command to connect to a Redis Cluster instance: + + ./redis-cli -h *{dcs_instance_address}* -p 6379 -a *{password}* **-c** + + - Run the following command to connect to a single-node, master/standby, or Proxy Cluster instance: + + *./redis-cli -h* *{dcs_instance_address} -p 6379* -a *{password}* + + For details, see :ref:`3 ` and :ref:`4 `. + +Prerequisites +------------- + +- The DCS Redis instance you want to access is in the **Running** state. +- An ECS has been created. For more information on how to create ECSs, see the `Elastic Cloud Server User Guide `__. +- If the ECS runs the Linux OS, ensure that the GCC compilation environment has been installed on the ECS. + +Procedure (Linux) +----------------- + +#. .. _dcs-ug-0326009__en-us_topic_0148195299_li5799181918288: + + Obtain the IP address and port number of the DCS Redis instance to be accessed. + + For details, see :ref:`Viewing Details of a DCS Instance `. + +#. Install redis-cli. + + The following steps assume that your client is installed on the Linux OS. + + a. Log in to the ECS. + + b. Run the following command to download the source code package of your Redis client from http://download.redis.io/releases/redis-5.0.8.tar.gz: + + **wget http://download.redis.io/releases/redis-5.0.8.tar.gz** + + c. Run the following command to decompress the source code package of your Redis client: + + **tar -xzf redis-5.0.8.tar.gz** + + d. Run the following commands to go to the Redis directory and compile the source code of your Redis client: + + **cd redis-5.0.8** + + **make** + + **cd src** + +#. .. _dcs-ug-0326009__en-us_topic_0148195299_li1511472544119: + + Access a DCS instance of a type other than Redis Cluster. + + Perform the following procedure to access a DCS Redis 3.0 instance, or a single-node or master/standby DCS Redis 4.0 or 5.0 instance. + + **./redis-cli -h** *${instance IP}* **-p 6379 -a** *${password}* + + .. note:: + + a. If the instance is password-free, connect it by running the **./redis-cli -h** *${instance IP}* **-p 6379** command. + b. If the instance is password-protected, connect it by running the **./redis-cli -h** *${instance IP}* **-p 6379 -a** *${password}* command. + +#. .. _dcs-ug-0326009__en-us_topic_0148195299_li126171140194317: + + Access a DCS instance of the Redis Cluster type. + + Perform the following procedure to access a DCS Redis 4.0 or 5.0 instance in Redis Cluster type. + + a. Run the following commands to access the chosen DCS Redis instance: + + **./redis-cli -h {dcs_instance_address} -p 6379 -a {password} -c** + + *{dcs_instance_address}* indicates the IP address of the DCS Redis instance, **6379** is the port used for accessing the instance, *{password}* is the password of the instance, and **-c** is used for accessing Redis Cluster nodes. The IP address and port number are obtained in :ref:`1 `. + + Example: + + .. code-block:: + + root@ecs-redis:~/redis-5.0.8/src# ./redis-cli -h 192.168.0.85 -p 6379 -a ****** -c + 192.168.0.85:6379> + + b. Run the following command to view the Redis Cluster node information: + + **cluster nodes** + + Each shard in a Redis Cluster has a master and a replica by default. The proceeding command provides all the information of cluster nodes. + + .. code-block:: + + 192.168.0.85:6379> cluster nodes + 0988ae8fd3686074c9afdcce73d7878c81a33ddc 192.168.0.231:6379@16379 slave f0141816260ca5029c56333095f015c7a058f113 0 1568084030 + 000 3 connected + 1a32d809c0b743bd83b5e1c277d5d201d0140b75 192.168.0.85:6379@16379 myself,master - 0 1568084030000 2 connected 5461-10922 + c8ad7af9a12cce3c8e416fb67bd6ec9207f0082d 192.168.0.130:6379@16379 slave 1a32d809c0b743bd83b5e1c277d5d201d0140b75 0 1568084031 + 000 2 connected + 7ca218299c254b5da939f8e60a940ac8171adc27 192.168.0.22:6379@16379 master - 0 1568084030000 1 connected 0-5460 + f0141816260ca5029c56333095f015c7a058f113 192.168.0.170:6379@16379 master - 0 1568084031992 3 connected 10923-16383 + 19b1a400815396c6223963b013ec934a657bdc52 192.168.0.161:6379@16379 slave 7ca218299c254b5da939f8e60a940ac8171adc27 0 1568084031 + 000 1 connected + + Write operations can only be performed on master nodes. The CRC16 of the key modulo 16384 is taken to compute what is the hash slot of a given key. + + As shown in the following, the value of **CRC16 (KEY) mode 16384** determines the hash slot that a given key is located at and redirects the client to the node where the hash slot is located at. + + .. code-block:: + + 192.168.0.170:6379> set hello world + -> Redirected to slot [866] located at 192.168.0.22:6379 + OK + 192.168.0.22:6379> set happy day + OK + 192.168.0.22:6379> set abc 123 + -> Redirected to slot [7638] located at 192.168.0.85:6379 + OK + 192.168.0.85:6379> get hello + -> Redirected to slot [866] located at 192.168.0.22:6379 + "world" + 192.168.0.22:6379> get abc + -> Redirected to slot [7638] located at 192.168.0.85:6379 + "123" + 192.168.0.85:6379> + +Procedure (Windows) +------------------- + +`Download `__ the compilation package of the Redis client for Windows. (This is not the source code package.) Decompress the package in any directory, open the CLI tool **cmd.exe**, and go to the directory. Then, run the following command to access the DCS Redis instance: + +**redis-cli.exe -h XXX -p 6379** + +**XXX** indicates the IP address of the DCS instance and **6379** is an example port number used for accessing a DCS instance. For details about how to obtain the IP address and port number, see :ref:`Viewing Details of a DCS Instance `. Change the IP address and port as required. diff --git a/umn/source/getting_started/accessing_an_instance/index.rst b/umn/source/getting_started/accessing_an_instance/index.rst new file mode 100644 index 0000000..e2d0193 --- /dev/null +++ b/umn/source/getting_started/accessing_an_instance/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-ug-0916002.html + +.. _dcs-ug-0916002: + +Accessing an Instance +===================== + +- :ref:`Accessing a DCS Redis Instance Through redis-cli ` +- :ref:`Access in Different Languages ` +- :ref:`Accessing a DCS Redis 4.0 or 5.0 Instance on the Console ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + accessing_a_dcs_redis_instance_through_redis-cli + access_in_different_languages/index + accessing_a_dcs_redis_4.0_or_5.0_instance_on_the_console diff --git a/umn/source/getting_started/creating_an_instance/creating_a_dcs_redis_instance.rst b/umn/source/getting_started/creating_an_instance/creating_a_dcs_redis_instance.rst new file mode 100644 index 0000000..90cc2e7 --- /dev/null +++ b/umn/source/getting_started/creating_an_instance/creating_a_dcs_redis_instance.rst @@ -0,0 +1,136 @@ +:original_name: dcs-ug-0326008.html + +.. _dcs-ug-0326008: + +Creating a DCS Redis Instance +============================= + +You can create one or more DCS Redis instances with the required computing capabilities and storage space based on service requirements. + +.. note:: + + The system automatically schedules the task every 3 minutes for checking whether resources are available or sold out. + + +Creating a DCS Redis Instance +----------------------------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner of the management console and select a region and a project. + +#. Click **Create DCS Instance**. + +#. Select a region closest to your application to reduce latency and accelerate access. + +#. Specify the following instance parameters based on the information collected in :ref:`Identifying Requirements `. + + a. **Cache Engine**: + + Select **Redis**. + + b. **Version**: + + Currently, 3.0, 4.0, and 5.0 versions are supported. + + .. note:: + + - When creating a Proxy Cluster instance, you can only select version 3.0. + - When creating a Redis Cluster instance, you can select versions 4.0 or 5.0. + + c. Set **Instance Type** to **Single-node**, **Master/Standby**, **Proxy Cluster** or **Redis Cluster**. + + d. Set **CPU Architecture** to **x86**. + + e. Set **Replicas**. The default value is **2** (including the master). + + This parameter is displayed only when you select Redis 4.0 or Redis 5.0 and the instance type is master/standby or Redis Cluster. + + f. Select an AZ. + + If the instance type is master/standby, Proxy Cluster, or Redis Cluster, **Standby AZ** is displayed. Select a standby AZ for the standby node of the instance. + + .. note:: + + - To accelerate access, deploy your instance and your application in the same AZ. + - There are multiple AZs in each region. If resources are insufficient in an AZ, the AZ will be unavailable. In this case, select another AZ. + + g. **Instance Specification**: + + The remaining quota is displayed on the console. + + To apply to increase quota, click **Increase quota** below the specifications. + +#. Configure the instance network parameters. + + a. For **VPC**, select a created VPC, subnet, and specify the IP address. + + You can choose to obtain an automatically assigned IP address or manually specify an IP address that is available in the selected subnet. + + For a DCS Redis 4.0 or 5.0 instance, you can specify a port numbering in the range from 1 to 65535. If no port is specified, the default port 6379 will be used. For a DCS Redis 3.0 instance, the port cannot be customized. Port 6379 will be used. + + b. Select a security group. + + A security group is a set of rules that control access to ECSs. It provides access policies for mutually trusted ECSs with the same security protection requirements in the same VPC. + + This parameter is displayed only for DCS Redis 3.0 instances. DCS Redis 4.0 and 5.0 instances are based on VPC endpoints and do not support security groups. To control access to a DCS Redis 4.0 or 5.0 instance, configure a whitelist after instance creation. For details, see :ref:`Managing IP Address Whitelist `. + +#. Set the instance password. + + This password is used for accessing the DCS Redis instance. + + .. note:: + + For security purposes, you must enter an instance-specific password when you are accessing the DCS Redis instance. Keep your instance password secure and change it periodically. + + The password must meet the following requirements: + + - Cannot be left blank. + - Can contain 8 to 32 characters. + - Must contain at least three of the following character types: + + - Lowercase letters + - Uppercase letters + - Digits + - special characters (:literal:`\`~!@#$^&*()-_=+\\|{}:,<.>/?`) + +#. Click **More Settings** to display more configurations, including auto backup. + + a. Specify **Name** and **Description**. + + The value of **Name** can contain 4 to 64 characters. + + b. Choose whether to enable **Auto Backup**. + + This parameter is displayed only when the instance type is master/standby or cluster. You can enable and schedule automated backup now or after the instance is created. For more information on how to configure a backup policy, see :ref:`Backing Up and Restoring DCS Instances `. + + c. Rename critical commands. + + **Command Renaming** is displayed for Redis 4.0 and 5.0. Currently, you can only rename the **COMMAND**, **KEYS**, **FLUSHDB**, **FLUSHALL**, and **HGETALL** commands. + + d. Specify the maintenance window. + + Choose a window for DCS O&M personnel to perform maintenance on your instance. You will be contacted before any maintenance activities are performed. + +#. Click **Create Now**. + + The displayed page shows the instance information you have specified. + +#. Confirm the instance information and click **Submit**. + +#. Return to the **Cache Manager** page to view and manage your DCS instances. + + a. Creating a single-node or master/standby DCS Redis 3.0 instance takes 5 to 15 minutes. Creating a cluster DCS Redis 3.0 instance takes 30 minutes. + + .. note:: + + DCS Redis 4.0 and 5.0 instances are containerized and can be created within seconds. + + b. After a DCS instance has been successfully created, it enters the **Running** state by default. + + .. note:: + + - If the new DCS instance failed to be created, delete the unsuccessful instance creation task by following the procedure in :ref:`Deleting Instance Creation Tasks That Have Failed to Run `. Then, create the DCS instance again. If the DCS instance still fails to be created, contact customer service. + - There is the management plane and the tenant plane. The tenant plane is also called the pod zone. During the creation of a DCS instance, a VM is created in the pod zone. If the instance creation fails, the instance status changes to **Faulty**, and the error message "Failed to connect to the instance. Network exceptions may have occurred in the pod zone." is displayed, indicating that the management plane cannot be connected to the tenant plane. + +.. |image1| image:: /_static/images/en-us_image_0266235412.png diff --git a/umn/source/getting_started/creating_an_instance/identifying_requirements.rst b/umn/source/getting_started/creating_an_instance/identifying_requirements.rst new file mode 100644 index 0000000..29b035a --- /dev/null +++ b/umn/source/getting_started/creating_an_instance/identifying_requirements.rst @@ -0,0 +1,35 @@ +:original_name: PurchasePreparation.html + +.. _PurchasePreparation: + +Identifying Requirements +======================== + +Before creating a DCS instance, identify your requirements and complete the following preparations: + +#. Decide on the required cache engine version. + + Different Redis versions have different features. For details, see :ref:`Comparing Redis Versions `. + +#. Decide on the required instance type. + + DCS provides single-node, master/standby, Proxy Cluster, and Redis Cluster types of instances. Each type has its own architecture. For details about the instance architectures, see :ref:`DCS Instance Types `. + +#. Decide on the required instance specification. + + Each specification specifies the maximum available memory, number of connections, and bandwidth. For details, see :ref:`DCS Instance Specifications `. + +#. Decide on the region and whether cross-AZ deployment is required. + + Choose a region closest to your application to reduce latency. + + A region consists of multiple availability zones (AZs) with physically isolated power supplies and networks. Master/standby and cluster DCS instances can be deployed across AZs. + + .. note:: + + - If a master/standby or cluster DCS instance is deployed across AZs, faults in an AZ do not affect cache nodes in other AZs. This is because when the master node is faulty, the standby cache node will automatically become the master node to provide services. Such deployment achieves better disaster recovery. + - Deploying a DCS instance across AZs slightly reduces network efficiency compared with deploying an instance within an AZ. Therefore, if a DCS instance is deployed across AZs, synchronization between master and standby cache nodes is slightly less efficient. + +#. Decide whether backup policies are required. + + Currently, backup policies can be configured only for master/standby and cluster DCS instances. For details about backup and restoration, see :ref:`Overview `. diff --git a/umn/source/getting_started/creating_an_instance/index.rst b/umn/source/getting_started/creating_an_instance/index.rst new file mode 100644 index 0000000..d6b3913 --- /dev/null +++ b/umn/source/getting_started/creating_an_instance/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-ug-0312003.html + +.. _dcs-ug-0312003: + +Creating an Instance +==================== + +- :ref:`Identifying Requirements ` +- :ref:`Preparing the Environment ` +- :ref:`Creating a DCS Redis Instance ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + identifying_requirements + preparing_the_environment + creating_a_dcs_redis_instance diff --git a/umn/source/getting_started/creating_an_instance/preparing_the_environment.rst b/umn/source/getting_started/creating_an_instance/preparing_the_environment.rst new file mode 100644 index 0000000..1dec14d --- /dev/null +++ b/umn/source/getting_started/creating_an_instance/preparing_the_environment.rst @@ -0,0 +1,48 @@ +:original_name: dcs-ug-0312004.html + +.. _dcs-ug-0312004: + +Preparing the Environment +========================= + +To access DCS instances through a Virtual Private Cloud (VPC), create a VPC and configure security groups and subnets for it before using DCS. A VPC provides an isolated virtual network environment which you can configure and manage. Using VPCs enhances cloud resource security and simplifies network deployment. + +Once you have created a VPC, you can use it for all DCS instances you subsequently create. + +Creating a VPC +-------------- + +#. Log in to the management console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. Click **Service List**, and choose **Network** > **Virtual Private Cloud** to launch the VPC console. + +#. Click **Apply for VPC**. + +#. Create a VPC as prompted, retaining the default values unless otherwise required. + + For details about how to create a VPC, see `Creating a VPC `__. + + After a VPC is created, a subnet is also created in the subnet. If the VPC needs more subnets, go to :ref:`7 `. Otherwise, go to :ref:`8 `. + + .. note:: + + - When creating a VPC, **CIDR Block** indicates the IP address range of the VPC. If this parameter is set, the IP addresses of subnets in the VPC must be within the IP address range of the VPC. + - If you create a VPC to provision DCS instances, you do not need to configure the CIDR block for the VPC. + +#. In the navigation pane on the left, choose **Virtual Private Cloud** > **Subnets**. + +#. .. _dcs-ug-0312004__en-us_topic_0148195347_li10954228154518: + + Click **Create Subnet**. Create a subnet as prompted, retaining the default values unless otherwise required. + + For details about how to create a subnet, see `Creating a Subnet for the VPC `__. + +#. .. _dcs-ug-0312004__en-us_topic_0148195347_li1940024225812: + + In the navigation pane on the left, choose **Access Control** > **Security Groups** and then click **Create Security Group** in the upper right corner of the displayed page. Create a security group as prompted, retaining the default values unless otherwise required. + + For details about how to create a security group, see `Creating a Security Group `__. + +.. |image1| image:: /_static/images/en-us_image_0000001214124082.png diff --git a/umn/source/getting_started/index.rst b/umn/source/getting_started/index.rst new file mode 100644 index 0000000..8fbf8d5 --- /dev/null +++ b/umn/source/getting_started/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-ug-0326007.html + +.. _dcs-ug-0326007: + +Getting Started +=============== + +- :ref:`Creating an Instance ` +- :ref:`Accessing an Instance ` +- :ref:`Viewing Details of a DCS Instance ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + creating_an_instance/index + accessing_an_instance/index + viewing_details_of_a_dcs_instance diff --git a/umn/source/getting_started/viewing_details_of_a_dcs_instance.rst b/umn/source/getting_started/viewing_details_of_a_dcs_instance.rst new file mode 100644 index 0000000..b32cc4b --- /dev/null +++ b/umn/source/getting_started/viewing_details_of_a_dcs_instance.rst @@ -0,0 +1,88 @@ +:original_name: dcs-ug-0312016.html + +.. _dcs-ug-0312016: + +Viewing Details of a DCS Instance +================================= + +On the DCS console, you can view DCS instance details. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Search for DCS instances using any of the following methods: + + - Search by keyword. + + Enter a keyword to search. + + - Select attributes and enter their keywords to search. + + Currently, you can search by name, ID, connection address (IP address:port number), AZ, status, instance type, and cache engine. + + For more information on how to search, click the question mark to the right of the search box. + +#. On the DCS instance list, click the name of a DCS instance to display more details about it. :ref:`Table 1 ` describes the parameters. + + .. _dcs-ug-0312016__table63471440101219: + + .. table:: **Table 1** Parameters on the Basic Information page of a DCS instance + + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Section | Parameter | Description | + +=======================+============================+========================================================================================================================================================+ + | Instance Details | Name | Name of the chosen instance. To modify the instance name, click the |image2| icon. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Status | State of the chosen instance. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | ID | ID of the chosen instance. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Cache Engine | Cache engine and cache engine version used by the DCS instance. For example, Redis 3.0. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Instance Type | Type of the selected instance. Currently, supported types include single-node, master/standby, Proxy Cluster, and Redis Cluster. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Cache Size | Specification of the chosen instance. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Used/Available Memory (MB) | The used memory space and maximum available memory space of the chosen instance. | + | | | | + | | | The used memory space includes: | + | | | | + | | | - Size of data stored on the DCS instance | + | | | - Size of Redis-server buffers (including client buffer and repl-backlog) and internal data structures | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | CPU | CPU of the DCS instance. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Created | Time at which the chosen instance started to be created. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Run | Time at which the instance was created. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Maintenance | Time range for any scheduled maintenance activities on cache nodes of this DCS instance. To modify the time window, click the |image3| icon. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Description | Description of the chosen DCS instance. To modify the description, click the |image4| icon. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Connection | Password Protected | Currently, password-protected access and password-free access are supported. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | IP Address | IP address and port number of the chosen instance. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Network | AZ | Availability zone in which the cache node running the selected DCS instance resides. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | VPC | VPC in which the chosen instance resides. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Subnet | Subnet in which the chosen instance resides. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + | | Security Group | Security group that controls access to the chosen instance. To modify the security group, click the |image5| icon. | + | | | | + | | | This parameter is displayed only for DCS Redis 3.0 instances. DCS for Redis 4.0 and 5.0 are based on VPC endpoints and do not support security groups. | + +-----------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+ + +.. |image1| image:: /_static/images/en-us_image_0000001194522893.png +.. |image2| image:: /_static/images/en-us_image_0266235362.png +.. |image3| image:: /_static/images/en-us_image_0266235362.png +.. |image4| image:: /_static/images/en-us_image_0266235362.png +.. |image5| image:: /_static/images/en-us_image_0266235362.png diff --git a/umn/source/glossary.rst b/umn/source/glossary.rst new file mode 100644 index 0000000..0338f13 --- /dev/null +++ b/umn/source/glossary.rst @@ -0,0 +1,8 @@ +:original_name: en-us_topic_0072429345.html + +.. _en-us_topic_0072429345: + +Glossary +======== + +For details about the terms involved in this document, see `Glossary `__. diff --git a/umn/source/index.rst b/umn/source/index.rst index 9112a17..b5dc1c4 100644 --- a/umn/source/index.rst +++ b/umn/source/index.rst @@ -2,3 +2,15 @@ Distributed Cache Service - User Guide ====================================== +.. toctree:: + :maxdepth: 1 + + service_overview/index + permissions_management/index + getting_started/index + operation_guide/index + monitoring/index + auditing/index + faqs/index + glossary + change_history diff --git a/umn/source/monitoring/configuring_alarm_rules_for_critical_metrics.rst b/umn/source/monitoring/configuring_alarm_rules_for_critical_metrics.rst new file mode 100644 index 0000000..b293898 --- /dev/null +++ b/umn/source/monitoring/configuring_alarm_rules_for_critical_metrics.rst @@ -0,0 +1,99 @@ +:original_name: dcs-ug-190905001.html + +.. _dcs-ug-190905001: + +Configuring Alarm Rules for Critical Metrics +============================================ + +This section describes the alarm rules of some metrics and how to configure the rules. In actual scenarios, configure alarm rules for metrics by referring to the following alarm policies. + +Alarm Policies for DCS Redis Instances +-------------------------------------- + +.. table:: **Table 1** DCS Redis instance metrics to configure alarm rules for + + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Metric | Normal Range | Alarm Policy | Approach Upper Limit | Handling Suggestion | + +===================+==============+===============================================+======================+==============================================================================================================================================================================+ + | CPU Usage | 0-100 | Alarm threshold: 70 | No | Consider capacity expansion based on the service analysis. | + | | | | | | + | | | Number of consecutive periods: 2 | | The CPU capacity of a single-node or master/standby instance cannot be expanded. If you need larger capacity, use a cluster instance instead. | + | | | | | | + | | | Alarm severity: Major | | | + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Memory Usage | 0-100 | Alarm threshold: 70 | No | Expand the capacity of the instance. | + | | | | | | + | | | Number of consecutive periods: 2 | | | + | | | | | | + | | | Alarm severity: Major | | | + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Connected Clients | 0-10,000 | Alarm threshold: 8000 | No | Optimize the connection pool in the service code to prevent the number of connections from exceeding the maximum limit. | + | | | | | | + | | | Number of consecutive periods: 2 | | For single-node and master/standby instances, the maximum number of connections allowed is 10,000. You can adjust the threshold based on service requirements. | + | | | | | | + | | | Alarm severity: Major | | | + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | New Connections | 0-10,000 | Alarm threshold: 10,000 | ``-`` | Check whether **connect** is used and whether the client connection is abnormal. Use persistent connections ("pconnect" in Redis terminology) to ensure performance. | + | | | | | | + | (Count/min) | | Number of consecutive periods: 2 | | | + | | | | | | + | | | Alarm severity: Minor | | | + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Input Flow | > 0 | Alarm threshold: 80% of the assured bandwidth | Yes | Consider capacity expansion based on the service analysis and bandwidth limit. | + | | | | | | + | | | Number of consecutive periods: 2 | | Configure this alarm only for single-node and master/standby DCS Redis 3.0 instances and set the alarm threshold to 80% of the assured bandwidth of DCS Redis 3.0 instances. | + | | | | | | + | | | Alarm severity: Major | | | + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Output Flow | > 0 | Alarm threshold: 80% of the assured bandwidth | Yes | Consider capacity expansion based on the service analysis and bandwidth limit. | + | | | | | | + | | | Number of consecutive periods: 2 | | Configure this alarm only for single-node and master/standby DCS Redis 3.0 instances and set the alarm threshold to 80% of the assured bandwidth of DCS Redis 3.0 instances. | + | | | | | | + | | | Alarm severity: Major | | | + +-------------------+--------------+-----------------------------------------------+----------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +Procedure +--------- + +In the following example, an alarm rule is set for the **CPU Usage** metric. + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. In the same row as the DCS instance whose metrics you want to view, choose **More** > **View Metric**. + + + .. figure:: /_static/images/en-us_image_0270432745.png + :alt: **Figure 1** Viewing instance metrics + + **Figure 1** Viewing instance metrics + +#. Locate the **CPU Usage** metric. Hover over the metric and click |image2| to create an alarm rule for the metric. + + The **Create Alarm Rule** page is displayed. + +#. Specify the alarm rule details. + + a. Specify the alarm policy and alarm severity. + + For example, the alarm policy shown in the following figure indicates that an alarm will be triggered if the CPU usage exceeds the threshold for two consecutive periods. + + + .. figure:: /_static/images/en-us_image_0000001321666164.png + :alt: **Figure 2** Setting the alarm content + + **Figure 2** Setting the alarm content + + b. Set the alarm notification configurations. If you enable **Alarm Notification**, set the validity period, notification object, and trigger condition. + + c. Click **Create**. + + .. note:: + + For more information about creating alarm rules, see the *Cloud Eye User Guide* > *Using the Alarm Function* > *Creating Alarm Rules*. + +.. |image1| image:: /_static/images/en-us_image_0000001148670664.png +.. |image2| image:: /_static/images/en-us_image_0227732778.png diff --git a/umn/source/monitoring/dcs_metrics.rst b/umn/source/monitoring/dcs_metrics.rst new file mode 100644 index 0000000..cf9e4bc --- /dev/null +++ b/umn/source/monitoring/dcs_metrics.rst @@ -0,0 +1,1296 @@ +:original_name: dcs-ug-0326019.html + +.. _dcs-ug-0326019: + +DCS Metrics +=========== + +Introduction +------------ + +This section describes DCS metrics reported to Cloud Eye as well as their namespaces and dimensions. You can use the Cloud Eye console or call APIs to query the DCS metrics and alarms. + +Different types of instances are monitored on different dimensions. + +- Single-node: + + Single-node instances are monitored on the instance dimension. The monitoring is conducted on the Redis Server. + +- Master/standby: + + Master/Standby instances are monitored on the instance and Redis Server dimensions. Instance monitoring covers the master node, while Redis Server monitoring covers the master and standby nodes. + +- Cluster: + + Proxy Cluster instances are monitored on the instance, Redis Server, and proxy dimensions. Instance monitoring covers the aggregated master node data, Redis Server monitoring covers each shard in the cluster, and proxy monitoring covers each proxy in the cluster. + + Redis Cluster instances are monitored on the instance and Redis Server dimensions. Instance monitoring covers the aggregated master node data and Redis Server monitoring covers each shard in the cluster. + +Namespace +--------- + +SYS.DCS + +DCS Redis 3.0 Instance Metrics +------------------------------ + +.. note:: + + The **Monitored Objects and Dimensions** column lists instances and dimensions that support the corresponding metrics. + +.. table:: **Table 1** DCS Redis 3.0 instance metrics + + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | Metric ID | Metric | Description | Value Range | Monitored Object and Dimension | Monitoring Period (Raw Data) | + +============================+============================+========================================================================================================================================================================================+===============+============================================================+==============================+ + | cpu_usage | CPU Usage | The monitored object's maximum CPU usage among multiple sampling values in a monitoring period | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | memory_usage | Memory Usage | Memory consumed by the monitored object | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | net_in_throughput | Network Input Throughput | Inbound throughput per second on a port | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | net_out_throughput | Network Output Throughput | Outbound throughput per second on a port | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | node_status | Instance Node Status | Status of instance nodes. If the status is normal, the value is **0**. If the status is abnormal, the value is **1**. | ``-`` | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | connected_clients | Connected Clients | Number of connected clients (excluding those from slave nodes) | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | client_longest_out_list | Client Longest Output List | Longest output list among current client connections | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | client_biggest_in_buf | Client Biggest Input Buf | Maximum input data length among current client connections | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | blocked_clients | Blocked Clients | Number of clients suspended by block operations such as BLPOP, BRPOP, and BRPOPLPUSH | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory | Used Memory | Number of bytes used by the Redis server | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_rss | Used Memory RSS | Resident set size (RSS) memory that the Redis server has used, which is the memory that actually resides in the memory, including all stack and heap memory but not swapped-out memory | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_peak | Used Memory Peak | Peak memory consumed by Redis since the Redis server last started | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_lua | Used Memory Lua | Number of bytes used by the Lua engine | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | memory_frag_ratio | Memory Fragmentation Ratio | Current memory fragmentation, which is the ratio between **used_memory_rss**/**used_memory**. | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | total_connections_received | New Connections | Number of connections received during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | total_commands_processed | Commands Processed | Number of commands processed during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | instantaneous_ops | Ops per Second | Number of commands processed per second | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | total_net_input_bytes | Network Input Bytes | Number of bytes received during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | total_net_output_bytes | Network Output Bytes | Number of bytes sent during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | instantaneous_input_kbps | Input Flow | Instantaneous input traffic | >= 0 kbits/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: kbit/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | instantaneous_output_kbps | Output Flow | Instantaneous output traffic | >= 0 kbits/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: kbit/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | rejected_connections | Rejected Connections | Number of connections that have exceeded maxclients and been rejected during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | expired_keys | Expired Keys | Number of keys that have expired and been deleted during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | evicted_keys | Evicted Keys | Number of keys that have been evicted and deleted during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keyspace_hits | Keyspace Hits | Number of successful lookups of keys in the main dictionary during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keyspace_misses | Keyspace Misses | Number of failed lookups of keys in the main dictionary during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | pubsub_channels | PubSub Channels | Number of Pub/Sub channels | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | pubsub_patterns | PubSub Patterns | Number of Pub/Sub patterns | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keyspace_hits_perc | Hit Rate | Ratio of the number of Redis cache hits to the number of lookups. Calculation: keyspace_hits/(keyspace_hits + keyspace_misses) | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | command_max_delay | Maximum Command Latency | Maximum latency of commands | >= 0 ms | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: ms | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | auth_errors | Authentication Failures | Number of failed authentications | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node or master/standby DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | is_slow_log_exist | Slow Query Logs | Existence of slow query logs in the instance | - **1**: yes | Monitored object: | 1 minute | + | | | | - **0**: no | | | + | | | | | Single-node or master/standby DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keys | Keys | Number of keys in Redis | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node or master/standby DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + +DCS Redis 4.0 and 5.0 Instance Metrics +-------------------------------------- + +.. note:: + + The **Monitored Objects and Dimensions** column lists instances and dimensions that support the corresponding metrics. + +.. table:: **Table 2** DCS Redis 4.0 and 5.0 instance metrics + + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | Metric ID | Metric | Description | Value Range | Monitored Object and Dimension | Monitoring Period (Raw Data) | + +============================+============================+========================================================================================================================================================================================+===============+============================================================+==============================+ + | cpu_usage | CPU Usage | The monitored object's maximum CPU usage among multiple sampling values in a monitoring period | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node or master/standby DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | command_max_delay | Maximum Command Latency | Maximum latency of commands | >= 0 ms | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: ms | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | total_connections_received | New Connections | Number of connections received during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | is_slow_log_exist | Slow Query Logs | Existence of slow query logs in the instance | - **1**: yes | Monitored object: | 1 minute | + | | | | - **0**: no | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | memory_usage | Memory Usage | Memory consumed by the monitored object | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | expires | Keys With an Expiration | Number of keys with an expiration in Redis | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keyspace_hits_perc | Hit Rate | Ratio of the number of Redis cache hits to the number of lookups. Calculation: keyspace_hits/(keyspace_hits + keyspace_misses) | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory | Used Memory | Number of bytes used by the Redis server | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_dataset | Used Memory Dataset | Dataset memory that the Redis server has used | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_dataset_perc | Used Memory Dataset Ratio | Percentage of dataset memory that the Redis server has used | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_rss | Used Memory RSS | Resident set size (RSS) memory that the Redis server has used, which is the memory that actually resides in the memory, including all stack and heap memory but not swapped-out memory | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | instantaneous_ops | Ops per Second | Number of commands processed per second | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keyspace_misses | Keyspace Misses | Number of failed lookups of keys in the main dictionary during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keys | Keys | Number of keys in Redis | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | rx_controlled | Flow Control Times | Number of flow control times during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | bandwidth_usage | Bandwidth Usage | Percentage of the maximum bandwidth limit used (the average value of the sum of input and output flows) | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | connections_usage | Connection Usage | Percentage of the current number of connections to the maximum allowed number of connections | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | Instance Node Status | Instance Node Status | Status of instance nodes. If the status is normal, the value is **0**. If the status is abnormal, the value is **1**. | ``-`` | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | command_max_rt | Maximum Latency | Maximum delay from when the node receives commands to when it responds | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: μs | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | command_avg_rt | Average Latency | Average delay from when the node receives commands to when it responds | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: μs | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | cpu_avg_usage | Average CPU Usage | Current average usage of CPU resources | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | blocked_clients | Blocked Clients | Number of clients suspended by block operations | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | connected_clients | Connected Clients | Number of connected clients (excluding those from slave nodes) | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | del | DEL | Number of **DEL** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | evicted_keys | Evicted Keys | Number of keys that have been evicted and deleted during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | expire | EXPIRE | Number of **EXPIRE** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | expired_keys | Expired Keys | Number of keys that have expired and been deleted during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | get | GET | Number of **GET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | hdel | HDEL | Number of **HDEL** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | hget | HGET | Number of **HGET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | hmget | HMGET | Number of **HMGET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | hmset | HMSET | Number of **HMSET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | hset | HSET | Number of **HSET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | instantaneous_input_kbps | Input Flow | Instantaneous input traffic | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | instantaneous_output_kbps | Output Flow | Instantaneous output traffic | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | memory_frag_ratio | Memory Fragmentation Ratio | Ratio between Used Memory RSS and Used Memory | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | mget | MGET | Number of **MGET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | mset | MSET | Number of **MSET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | pubsub_channels | PubSub Channels | Number of Pub/Sub channels | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | pubsub_patterns | PubSub Patterns | Number of Pub/Sub patterns | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | set | SET | Number of **SET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_lua | Used Memory Lua | Number of bytes used by the Lua engine | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_peak | Used Memory Peak | Peak memory consumed by Redis since the Redis server last started | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | sadd | Sadd | Number of **SADD** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | smembers | Smembers | Number of **SMEMBERS** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | rx_controlled | Flow Control Times | Number of flow control times during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count | | Redis Cluster instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | bandwidth_usage | Bandwidth Usage | Percentage of the used bandwidth to the maximum bandwidth limit | 0-200% | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Cluster instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | keyspace_misses | Keyspace Misses | Number of failed lookups of keys in the main dictionary during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_dataset | Used Memory Dataset | Dataset memory that the Redis server has used | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + | used_memory_dataset_perc | Used Memory Dataset Ratio | Percentage of dataset memory that server has used | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | | | Single-node, master/standby, or cluster DCS Redis instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + +----------------------------+----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+------------------------------------------------------------+------------------------------+ + +Node Metrics of DCS Redis Instances +----------------------------------- + +.. note:: + + - The following describes the metrics for cluster DCS instances. For Proxy Cluster DCS Redis 3.0 instances, the monitoring covers Redis Servers and Proxies. For Redis Cluster DCS Redis 4.0 and 5.0 instances, the monitoring only covers Redis Servers. For details, see :ref:`Table 3 ` and :ref:`Table 4 `. + + - The **Monitored Objects and Dimensions** column lists instances and dimensions that support the corresponding metrics. + +.. _dcs-ug-0326019__table11307163610588: + +.. table:: **Table 3** Redis Server metrics of DCS instances + + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | Metric ID | Metric | Description | Value Range | Monitored Object and Dimension | Monitoring Period (Raw Data) | + +============================+============================+================================================================================================================================+===============+===============================================================+==============================+ + | cpu_usage | CPU Usage | The monitored object's maximum CPU usage among multiple sampling values in a monitoring period | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | memory_usage | Memory Usage | Memory consumed by the monitored object | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | connected_clients | Connected Clients | Number of connected clients (excluding those from slave nodes) | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | client_longest_out_list | Client Longest Output List | Longest output list among current client connections | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | client_biggest_in_buf | Client Biggest Input Buf | Maximum input data length among current client connections | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | blocked_clients | Blocked Clients | Number of clients suspended by block operations such as BLPOP, BRPOP, and BRPOPLPUSH | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | used_memory | Used Memory | Number of bytes used by the Redis server | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | used_memory_rss | Used Memory RSS | RSS memory that the Redis server has used, which including all stack and heap memory but not swapped-out memory | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | used_memory_peak | Used Memory Peak | Peak memory consumed by Redis since the Redis server last started | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | used_memory_lua | Used Memory Lua | Number of bytes used by the Lua engine | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | memory_frag_ratio | Memory Fragmentation Ratio | Current memory fragmentation, which is the ratio between **used_memory_rss**/**used_memory**. | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | total_connections_received | New Connections | Number of connections received during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | total_commands_processed | Commands Processed | Number of commands processed during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | instantaneous_ops | Ops per Second | Number of commands processed per second | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | total_net_input_bytes | Network Input Bytes | Number of bytes received during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | total_net_output_bytes | Network Output Bytes | Number of bytes sent during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: byte | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | instantaneous_input_kbps | Input Flow | Instantaneous input traffic | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | instantaneous_output_kbps | Output Flow | Instantaneous output traffic | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | rejected_connections | Rejected Connections | Number of connections that have exceeded maxclients and been rejected during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | expired_keys | Expired Keys | Number of keys that have expired and been deleted during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | evicted_keys | Evicted Keys | Number of keys that have been evicted and deleted during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | pubsub_channels | PubSub Channels | Number of Pub/Sub channels | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | pubsub_patterns | PubSub Patterns | Number of Pub/Sub patterns | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | keyspace_hits_perc | Hit Rate | Ratio of the number of Redis cache hits to the number of lookups. Calculation: keyspace_hits/(keyspace_hits + keyspace_misses) | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | command_max_delay | Maximum Command Latency | Maximum latency of commands | >= 0 ms | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: ms | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | is_slow_log_exist | Slow Query Logs | Existence of slow query logs in the node | - **1**: yes | Monitored object: | 1 minute | + | | | | - **0**: no | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | keys | Keys | Number of keys in Redis | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | sadd | Sadd | Number of **SADD** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 3.0, 4.0, or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | smembers | Smembers | Number of **SMEMBERS** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | ms_repl_offset | Replication Gap | Data synchronization gap between the master and the replica | ``-`` | Monitored object: | 1 minute | + | | | | | | | + | | | | | Replica of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | del | DEL | Number of **DEL** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | expire | EXPIRE | Number of **EXPIRE** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | get | GET | Number of **GET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | hdel | HDEL | Number of **HDEL** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | hget | HGET | Number of **HGET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | hmget | HMGET | Number of **HMGET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | hmset | HMSET | Number of **HMSET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | hset | HSET | Number of **HSET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | mget | MGET | Number of **MGET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | mset | MSET | Number of **MSET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | set | SET | Number of **SET** commands processed per second | 0-500,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count/s | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | rx_controlled | Flow Control Times | Number of flow control times during the monitoring period | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: count | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + | bandwidth_usage | Bandwidth Usage | Percentage of the used bandwidth to the maximum bandwidth limit | 0-200% | Monitored object: | 1 minute | + | | | | | | | + | | | | | Redis Server of a cluster DCS Redis 4.0 or 5.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_redis_node | | + +----------------------------+----------------------------+--------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------------------------+------------------------------+ + +.. _dcs-ug-0326019__en-us_topic_0148195272_table107134417017: + +.. table:: **Table 4** Proxy metrics + + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | Metric ID | Metric | Description | Value Range | Monitored Object and Dimension | Monitoring Period (Raw Data) | + +=====================+=======================================+=====================================================================================================+==============+=================================================+==============================+ + | cpu_usage | CPU Usage | The monitored object's maximum CPU usage among multiple sampling values in a monitoring period | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | memory_usage | Memory Usage | Memory consumed by the monitored object | 0-100% | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: % | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | p_connected_clients | Connected Clients | Number of connected clients | >= 0 | Monitored object: | 1 minute | + | | | | | | | + | | | | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | max_rxpck_per_sec | Max. NIC Data Packet Receive Rate | Maximum number of data packets received by the proxy NIC per second during the monitoring period | 0-10,000,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: packages/second | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | max_txpck_per_sec | Max. NIC Data Packet Transmit Rate | Maximum number of data packets transmitted by the proxy NIC per second during the monitoring period | 0-10,000,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: packages/second | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | max_rxkB_per_sec | Maximum Inbound Bandwidth | Largest volume of data received by the proxy NIC per second | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | max_txkB_per_sec | Maximum Outbound Bandwidth | Largest volume of data transmitted by the proxy NIC per second | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | avg_rxpck_per_sec | Average NIC Data Packet Receive Rate | Average number of data packets received by the proxy NIC per second during the monitoring period | 0-10,000,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: packages/second | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | avg_txpck_per_sec | Average NIC Data Packet Transmit Rate | Average number of data packets transmitted by the proxy NIC per second during the monitoring period | 0-10,000,000 | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: packages/second | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | avg_rxkB_per_sec | Average Inbound Bandwidth | Average volume of data received by the proxy NIC per second | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + | avg_txkB_per_sec | Average Outbound Bandwidth | Average volume of data transmitted by the proxy NIC per second | >= 0 KB/s | Monitored object: | 1 minute | + | | | | | | | + | | | Unit: KB/s | | Proxy in a Proxy Cluster DCS Redis 3.0 instance | | + | | | | | | | + | | | | | Dimension: | | + | | | | | | | + | | | | | dcs_instance_id | | + | | | | | | | + | | | | | dcs_cluster_proxy_node | | + +---------------------+---------------------------------------+-----------------------------------------------------------------------------------------------------+--------------+-------------------------------------------------+------------------------------+ + +Dimensions +---------- + +====================== ================== +Key Value +====================== ================== +dcs_instance_id DCS Redis instance +dcs_cluster_redis_node Redis Server +dcs_cluster_proxy_node Proxy +====================== ================== diff --git a/umn/source/monitoring/index.rst b/umn/source/monitoring/index.rst new file mode 100644 index 0000000..05201d1 --- /dev/null +++ b/umn/source/monitoring/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-ug-0326016.html + +.. _dcs-ug-0326016: + +Monitoring +========== + +- :ref:`DCS Metrics ` +- :ref:`Viewing DCS Monitoring Metrics ` +- :ref:`Configuring Alarm Rules for Critical Metrics ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + dcs_metrics + viewing_dcs_monitoring_metrics + configuring_alarm_rules_for_critical_metrics diff --git a/umn/source/monitoring/viewing_dcs_monitoring_metrics.rst b/umn/source/monitoring/viewing_dcs_monitoring_metrics.rst new file mode 100644 index 0000000..25e2eed --- /dev/null +++ b/umn/source/monitoring/viewing_dcs_monitoring_metrics.rst @@ -0,0 +1,23 @@ +:original_name: dcs-ug-0312045.html + +.. _dcs-ug-0312045: + +Viewing DCS Monitoring Metrics +============================== + +You can view DCS instance metrics on the **Performance Monitoring** page. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. Click the desired instance. +#. Choose **Performance Monitoring**. All monitoring metrics of the instance are displayed. + + .. note:: + + You can also click **View Metric** in the **Operation** column on the **Cache Manager** page. You will be redirected to the Cloud Eye console. The metrics displayed on the Cloud Eye console are the same as those displayed on the **Performance Monitoring** page of the DCS console. + +.. |image1| image:: /_static/images/en-us_image_0000001196710703.png diff --git a/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/configuring_a_backup_policy.rst b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/configuring_a_backup_policy.rst new file mode 100644 index 0000000..57503c4 --- /dev/null +++ b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/configuring_a_backup_policy.rst @@ -0,0 +1,54 @@ +:original_name: dcs-ug-0312031.html + +.. _dcs-ug-0312031: + +Configuring a Backup Policy +=========================== + +On the DCS console, you can configure an automatic backup policy. The system then backs up data in your instances according to the backup policy. + +If automatic backup is not required, disable the automatic backup function in the backup policy. + +Prerequisites +------------- + +At least one master/standby DCS instance has been created. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. Click the name of the DCS instance to display more details about the DCS instance. +#. On the instance details page, click **Backups & Restorations**. +#. Slide |image2| to the right to enable automatic backup. Backup policies will be displayed. + + .. table:: **Table 1** Parameters in a backup policy + + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Parameter | Description | + +===================================+============================================================================================================================================================================================================================================+ + | Backup Schedule | Day of a week on which data in the chosen DCS instance is automatically backed up. | + | | | + | | You can select one or multiple days of a week. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Retention Period (days) | The number of days that automatically backed up data is retained. | + | | | + | | Backup data will be permanently deleted at the end of retention period and cannot be restored. Value range: 1-7. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Start Time | Time at which automatic backup starts. Value: the full hour between 00:00 to 23:00 | + | | | + | | The DCS checks backup policies once every hour. If the backup start time in a backup policy has arrived, data in the corresponding instance is backed up. | + | | | + | | .. note:: | + | | | + | | Instance backup takes 5 to 30 minutes. The data added or modified during the backup process will not be backed up. To reduce the impact of backup on services, it is recommended that data should be backed up during off-peak periods. | + | | | + | | Only instances in the **Running** state can be backed up. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +#. Click **OK**. + +.. |image1| image:: /_static/images/en-us_image_0000001194403149.png +.. |image2| image:: /_static/images/en-us_image_0000001256735725.png diff --git a/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/downloading_a_backup_file.rst b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/downloading_a_backup_file.rst new file mode 100644 index 0000000..b37b375 --- /dev/null +++ b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/downloading_a_backup_file.rst @@ -0,0 +1,55 @@ +:original_name: dcs-ug-0312034.html + +.. _dcs-ug-0312034: + +Downloading a Backup File +========================= + +Due to the limitations of automatic and manual backups (automatically backed up data can be retained for a maximum of 7 days, and manually backed up data takes space in OBS), you should download the backup files and permanently save them on the local host. + +This function is supported only by master/standby and cluster instances, and not by single-node instances. + +Prerequisites +------------- + +The instance has been backed up and the backup is still valid. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of the DCS instance to display more details about the DCS instance. + +#. On the instance details page, click **Backups & Restorations**. + + A list of historical backup tasks is then displayed. + +#. Select the historical backup data to be downloaded, and click **Download**. + +#. In the displayed, **Download Backup File** dialog box, select either of the following two download methods. + + Download methods: + + - By URL + + a. Set the URL validity period and click **Query**. + b. Download the backup file by using the URL list. + + .. note:: + + If you choose to copy URLs, use quotation marks to quote the URLs when running the **wget** command in Linux. For example: + + **wget 'https://obsEndpoint.com:443/redisdemo.rdb?parm01=value01&parm02=value02'** + + This is because the URL contains the special character and (&), which will confuse the **wget** command. Quoting the URL facilitates URL identification. + + - By OBS + + Perform the procedure as prompted. + +.. |image1| image:: /_static/images/en-us_image_0000001194403147.png diff --git a/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/index.rst b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/index.rst new file mode 100644 index 0000000..486dbed --- /dev/null +++ b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/index.rst @@ -0,0 +1,22 @@ +:original_name: dcs-ug-0312030.html + +.. _dcs-ug-0312030: + +Backing Up and Restoring DCS Instances +====================================== + +- :ref:`Overview ` +- :ref:`Configuring a Backup Policy ` +- :ref:`Manually Backing Up a DCS Instance ` +- :ref:`Restoring a DCS Instance ` +- :ref:`Downloading a Backup File ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + overview + configuring_a_backup_policy + manually_backing_up_a_dcs_instance + restoring_a_dcs_instance + downloading_a_backup_file diff --git a/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/manually_backing_up_a_dcs_instance.rst b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/manually_backing_up_a_dcs_instance.rst new file mode 100644 index 0000000..cfe7ee2 --- /dev/null +++ b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/manually_backing_up_a_dcs_instance.rst @@ -0,0 +1,44 @@ +:original_name: dcs-ug-0312032.html + +.. _dcs-ug-0312032: + +Manually Backing Up a DCS Instance +================================== + +You need to manually back up data in DCS instances in a timely manner. This section describes how to manually back up data in master/standby instances using the DCS console. + +By default, manually backed up data is permanently retained. If backup data is no longer in use, you can delete it manually. + +Prerequisites +------------- + +At least one master/standby DCS instance is in the **Running** state. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of the DCS instance to display more details about the DCS instance. + +#. On the instance details page, click **Backups & Restorations**. + +#. Click **Create Backup**. + +#. Select a backup file format. + + Only DCS Redis 4.0 and 5.0 instances support backup file format selection. + +#. In the **Create Backup** dialog box, click **OK**. + + Information in the **Description** text box cannot exceed 128 bytes. + + .. note:: + + Instance backup takes 10 to 15 minutes. The data added or modified during the backup process will not be backed up. + +.. |image1| image:: /_static/images/en-us_image_0000001148603242.png diff --git a/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/overview.rst b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/overview.rst new file mode 100644 index 0000000..dec4090 --- /dev/null +++ b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/overview.rst @@ -0,0 +1,97 @@ +:original_name: en-us_topic_0079835992.html + +.. _en-us_topic_0079835992: + +Overview +======== + +On the DCS console, you can back up and restore DCS instances. + +Importance of DCS Instance Backup +--------------------------------- + +There is a small chance that inconsistent data could exist in a DCS instance owing to service system exceptions or problems in loading data from persistence files. In addition, some systems demand not only high reliability but also data security, data restoration, and even permanent data storage. + +Currently, data in DCS instances can be backed up to OBS. If a DCS instance becomes faulty, data in the instance can be restored from backup so that service continuity is not affected. + +Backup Modes +------------ + +DCS instances support the following backup modes: + +- Automated backup + + You can create a scheduled backup policy on the DCS console. Then, data in the chosen DCS instances will be automatically backed up at the scheduled time. + + You can choose the days of the week on which scheduled backup will run. Backup data will be retained for a maximum of seven days. Backup data older than seven days will be automatically deleted. + + The primary purpose of scheduled backups is to create complete data replicas of DCS instances so that the instance can be quickly restored if necessary. + +- Manual backup + + Backup requests can also be issued manually. Then, data in the chosen DCS instances will be permanently backed up to OBS. Backup data can be deleted manually. + + Before performing high-risk operations, such as system maintenance or upgrade, back up DCS instance data. + +Additional Information About Data Backup +---------------------------------------- + +- Instance type + + Redis: Only master/standby, Proxy Cluster, and Redis Cluster instances can be backed up and restored, while single-node instances cannot. However, you can export data of a single-node instance to an RDB file using redis-cli. For details, see :ref:`Can I Export Backup Data of DCS Redis Instances to RDB Files Using the Console? ` + +- Backup mechanisms + + DCS for Redis 3.0 persists data with Redis AOF. DCS for Redis 4.0 and 5.0 persist data to RDB or AOF files in manual backup mode, and to RDB files in automatic backup mode. + + Backup tasks run on standby cache nodes. DCS instance data is backed up by compressing and storing the data persistence files from the standby cache node to SwiftAdapter. + + DCS checks instance backup policies once an hour. If a backup policy is matched, DCS runs a backup task for the corresponding DCS instance. + +- Impact on DCS instances during backup + + Backup tasks run on standby cache nodes, without incurring any downtime. + + In the event of full-data synchronization or heavy instance load, it takes a few minutes to complete data synchronization. If instance backup starts before data synchronization is complete, the backup data will be slightly behind the data in the master cache node. + + During instance backup, the standby cache node stops persisting the latest changes to disk files. If new data is written to the master cache node during backup, the backup file will not contain the new data. + +- Backup time + + It is advisable to back up instance data during off-peak periods. + +- Storage and pricing of backup files + + Backup files are stored to OBS. + +- Handling exceptions in scheduled backup + + If a scheduled backup task is triggered while the DCS instance is restarting or being scaled up, the scheduled backup task will be run in the next cycle. + + If backing up a DCS instance fails or the backup is postponed because another task is in progress, DCS will try to back up the instance in the next cycle. A maximum of three retries are allowed within a single day. + +- Retention period of backup data + + Scheduled backup files are retained for up to seven days. You can configure the retention period. At the end of the retention period, most backup files of the DCS instance will be automatically deleted, but at least one backup file will be retained. + + Manual backup files are retained permanently and need to be manually deleted. + +Data Restoration +---------------- + +- Data restoration process + + #. You can initiate a data restoration request using the DCS console. + #. DCS obtains the backup file from OBS. + #. Read/write to the DCS instance is suspended. + #. The original data persistence file of the master cache node is replaced by the backup file. + #. The new data persistence file (that is, the backup file) is reloaded. + #. Data is restored, and the DCS instance starts to provide read/write service again. + +- Impact on service systems + + Restoration tasks run on master cache nodes. During restoration, data cannot be written into or read from instances. + +- Handling data restoration exceptions + + If a backup file is corrupted, DCS will try to fix the backup file while restoring instance data. If the backup file is successfully fixed, the restoration proceeds. If the backup file cannot be fixed, the master/standby DCS instance will be changed back to the state in which it was before data restoration. diff --git a/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/restoring_a_dcs_instance.rst b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/restoring_a_dcs_instance.rst new file mode 100644 index 0000000..fa2e60d --- /dev/null +++ b/umn/source/operation_guide/backing_up_and_restoring_dcs_instances/restoring_a_dcs_instance.rst @@ -0,0 +1,45 @@ +:original_name: dcs-ug-0312033.html + +.. _dcs-ug-0312033: + +Restoring a DCS Instance +======================== + +On the DCS console, you can restore backup data to a chosen DCS instance. + +Prerequisites +------------- + +- At least one master/standby or cluster DCS instance is in the **Running** state. +- A backup task has been run to back up data in the instance to be restored and the status of the backup task is **Succeeded**. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of the DCS instance to display more details about the DCS instance. + +#. On the instance details page, click **Backups & Restorations**. + + A list of historical backup tasks is then displayed. + +#. Click **Restore** in the same row as the chosen backup task. + +#. Click **OK** to start instance restoration. + + Information in the **Description** text box cannot exceed 128 bytes. + + The **Restoration History** tab page displays the result of the instance restoration task. + + .. note:: + + Instance restoration takes 5 to 30 minutes. + + While being restored, DCS instances do not accept data operation requests from clients because existing data is being overwritten by the backup data. + +.. |image1| image:: /_static/images/en-us_image_0000001194523039.png diff --git a/umn/source/operation_guide/index.rst b/umn/source/operation_guide/index.rst new file mode 100644 index 0000000..80eb454 --- /dev/null +++ b/umn/source/operation_guide/index.rst @@ -0,0 +1,22 @@ +:original_name: dcs-ug-0326010.html + +.. _dcs-ug-0326010: + +Operation Guide +=============== + +- :ref:`Operating DCS Instances ` +- :ref:`Managing DCS Instances ` +- :ref:`Backing Up and Restoring DCS Instances ` +- :ref:`Migrating Data with DCS ` +- :ref:`Managing Passwords ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + operating_dcs_instances/index + managing_dcs_instances/index + backing_up_and_restoring_dcs_instances/index + migrating_data_with_dcs/index + managing_passwords/index diff --git a/umn/source/operation_guide/managing_dcs_instances/cache_analysis.rst b/umn/source/operation_guide/managing_dcs_instances/cache_analysis.rst new file mode 100644 index 0000000..48c2912 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/cache_analysis.rst @@ -0,0 +1,99 @@ +:original_name: dcs-ug-190808001.html + +.. _dcs-ug-190808001: + +Cache Analysis +============== + +By performing big key analysis and hot key analysis, you will have a picture of keys that occupy a large space and keys that are the most frequently accessed. + +**Notes on big key analysis:** + +- All DCS Redis instances support big key analysis. +- During big key analysis, all keys will be traversed. The larger the number of keys, the longer the analysis takes. +- Perform big key analysis during off-peak hours and avoid automatic backup periods. +- For a master/standby or cluster instance, the big key analysis is performed on the standby node, so the impact on the instance is minor. For a single-node instance, the big key analysis is performed on the only node of the instance and will reduce the instance access performance by up to 10%. Therefore, perform big key analysis on single-node instances during off-peak hours. +- A maximum of 100 big key analysis records (20 for Strings and 80 for Lists/Sets/Zsets/Hashes) are retained for each instance. When this limit is reached, the oldest records will be deleted to make room for new records. You can also manually delete records you no longer need. + +**Notes on hot key analysis:** + +- Only DCS Redis 4.0 and 5.0 instances support hot key analysis, and the **maxmemory-policy** parameter of the instances must be set to **allkeys-lfu** or **volatile-lfu**. +- During hot key analysis, all keys will be traversed. The larger the number of keys, the longer the analysis takes. +- Perform hot key analysis shortly after peak hours to ensure the accuracy of the analysis results. +- The hot key analysis is performed on the master node of each instance and will reduce the instance access performance by up to 10%. +- A maximum of 100 hot key analysis records are retained for each instance. When this limit is reached, the oldest records will be deleted to make room for new records. You can also manually delete records you no longer need. + +.. note:: + + Perform big key and hot key analysis during off-peak hours to avoid 100% CPU usage. + +Big Key Analysis Procedure +-------------------------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of a DCS Redis instance. + +#. Click the **Cache Analysis** tab. + +#. On the **Big Key Analysis** tab page, manually perform big key analysis or schedule daily automatic analysis. + +#. After an analysis task completes, click **View** to view the analysis results. + + You can view the analysis results of different data types. + + .. note:: + + A maximum of 20 big key analysis records are retained for Strings and 80 are retained for Lists, Sets, Zsets, and Hashes. + +Hot Key Analysis Procedure +-------------------------- + +#. Log in to the DCS console. + +#. Click |image2| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of a DCS Redis instance. + +#. Click the **Cache Analysis** tab. + +#. On the **Hot Key Analysis** tab page, manually perform hot key analysis or schedule daily automatic analysis. + + .. note:: + + The default value of the **maxmemory-policy** parameter of a Redis 4.0 or 5.0 instance is **noeviction**. To perform hot key analysis, set this parameter to **allkeys-lfu** or **volatile-lfu**. If this parameter has already been set to **allkeys-lfu** or **volatile-lfu**, perform hot key analysis right away. + +#. After an analysis task completes, click **View** to view the analysis results. + + The hot key analysis results are displayed. + + .. note:: + + The console displays a maximum of 100 hot key analysis records for each instance. + + .. table:: **Table 1** Results of hot key analysis + + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Parameter | Description | + +===================================+======================================================================================================================================================================================================================================================================================================================================+ + | Key | Name of a hot key. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Type | Type of a hot key, which can be string, hash, list, set, or sorted set. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Size | Size of the hot key value. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | FREQ | Reflects the access frequency of a key within a specific period of time. | + | | | + | | **FREQ** is the logarithmic access frequency counter. The maximum value of **FREQ** is 255, which indicates 1 million access requests. After **FREQ** reaches **255**, it will no longer increment even if access requests continue to increase. **FREQ** will decrement by 1 for every minute during which the key is not accessed. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | DataBase | Database where a hot key is located. | + +-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +.. |image1| image:: /_static/images/en-us_image_0000001194403151.png +.. |image2| image:: /_static/images/en-us_image_0000001148603244.png diff --git a/umn/source/operation_guide/managing_dcs_instances/configuration_notice.rst b/umn/source/operation_guide/managing_dcs_instances/configuration_notice.rst new file mode 100644 index 0000000..674b672 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/configuration_notice.rst @@ -0,0 +1,25 @@ +:original_name: dcs-ug-0312023.html + +.. _dcs-ug-0312023: + +Configuration Notice +==================== + +- In most cases, different DCS instance management operations cannot proceed concurrently. If you initiate a new management operation while the current operation is in progress, the DCS console prompts you to initiate the new operation again after the current operation is complete. DCS instance management operations include: + + - Creating a DCS instance + - Configuring parameters + - Restarting a DCS instance + - Changing the instance password + - Resetting the instance password + - Scaling, backing up, or restoring an instance + +- You can restart a DCS instance while it is being backed up, but the backup task will be forcibly interrupted and is likely to result in a backup failure. + +.. important:: + + In the event that a cache node of a DCS instance is faulty: + + - The instance remains in the **Running** state and you can continue to read from and write to the instance. This is achieved thanks to the high availability of DCS. + - Cache nodes can recover from internal faults automatically. Manual fault recovery is also supported. + - Certain operations (such as parameter configuration, password change or resetting, backup, restoration, and specification modification) in the management zone are not supported during fault recovery. You can contact technical support or perform these operations after the cache nodes recover from faults. diff --git a/umn/source/operation_guide/managing_dcs_instances/index.rst b/umn/source/operation_guide/managing_dcs_instances/index.rst new file mode 100644 index 0000000..0818e74 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/index.rst @@ -0,0 +1,34 @@ +:original_name: dcs-ug-0312022.html + +.. _dcs-ug-0312022: + +Managing DCS Instances +====================== + +- :ref:`Configuration Notice ` +- :ref:`Modifying Configuration Parameters ` +- :ref:`Modifying Maintenance Time Window ` +- :ref:`Modifying the Security Group ` +- :ref:`Viewing Background Tasks ` +- :ref:`Viewing Data Storage Statistics of a DCS Redis 3.0 Proxy Cluster Instance ` +- :ref:`Managing Shards and Replicas ` +- :ref:`Cache Analysis ` +- :ref:`Managing IP Address Whitelist ` +- :ref:`Viewing Redis Slow Logs ` +- :ref:`Viewing Redis Run Logs ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + configuration_notice + modifying_configuration_parameters + modifying_maintenance_time_window + modifying_the_security_group + viewing_background_tasks + viewing_data_storage_statistics_of_a_dcs_redis_3.0_proxy_cluster_instance + managing_shards_and_replicas + cache_analysis + managing_ip_address_whitelist + viewing_redis_slow_logs + viewing_redis_run_logs diff --git a/umn/source/operation_guide/managing_dcs_instances/managing_ip_address_whitelist.rst b/umn/source/operation_guide/managing_dcs_instances/managing_ip_address_whitelist.rst new file mode 100644 index 0000000..fd88a7c --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/managing_ip_address_whitelist.rst @@ -0,0 +1,57 @@ +:original_name: dcs-ug-190812001.html + +.. _dcs-ug-190812001: + +Managing IP Address Whitelist +============================= + +DCS helps you control access to your DCS instances in the following ways, depending on the deployment mode: + +- To control access to Redis 3.0 instances, you can use security groups. Whitelists are not supported. For details about how to configure a security group, see :ref:`Security Group Configurations `. +- To control access to Redis 4.0 and 5.0 instances, you can use whitelists. Security groups are not supported. + +The following describes how to manage whitelists of a Redis 4.0 or 5.0 instance to allow access only from whitelisted IP addresses. If no whitelists are added for the instance or the whitelist function is disabled, all IP addresses that can communicate with the VPC can access the instance. + +Creating a Whitelist Group +-------------------------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner of the management console and select a region. + + .. note:: + + Select the same region as your application service. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of a DCS instance. + +#. Click the **Whitelist** tab and then click **Create Whitelist Group**. + +#. In the **Create Whitelist Group** dialogue box, specify **Group Name** and **IP Address/Range**. + + .. table:: **Table 1** Whitelist parameters + + +-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------+------------------------+ + | Parameter | Description | Example | + +=======================+=================================================================================================================================================+========================+ + | Group Name | Whitelist group name of the instance. | DCS-test | + | | | | + | | A maximum of four whitelist groups can be created for each instance. | | + +-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------+------------------------+ + | IP Address/Range | A maximum of 20 IP addresses or IP address ranges can be added to an instance. Separate multiple IP addresses or IP address ranges with commas. | 10.10.10.1,10.10.10.10 | + | | | | + | | Unsupported IP address and IP address range: 0.0.0.0 and 0.0.0/0. | | + +-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------+------------------------+ + +#. Click **OK**. + + A whitelist group is automatically enabled for the instance once created. Only whitelisted IP addresses can access the instance. + + .. note:: + + - In the whitelist group list, click **Modify** to modify the IP addresses or IP address ranges in a group, and click **Delete** to delete a whitelist group. + - After whitelist has been enabled, you can click **Disable Whitelist** above the whitelist group list to allow all IP addresses connected to the VPC to access the instance. + +.. |image1| image:: /_static/images/en-us_image_0148195246.png diff --git a/umn/source/operation_guide/managing_dcs_instances/managing_shards_and_replicas.rst b/umn/source/operation_guide/managing_dcs_instances/managing_shards_and_replicas.rst new file mode 100644 index 0000000..54394a6 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/managing_shards_and_replicas.rst @@ -0,0 +1,40 @@ +:original_name: dcs-ug-210107001.html + +.. _dcs-ug-210107001: + +Managing Shards and Replicas +============================ + +This section describes how to query the shards and replicas of a DCS Redis 4.0 or 5.0 instance and how to manually promote a replica to master. + +Currently, **this function is supported only by Redis Cluster DCS Redis 4.0 or 5.0 instances.** + +- A Redis Cluster instance has multiple shards. Each shard has one master and one replica by default. On the **Shards and Replicas** page, you can view the sharding information and manually switch the master and replica roles. For details about the number of shards corresponding to different instance specifications, see :ref:`Redis Cluster `. + +Promoting a Replica to Master +----------------------------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. The **Cache Manager** page is displayed. + +4. Click an instance. + +5. Click the **Shards and Replicas** tab. + + The page displays all shards in the instance and the list of replicas of each shard. + +6. Click |image2| to show all replicas of a shard. + + + .. figure:: /_static/images/en-us_image_0000001322339434.png + :alt: **Figure 1** Lists of shards and replicas + + **Figure 1** Lists of shards and replicas + +7. Click **Promote to Master** in the row containing another replica which is in the "Replica" role. + +8. Click **Yes**. + +.. |image1| image:: /_static/images/en-us_image_0000001241411631.png +.. |image2| image:: /_static/images/en-us_image_0000001241691605.png diff --git a/umn/source/operation_guide/managing_dcs_instances/modifying_configuration_parameters.rst b/umn/source/operation_guide/managing_dcs_instances/modifying_configuration_parameters.rst new file mode 100644 index 0000000..187e717 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/modifying_configuration_parameters.rst @@ -0,0 +1,180 @@ +:original_name: dcs-ug-0312024.html + +.. _dcs-ug-0312024: + +Modifying Configuration Parameters +================================== + +You can modify the configuration parameters of your DCS instance to optimize DCS performance based on your requirements. + +For example, if you do not need data persistence, set **appendonly** to **no**. + +After the instance configuration parameters are modified, the modification takes effect immediately without the need to manually restart the instance. For a cluster instance, the modification takes effect on all shards. + +.. _dcs-ug-0312024__en-us_topic_0148195239_section4626406517526: + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. On the **Cache Manager** page, click the name of the DCS instance you want to configure. + +#. Choose **Parameters**. + +#. On the **Parameters** page, click **Modify**. + +#. Modify parameters based on your requirements. + + :ref:`Table 1 ` describes the parameters. In most cases, retain the default values. + + .. _dcs-ug-0312024__en-us_topic_0148195239_table14227144219555: + + .. table:: **Table 1** DCS Redis instance configuration parameters + + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | Parameter | Description | Value Range | Default Value | + +===============================================+=================================================================================================================================================================================================================================================================================================================================+==================================================+==================================================+ + | timeout | The maximum amount of time (in seconds) a connection between a client and the DCS instance can be allowed to remain idle before the connection is terminated. A setting of **0** means that this function is disabled. | 0-7200 seconds | 0 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | appendfsync | Controls how often fsync() transfers cached data to the disk. Note that some OSs will perform a complete data transfer but some others only make a "best-effort" attempt. | - no | everysec | + | | | - always | | + | | There are three settings: | - everysec | | + | | | | | + | | no: fsync() is never called. The OS will flush data when it is ready. This mode offers the highest performance. | | | + | | | | | + | | always: fsync() is called after every write to the AOF. This mode is very slow, but also very safe. | | | + | | | | | + | | everysec: fsync() is called once per second. This mode provides a compromise between safety and performance. | | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | appendonly | Indicates whether to log each modification of the instance. By default, data is written to disks asynchronously in Redis. If this function is disabled, recently-generated data might be lost in the event of a power failure. Options: | - yes | yes | + | | | - no | | + | | yes: enabled | | | + | | | | | + | | no: disabled | | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | client-output-buffer-limit-slave-soft-seconds | Number of seconds that the output buffer remains above **client-output-buffer-slave-soft-limit** before the client is disconnected. | 0-60 | 60 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | client-output-buffer-slave-hard-limit | Hard limit (in bytes) on the output buffer of replica clients. Once the output buffer exceeds the hard limit, the client is immediately disconnected. | Depends on the instance type and specifications. | Depends on the instance type and specifications. | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | client-output-buffer-slave-soft-limit | Soft limit (in bytes) on the output buffer of replica clients. Once the output buffer exceeds the soft limit and continuously remains above the limit for the time specified by the **client-output-buffer-limit-slave-soft-seconds** parameter, the client is disconnected. | Depends on the instance type and specifications. | Depends on the instance type and specifications. | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | maxmemory-policy | The deletion policy to apply when the maxmemory limit is reached. Options: | Depends on the instance version. | Depends on the instance version and type. | + | | | | | + | | **volatile-lru**: Evict keys by trying to remove the less recently used (LRU) keys first, but only among keys that have an expire set. **(Recommended)** | | | + | | | | | + | | **allkeys-lru**: Evict keys by trying to remove the LRU keys first. | | | + | | | | | + | | **volatile-random**: evict keys randomly, but only evict keys with an expire set. | | | + | | | | | + | | **allkeys-random**: Evict keys randomly. | | | + | | | | | + | | **volatile-ttl**: Evict keys with an expire set, and try to evict keys with a shorter time to live (TTL) first. | | | + | | | | | + | | **noeviction**: Do not delete any keys and only return errors when the memory limit was reached. | | | + | | | | | + | | **volatile-lfu**: Evict keys by trying to remove the less frequently used (LFU) keys first, but only among keys that have an expire set. | | | + | | | | | + | | **allkeys-lfu**: Evict keys by trying to remove the LFU keys first. | | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | lua-time-limit | Maximum time allowed for executing a Lua script (in milliseconds). | 100-5000 | 5,000 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | master-read-only | Sets the instance to be read-only. All write operations will fail. | - yes | no | + | | | - no | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | maxclients | The maximum number of clients allowed to be concurrently connected to a DCS instance. | Depends on the instance type and specifications. | Depends on the instance type and specifications. | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | proto-max-bulk-len | Maximum size of a single element request (in bytes). | 1,048,576-536,870,912 | 536,870,912 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | repl-backlog-size | The replication backlog size (bytes). The backlog is a buffer that accumulates replica data when replicas are disconnected from the master. When a replica reconnects, a partial synchronization is performed to synchronize the data that was missed while replicas were disconnected. | 16,384-1,073,741,824 | 1,048,576 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | repl-backlog-ttl | The amount of time, in seconds, before the backlog buffer is released, starting from the last a replica was disconnected. The value **0** indicates that the backlog is never released. | 0-604,800 | 3,600 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | repl-timeout | Replication timeout (in seconds). | 30-3,600 | 60 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | hash-max-ziplist-entries | Hashes are encoded using a memory efficient data structure when the number of entries in hashes is less than the value of this parameter. | 1-10,000 | 512 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | hash-max-ziplist-value | Hashes are encoded using a memory efficient data structure when the biggest entry in hashes does not exceed the length threshold indicated by this parameter. | 1-10,000 | 64 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | set-max-intset-entries | When a set is composed of just strings that happen to be integers in radix 10 in the range of 64 bit signed integers, sets are encoded using a memory efficient data structure. | 1-10,000 | 512 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | zset-max-ziplist-entries | Sorted sets are encoded using a memory efficient data structure when the number of entries in sorted sets is less than the value of this parameter. | 1-10,000 | 128 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | zset-max-ziplist-value | Sorted sets are encoded using a memory efficient data structure when the biggest entry in sorted sets does not exceed the length threshold indicated by this parameter. | 1-10,000 | 64 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | latency-monitor-threshold | Threshold time in latency monitoring. Unit: millisecond. | 0-86,400,000 ms | 0 | + | | | | | + | | Set to **0**: Latency monitoring is disabled. | | | + | | | | | + | | Set to more than 0: All with at least this many milliseconds of latency will be logged. | | | + | | | | | + | | By running the **LATENCY** command, you can perform operations related to latency monitoring, such as obtaining statistical data, and configuring and enabling latency monitoring. | | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | notify-keyspace-events | Controls which keyspace events notifications are enabled for. If the value is an empty string, this function is disabled. A combination of different values can be used to enable notifications for multiple event types. Possible values: | See the parameter description. | Ex | + | | | | | + | | **K**: Keyspace events, published with the **\__keyspace@_\_** prefix. | | | + | | | | | + | | **E**: Keyevent events, published with \__keyevent@_\_ prefix | | | + | | | | | + | | **g**: Generic commands (non-type specific) such as DEL, EXPIRE, and RENAME | | | + | | | | | + | | **$**: String commands | | | + | | | | | + | | **l**: List commands | | | + | | | | | + | | **s**: Set commands | | | + | | | | | + | | **h**: Hash commands | | | + | | | | | + | | **z**: Sorted set commands | | | + | | | | | + | | **x**: Expired events (events generated every time a key expires) | | | + | | | | | + | | **e**: Evicted events (events generated when a key is evicted for maxmemory) | | | + | | | | | + | | **A**: an alias for "g$lshzxe" | | | + | | | | | + | | The parameter value must contain either **K** or **E**. **A** cannot be used together with any of the characters in "g$lshzxe". For example, the value **Kl** means that Redis will notify Pub/Sub clients about keyspace events and list commands. The value **AKE** means Redis will notify Pub/Sub clients about all events. | | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | slowlog-log-slower-than | Redis records queries that exceed a specified execution time. | 0-1,000,000 | 10,000 | + | | | | | + | | **slowlog-log-slower-than** is the maximum time allowed, in microseconds, for command execution. If this threshold is exceeded, Redis will record the query. | | | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + | slowlog-max-len | The maximum allowed number of slow queries that can be logged. Slow query log consumes memory, but you can reclaim this memory by running the **SLOWLOG RESET** command. | 0-1000 | 128 | + +-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+--------------------------------------------------+ + + .. note:: + + a. For more information about the parameters described in :ref:`Table 1 `, visit https://redis.io/topics/memory-optimization. + b. The **latency-monitor-threshold** parameter is usually used for fault location. After locating faults based on the latency information collected, change the value of **latency-monitor-threshold** to **0** to avoid unnecessary latency. + c. More about the **notify-keyspace-events** parameter: + + - The parameter setting must contain at least a **K** or **E**. + - **A** is an alias for "g$lshzxe" and cannot be used together with any of the characters in "g$lshzxe". + - For example, the value **Kl** means that Redis will notify Pub/Sub clients about keyspace events and list commands. The value **AKE** means Redis will notify Pub/Sub clients about all events. + +#. After you have finished setting the parameters, click **Save**. + +#. Click **Yes** to confirm the modification. + +Typical Scenarios of Configuring Parameters +------------------------------------------- + +The following describes how to change the value of the **appendonly** parameter: + +- If Redis is used as the cache and services are insensitive to Redis data losses, disable instance persistence to improve performance. In this case, change the value of **appendonly** to **no**. For details, see :ref:`Procedure `. +- If Redis is used as the database or services are sensitive to Redis data losses, enable instance persistence. In this case, change the value of **appendonly** to **yes**. For details, see :ref:`Procedure `. After instance persistence is enabled, you need to consider the frequency of writing Redis cache data to disks and the impact on the Redis performance. You can use this parameter together with the **appendfsync** parameter. There are three modes of calling fsync(): + + - **no**: fsync() is never called. The OS will flush data when it is ready. This mode offers the highest performance. + - **always**: fsync() is called after every write to the AOF. This mode is very slow, but also very safe. + - **everysec**: fsync() is called once per second, ensuring both data security and performance. + +.. note:: + + Currently, the **appendonly** and **appendfsync** parameters can be modified on the console only for master/standby and Redis 4.0/5.0 Redis Cluster instances. + +.. |image1| image:: /_static/images/en-us_image_0000001194523045.png diff --git a/umn/source/operation_guide/managing_dcs_instances/modifying_maintenance_time_window.rst b/umn/source/operation_guide/managing_dcs_instances/modifying_maintenance_time_window.rst new file mode 100644 index 0000000..94b209b --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/modifying_maintenance_time_window.rst @@ -0,0 +1,35 @@ +:original_name: dcs-ug-0312025.html + +.. _dcs-ug-0312025: + +Modifying Maintenance Time Window +================================= + +On the DCS console, after creating a DCS instance, you can modify the maintenance time window of the DCS instance on the instance's **Basic Information** page. + +Prerequisites +------------- + +At least one DCS instance has been created. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of the DCS instance for which you want to modify the maintenance time window. + +#. Click the **Basic Information** tab. In the **Instance Details** area, click the |image2| icon next to the **Maintenance** parameter. + +#. Select a new maintenance time window from the drop-down list. Click |image3| to save the modification or |image4| to discard the modification. + + The modification will take effect immediately, that is, the new maintenance time window will appear on the **Basic Information** tab page immediately. + +.. |image1| image:: /_static/images/en-us_image_0000001148443456.png +.. |image2| image:: /_static/images/en-us_image_0266235581.jpg +.. |image3| image:: /_static/images/en-us_image_0266235565.jpg +.. |image4| image:: /_static/images/en-us_image_0266235461.jpg diff --git a/umn/source/operation_guide/managing_dcs_instances/modifying_the_security_group.rst b/umn/source/operation_guide/managing_dcs_instances/modifying_the_security_group.rst new file mode 100644 index 0000000..78af676 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/modifying_the_security_group.rst @@ -0,0 +1,41 @@ +:original_name: dcs-ug-0312026.html + +.. _dcs-ug-0312026: + +Modifying the Security Group +============================ + +On the DCS console, after creating a DCS instance, you can modify the security group of the DCS instance on the instance's **Basic Information** page. + +You can modify the security groups of DCS Redis 3.0 instances but cannot modify those of DCS Redis 4.0 or 5.0 instances. + +Prerequisites +------------- + +At least one DCS instance has been created. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of the DCS instance for which you want to modify the security group. + +#. Click the **Basic Information** tab. In the **Network** area, click |image2| next to the **Security Group** parameter. + +#. Select a new security group from the drop-down list. Click |image3| to save the modification or |image4| to discard the modification. + + .. note:: + + Only the security groups that have been created can be selected from the drop-down list. If you need to create a security group, follow the procedure described :ref:`Security Group Configurations `. + + The modification will take effect immediately, that is, the new maintenance time window will appear on the **Basic Information** tab page immediately. + +.. |image1| image:: /_static/images/en-us_image_0000001194403153.png +.. |image2| image:: /_static/images/en-us_image_0266235582.png +.. |image3| image:: /_static/images/en-us_image_0266235565.jpg +.. |image4| image:: /_static/images/en-us_image_0266235461.jpg diff --git a/umn/source/operation_guide/managing_dcs_instances/viewing_background_tasks.rst b/umn/source/operation_guide/managing_dcs_instances/viewing_background_tasks.rst new file mode 100644 index 0000000..f49cee3 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/viewing_background_tasks.rst @@ -0,0 +1,36 @@ +:original_name: dcs-ug-0312028.html + +.. _dcs-ug-0312028: + +Viewing Background Tasks +======================== + +After you initiate certain instance operations such as modifying instance specifications and changing or resetting a password, a background task will start for the operation. On the DCS console, you can view the background task status and clear task information by deleting task records. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of the DCS instance whose background task you want to manage. + +#. Click the **Background Tasks** tab. + + A list of background tasks is displayed. + +#. Click |image2|, specify **Start Date** and **End Date**, and click **OK** to view tasks started in the corresponding time segment. + + - Click |image3| to refresh the task status. + - To clear the record of a background task, click **Delete** in the **Operation** column. + + .. note:: + + You can only delete the records of tasks in the **Successful** or **Failed** state. + +.. |image1| image:: /_static/images/en-us_image_0000001148603246.png +.. |image2| image:: /_static/images/en-us_image_0266235508.png +.. |image3| image:: /_static/images/en-us_image_0266235430.png diff --git a/umn/source/operation_guide/managing_dcs_instances/viewing_data_storage_statistics_of_a_dcs_redis_3.0_proxy_cluster_instance.rst b/umn/source/operation_guide/managing_dcs_instances/viewing_data_storage_statistics_of_a_dcs_redis_3.0_proxy_cluster_instance.rst new file mode 100644 index 0000000..97762f9 --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/viewing_data_storage_statistics_of_a_dcs_redis_3.0_proxy_cluster_instance.rst @@ -0,0 +1,33 @@ +:original_name: dcs-ug-0312029.html + +.. _dcs-ug-0312029: + +Viewing Data Storage Statistics of a DCS Redis 3.0 Proxy Cluster Instance +========================================================================= + +You can view the data storage statistics of all nodes of a DCS Redis 3.0 Proxy Cluster instance. If data storage is unevenly distributed across nodes, you can scale up the instance or clear data. + +You can only view data storage statistics of DCS Redis 3.0 Proxy Cluster instances. Instances of other types, for example, master/standby, only have one node, and you can view the used memory on the instance details page. + +.. note:: + + A Redis Cluster instance has multiple storage nodes. You can check the data storage statistics of a Redis Cluster instance in its Redis Server monitoring data. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of a DCS Redis cluster instance to view the basic information. + +#. Click the **Node Management** tab. + + The data volume of each node in the cluster instance is displayed. + + When the data storage capacity of a node in a cluster is used up, you can scale up the instance according to :ref:`Modifying DCS Instance Specifications `. + +.. |image1| image:: /_static/images/en-us_image_0000001194523043.png diff --git a/umn/source/operation_guide/managing_dcs_instances/viewing_redis_run_logs.rst b/umn/source/operation_guide/managing_dcs_instances/viewing_redis_run_logs.rst new file mode 100644 index 0000000..959816e --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/viewing_redis_run_logs.rst @@ -0,0 +1,27 @@ +:original_name: dcs-ug-1009001.html + +.. _dcs-ug-1009001: + +Viewing Redis Run Logs +====================== + +You can create run log files on the DCS console to collect run logs of DCS Redis instances within a specified period. After the logs are collected, you can download the log files to view the logs. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of a DCS instance. + +#. Click the **Run Logs** tab. + +#. Click **Create Log File**. + + If the instance is the master/standby or cluster type, you can specify the shard and replica whose run logs you want to collect. If the instance is the single-node type, logs of the only node of the instance will be collected. + +.. |image1| image:: /_static/images/en-us_image_0000001148443514.png diff --git a/umn/source/operation_guide/managing_dcs_instances/viewing_redis_slow_logs.rst b/umn/source/operation_guide/managing_dcs_instances/viewing_redis_slow_logs.rst new file mode 100644 index 0000000..9d7037e --- /dev/null +++ b/umn/source/operation_guide/managing_dcs_instances/viewing_redis_slow_logs.rst @@ -0,0 +1,48 @@ +:original_name: dcs-ug-190926001.html + +.. _dcs-ug-190926001: + +Viewing Redis Slow Logs +======================= + +Redis logs queries that exceed a specified execution time. You can view the slow query log on the DCS console to identify performance issues. + +For details about the commands, visit the `Redis official website `__. + +Configure the slow log with the following parameters: + +- **slowlog-log-slower-than**: The maximum time allowed, in microseconds, for command execution. If this threshold is exceeded, Redis will log the command. The default value is **10,000**. That is, if command execution exceeds 10 ms, the command will be logged. +- **slowlog-max-len**: The maximum allowed number of slow logs that can be logged. The default value is **128**. That is, if the number of slow logs exceeds 128, the earliest record will be deleted to make room for new ones. + +For details about the configuration parameters, see :ref:`Modifying Configuration Parameters `. + +.. note:: + + You can view the slow log of a Proxy Cluster DCS Redis 3.0 instance only if the instance is created after October 14, 2019. If the instance was created earlier, contact technical support to upgrade it. The upgrade adds the slow log function to the console, and does not affect services. + +Viewing Slow Logs on the Console +-------------------------------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the name of a DCS instance. + +#. Choose **Slow Log**. + +#. Select a start date and an end date to view the slow log within the specified period. + + .. note:: + + For details about the commands, visit the `Redis official website `__. + + + .. figure:: /_static/images/en-us_image_0281049655.png + :alt: **Figure 1** Slow query log of an instance + + **Figure 1** Slow query log of an instance + +.. |image1| image:: /_static/images/en-us_image_0000001194523041.png diff --git a/umn/source/operation_guide/managing_passwords/changing_instance_passwords.rst b/umn/source/operation_guide/managing_passwords/changing_instance_passwords.rst new file mode 100644 index 0000000..4310379 --- /dev/null +++ b/umn/source/operation_guide/managing_passwords/changing_instance_passwords.rst @@ -0,0 +1,48 @@ +:original_name: dcs-ug-0312040.html + +.. _dcs-ug-0312040: + +Changing Instance Passwords +=========================== + +On the DCS console, you can change the password required for accessing your DCS instance. + +.. note:: + + - You cannot change the password of a DCS instance in password-free mode. + - The DCS instance for which you want to change the password is in the **Running** state. + - The new password takes effect immediately on the server without requiring a restart. The client must reconnect to the server using the new password after a pconnect connection is closed. (The old password can still be used before disconnection.) + +Prerequisites +------------- + +At least one DCS instance has been created. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. Choose **More** > **Change Password** in the same row as the chosen instance. +#. In the displayed dialog box, set **Old Password**, **New Password**, and **Confirm Password**. + + .. note:: + + After 5 consecutive incorrect password attempts, the account for accessing the chosen DCS instance will be locked for 5 minutes. Passwords cannot be changed during the lockout period. + + The password must meet the following requirements: + + - Cannot be left blank. + - The new password cannot be the same as the old password. + - Can contain 8 to 32 characters. + - Must contain at least three of the following character types: + + - Lowercase letters + - Uppercase letters + - Digits + - special characters (:literal:`\`~!@#$^&*()-_=+\\|{}:,<.>/?`) + +#. In the **Change Password** dialog box, click **OK** to confirm the password change. + +.. |image1| image:: /_static/images/en-us_image_0000001195353813.png diff --git a/umn/source/operation_guide/managing_passwords/dcs_instance_passwords.rst b/umn/source/operation_guide/managing_passwords/dcs_instance_passwords.rst new file mode 100644 index 0000000..e57d5a6 --- /dev/null +++ b/umn/source/operation_guide/managing_passwords/dcs_instance_passwords.rst @@ -0,0 +1,44 @@ +:original_name: cache-instance-password.html + +.. _cache-instance-password: + +DCS Instance Passwords +====================== + +Passwords can be configured to control access to your DCS instances, ensuring the security of your data. + +.. note:: + + After 5 consecutive incorrect password attempts, the account for accessing the chosen DCS instance will be locked for 5 minutes. Passwords cannot be changed during the lockout period. + + The password must meet the following requirements: + + - Cannot be left blank. + - Cannot be the same as the old password. + - Can contain 8 to 32 characters. + - Must contain at least three of the following character types: + + - Lowercase letters + - Uppercase letters + - Digits + - special characters (:literal:`\`~!@#$^&*()-_=+\\|{}:,<.>/?`) + +Using Passwords Securely +------------------------ + +#. Hide the password when using redis-cli. + + If the **-a ** option is used in redis-cli in Linux, the password is prone to leakage because it is logged and kept in the history. You are advised not to use **-a ** when running commands in redis-cli. After connecting to Redis, run the **auth** command to complete authentication as shown in the following example: + + .. code-block:: + + $ redis-cli -h 192.168.0.148 -p 6379 + redis 192.168.0.148:6379>auth yourPassword + OK + redis 192.168.0.148:6379> + +#. Use interactive password authentication or switch between users with different permissions. + + If the script involves DCS instance access, use interactive password authentication. To enable automatic script execution, manage the script as another user and authorize execution using sudo. + +#. Use an encryption module in your application to encrypt the password. diff --git a/umn/source/operation_guide/managing_passwords/index.rst b/umn/source/operation_guide/managing_passwords/index.rst new file mode 100644 index 0000000..8f3663a --- /dev/null +++ b/umn/source/operation_guide/managing_passwords/index.rst @@ -0,0 +1,16 @@ +:original_name: dcs-ug-0312039.html + +.. _dcs-ug-0312039: + +Managing Passwords +================== + +- :ref:`DCS Instance Passwords ` +- :ref:`Changing Instance Passwords ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + dcs_instance_passwords + changing_instance_passwords diff --git a/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/importing_backup_files_from_an_obs_bucket.rst b/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/importing_backup_files_from_an_obs_bucket.rst new file mode 100644 index 0000000..a560ad8 --- /dev/null +++ b/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/importing_backup_files_from_an_obs_bucket.rst @@ -0,0 +1,134 @@ +:original_name: dcs-ug-0312037.html + +.. _dcs-ug-0312037: + +Importing Backup Files from an OBS Bucket +========================================= + +Scenario +-------- + +Use the DCS console to migrate Redis data from Redis of other vendors or self-hosted Redis to DCS for Redis. + +Simply download the source Redis data and then upload the data to an OBS bucket in the same region as the target DCS Redis instance. After you have created a migration task on the DCS console, DCS will read data from the OBS bucket and data will be migrated to the target instance. + +.aof, .rbb, .zip, and .tar.gz files can be uploaded to OBS buckets. You can directly upload .aof and .rdb files or compress them into .zip or .tar.gz files before uploading. + +Prerequisites +------------- + +- The OBS bucket must be in the same region as the target DCS Redis instance. +- The data files to be uploaded must be in the .aof, .rdb, .zip, or .tar.gz format. +- To migrate data from a single-node or master/standby Redis instance of other cloud vendors, create a backup task and download the backup file. +- To migrate data from a cluster Redis instance of other cloud vendors, download all backup files and upload all of them to the OBS bucket. Each backup file contains data for a shard of the instance. +- .rdb backup files of self-hosted Redis 5.0 cannot be imported. .rdb backup files of self-hosted Redis 3.0 or 4.0 can be exported using redis-cli. .rdb files of other cloud Redis can be exported only by creating backup tasks, and cannot be exported by running commands in redis-cli. +- Redis Cluster instances only support .rdb files and do not support .aof files. + +.. _dcs-ug-0312037__en-us_topic_0179456697_en-us_topic_0177563520_section1128152020384: + +Step 1: Prepare the Target DCS Redis Instance +--------------------------------------------- + +- If a DCS Redis instance is not available, create one first. For details, see :ref:`Creating a DCS Redis Instance `. +- If a DCS Redis instance is available, you do not need to create a new one. However, you must clear the instance data before the migration. + + - If the target instance is Redis 4.0 or 5.0, clear the data by referring to :ref:`Clearing DCS Instance Data `. + - If the target instance is a DCS Redis 3.0 instance, run the **FLUSHALL** command to clear data. + +You can use a DCS Redis 3.0, 4.0, or 5.0 instance as the target instance. + +Step 2: Create an OBS Bucket and Upload Backup Files +---------------------------------------------------- + +#. Create an OBS bucket. + + a. Log in to the OBS Console and click **Create Bucket**. + + b. Select a region. + + The OBS bucket must be in the same region as the target DCS Redis instance. + + c. Specify **Bucket Name**. + + The bucket name must meet the naming rules specified on the console. + + d. Set **Storage Class** to **Standard**, **Warm** or **Cold**. + + e. Set **Bucket Policy** to **Private**, **Public Read**, or **Public Read and Write**. + + f. Configure default encryption. + + g. Click **Create Now**. + +#. Upload the backup data files to the OBS bucket by using OBS Browser+. + + If the backup file to be uploaded does not exceed 5 GB, upload the file using the OBS console by referring to step :ref:`3 `. + + If the backup file to be uploaded is larger than 5 GB, perform the following steps to upload the file using OBS Browser+. + + a. Download OBS Browser+. + + For details, see section "Downloading OBS Browser+" in *Object Storage Service (OBS) Tools Guide (OBS Browser+)*. + + b. Install OBS Browser+. + + For details, see section "Installing OBS Browser+" in *Object Storage Service (OBS) Tools Guide (OBS Browser+)*. + + c. Log in to OBS Browser+. + + For details, see section "Logging In to OBS Browser+" in *Object Storage Service (OBS) Tools Guide (OBS Browser+)*. + + d. Creates a bucket. + + e. Upload backup data. + +#. .. _dcs-ug-0312037__li8307135965315: + + On the OBS console, upload the backup data files to the OBS bucket. + + Perform the following steps if the backup file size does not exceed 5 GB: + + a. In the bucket list, click the name of the created bucket. + + b. In the navigation pane, choose **Objects**. + + c. On the **Objects** tab page, click **Upload Object**. + + d. A maximum of 100 files can be uploaded at a time. The total size cannot exceed 5 GB. + + To upload objects, drag files or folders to the **Upload Object** area or click **add file**. + + e. Click **Upload**. + +Step 3: Create a Migration Task +------------------------------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Data Migration**. + +#. Click **Create Backup Import Task**. + +#. Specify **Task Name** and **Description**. + +#. Select **OBS Bucket** as the data source and then select the OBS bucket to which you have uploaded backup files. + + .. note:: + + You can upload files in the .aof, .rdb, .zip, or .tar.gz format. + +#. Select the backup files whose data is to be migrated. + +#. Select the target DCS Redis instance prepared in :ref:`Step 1: Prepare the Target DCS Redis Instance `. + +#. Enter the password of the target instance. Click **Test Connection** to verify the password. + +#. Click **Next**. + +#. Confirm the migration task details and click **Submit**. + + Go back to the data migration task list. After the migration is successful, the task status changes to **Successful**. + +.. |image1| image:: /_static/images/en-us_image_0000001194523107.png diff --git a/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/importing_backup_files_from_redis.rst b/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/importing_backup_files_from_redis.rst new file mode 100644 index 0000000..bcd2163 --- /dev/null +++ b/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/importing_backup_files_from_redis.rst @@ -0,0 +1,69 @@ +:original_name: dcs-ug-210226001.html + +.. _dcs-ug-210226001: + +Importing Backup Files from Redis +================================= + +Scenario +-------- + +Use the DCS console to migrate Redis data from self-hosted Redis to DCS for Redis. + +Simply back up your Redis data, create a migration task on the DCS console, and then import the backup to a DCS Redis instance. + +Prerequisites +------------- + +A master/standby or cluster DCS Redis instance has been created as the target for the migration. The source instance has data and has been backed up. + +.. _dcs-ug-210226001__section15805239143710: + +Step 1: Obtain the Source Instance Name and Password +---------------------------------------------------- + +Obtain the name of the source Redis instance. + +.. _dcs-ug-210226001__en-us_topic_0179456697_en-us_topic_0177563520_section1128152020384: + +Step 2: Prepare the Target DCS Redis Instance +--------------------------------------------- + +- If a DCS Redis instance is not available, create one first. For details, see :ref:`Creating a DCS Redis Instance `. +- If a DCS Redis instance is available, you do not need to create a new one. However, you must clear the instance data before the migration. + + - If the target instance is Redis 4.0 or 5.0, clear the data by referring to :ref:`Clearing DCS Instance Data `. + - If the target instance is a DCS Redis 3.0 instance, run the **FLUSHALL** command to clear data. + +You can use a DCS Redis 3.0, 4.0, or 5.0 instance as the target instance. + +Step 3: Create a Migration Task +------------------------------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Data Migration**. + +#. Click **Create Backup Import Task**. + +#. Enter the task name and description. + +#. Set **Data Source** to **Redis**. + +#. For source Redis, select the instance prepared in :ref:`Step 1: Obtain the Source Instance Name and Password `. + +#. Select the backup task whose data is to be migrated. + +#. Select the target instance created in :ref:`Step 2: Prepare the Target DCS Redis Instance `. + +#. Enter the password of the target instance. Click **Test Connection** to verify the password. + +#. Click **Next**. + +#. Confirm the migration task details and click **Submit**. + + Go back to the data migration task list. After the migration is successful, the task status changes to **Successful**. + +.. |image1| image:: /_static/images/en-us_image_0000001148443514.png diff --git a/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/index.rst b/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/index.rst new file mode 100644 index 0000000..59858cf --- /dev/null +++ b/umn/source/operation_guide/migrating_data_with_dcs/importing_backup_files/index.rst @@ -0,0 +1,16 @@ +:original_name: dcs-ug-210922001.html + +.. _dcs-ug-210922001: + +Importing Backup Files +====================== + +- :ref:`Importing Backup Files from an OBS Bucket ` +- :ref:`Importing Backup Files from Redis ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + importing_backup_files_from_an_obs_bucket + importing_backup_files_from_redis diff --git a/umn/source/operation_guide/migrating_data_with_dcs/index.rst b/umn/source/operation_guide/migrating_data_with_dcs/index.rst new file mode 100644 index 0000000..7972e38 --- /dev/null +++ b/umn/source/operation_guide/migrating_data_with_dcs/index.rst @@ -0,0 +1,18 @@ +:original_name: dcs-ug-0312035.html + +.. _dcs-ug-0312035: + +Migrating Data with DCS +======================= + +- :ref:`Introduction to Migration with DCS ` +- :ref:`Importing Backup Files ` +- :ref:`Migrating Data Online ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + introduction_to_migration_with_dcs + importing_backup_files/index + migrating_data_online diff --git a/umn/source/operation_guide/migrating_data_with_dcs/introduction_to_migration_with_dcs.rst b/umn/source/operation_guide/migrating_data_with_dcs/introduction_to_migration_with_dcs.rst new file mode 100644 index 0000000..fa41181 --- /dev/null +++ b/umn/source/operation_guide/migrating_data_with_dcs/introduction_to_migration_with_dcs.rst @@ -0,0 +1,74 @@ +:original_name: dcs-ug-0312036.html + +.. _dcs-ug-0312036: + +Introduction to Migration with DCS +================================== + +Migration Modes +--------------- + +DCS for Redis provides the following migration modes: + +- Backup file import: The data source can be an OBS bucket or a Redis instance. + + - Importing data from an OBS bucket: Download the source Redis data and then upload it to an OBS bucket in the same region as the target DCS Redis instance. DCS will read the backup data from the OBS bucket and migrate the data into the target instance. + + **This migration mode can be used for migrating data from other Redis vendors or self-hosted Redis to DCS for Redis.** + + - Importing data from a Redis instance: Back up the source Redis data and then migrate the backup data to DCS for Redis. + +- Migrating data online: If the source and target instances are interconnected and the **SYNC** and **PSYNC** commands are supported in the source instance, data can be migrated online in full or incrementally from the source to the target. + +The following table describes data migration modes supported by DCS. + +.. note:: + + Data can be migrated only from DCS Redis instances or self-hosted Redis. After data migration, change the instance connection address to the target instance address. + + Data migration is not supported if the DCS instance is created by another service, such as ROMA Connect, or by calling an API. + +.. table:: **Table 1** DCS data migration modes + + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | Migration Mode | Source | Target: DCS | | | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | | Single-Node and Master/Standby | Proxy Cluster | Redis Cluster | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | Importing backup files | AOF files in OBS | Y | Y | x | + | | | | | | + | | .. note:: | | | | + | | | | | | + | | AOF files exported from Redis 4.0/5.0 instances and other instances with RDB compression enabled cannot be imported. | | | | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | RDB files in OBS | Y | Y | Y | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | Migrating data online | DCS for Redis: single-node or master/standby | Y | Y | Y | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | DCS for Redis: Proxy Cluster | Y | Y | Y | + | | | | | | + | | .. note:: | | | | + | | | | | | + | | Proxy Cluster DCS Redis 3.0 instances cannot be used as the source, while Proxy Cluster DCS Redis 4.0 or 5.0 instances can. | | | | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | DCS for Redis: Redis Cluster | Y | Y | Y | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | Self-hosted Redis: single-node or master/standby | Y | Y | Y | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | Self-hosted Redis: proxy-based cluster | Y | Y | Y | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | Self-hosted Redis: Redis Cluster | Y | Y | Y | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | Other Redis: single-node or master/standby | x | x | x | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | Other Redis: proxy-based cluster | x | x | x | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + | | Other Redis: Redis Cluster | x | x | x | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------+--------------------------------+---------------+---------------+ + +.. note:: + + - **DCS for Redis** refers to Redis instances provided by DCS + - **Self-hosted Redis** refers to self-hosted Redis on the cloud, from other cloud vendors, or in on-premises data centers. + - **Other Redis** refers to Redis services provided by other cloud vendors. + - **Y**: Supported. **x**: Not supported. diff --git a/umn/source/operation_guide/migrating_data_with_dcs/migrating_data_online.rst b/umn/source/operation_guide/migrating_data_with_dcs/migrating_data_online.rst new file mode 100644 index 0000000..123d8a7 --- /dev/null +++ b/umn/source/operation_guide/migrating_data_with_dcs/migrating_data_online.rst @@ -0,0 +1,127 @@ +:original_name: dcs-ug-0312038.html + +.. _dcs-ug-0312038: + +Migrating Data Online +===================== + +Scenario +-------- + +If the source and target instances are interconnected and the **SYNC** and **PSYNC** commands are supported in the source instance, data can be migrated online in full or incrementally from the source to the target. + +Prerequisites +------------- + +- Before migrating data, read through :ref:`Introduction to Migration with DCS ` to learn about the DCS data migration function and select an appropriate target instance. +- To migrate data from a single-node or master/standby instance to a Redis Cluster instance, check if any data exists in DBs other than DB0 in the source instance. If yes, move the data to DB0 by using the open-source tool Rump. Otherwise, the migration will fail because a Redis Cluster instance has only one DB. For details about the migration operations, see :ref:`Online Migration with Rump `. + +Obtaining Information About the Source Redis Instance +----------------------------------------------------- + +- If the source is a cloud Redis instance, obtain its name. +- If the source is self-hosted Redis, obtain its IP address or domain name and port number. + +.. _dcs-ug-0312038__en-us_topic_0179456698_en-us_topic_0177563541_section1128152020384: + +Prepare the Target DCS Redis Instance +------------------------------------- + +- If a target DCS Redis instance is not available, create one first. For details, see :ref:`Creating a DCS Redis Instance `. +- If a target instance is available, you do not need to create a new one. However, you must clear the instance data before the migration. For details, see :ref:`Clearing DCS Instance Data `. + +Requirements on the Network Between the Online Migration Task, Source Redis, and Target Redis +--------------------------------------------------------------------------------------------- + +.. note:: + + - If the source or target of online migration is **Redis in the cloud**, the selected Redis instance must be in the same VPC as the migration task. Otherwise, the migration task may fail to connect to the cloud Redis instance. + - In special scenarios, if you have enabled cross-VPC access between the migration task and the cloud Redis instance, the cloud Redis instance and the migration task can be in different VPCs. + +:ref:`Table 1 ` lists the requirements on the network between the online migration task, source Redis, and target Redis. + +.. _dcs-ug-0312038__table10117165272313: + +.. table:: **Table 1** Requirements on the network between the online migration task, source Redis, and target Redis + + +-----------------------+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Source Redis Type | Target Redis Type | Network Requirement on Online Migration | + +=======================+=======================+===============================================================================================================================================================================================================================================================================================================================================================================================================================================================================+ + | Redis in the cloud | Redis in the cloud | When creating an online migration task, ensure that the online migration task is in the same VPC as the source and target Redis. If they are not in the same VPC, enable cross-network access between the migration task and the source and target Redis. To enable cross-network access, create a VPC peering connection by referring to section "VPC Peering Connection" in `Creating a VPC `__. | + +-----------------------+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Redis in the cloud | Self-hosted Redis | When creating an online migration task, ensure that the migration task and the source Redis are in the same VPC. Then, enable cross-network access between the migration task and the target Redis. | + | | | | + | | | To enable cross-network access, create a VPC peering connection by referring to section "VPC Peering Connection" in `Creating a VPC `__. | + +-----------------------+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Self-hosted Redis | Redis in the cloud | When creating an online migration task, ensure that the migration task and the target Redis are in the same VPC. Then, enable cross-network access between the migration task and the source Redis. | + | | | | + | | | To enable cross-network access, create a VPC peering connection by referring to section "VPC Peering Connection" in `Creating a VPC `__. | + +-----------------------+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Self-hosted Redis | Self-hosted Redis | After creating an online migration task, enable cross-network access between the migration task and the source and target Redis, respectively. | + | | | | + | | | To enable cross-network access, create a VPC peering connection by referring to section "VPC Peering Connection" in `Creating a VPC `__. | + +-----------------------+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +Create a Migration Task +----------------------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Data Migration**. The migration task list is displayed. +#. Click **Create Online Migration Task**. +#. Enter the task name and description. +#. Select a VPC and security group. +#. Click **Next**. +#. Click **Submit**. + +Configuring the Online Migration Task +------------------------------------- + +#. On the **Online Migration** tab page, click **Configure** in the row containing the online migration task you just created. + +#. Specify **Migration Type**. + + Supported migration types are **Full** and **Full + incremental**, which are described in :ref:`Table 2 `. + + .. _dcs-ug-0312038__table621916513914: + + .. table:: **Table 2** Migration type description + + +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Migration Type | Description | + +===================================+===================================================================================================================================================================================================================================================================================================================================================================================================================================+ + | Full | Suitable for scenarios where services can be interrupted. Data is migrated at one time. Source instance data updated during the migration will not be migrated to the target instance. | + +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Full + incremental | Suitable for scenarios requiring minimal service downtime. The incremental migration parses logs to ensure data consistency between the source and target instances. | + | | | + | | **Once incremental migration starts, it remains** **Migrating** until you click **Stop** in the **Operation** column. After the migration is stopped, data in the source instance will not be lost, but data will not be written to the target instance. When the transmission network is stable, the delay of incremental migration is within seconds. The actual delay depends on the transmission quality of the network link. | + +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +#. Configure source Redis and target Redis. + + a. **Source Redis Type**: Select **Redis in the cloud** or **Self-hosted Redis** as required. + + - **Redis in the cloud**: a DCS Redis instance that is in the same VPC as the migration task + - **Self-hosted Redis**: self-hosted Redis in another cloud, or in on-premises data centers. If you select this option, enter Redis addresses. + + b. If the instance is password-protected, you can click **Test Connection** to check whether the instance password is correct and whether the network is connected. + +#. For **Target Instance**, select the DCS Redis Instance prepared in :ref:`Prepare the Target DCS Redis Instance `. + + If the instance is password-protected, you can click **Test Connection** to check whether the instance password meets the requirements. + + .. note:: + + If the source and target Redis instances are connected but are in different regions of DCS, you can only select **Self-hosted Redis** for **Target Redis Type** and enter the instance addresses, regardless of whether the target Redis instance is self-hosted or in the cloud. + +#. Click **Next**. + +#. Confirm the migration task details and click **Submit**. + + Go back to the data migration task list. After the migration is successful, the task status changes to **Successful**. + + .. note:: + + If the migration type is full+incremental, the migration task status will remain **Migrating** until you click **Stop**. + +.. |image1| image:: /_static/images/en-us_image_0000001206970621.png diff --git a/umn/source/operation_guide/operating_dcs_instances/clearing_dcs_instance_data.rst b/umn/source/operation_guide/operating_dcs_instances/clearing_dcs_instance_data.rst new file mode 100644 index 0000000..3bf686c --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/clearing_dcs_instance_data.rst @@ -0,0 +1,22 @@ +:original_name: dcs-ug-0312018.html + +.. _dcs-ug-0312018: + +Clearing DCS Instance Data +========================== + +On the DCS console, you can clear data only for DCS Redis 4.0 and 5.0 instances. + +**Clearing instance data cannot be undone and cleared data cannot be recovered. Exercise caution when performing this operation.** + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. Select one or more DCS2.0 instances to clear. +#. Click **Clear data** above the instance list. +#. In the displayed dialog box, click **Yes**. + +.. |image1| image:: /_static/images/en-us_image_0000001148443458.png diff --git a/umn/source/operation_guide/operating_dcs_instances/command_renaming.rst b/umn/source/operation_guide/operating_dcs_instances/command_renaming.rst new file mode 100644 index 0000000..8600c81 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/command_renaming.rst @@ -0,0 +1,26 @@ +:original_name: dcs-ug-1009002.html + +.. _dcs-ug-1009002: + +Command Renaming +================ + +After creating a DCS Redis 4.0 or 5.0 instance, you can rename the following critical commands: **COMMAND**, **KEYS**, **FLUSHDB**, **FLUSHALL**, and **HGETALL**. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. In the **Operation** column of an instance, choose **More** > **Command Renaming**. +#. Select a command, enter a new name, and click **OK**. + + .. note:: + + - You can rename multiple commands at a time. + - The new command names will take effect only after you restart the instance. Remember the new command names because they will not be displayed on the console for security purposes. + - To use the original name of a command, rename the command again. + - The new name must contain at least four characters. + +.. |image1| image:: /_static/images/en-us_image_0000001148603248.png diff --git a/umn/source/operation_guide/operating_dcs_instances/deleting_dcs_instances.rst b/umn/source/operation_guide/operating_dcs_instances/deleting_dcs_instances.rst new file mode 100644 index 0000000..16fffd8 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/deleting_dcs_instances.rst @@ -0,0 +1,66 @@ +:original_name: dcs-ug-0326014.html + +.. _dcs-ug-0326014: + +Deleting DCS Instances +====================== + +On the DCS console, you can delete one or multiple DCS instances at a time. You can also delete all instance creation tasks that have failed to run. + +.. important:: + + - After a DCS instance is deleted, the instance data will also be deleted without backup. In addition, any backup data of the instance will be deleted. Therefore, download the backup files of the instance for permanent storage before deleting the instance. + - If the instance is in cluster mode, all cluster nodes will be deleted. + +Prerequisites +------------- + +- The DCS instances you want to delete have been created. +- The DCS instances you want to delete are in the **Running** or **Faulty** state. + +Procedure +--------- + +Deleting DCS Instances + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. On the **Cache Manager** page, select one or more DCS instances you want to delete. + + DCS instances in the **Creating**, **Restarting**, **Upgrading**, **Resizing**, **Clearing data**, **Backing up**, or **Restoring** state cannot be deleted. + +#. Choose **More** > **Delete** above the instance list. + +#. In the displayed dialog box, click **Yes**. + + It takes 1 to 30 minutes to delete DCS instances. + + .. note:: + + To delete a single instance, choose **Operation** > **More** > **Delete** in the same row as the instance. + +Deleting Instance Creation Tasks That Have Failed to Run + +#. Log in to the DCS console. + +#. Click |image2| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. If there are DCS instances that have failed to be created, **Instance Creation Failures** is displayed above the instance list. + +#. Click the icon or the number of failed tasks next to **Instance Creation Failures**. + + The **Instance Creation Failures** dialog box is displayed. + +#. Choose failed instance creation tasks to delete. + + - To delete all failed tasks, click **Delete All** above the task list. + - To delete a single failed task, click **Delete** in the same row as the task. + +.. |image1| image:: /_static/images/en-us_image_0000001194403157.png +.. |image2| image:: /_static/images/en-us_image_0000001148603250.png diff --git a/umn/source/operation_guide/operating_dcs_instances/exporting_dcs_instance_list.rst b/umn/source/operation_guide/operating_dcs_instances/exporting_dcs_instance_list.rst new file mode 100644 index 0000000..abb8063 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/exporting_dcs_instance_list.rst @@ -0,0 +1,26 @@ +:original_name: dcs-ug-0312019.html + +.. _dcs-ug-0312019: + +Exporting DCS Instance List +=========================== + +On the DCS console, you can export DCS instance information in full to an Excel file. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. Click the search bar. In the displayed drop-down list, select the filter criteria to query the desired DCS instances. + +#. Click |image2| above the instance list. + + Click the export result displayed in the lower left corner of the page. + +.. |image1| image:: /_static/images/en-us_image_0000001194403155.png +.. |image2| image:: /_static/images/en-us_image_0266235403.png diff --git a/umn/source/operation_guide/operating_dcs_instances/index.rst b/umn/source/operation_guide/operating_dcs_instances/index.rst new file mode 100644 index 0000000..9898c61 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/index.rst @@ -0,0 +1,28 @@ +:original_name: dcs-ug-0312015.html + +.. _dcs-ug-0312015: + +Operating DCS Instances +======================= + +- :ref:`Modifying DCS Instance Specifications ` +- :ref:`Starting DCS Instances ` +- :ref:`Restarting DCS Instances ` +- :ref:`Deleting DCS Instances ` +- :ref:`Performing a Master/Standby Switchover for a DCS Instance ` +- :ref:`Clearing DCS Instance Data ` +- :ref:`Exporting DCS Instance List ` +- :ref:`Command Renaming ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + modifying_dcs_instance_specifications + starting_dcs_instances + restarting_dcs_instances + deleting_dcs_instances + performing_a_master_standby_switchover_for_a_dcs_instance + clearing_dcs_instance_data + exporting_dcs_instance_list + command_renaming diff --git a/umn/source/operation_guide/operating_dcs_instances/modifying_dcs_instance_specifications.rst b/umn/source/operation_guide/operating_dcs_instances/modifying_dcs_instance_specifications.rst new file mode 100644 index 0000000..a8cbc94 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/modifying_dcs_instance_specifications.rst @@ -0,0 +1,79 @@ +:original_name: dcs-ug-0326011.html + +.. _dcs-ug-0326011: + +Modifying DCS Instance Specifications +===================================== + +On the DCS console, you can scale a DCS Redis instance to a larger or smaller capacity. + +.. note:: + + - **Modify instance specifications during off-peak hours.** + - If your DCS instances are too old to support scaling, contact technical support to upgrade the instances. + - Services may be interrupted for seconds during the modification. Therefore, services connected to Redis must support reconnection. + +Scaling +------- + +- **The following table lists scaling options supported by different DCS instances.** + + .. table:: **Table 1** Scaling options supported by different DCS instances + + ============ =============== =============== ============= ============= + Cache Engine Single-Node Master/Standby Redis Cluster Proxy Cluster + ============ =============== =============== ============= ============= + Redis 3.0 Scaling up/down Scaling up/down N/A Scaling up + Redis 4.0 Scaling up/down Scaling up/down Scaling up N/A + Redis 5.0 Scaling up/down Scaling up/down Scaling up N/A + ============ =============== =============== ============= ============= + + .. note:: + + If the reserved memory of a DCS Redis 3.0 instance is insufficient, the scaling may fail when the memory is used up. + +- **Impact of scaling:** + + - Single-node and master/standby + + - A DCS Redis 4.0 or 5.0 instance will be disconnected for several seconds and remain read-only for about 1 minute. + - A DCS Redis 3.0 instance will be disconnected and remain read-only for 5 to 30 minutes. + - For scaling up, only the memory of the instance is expanded. The CPU processing capability is not improved. + - Data of single-node instances may be lost because they do not support data persistence. After scaling, check whether the data is complete and import data if required. + - Backup records of master/standby instances cannot be restored after scaling down. + + - Cluster + + - If the shard quantity is not decreased, the instance can always be connected, but the CPU usage will increase, compromising performance by up to 20%, and the latency will increase during data migration. + - During scaling up, new Redis Server nodes are added, and data is automatically balanced to the new nodes. + - Nodes will be deleted if the shard quantity decreases. To prevent disconnection, ensure that the deleted nodes are not directly referenced in your application. + - Ensure that the used memory of each node is less than 70% of the maximum memory per node of the new flavor. Otherwise, you cannot perform the scale-in. + - If the memory becomes full during scaling due to a large amount of data being written, scaling will fail. Modify specifications during off-peak hours. + - Scaling involves data migration. The latency for accessing the key being migrated increases. For a Redis Cluster instance, ensure that the client can properly process the **MOVED** and **ASK** commands. Otherwise, requests will fail. + - Before scaling, perform cache analysis to ensure that no big keys (>= 512 MB) exist in the instance. Otherwise, scaling may fail. + - Backup records created before scaling cannot be restored. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. + +4. Choose **More** > **Modify Specifications** in the row containing the DCS instance. + +5. On the **Modify Specifications** page, select the desired specification and click Next. + +6. Click **Submit**. + + On the displayed **Background Tasks** page, view the modification status. For more information, see :ref:`Viewing Background Tasks `. + + Specification modification of a single-node or master/standby DCS instance takes about 5 to 30 minutes to complete, while that of a cluster DCS instance takes a longer time. After an instance is successfully modified, it changes to the **Running** state. + + .. note:: + + - If the specification modification of a single-node DCS instance fails, the instance is temporarily unavailable for use. The specification remains unchanged. Some management operations (such as parameter configuration and specification modification) are temporarily not supported. After the specification modification is completed in the backend, the instance changes to the new specification and becomes available for use again. + - If the specification modification of a master/standby or cluster DCS instance fails, the instance is still available for use with its original specifications. Some management operations (such as parameter configuration, backup, restoration, and specification modification) are temporarily not supported. Remember not to read or write more data than allowed by the original specifications; otherwise, data loss may occur. + - After the specification modification is successful, the new specification of the instance takes effect. + +.. |image1| image:: /_static/images/en-us_image_0000001194523049.png diff --git a/umn/source/operation_guide/operating_dcs_instances/performing_a_master_standby_switchover_for_a_dcs_instance.rst b/umn/source/operation_guide/operating_dcs_instances/performing_a_master_standby_switchover_for_a_dcs_instance.rst new file mode 100644 index 0000000..7eeba47 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/performing_a_master_standby_switchover_for_a_dcs_instance.rst @@ -0,0 +1,31 @@ +:original_name: dcs-ug-0312017.html + +.. _dcs-ug-0312017: + +Performing a Master/Standby Switchover for a DCS Instance +========================================================= + +On the DCS console, you can manually switch the master and standby nodes of a DCS instance. This operation is used for special purposes, for example, releasing all service connections or terminating ongoing service operations. + +Only master/standby instances support a master/standby node switchover. + +.. important:: + + - Services may be interrupted for up to 10 seconds during the switchover. Before performing a switchover, ensure that your application supports reconnection. + - During a master/standby node switchover, a large amount of resources will be consumed for data synchronization between the master and standby nodes. You are advised to perform this operation during off-peak hours. + - Data of the maser and standby nodes is synchronized asynchronously. Therefore, a small amount of data that is being operated on during the switchover may be lost. + +Prerequisites +------------- + +The DCS instance for which you want to perform a master/standby node switchover is in the **Running** state. + +Procedure +--------- + +#. Log in to the DCS console. +#. Click |image1| in the upper left corner and select a region and a project. +#. In the navigation pane, choose **Cache Manager**. +#. In the **Operation** column of the instance, choose **More** > **Master/Standby Switchover**. + +.. |image1| image:: /_static/images/en-us_image_0000001194523047.png diff --git a/umn/source/operation_guide/operating_dcs_instances/restarting_dcs_instances.rst b/umn/source/operation_guide/operating_dcs_instances/restarting_dcs_instances.rst new file mode 100644 index 0000000..ea0167f --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/restarting_dcs_instances.rst @@ -0,0 +1,43 @@ +:original_name: dcs-ug-0326013.html + +.. _dcs-ug-0326013: + +Restarting DCS Instances +======================== + +On the DCS console, you can restart one or multiple DCS instances at a time. + +.. important:: + + - After a single-node DCS instance is restarted, data will be deleted from the instance. + - While a DCS instance is restarting, it cannot be read from or written to. + - An attempt to restart a DCS instance while it is being backed up may result in a failure. + +Prerequisites +------------- + +The DCS instances you want to restart are in the **Running** or **Faulty** state. + +Procedure +--------- + +#. Log in to the DCS console. + +#. Click |image1| in the upper left corner and select a region and a project. + +#. In the navigation pane, choose **Cache Manager**. + +#. On the **Cache Manager** page, select one or more DCS instances you want to restart. + +#. Click **Restart** above the DCS instance list. + +#. In the displayed dialog box, click **Yes**. + + It takes 1 to 30 minutes to restart DCS instances. After DCS instances are restarted, their status changes to **Running**. + + .. note:: + + - To restart a single instance, you can also click **Restart** in the same row as the instance. + - The time required for restarting a DCS instance depends on the cache size of the instance. + +.. |image1| image:: /_static/images/en-us_image_0000001148443460.png diff --git a/umn/source/operation_guide/operating_dcs_instances/starting_dcs_instances.rst b/umn/source/operation_guide/operating_dcs_instances/starting_dcs_instances.rst new file mode 100644 index 0000000..bf86707 --- /dev/null +++ b/umn/source/operation_guide/operating_dcs_instances/starting_dcs_instances.rst @@ -0,0 +1,40 @@ +:original_name: dcs-ug-0911001.html + +.. _dcs-ug-0911001: + +Starting DCS Instances +====================== + +Scenario +-------- + +On the DCS console, you can start one or multiple DCS instances at a time. + +.. note:: + + This function is not supported by recent instances. You can only start old instances that have been stopped. Once started, these instances can only be restarted and can no longer be stopped or started. + +Prerequisites +------------- + +The DCS instances you want to start are in the **Stopped** state. + +Procedure +--------- + +#. Log in to the management console. +#. Click |image1| in the upper left corner and select a region and a project. +#. Click **Service List**, and choose **Application** > **Distributed Cache Service** to launch the DCS console. +#. In the navigation pane, choose **Cache Manager**. +#. On the **Cache Manager** page, select one or more DCS instances you want to restart. +#. Click **Start** above the DCS instance list. +#. In the **Start** dialog box, click **Yes** to confirm that you want to start the instances. + + - It takes 1 to 30 minutes to start DCS instances. + - After DCS instances are started, their statuses change from **Stopped** to **Running**. + + .. note:: + + To start a single instance, you can also click **Start** in the **Operation** column in the same row as the instance. + +.. |image1| image:: /_static/images/en-us_image_0000001148443450.png diff --git a/umn/source/permissions_management/creating_a_user_and_granting_dcs_permissions.rst b/umn/source/permissions_management/creating_a_user_and_granting_dcs_permissions.rst new file mode 100644 index 0000000..01279ce --- /dev/null +++ b/umn/source/permissions_management/creating_a_user_and_granting_dcs_permissions.rst @@ -0,0 +1,45 @@ +:original_name: dcs-ug-210626004.html + +.. _dcs-ug-210626004: + +Creating a User and Granting DCS Permissions +============================================ + +This chapter describes how to use IAM to implement fine-grained permissions control for your DCS resources. With IAM, you can: + +- Create IAM users for employees based on your enterprise's organizational structure. Each IAM user will have their own security credentials for accessing DCS resources. +- Grant only the permissions required for users to perform a specific task. +- Entrust an account or cloud service to perform efficient O&M on your DCS resources. + +If your account does not need individual IAM users, you may skip over this chapter. + +This section describes the procedure for granting the **DCS ReadOnlyAccess** permission (see :ref:`Figure 1 `) as an example. + +Prerequisites +------------- + +You are familiar with the permissions (see :ref:`Permissions Management `) supported by DCS and choose policies or roles according to your requirements. For the permissions of other services, see Permissions Policies. + +Process Flow +------------ + +.. _dcs-ug-210626004__fig17581732820: + +.. figure:: /_static/images/en-us_image_0000001196623620.png + :alt: **Figure 1** Process of granting DCS permissions + + **Figure 1** Process of granting DCS permissions + +#. .. _dcs-ug-210626004__en-us_topic_0170877287_en-us_topic_0170877287_li10176121316284: + + Create a user group and grant permissions. + + Create a user group on the IAM console, and attach the **DCS ReadOnlyAccess** policy to the group. + +#. Create an IAM user. + + Create a user on the IAM console and add the user to the group created in :ref:`1 `. + +#. Log in and verify permissions. + + Log in to the DCS console by using the newly created user, and verify that the user only has read permissions for DCS. diff --git a/umn/source/permissions_management/dcs_custom_policies.rst b/umn/source/permissions_management/dcs_custom_policies.rst new file mode 100644 index 0000000..6f4add2 --- /dev/null +++ b/umn/source/permissions_management/dcs_custom_policies.rst @@ -0,0 +1,61 @@ +:original_name: dcs-ug-210626005.html + +.. _dcs-ug-210626005: + +DCS Custom Policies +=================== + +Custom policies can be created to supplement the system-defined policies of DCS. For the actions that can be added for custom policies, see Permissions Policies and Supported Actions. + +You can create custom policies in either of the following ways: + +- Visual editor: Select cloud services, actions, resources, and request conditions. This does not require knowledge of policy syntax. +- JSON: Edit JSON policies from scratch or based on an existing policy. + +For details, see "Creating a Custom Policy". The following section contains examples of common DCS custom policies. + +.. note:: + + Due to data caching, a policy involving OBS actions will take effect five minutes after it is attached to a user, user group, or project. + +Example Custom Policies +----------------------- + +- Example 1: Allowing users to delete and restart DCS instances and clear data of an instance + + .. code-block:: + + { + "Version": "1.1", + "Statement": [ + { + "Effect": "Allow", + "Action": [ + " + dcs:instance:delete + dcs:instance:modifyStatus + " + ] + } + ] + } + +- Example 2: Denying DCS instance deletion + + A policy with only "Deny" permissions must be used in conjunction with other policies to take effect. If the permissions assigned to a user contain both "Allow" and "Deny", the "Deny" permissions take precedence over the "Allow" permissions. + + The following method can be used if you need to assign permissions of the **DCS FullAccess** policy to a user but you want to prevent the user from deleting DCS instances. Create a custom policy for denying DCS instance deletion, and attach both policies to the group to which the user belongs. Then, the user can perform all operations on DCS instances except deleting DCS instances. The following is an example of a deny policy: + + .. code-block:: + + { + "Version": "1.1", + "Statement": [ + { + "Effect": "Deny", + "Action": [ + "dcs:instance:delete" + ] + } + ] + } diff --git a/umn/source/permissions_management/index.rst b/umn/source/permissions_management/index.rst new file mode 100644 index 0000000..8c86172 --- /dev/null +++ b/umn/source/permissions_management/index.rst @@ -0,0 +1,16 @@ +:original_name: dcs-ug-210626003.html + +.. _dcs-ug-210626003: + +Permissions Management +====================== + +- :ref:`Creating a User and Granting DCS Permissions ` +- :ref:`DCS Custom Policies ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + creating_a_user_and_granting_dcs_permissions + dcs_custom_policies diff --git a/umn/source/service_overview/accessing_dcs/how_to_access_dcs.rst b/umn/source/service_overview/accessing_dcs/how_to_access_dcs.rst new file mode 100644 index 0000000..3a8ee45 --- /dev/null +++ b/umn/source/service_overview/accessing_dcs/how_to_access_dcs.rst @@ -0,0 +1,16 @@ +:original_name: en-us_topic_0054235837.html + +.. _en-us_topic_0054235837: + +How to Access DCS +================= + +There are two ways to access DCS: + +- Using the management console + + The DCS provides a web-based management console. To launch the DCS console, create an account on the management console and log in, and then choose **Application** > **Distributed Cache Service** on the homepage. On the DCS console, you can create, restart, and delete DCS instances, and change their passwords. + +- Using APIs + + If you want to integrate DCS into a third-party system for secondary development, use APIs to access DCS. For more information about available APIs, see the *Distributed Cache Service API Reference*. diff --git a/umn/source/service_overview/accessing_dcs/index.rst b/umn/source/service_overview/accessing_dcs/index.rst new file mode 100644 index 0000000..44d7be4 --- /dev/null +++ b/umn/source/service_overview/accessing_dcs/index.rst @@ -0,0 +1,16 @@ +:original_name: en-us_topic_0054235836.html + +.. _en-us_topic_0054235836: + +Accessing DCS +============= + +- :ref:`How to Access DCS ` +- :ref:`User Permissions ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + how_to_access_dcs + user_permissions diff --git a/umn/source/service_overview/accessing_dcs/user_permissions.rst b/umn/source/service_overview/accessing_dcs/user_permissions.rst new file mode 100644 index 0000000..6eefaee --- /dev/null +++ b/umn/source/service_overview/accessing_dcs/user_permissions.rst @@ -0,0 +1,14 @@ +:original_name: en-us_topic_0054247786.html + +.. _en-us_topic_0054247786: + +User Permissions +================ + +The public cloud system provides two types of user permissions by default: user management and resource management. + +User management refers to the management of users, user groups, and user group rights. + +Resource management refers to the control operations that can be performed by users on cloud service resources. + +For details, see `Permissions `__. diff --git a/umn/source/service_overview/application_scenarios.rst b/umn/source/service_overview/application_scenarios.rst new file mode 100644 index 0000000..121333e --- /dev/null +++ b/umn/source/service_overview/application_scenarios.rst @@ -0,0 +1,35 @@ +:original_name: dcs-pd-0326002.html + +.. _dcs-pd-0326002: + +Application Scenarios +===================== + +Redis Application Scenarios +--------------------------- + +Many large-scale e-commerce websites and video streaming and gaming applications require fast access to large amounts of data that has simple data structures and does not need frequent join queries. In such scenarios, you can use Redis to achieve fast yet inexpensive access to data. Redis enables you to retrieve data from in-memory data stores instead of relying entirely on slower disk-based databases. In addition, you no longer need to perform additional management tasks. These features make Redis an important supplement to traditional disk-based databases and a basic service essential for internet applications receiving high-concurrency access. + +Typical application scenarios of DCS for Redis are as follows: + +#. **E-commerce flash sales** + + E-commerce product catalogue, deals, and flash sales data can be cached to Redis. + + For example, the high-concurrency data access in flash sales can be hardly handled by traditional relational databases. It requires the hardware to have higher configuration such as disk I/O. By contrast, Redis supports 100,000 QPS per node and allows you to implement locking using simple commands such as **SET**, **GET**, **DEL**, and **RPUSH** to handle flash sales. + +#. **Live video commenting** + + In live streaming, online user, gift ranking, and bullet comment data can be stored as sorted sets in Redis. + + For example, bullet comments can be returned using the **ZREVRANGEBYSCORE** command. The **ZPOPMAX** and **ZPOPMIN** commands in Redis 5.0 can further facilitate message processing. + +#. **Game leaderboard** + + In online gaming, the highest ranking players are displayed and updated in real time. The leaderboard ranking can be stored as sorted sets, which are easy to use with up to 20 commands. + +#. **Social networking comments** + + In web applications, queries of post comments often involve sorting by time in descending order. As comments pile up, sorting becomes less efficient. + + By using lists in Redis, a preset number of comments can be returned from the cache, rather than from disk, easing the load off the database and accelerating application responses. diff --git a/umn/source/service_overview/basic_concepts.rst b/umn/source/service_overview/basic_concepts.rst new file mode 100644 index 0000000..9d31772 --- /dev/null +++ b/umn/source/service_overview/basic_concepts.rst @@ -0,0 +1,50 @@ +:original_name: dcs-pd-200312004.html + +.. _dcs-pd-200312004: + +Basic Concepts +============== + +DCS Instance +------------ + +An instance is the minimum resource unit provided by DCS. + +DCS supports the Redis cache engine, and single-node, master/standby, and cluster instance types. For each instance type, multiple specifications are available. + +For details, see :ref:`DCS Instance Specifications ` and :ref:`DCS Instance Types `. + +Project +------- + +Projects are used to group and isolate OpenStack resources (computing resources, storage resources, and network resources). A project can be a department or a project team. Multiple projects can be created for one account. + +Replica +------- + +A replica is a node of a DCS instance. No replication indicates that the instance does not have a standby node. Master/Standby replication indicates that the instance has a standby node. For example, a master/standby DCS instance has a master/standby replication. Each node of a cluster DCS Redis instance has a master/standby replication. + +Maintenance Time Window +----------------------- + +The maintenance time window is the period when the DCS service team upgrade and maintain the instance. + +DCS instance maintenance takes place only once a quarter and does not interrupt services. Even so, you are advised to select a time period when the service demand is low. + +When creating an instance, you must specify a maintenance time window, which can be modified after the instance is created. + +For details, see: :ref:`Modifying Maintenance Time Window `. + +Cross-AZ Deployment +------------------- + +Master/Standby instances are deployed across different AZs with physically isolated power supplies and networks. Applications can also be deployed across AZs to achieve HA for both data and applications. + +When creating a master/standby or cluster DCS Redis instance, you can select a standby AZ for the standby node. + +.. _dcs-pd-200312004__en-us_topic_0145956240_section20999323134412: + +Shard +----- + +A shard is a management unit of a cluster DCS Redis instance. Each shard corresponds to a redis-server process. A cluster consists of multiple shards. Each shard has multiple slots. Data is distributedly stored in the slots. The use of shards increases cache capacity and concurrent connections. diff --git a/umn/source/service_overview/command_compatibility/command_restrictions_for_cluster_instances.rst b/umn/source/service_overview/command_compatibility/command_restrictions_for_cluster_instances.rst new file mode 100644 index 0000000..c312bde --- /dev/null +++ b/umn/source/service_overview/command_compatibility/command_restrictions_for_cluster_instances.rst @@ -0,0 +1,62 @@ +:original_name: dcs-pd-200813003.html + +.. _dcs-pd-200813003: + +Command Restrictions for Cluster Instances +========================================== + +Some Redis commands are supported by cluster DCS instances for multi-key operations in the same slot. For details, see :ref:`Table 1 `. + +.. _dcs-pd-200813003__table7589193113396: + +.. table:: **Table 1** Redis commands restricted in cluster DCS instances. + + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Category | Description | + +=================+===================================================================================================================================================================+ + | **Set** | | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SINTER | Returns the members of the set resulting from the intersection of all the given sets. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SINTERSTORE | Equal to **SINTER**, but instead of returning the result set, it is stored in *destination*. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SUNION | Returns the members of the set resulting from the union of all the given sets. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SUNIONSTORE | Equal to **SUNION**, but instead of returning the result set, it is stored in *destination*. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SDIFF | Returns the members of the set resulting from the difference between the first set and all the successive sets. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SDIFFSTORE | Equal to **SDIFF**, but instead of returning the result set, it is stored in *destination*. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | SMOVE | Moves **member** from the set at **source** to the set at *destination*. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | **Sorted Set** | | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | ZUNIONSTORE | Computes the union of *numkeys* sorted sets given by the specified keys. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | ZINTERSTORE | Computes the intersection of *numkeys* sorted sets given by the specified keys. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | **HyperLogLog** | | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | PFCOUNT | Returns the approximated cardinality computed by the HyperLogLog data structure stored at the specified variable. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | PFMERGE | Merges multiple HyperLogLog values into a unique value. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | **Keys** | | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | RENAME | Renames *key* to *newkey*. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | RENAMENX | Renames *key* to *newkey* if *newkey* does not yet exist. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | BITOP | Performs a bitwise operation between multiple keys (containing string values) and stores the result in the destination key. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | RPOPLPUSH | Returns and removes the last element (tail) of the list stored at source, and pushes the element at the first element (head) of the list stored at *destination*. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | **String** | | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | MSETNX | Merges multiple HyperLogLog values into a unique value. | + +-----------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +.. note:: + + While running commands that take a long time to run, such as **FLUSHALL**, DCS instances may not respond to other commands and may change to the faulty state. After the command finishes executing, the instance will return to normal. diff --git a/umn/source/service_overview/command_compatibility/index.rst b/umn/source/service_overview/command_compatibility/index.rst new file mode 100644 index 0000000..06191b1 --- /dev/null +++ b/umn/source/service_overview/command_compatibility/index.rst @@ -0,0 +1,24 @@ +:original_name: dcs-pd-200312003.html + +.. _dcs-pd-200312003: + +Command Compatibility +===================== + +- :ref:`Redis 3.0 Commands ` +- :ref:`Redis 4.0 Commands ` +- :ref:`Redis 5.0 Commands ` +- :ref:`Web CLI Commands ` +- :ref:`Command Restrictions for Cluster Instances ` +- :ref:`Other Command Usage Restrictions ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + redis_3.0_commands + redis_4.0_commands + redis_5.0_commands + web_cli_commands + command_restrictions_for_cluster_instances + other_command_usage_restrictions diff --git a/umn/source/service_overview/command_compatibility/other_command_usage_restrictions.rst b/umn/source/service_overview/command_compatibility/other_command_usage_restrictions.rst new file mode 100644 index 0000000..e33949b --- /dev/null +++ b/umn/source/service_overview/command_compatibility/other_command_usage_restrictions.rst @@ -0,0 +1,35 @@ +:original_name: dcs-pd-200813004.html + +.. _dcs-pd-200813004: + +Other Command Usage Restrictions +================================ + +This section describes restrictions on some Redis commands. + +KEYS Command +------------ + +In case of a large amount of cached data, running the **KEYS** command may block the execution of other commands for a long time or occupy exceptionally large memory. Therefore, when running the **KEYS** command, describe the exact pattern and do not use fuzzy **keys \***. Do not use the **KEYS** command in the production environment. Otherwise, the service running will be affected. + +Commands in the Server Group +---------------------------- + +- While running commands that take a long time to run, such as **FLUSHALL**, DCS instances may not respond to other commands and may change to the faulty state. After the command finishes executing, the instance will return to normal. +- When the **FLUSHDB** or **FLUSHALL** command is run, execution of other service commands may be blocked for a long time in case of a large amount of cached data. + +EVAL and EVALSHA Commands +------------------------- + +- When the **EVAL** or **EVALSHA** command is run, at least one key must be contained in the command parameter. Otherwise, the error message "ERR eval/evalsha numkeys must be bigger than zero in redis cluster mode" is displayed. +- When the **EVAL** or **EVALSHA** command is run, a cluster DCS Redis instance uses the first key to compute slots. Ensure that the keys to be operated in your code are in the same slot. For details, visit https://redis.io/commands. +- For the **EVAL** command: + + - You are advised to learn the Lua script features of Redis before running the **EVAL** command. For details, see https://redis.io/commands/eval. + - The execution timeout time of a Lua script is 5 seconds. Time-consuming statements such as long-time sleep and large loop statements should be avoided. + - When calling a Lua script, do not use random functions to specify keys. Otherwise, the execution results are inconsistent on the master and standby nodes. + +Other Restrictions +------------------ + +- The time limit for executing a Redis command is 15 seconds. To prevent other services from failing, a master/replica switchover will be triggered after the command execution times out. diff --git a/umn/source/service_overview/command_compatibility/redis_3.0_commands.rst b/umn/source/service_overview/command_compatibility/redis_3.0_commands.rst new file mode 100644 index 0000000..c8e6021 --- /dev/null +++ b/umn/source/service_overview/command_compatibility/redis_3.0_commands.rst @@ -0,0 +1,164 @@ +:original_name: dcs-pd-200713005.html + +.. _dcs-pd-200713005: + +Redis 3.0 Commands +================== + +DCS for Redis 3.0 is developed based on Redis 3.0.7 and is compatible with open-source protocols and commands. + +This section describes DCS for Redis 3.0's compatibility with Redis commands, including supported commands, disabled commands, unsupported scripts and commands of later Redis versions, and restrictions on command usage. For more information about the command syntax, visit the `Redis official website `__. + +DCS for Redis instances support most Redis commands, which are listed in :ref:`Commands Supported by DCS for Redis 3.0 `. Any client compatible with the Redis protocol can access DCS. + +- For security purposes, some Redis commands are disabled in DCS, as listed in :ref:`Commands Disabled by DCS for Redis 3.0 `. +- Some Redis commands are supported by cluster DCS instances for multi-key operations in the same slot. For details, see :ref:`Command Restrictions for Cluster Instances `. +- Some Redis commands have usage restrictions, which are described in :ref:`Other Command Usage Restrictions `. + +.. _dcs-pd-200713005__section2058132020426: + +Commands Supported by DCS for Redis 3.0 +--------------------------------------- + +The following lists commands supported by DCS for Redis 3.0. + +.. note:: + + - Commands available since later Redis versions are not supported by earlier-version instances. Run a command on redis-cli to check whether it is supported by DCS for Redis. If the message "(error) ERR unknown command" is returned, the command is not supported. + - The following commands listed in the tables are not supported by Proxy Cluster instances: + + - **List** group: **BLPOP**, **BRPOP**, and **BRPOPLRUSH** + - **CLIENT** commands in the **Server** group: **CLIENT KILL**, **CLIENT GETNAME**, **CLIENT LIST**, **CLIENT SETNAME**, **CLIENT PAUSE**, and **CLIENT REPLY**. + - **Server** group: **MONITOR** + - **Key** group: **RANDOMKE** (for old Proxy Cluster instances) + +.. table:: **Table 1** Commands supported by DCS Redis 3.0 instances 1 + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `String `__ | `Hash `__ | `List `__ | `Set `__ | `Sorted Set `__ | `Server `__ | + +==============================================+===============================================+===========================================+===========================================+=========================================+=======================================================+===============================================+ + | DEL | APPEND | HDEL | BLPOP | SADD | ZADD | FLUSHALL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | DUMP | BITCOUNT | HEXISTS | BRPOP | SCARD | ZCARD | FLUSHDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXISTS | BITOP | HGET | BRPOPLRUSH | SDIFF | ZCOUNT | DBSIZE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXPIRE | BITPOS | HGETALL | LINDEX | SDIFFSTORE | ZINCRBY | TIME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | MOVE | DECR | HINCRBY | LINSERT | SINTER | ZRANGE | INFO | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PERSIST | DECRBY | HINCRBYFLOAT | LLEN | SINTERSTORE | ZRANGEBYSCORE | KEYS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PTTL | GET | HKEYS | LPOP | SISMEMBER | ZRANK | CLIENT KILL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RANDOMKEY | GETRANGE | HMGET | LPUSHX | SMEMBERS | ZREMRANGEBYRANK | CLIENT LIST | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAME | GETSET | HMSET | LRANGE | SMOVE | ZREMRANGEBYCORE | CLIENT GETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAMENX | INCR | HSET | LREM | SPOP | ZREVRANGE | CLIENT SETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RESTORE | INCRBY | HSETNX | LSET | SRANDMEMBER | ZREVRANGEBYSCORE | CONFIG GET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SORT | INCRBYFLOAT | HVALS | LTRIM | SREM | ZREVRANK | MONITOR | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TTL | MGET | HSCAN | RPOP | SUNION | ZSCORE | SLOWLOG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TYPE | MSET | ``-`` | RPOPLPU | SUNIONSTORE | ZUNIONSTORE | ROLE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SCAN | MSETNX | ``-`` | RPOPLPUSH | SSCAN | ZINTERSTORE | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | OBJECT | PSETEX | ``-`` | RPUSH | ``-`` | ZSCAN | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SET | ``-`` | RPUSHX | ``-`` | ZRANGEBYLEX | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETBIT | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETEX | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETNX | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETRANGE | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | STRLEN | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + +.. table:: **Table 2** Commands supported by DCS Redis 3.0 instances 2 + + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | `HyperLoglog `__ | `Pub/Sub `__ | `Transactions `__ | `Connection `__ | `Scripting `__ | `Geo `__ | + +=========================================================+================================================+===========================================================+=======================================================+=====================================================+=========================================+ + | PFADD | PSUBSCRIBE | DISCARD | AUTH | EVAL | GEOADD | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | PFCOUNT | PUBLISH | EXEC | ECHO | EVALSHA | GEOHASH | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | PFMERGE | PUBSUB | MULTI | PING | SCRIPT EXISTS | GEOPOS | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | ``-`` | PUNSUBSCRIBE | UNWATCH | QUIT | SCRIPT FLUSH | GEODIST | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | ``-`` | SUBSCRIBE | WATCH | SELECT | SCRIPT KILL | GEORADIUS | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | ``-`` | UNSUBSCRIBE | ``-`` | ``-`` | SCRIPT LOAD | GEORADIUSBYMEMBER | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + +.. _dcs-pd-200713005__section144182915424: + +Commands Disabled by DCS for Redis 3.0 +-------------------------------------- + +The following lists commands disabled by DCS for Redis 3.0. + +.. table:: **Table 3** Redis commands disabled in single-node and master/standby Redis 3.0 instances + + +----------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `Server `__ | + +==============================================+===============================================+ + | MIGRATE | SLAVEOF | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SHUTDOWN | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | LASTSAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | DEBUG commands | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | COMMAND | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | BGSAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | BGREWRITEAOF | + +----------------------------------------------+-----------------------------------------------+ + +.. table:: **Table 4** Redis commands disabled in Proxy Cluster Redis 3.0 instances + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | `Keys `__ | `Server `__ | `List `__ | `Transactions `__ | `Connection `__ | `Cluster `__ | codis | + +==============================================+===============================================+===========================================+===========================================================+=======================================================+=================================================+==================+ + | MIGRATE | SLAVEOF | BLPOP | DISCARD | SELECT | CLUSTER | TIME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | MOVE | SHUTDOWN | BRPOP | EXEC | ``-`` | ``-`` | SLOTSINFO | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | LASTSAVE | BRPOPLPUSH | MULTI | ``-`` | ``-`` | SLOTSDEL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | DEBUG commands | ``-`` | UNWATCH | ``-`` | ``-`` | SLOTSMGRTSLOT | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | COMMAND | ``-`` | WATCH | ``-`` | ``-`` | SLOTSMGRTONE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | SAVE | ``-`` | ``-`` | ``-`` | ``-`` | SLOTSCHECK | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | BGSAVE | ``-`` | ``-`` | ``-`` | ``-`` | SLOTSMGRTTAGSLOT | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | BGREWRITEAOF | ``-`` | ``-`` | ``-`` | ``-`` | SLOTSMGRTTAGONE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | SYNC | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | PSYNC | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | MONITOR | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | CLIENT commands | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | OBJECT | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ + | ``-`` | ROLE | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-------------------------------------------------+------------------+ diff --git a/umn/source/service_overview/command_compatibility/redis_4.0_commands.rst b/umn/source/service_overview/command_compatibility/redis_4.0_commands.rst new file mode 100644 index 0000000..edbae5e --- /dev/null +++ b/umn/source/service_overview/command_compatibility/redis_4.0_commands.rst @@ -0,0 +1,167 @@ +:original_name: dcs-pd-200916001.html + +.. _dcs-pd-200916001: + +Redis 4.0 Commands +================== + +DCS for Redis 4.0 is developed based on Redis 4.0.14 and is compatible with open-source protocols and commands. + +This section describes DCS for Redis 4.0's compatibility with Redis commands, including supported and disabled commands. For more information about the command syntax, visit the `Redis official website `__. + +DCS for Redis instances support most Redis commands, which are listed in :ref:`Commands Supported by DCS for Redis 4.0 `. Any client compatible with the Redis protocol can access DCS. + +- For security purposes, some Redis commands are disabled in DCS, as listed in :ref:`Commands Disabled by DCS for Redis 4.0 `. +- Some Redis commands are supported by cluster DCS instances for multi-key operations in the same slot. For details, see :ref:`Command Restrictions for Cluster Instances `. +- Some Redis commands have usage restrictions, which are described in :ref:`Other Command Usage Restrictions `. + +.. _dcs-pd-200916001__section2058132020426: + +Commands Supported by DCS for Redis 4.0 +--------------------------------------- + +:ref:`Table 1 ` and :ref:`Table 2 ` list the Redis commands supported by single-node, master/standby, and Redis Cluster DCS Redis 4.0 instances. + +.. note:: + + - Commands available since later Redis versions are not supported by earlier-version instances. Run a command on redis-cli to check whether it is supported by DCS for Redis. If the message "(error) ERR unknown command" is returned, the command is not supported. + - For DCS Redis 4.0 instances in the Redis Cluster mode, ensure that all commands in a pipeline are executed on the same shard. + +.. _dcs-pd-200916001__table16556145351911: + +.. table:: **Table 1** Commands supported by single-node, master/standby, and Redis Cluster DCS Redis 4.0 instances (1) + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `String `__ | `Hash `__ | `List `__ | `Set `__ | `Sorted Set `__ | `Server `__ | + +==============================================+===============================================+===========================================+===========================================+=========================================+=======================================================+===============================================+ + | DEL | APPEND | HDEL | BLPOP | SADD | ZADD | FLUSHALL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | DUMP | BITCOUNT | HEXISTS | BRPOP | SCARD | ZCARD | FLUSHDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXISTS | BITOP | HGET | BRPOPLRUSH | SDIFF | ZCOUNT | DBSIZE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXPIRE | BITPOS | HGETALL | LINDEX | SDIFFSTORE | ZINCRBY | TIME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | MOVE | DECR | HINCRBY | LINSERT | SINTER | ZRANGE | INFO | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PERSIST | DECRBY | HINCRBYFLOAT | LLEN | SINTERSTORE | ZRANGEBYSCORE | KEYS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PTTL | GET | HKEYS | LPOP | SISMEMBER | ZRANK | CLIENT KILL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RANDOMKEY | GETRANGE | HMGET | LPUSHX | SMEMBERS | ZREMRANGEBYRANK | CLIENT LIST | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAME | GETSET | HMSET | LRANGE | SMOVE | ZREMRANGEBYCORE | CLIENT GETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAMENX | INCR | HSET | LREM | SPOP | ZREVRANGE | CLIENT SETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RESTORE | INCRBY | HSETNX | LSET | SRANDMEMBER | ZREVRANGEBYSCORE | CONFIG GET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SORT | INCRBYFLOAT | HVALS | LTRIM | SREM | ZREVRANK | MONITOR | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TTL | MGET | HSCAN | RPOP | SUNION | ZSCORE | SLOWLOG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TYPE | MSET | HSTRLEN | RPOPLPU | SUNIONSTORE | ZUNIONSTORE | ROLE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SCAN | MSETNX | HLEN | RPOPLPUSH | SSCAN | ZINTERSTORE | SWAPDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | OBJECT | PSETEX | ``-`` | RPUSH | SPOP | ZSCAN | MEMORY | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PEXPIRE | SET | ``-`` | RPUSHX | ``-`` | ZRANGEBYLEX | CONFIG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PEXPIREAT | SETBIT | ``-`` | LPUSH | ``-`` | ZLEXCOUNT | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETEX | ``-`` | ``-`` | ``-`` | ZREMRANGEBYSCORE | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETNX | ``-`` | ``-`` | ``-`` | ZREM | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETRANGE | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | STRLEN | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | BITFIELD | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + +.. _dcs-pd-200916001__table16968255165120: + +.. table:: **Table 2** Commands supported by single-node, master/standby, and Redis Cluster DCS Redis 4.0 instances (2) + + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | `HyperLoglog `__ | `Pub/Sub `__ | `Transactions `__ | `Connection `__ | `Scripting `__ | `Geo `__ | + +=========================================================+================================================+===========================================================+=======================================================+=====================================================+=========================================+ + | PFADD | PSUBSCRIBE | DISCARD | AUTH | EVAL | GEOADD | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | PFCOUNT | PUBLISH | EXEC | ECHO | EVALSHA | GEOHASH | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | PFMERGE | PUBSUB | MULTI | PING | SCRIPT EXISTS | GEOPOS | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | ``-`` | PUNSUBSCRIBE | UNWATCH | QUIT | SCRIPT FLUSH | GEODIST | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | ``-`` | SUBSCRIBE | WATCH | SELECT | SCRIPT KILL | GEORADIUS | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | ``-`` | UNSUBSCRIBE | ``-`` | ``-`` | SCRIPT LOAD | GEORADIUSBYMEMBER | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + +.. _dcs-pd-200916001__section144182915424: + +Commands Disabled by DCS for Redis 4.0 +-------------------------------------- + +The following lists commands disabled by DCS for Redis 4.0. + +.. table:: **Table 3** Redis commands disabled in single-node and master/standby Redis 4.0 instances + + +----------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `Server `__ | + +==============================================+===============================================+ + | MIGRATE | SLAVEOF | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SHUTDOWN | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | LASTSAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | DEBUG commands | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | COMMAND | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | BGSAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | BGREWRITEAOF | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SYNC | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | PSYNC | + +----------------------------------------------+-----------------------------------------------+ + +.. table:: **Table 4** Redis commands disabled in Redis Cluster Redis 4.0 instances + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | `Keys `__ | `Server `__ | `Cluster `__ | + +==============================================+===============================================+=================================================+ + | MIGRATE | SLAVEOF | CLUSTER MEET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | SHUTDOWN | CLUSTER FLUSHSLOTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | LASTSAVE | CLUSTER ADDSLOTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | DEBUG commands | CLUSTER DELSLOTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | COMMAND | CLUSTER SETSLOT | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | SAVE | CLUSTER BUMPEPOCH | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | BGSAVE | CLUSTER SAVECONFIG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | BGREWRITEAOF | CLUSTER FORGET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | SYNC | CLUSTER REPLICATE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | PSYNC | CLUSTER COUNT-FAILURE-REPORTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | ``-`` | CLUSTER FAILOVER | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | ``-`` | CLUSTER SET-CONFIG-EPOCH | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | ``-`` | CLUSTER RESET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ diff --git a/umn/source/service_overview/command_compatibility/redis_5.0_commands.rst b/umn/source/service_overview/command_compatibility/redis_5.0_commands.rst new file mode 100644 index 0000000..321bde2 --- /dev/null +++ b/umn/source/service_overview/command_compatibility/redis_5.0_commands.rst @@ -0,0 +1,179 @@ +:original_name: dcs-pd-200813002.html + +.. _dcs-pd-200813002: + +Redis 5.0 Commands +================== + +DCS for Redis 5.0 is developed based on Redis 5.0.9 and is compatible with open-source protocols and commands. + +This section describes DCS for Redis 5.0's compatibility with Redis commands, including supported and disabled commands. For more information about the command syntax, visit the `Redis official website `__. + +DCS for Redis instances support most Redis commands. Any client compatible with the Redis protocol can access DCS. + +- For security purposes, some Redis commands are disabled in DCS, as listed in :ref:`Commands Disabled by DCS for Redis 5.0 `. +- Some Redis commands are supported by cluster DCS instances for multi-key operations in the same slot. For details, see :ref:`Command Restrictions for Cluster Instances `. +- Some Redis commands have usage restrictions, which are described in :ref:`Other Command Usage Restrictions `. + +Commands Supported by DCS for Redis 5.0 +--------------------------------------- + +- :ref:`Table 1 ` and :ref:`Table 2 ` list commands supported by single-node, master/standby, and Redis Cluster DCS for Redis 5.0. + +.. note:: + + - Commands available since later Redis versions are not supported by earlier-version instances. Run a command on redis-cli to check whether it is supported by DCS for Redis. If the message "(error) ERR unknown command" is returned, the command is not supported. + - For DCS Redis 5.0 instances in the Redis Cluster mode, ensure that all commands in a pipeline are executed on the same shard. + +.. _dcs-pd-200813002__table16556145351911: + +.. table:: **Table 1** Commands supported by single-node, master/standby, and Redis Cluster DCS Redis 5.0 instances (1) + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `String `__ | `Hash `__ | `List `__ | `Set `__ | `Sorted Set `__ | `Server `__ | + +==============================================+===============================================+===========================================+===========================================+=========================================+=======================================================+===============================================+ + | DEL | APPEND | HDEL | BLPOP | SADD | ZADD | FLUSHALL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | DUMP | BITCOUNT | HEXISTS | BRPOP | SCARD | ZCARD | FLUSHDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXISTS | BITOP | HGET | BRPOPLRUSH | SDIFF | ZCOUNT | DBSIZE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXPIRE | BITPOS | HGETALL | LINDEX | SDIFFSTORE | ZINCRBY | TIME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | MOVE | DECR | HINCRBY | LINSERT | SINTER | ZRANGE | INFO | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PERSIST | DECRBY | HINCRBYFLOAT | LLEN | SINTERSTORE | ZRANGEBYSCORE | KEYS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PTTL | GET | HKEYS | LPOP | SISMEMBER | ZRANK | CLIENT KILL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RANDOMKEY | GETRANGE | HMGET | LPUSHX | SMEMBERS | ZREMRANGEBYRANK | CLIENT LIST | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAME | GETSET | HMSET | LRANGE | SMOVE | ZREMRANGEBYCORE | CLIENT GETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAMENX | INCR | HSET | LREM | SPOP | ZREVRANGE | CLIENT SETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RESTORE | INCRBY | HSETNX | LSET | SRANDMEMBER | ZREVRANGEBYSCORE | CONFIG GET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SORT | INCRBYFLOAT | HVALS | LTRIM | SREM | ZREVRANK | MONITOR | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TTL | MGET | HSCAN | RPOP | SUNION | ZSCORE | SLOWLOG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TYPE | MSET | HSTRLEN | RPOPLPU | SUNIONSTORE | ZUNIONSTORE | ROLE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SCAN | MSETNX | HLEN | RPOPLPUSH | SSCAN | ZINTERSTORE | SWAPDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | OBJECT | PSETEX | ``-`` | RPUSH | SPOP | ZSCAN | MEMORY | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PEXPIREAT | SET | ``-`` | RPUSHX | ``-`` | ZRANGEBYLEX | CONFIG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PEXPIRE | SETBIT | ``-`` | LPUSH | ``-`` | ZLEXCOUNT | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETEX | ``-`` | ``-`` | ``-`` | ZPOPMIN | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETNX | ``-`` | ``-`` | ``-`` | ZPOPMAX | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETRANGE | ``-`` | ``-`` | ``-`` | ZREMRANGEBYSCORE | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | STRLEN | ``-`` | ``-`` | ``-`` | ZREM | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | BITFIELD | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + +.. _dcs-pd-200813002__table16968255165120: + +.. table:: **Table 2** Commands supported by single-node, master/standby, and Redis Cluster DCS Redis 5.0 instances (2) + + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | `HyperLoglog `__ | `Pub/Sub `__ | `Transactions `__ | `Connection `__ | `Scripting `__ | `Geo `__ | `Stream `__ | + +=========================================================+================================================+===========================================================+=======================================================+=====================================================+=========================================+===============================================+ + | PFADD | PSUBSCRIBE | DISCARD | AUTH | EVAL | GEOADD | XACK | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | PFCOUNT | PUBLISH | EXEC | ECHO | EVALSHA | GEOHASH | XADD | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | PFMERGE | PUBSUB | MULTI | PING | SCRIPT EXISTS | GEOPOS | XCLAIM | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | PUNSUBSCRIBE | UNWATCH | QUIT | SCRIPT FLUSH | GEODIST | XDEL | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | SUBSCRIBE | WATCH | SELECT | SCRIPT KILL | GEORADIUS | XGROUP | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | UNSUBSCRIBE | ``-`` | ``-`` | SCRIPT LOAD | GEORADIUSBYMEMBER | XINFO | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XLEN | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XPENDING | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XRANGE | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XREAD | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XREADGROUP | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XREVRANGE | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | ``-`` | XTRIM | + +---------------------------------------------------------+------------------------------------------------+-----------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+-----------------------------------------------+ + +.. _dcs-pd-200813002__section144182915424: + +Commands Disabled by DCS for Redis 5.0 +-------------------------------------- + +The following lists commands disabled by DCS for Redis 5.0. + +.. table:: **Table 3** Redis commands disabled in single-node and master/standby Redis 5.0 instances + + +----------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `Server `__ | + +==============================================+===============================================+ + | MIGRATE | SLAVEOF | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SHUTDOWN | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | LASTSAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | DEBUG commands | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | COMMAND | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | BGSAVE | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | BGREWRITEAOF | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | SYNC | + +----------------------------------------------+-----------------------------------------------+ + | ``-`` | PSYNC | + +----------------------------------------------+-----------------------------------------------+ + +.. table:: **Table 4** Redis commands disabled in Redis Cluster Redis 5.0 instances + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | `Keys `__ | `Server `__ | `Cluster `__ | + +==============================================+===============================================+=================================================+ + | MIGRATE | SLAVEOF | CLUSTER MEET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | SHUTDOWN | CLUSTER FLUSHSLOTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | LASTSAVE | CLUSTER ADDSLOTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | DEBUG commands | CLUSTER DELSLOTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | COMMAND | CLUSTER SETSLOT | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | SAVE | CLUSTER BUMPEPOCH | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | BGSAVE | CLUSTER SAVECONFIG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | BGREWRITEAOF | CLUSTER FORGET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | SYNC | CLUSTER REPLICATE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | PSYNC | CLUSTER COUNT-FAILURE-REPORTS | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | ``-`` | CLUSTER FAILOVER | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | ``-`` | CLUSTER SET-CONFIG-EPOCH | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ + | ``-`` | ``-`` | CLUSTER RESET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------------+ diff --git a/umn/source/service_overview/command_compatibility/web_cli_commands.rst b/umn/source/service_overview/command_compatibility/web_cli_commands.rst new file mode 100644 index 0000000..cf465bb --- /dev/null +++ b/umn/source/service_overview/command_compatibility/web_cli_commands.rst @@ -0,0 +1,217 @@ +:original_name: dcs-pd-190826001.html + +.. _dcs-pd-190826001: + +Web CLI Commands +================ + +Web CLI is a command line tool provided on the DCS console. This section describes Web CLI's compatibility with Redis commands, including supported and disabled commands. For details about the command syntax, visit the `Redis official website `__. + +**Currently, only DCS for Redis 4.0 and 5.0 support Web CLI.** + +.. note:: + + - Keys and values cannot contain spaces. + - If the value is empty, **nil** is returned after the **GET** command is executed. + +Commands Supported by Web CLI +----------------------------- + +The following lists the commands supported when you use Web CLI. + +.. table:: **Table 1** Commands supported by Web CLI (1) + + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | `Keys `__ | `String `__ | `List `__ | `Set `__ | `Sorted Set `__ | `Server `__ | + +==============================================+===============================================+===========================================+=========================================+=======================================================+===============================================+ + | DEL | APPEND | RPUSH | SADD | ZADD | FLUSHALL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | OBJECT | BITCOUNT | RPUSHX | SCARD | ZCARD | FLUSHDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXISTS | BITOP | BRPOPLRUSH | SDIFF | ZCOUNT | DBSIZE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | EXPIRE | BITPOS | LINDEX | SDIFFSTORE | ZINCRBY | TIME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | MOVE | DECR | LINSERT | SINTER | ZRANGE | INFO | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PERSIST | DECRBY | LLEN | SINTERSTORE | ZRANGEBYSCORE | CLIENT KILL | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | PTTL | GET | LPOP | SISMEMBER | ZRANK | CLIENT LIST | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RANDOMKEY | GETRANGE | LPUSHX | SMEMBERS | ZREMRANGEBYRANK | CLIENT GETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAME | GETSET | LRANGE | SMOVE | ZREMRANGEBYCORE | CLIENT SETNAME | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | RENAMENX | INCR | LREM | SPOP | ZREVRANGE | CONFIG GET | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SCAN | INCRBY | LSET | SRANDMEMBER | ZREVRANGEBYSCORE | MONITOR | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | SORT | INCRBYFLOAT | LTRIM | SREM | ZREVRANK | SLOWLOG | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TTL | MGET | RPOP | SUNION | ZSCORE | ROLE | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | TYPE | MSET | RPOPLPU | SUNIONSTORE | ZUNIONSTORE | SWAPDB | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | MSETNX | RPOPLPUSH | SSCAN | ZINTERSTORE | MEMORY | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | PSETEX | ``-`` | SPOP | ZSCAN | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SET | ``-`` | ``-`` | ZRANGEBYLEX | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETBIT | ``-`` | ``-`` | ZLEXCOUNT | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETEX | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETNX | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | SETRANGE | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | STRLEN | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + | ``-`` | BITFIELD | ``-`` | ``-`` | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-------------------------------------------+-----------------------------------------+-------------------------------------------------------+-----------------------------------------------+ + +.. table:: **Table 2** Commands supported by Web CLI (2) + + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | `Hash `__ | `HyperLoglog `__ | `Connection `__ | `Scripting `__ | `Geo `__ | + +===========================================+=========================================================+=======================================================+=====================================================+=========================================+ + | HDEL | PFADD | AUTH | EVAL | GEOADD | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HEXISTS | PFCOUNT | ECHO | EVALSHA | GEOHASH | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HGET | PFMERGE | PING | SCRIPT EXISTS | GEOPOS | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HGETALL | ``-`` | QUIT | SCRIPT FLUSH | GEODIST | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HINCRBY | ``-`` | ``-`` | SCRIPT KILL | GEORADIUS | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HINCRBYFLOAT | ``-`` | ``-`` | SCRIPT LOAD | GEORADIUSBYMEMBER | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HKEYS | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HMGET | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HMSET | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HSET | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HSETNX | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HVALS | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HSCAN | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + | HSTRLEN | ``-`` | ``-`` | ``-`` | ``-`` | + +-------------------------------------------+---------------------------------------------------------+-------------------------------------------------------+-----------------------------------------------------+-----------------------------------------+ + +Commands Disabled in Web CLI +---------------------------- + +The following lists the commands disabled when you use Web CLI. + +.. table:: **Table 3** Redis commands disabled in Web CLI for single-node and master/standby instances (1) + + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | `Keys `__ | `Server `__ | `Transactions `__ | `Pub/Sub `__ | + +==============================================+===============================================+===========================================================+================================================+ + | MIGRATE | SLAVEOF | UNWATCH | PSUBSCRIBE | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | WAIT | SHUTDOWN | REPLICAOF | PUBLISH | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | DUMP | DEBUG commands | DISCARD | PUBSUB | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | RESTORE | CONFIG SET | EXEC | PUNSUBSCRIBE | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | CONFIG REWRITE | MULTI | SUBSCRIBE | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | CONFIG RESETSTAT | WATCH | UNSUBSCRIBE | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | SAVE | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | BGSAVE | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | BGREWRITEAOF | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | COMMAND | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | KEYS | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | MONITOR | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | SYNC | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | PSYNC | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + | ``-`` | ACL | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+------------------------------------------------+ + +.. table:: **Table 4** Redis commands disabled in Web CLI for single-node and master/standby instances (2) + + +-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | `List `__ | `Connection `__ | `Sorted Set `__ | + +===========================================+=======================================================+=======================================================+ + | BLPOP | SELECT | BZPOPMAX | + +-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | BRPOP | ``-`` | BZPOPMIN | + +-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | BLMOVE | ``-`` | BZMPOP | + +-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | BRPOPLPUSH | ``-`` | ``-`` | + +-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | BLMPOP | ``-`` | ``-`` | + +-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + +.. table:: **Table 5** Redis commands disabled in Web CLI for Redis Cluster instances (1) + + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | `Keys `__ | `Server `__ | `Transactions `__ | `Cluster `__ | + +==============================================+===============================================+===========================================================+=================================================+ + | MIGRATE | SLAVEOF | UNWATCH | CLUSTER MEET | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | WAIT | SHUTDOWN | REPLICAOF | CLUSTER FLUSHSLOTS | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | DUMP | DEBUG commands | DISCARD | CLUSTER ADDSLOTS | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | RESTORE | CONFIG SET | EXEC | CLUSTER DELSLOTS | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | CONFIG REWRITE | MULTI | CLUSTER SETSLOT | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | CONFIG RESETSTAT | WATCH | CLUSTER BUMPEPOCH | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | SAVE | ``-`` | CLUSTER SAVECONFIG | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | BGSAVE | ``-`` | CLUSTER FORGET | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | BGREWRITEAOF | ``-`` | CLUSTER REPLICATE | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | COMMAND | ``-`` | CLUSTER COUNT-FAILURE-REPORTS | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | KEYS | ``-`` | CLUSTER FAILOVER | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | MONITOR | ``-`` | CLUSTER SET-CONFIG-EPOCH | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | SYNC | ``-`` | CLUSTER RESET | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | PSYNC | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + | ``-`` | ACL | ``-`` | ``-`` | + +----------------------------------------------+-----------------------------------------------+-----------------------------------------------------------+-------------------------------------------------+ + +.. table:: **Table 6** Redis commands disabled in Web CLI for Redis Cluster instances (2) + + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | `Pub/Sub `__ | `List `__ | `Connection `__ | `Sorted Set `__ | + +================================================+===========================================+=======================================================+=======================================================+ + | PSUBSCRIBE | BLPOP | SELECT | BZPOPMAX | + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | PUBLISH | BRPOP | ``-`` | BZPOPMIN | + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | PUBSUB | BLMOVE | ``-`` | BZMPOP | + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | PUNSUBSCRIBE | BRPOPLPUSH | ``-`` | ``-`` | + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | SUBSCRIBE | BLMPOP | ``-`` | ``-`` | + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ + | UNSUBSCRIBE | ``-`` | ``-`` | ``-`` | + +------------------------------------------------+-------------------------------------------+-------------------------------------------------------+-------------------------------------------------------+ diff --git a/umn/source/service_overview/comparing_dcs_and_open-source_cache_services.rst b/umn/source/service_overview/comparing_dcs_and_open-source_cache_services.rst new file mode 100644 index 0000000..08b1ece --- /dev/null +++ b/umn/source/service_overview/comparing_dcs_and_open-source_cache_services.rst @@ -0,0 +1,49 @@ +:original_name: dcs-pd-0326003.html + +.. _dcs-pd-0326003: + +Comparing DCS and Open-Source Cache Services +============================================ + +DCS supports single-node, master/standby, and cluster instances, ensuring high read/write performance and fast data access. It also supports various instance management operations to facilitate your O&M. With DCS, you only need to focus on the service logic, without concerning about the deployment, monitoring, scaling, security, and fault recovery issues. + +DCS is compatible with open-source Redis, and can be customized based on your requirements. This renders DCS unique features in addition to the advantages of open-source cache databases. + +DCS for Redis vs. Open-Source Redis +----------------------------------- + +.. table:: **Table 1** Differences between DCS for Redis and open-source Redis + + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Feature | Open-Source Redis | DCS for Redis | + +========================+==================================================================================================================================================+============================================================================================================================================================================+ + | Service deployment | Requires 0.5 to 2 days to prepare servers. | - Creates a Redis 3.0 instance in 5 to 15 minutes. | + | | | - Creates a containerized Redis 4.0 or 5.0 instance within 8 seconds. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Version | ``-`` | Deeply engaged in the open-source community and supports the latest Redis version. Currently, Redis 3.0, 4.0, and 5.0 are supported. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Security | Network and server safety is the user's responsibility. | - Network security is ensured using VPCs and security groups. | + | | | - Data reliability is ensured by data replication and scheduled backup. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Performance | ``-`` | 100,000 QPS per node | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Monitoring | Provides only basic statistics. | Provides more than 30 monitoring metrics and customizable alarm threshold and policies. | + | | | | + | | | - Various metrics | + | | | | + | | | - External metrics include the number of commands, concurrent operations, connections, clients, and denied connections. | + | | | - Resource usage metrics include CPU usage, physical memory usage, network input throughput, and network output throughput. | + | | | - Internal metrics include instance capacity usage, as well as the number of keys, expired keys, PubSub channels, PubSub patterns, keyspace hits, and keyspace misses. | + | | | | + | | | - Custom alarm thresholds and policies for different metrics to help identify service faults. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Backup and restoration | Supported | - Supports scheduled and manual backup. Backup files can be downloaded. | + | | | - Backup data can be restored on the console. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Parameter management | No visualized parameter management | - Visualized parameter management is supported on the console. | + | | | - Configuration parameters can be modified online. | + | | | - Data can be accessed and modified on the console. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Scale-up | Interrupts services and involves a complex procedure from modifying the server RAM to modifying Redis memory and restarting the OS and services. | - Supports online scale-up and scale-down without interrupting services. | + | | | - Specifications can be scaled up or down within the available range based on service requirements. | + +------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ diff --git a/umn/source/service_overview/comparing_redis_versions.rst b/umn/source/service_overview/comparing_redis_versions.rst new file mode 100644 index 0000000..59ef6d3 --- /dev/null +++ b/umn/source/service_overview/comparing_redis_versions.rst @@ -0,0 +1,40 @@ +:original_name: RedisDifference.html + +.. _RedisDifference: + +Comparing Redis Versions +======================== + +When creating a DCS Redis instance, you can select the cache engine version and the instance type. + +- **Version** + + DCS supports Redis 3.0, 4.0, and 5.0. The following table describes the differences between these versions. + + .. table:: **Table 1** Differences between Redis versions + + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Feature | Redis 3.0 | Redis 4.0 and Redis 5.0 | + +========================================+=======================================================+==================================================================================================================================================================================================+ + | Instance deployment mode | Based on VMs | Containerized based on physical servers | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Time required for creating an instance | 3-15 minutes, or 10-30 minutes for cluster instances. | 8 seconds | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | QPS | 100,000 QPS per node | 100,000 QPS per node | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Instance type | Single-node, master/standby, and Proxy Cluster | Single-node, master/standby and Redis Cluster | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Instance total memory | Ranges from 2 GB, 4 GB, 8 GB, to 1024 GB. | Regular specifications range from 2 GB, 4 GB, 8 GB, to 1024 GB. Small specifications, such as 128 MB, 256 MB, 512 MB, and 1 GB, are also available for single-node and master/standby instances. | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Scale-up or scale-down | Online scale-up and scale-down | Online scale-up and scale-down | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Backup and restoration | Supported for master/standby and cluster instances | Supported for master/standby and cluster instances | + +----------------------------------------+-------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + + .. note:: + + The underlying architectures vary by Redis version. Once a Redis version is chosen, it cannot be changed. For example, you cannot upgrade a DCS Redis 3.0 instance to Redis 4.0 or 5.0. If you require a higher Redis version, create a new instance that meets your requirements and then migrate data from the old instance to the new one. + +- **Instance type** + + Select from single-node, master/standby, and cluster types. For details about their architectures and application scenarios, see :ref:`DCS Instance Types `. diff --git a/umn/source/service_overview/dcs_instance_specifications/index.rst b/umn/source/service_overview/dcs_instance_specifications/index.rst new file mode 100644 index 0000000..1b999f3 --- /dev/null +++ b/umn/source/service_overview/dcs_instance_specifications/index.rst @@ -0,0 +1,16 @@ +:original_name: en-us_topic_0054235835.html + +.. _en-us_topic_0054235835: + +DCS Instance Specifications +=========================== + +- :ref:`Redis 3.0 Instance Specifications ` +- :ref:`Redis 4.0 and 5.0 Instance Specifications ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + redis_3.0_instance_specifications + redis_4.0_and_5.0_instance_specifications diff --git a/umn/source/service_overview/dcs_instance_specifications/redis_3.0_instance_specifications.rst b/umn/source/service_overview/dcs_instance_specifications/redis_3.0_instance_specifications.rst new file mode 100644 index 0000000..6375186 --- /dev/null +++ b/umn/source/service_overview/dcs_instance_specifications/redis_3.0_instance_specifications.rst @@ -0,0 +1,94 @@ +:original_name: dcs-pd-0916001.html + +.. _dcs-pd-0916001: + +Redis 3.0 Instance Specifications +================================= + +This section describes DCS Redis 3.0 instance specifications, including the total memory, available memory, maximum number of connections allowed, maximum/assured bandwidth, and reference performance. + +The following metrics are related to the instance specifications: + +- Used memory: You can check the memory usage of an instance by viewing the **Memory Usage** and **Used Memory** metrics. +- Maximum connections: The maximum number of connections allowed is the maximum number of clients that can be connected to an instance. To check the number of connections to an instance, view the **Connected Clients** metric. +- QPS represents queries per second, which is the number of commands processed per second. + + .. note:: + + - Single-node, master/standby, and Proxy Cluster types are available. + - Only the x86 architecture is supported. The Arm architecture is not supported. + +Single-Node Instances +--------------------- + +For each single-node DCS Redis instance, the available memory is less than the total memory because some memory is reserved for system overheads, as shown in :ref:`Table 1 `. + +.. _dcs-pd-0916001__table2399016819: + +.. table:: **Table 1** Specifications of single-node DCS Redis 3.0 instances + + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | Total Memory | Available Memory | Max. Connections (Default/Limit) | Assured/Maximum Bandwidth | Reference Performance | + | | | | | | + | (GB) | (GB) | (Count) | (Mbit/s) | (QPS) | + +==============+==================+==================================+===========================+=======================+ + | 2 | 1.5 | 5000/50,000 | 42/512 | 50,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 4 | 3.2 | 5000/50,000 | 64/1536 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 8 | 6.8 | 5000/50,000 | 64/1536 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 16 | 13.6 | 5000/50,000 | 85/3072 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 32 | 27.2 | 5000/50,000 | 85/3072 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 64 | 58.2 | 5000/60,000 | 128/5120 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + +Master/Standby Instances +------------------------ + +For each master/standby DCS Redis instance, the available memory is less than that of a single-node DCS Redis instance because some memory is reserved for data persistence, as shown in :ref:`Table 2 `. The available memory of a master/standby instance can be adjusted to support background tasks such as data persistence and master/standby synchronization. + +.. _dcs-pd-0916001__table1521627154210: + +.. table:: **Table 2** Specifications of master/standby DCS Redis 3.0 instances + + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | Total Memory | Available Memory | Max. Connections (Default/Limit) | Assured/Maximum Bandwidth | Reference Performance | + | | | | | | + | (GB) | (GB) | (Count) | (Mbit/s) | (QPS) | + +==============+==================+==================================+===========================+=======================+ + | 2 | 1.5 | 5000/50,000 | 42/512 | 50,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 4 | 3.2 | 5000/50,000 | 64/1536 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 8 | 6.4 | 5000/50,000 | 64/1536 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 16 | 12.8 | 5000/50,000 | 85/3072 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 32 | 25.6 | 5000/50,000 | 85/3072 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 64 | 51.2 | 5000/60,000 | 128/5120 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + +Proxy Cluster Instances +----------------------- + +In addition to larger memory, cluster instances feature more connections allowed, higher bandwidth allowed, and more QPS than single-node and master/standby instances. + +.. table:: **Table 3** Specifications of Proxy Cluster DCS Redis 3.0 instances + + +---------------+------------------+----------------------------------+---------------------------+-----------------------+ + | Specification | Available Memory | Max. Connections (Default/Limit) | Assured/Maximum Bandwidth | Reference Performance | + | | | | | | + | (GB) | (GB) | (Count) | (Mbit/s) | (QPS) | + +===============+==================+==================================+===========================+=======================+ + | 64 | 64 | 90,000/90,000 | 600/5120 | 500,000 | + +---------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 128 | 128 | 180,000/180,000 | 600/5120 | 500,000 | + +---------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 256 | 256 | 240,000/240,000 | 600/5120 | 500,000 | + +---------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 512 | 512 | 480,000/480,000 | 600/5120 | 500,000 | + +---------------+------------------+----------------------------------+---------------------------+-----------------------+ diff --git a/umn/source/service_overview/dcs_instance_specifications/redis_4.0_and_5.0_instance_specifications.rst b/umn/source/service_overview/dcs_instance_specifications/redis_4.0_and_5.0_instance_specifications.rst new file mode 100644 index 0000000..4b6daef --- /dev/null +++ b/umn/source/service_overview/dcs_instance_specifications/redis_4.0_and_5.0_instance_specifications.rst @@ -0,0 +1,161 @@ +:original_name: dcs-pd-0916002.html + +.. _dcs-pd-0916002: + +Redis 4.0 and 5.0 Instance Specifications +========================================= + +This section describes DCS Redis 4.0 and 5.0 instance specifications, including the total memory, available memory, maximum number of connections allowed, maximum/assured bandwidth, and reference performance. + +The following metrics are related to the instance specifications: + +- Used memory: You can check the memory usage of an instance by viewing the **Memory Usage** and **Used Memory** metrics. +- Maximum connections: The maximum number of connections allowed is the maximum number of clients that can be connected to an instance. To check the number of connections to an instance, view the **Connected Clients** metric. +- QPS represents queries per second, which is the number of commands processed per second. +- Bandwidth: You can view the **Flow Control Times** metric to check whether the bandwidth has exceeded the limit. + +.. note:: + + - DCS Redis 4.0 and 5.0 instances are available in single-node, master/standby, and Redis Cluster types. + - Only the x86 architecture is supported. The Arm architecture is not supported. + +Single-Node Instances +--------------------- + +.. table:: **Table 1** Specifications of single-node DCS Redis 4.0 or 5.0 instances + + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | Total Memory | Available Memory | Max. Connections (Default/Limit) | Assured/Maximum Bandwidth | Reference Performance | + | | | | | | + | (GB) | (GB) | (Count) | (Mbit/s) | (QPS) | + +==============+==================+==================================+===========================+=======================+ + | 0.125 | 0.125 | 10,000/10,000 | 40/40 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 0.25 | 0.25 | 10,000/10,000 | 80/80 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 0.5 | 0.5 | 10,000/10,000 | 80/80 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 1 | 1 | 10,000/50,000 | 80/80 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 2 | 2 | 10,000/50,000 | 128/128 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 4 | 4 | 10,000/50,000 | 192/192 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 8 | 8 | 10,000/50,000 | 192/192 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 16 | 16 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 24 | 24 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 32 | 32 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 48 | 48 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 64 | 64 | 10,000/50,000 | 384/384 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + +Master/Standby Instances +------------------------ + +.. table:: **Table 2** Specifications of master/standby DCS Redis 4.0 or 5.0 instances + + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | Total Memory | Available Memory | Max. Connections (Default/Limit) | Assured/Maximum Bandwidth | Reference Performance | + | | | | | | + | (GB) | (GB) | (Count) | (Mbit/s) | (QPS) | + +==============+==================+==================================+===========================+=======================+ + | 0.125 | 0.125 | 10,000/10,000 | 40/40 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 0.25 | 0.25 | 10,000/10,000 | 80/80 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 0.5 | 0.5 | 10,000/10,000 | 80/80 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 1 | 1 | 10,000/50,000 | 80/80 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 2 | 2 | 10,000/50,000 | 128/128 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 4 | 4 | 10,000/50,000 | 192/192 | 80,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 8 | 8 | 10,000/50,000 | 192/192 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 16 | 16 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 24 | 24 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 32 | 32 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 48 | 48 | 10,000/50,000 | 256/256 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + | 64 | 64 | 10,000/50,000 | 384/384 | 100,000 | + +--------------+------------------+----------------------------------+---------------------------+-----------------------+ + +Redis Cluster Instances +----------------------- + +.. table:: **Table 3** Specifications of Redis Cluster DCS Redis 4.0 or 5.0 instances + + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | Specification | Available Memory | Shards (Master Nodes) | Max. Connections (Default/Limit) | Assured/Maximum Bandwidth | Reference Performance | + | | | | | | | + | (GB) | (GB) | | (Count) | (Mbit/s) | (QPS) | + +===============+==================+=======================+==================================+===========================+=======================+ + | 4 | 4 | 3 | 30,000 | 2304/2304 | 240,000 | + | | | | | | | + | | | | /150,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 8 | 8 | 3 | 30,000 | 2304/2304 | 240,000 | + | | | | | | | + | | | | /150,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 16 | 16 | 3 | 30,000 | 2304/2304 | 240,000 | + | | | | | | | + | | | | /150,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 24 | 24 | 3 | 30,000 | 2304/2304 | 300,000 | + | | | | | | | + | | | | /150,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 32 | 32 | 3 | 30,000 | 2304/2304 | 300,000 | + | | | | | | | + | | | | /150,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 48 | 48 | 6 | 60,000 | 4608/4608 | > 300,000 | + | | | | | | | + | | | | /300,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 64 | 64 | 8 | 80,000 | 6144/6144 | 500,000 | + | | | | | | | + | | | | /400,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 96 | 96 | 12 | 120,000 | 9216/9216 | > 500,000 | + | | | | | | | + | | | | /600,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 128 | 128 | 16 | 160,000 | 12,288/12,288 | 1,000,000 | + | | | | | | | + | | | | /800,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 192 | 192 | 24 | 240,000 | 18,432/18,432 | > 1,000,000 | + | | | | | | | + | | | | /1,200,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 256 | 256 | 32 | 320,000 | 24,576/24,576 | > 2,000,000 | + | | | | | | | + | | | | /1,600,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 384 | 384 | 48 | 480,000 | 36,864/36,864 | > 2,000,000 | + | | | | | | | + | | | | /2,400,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 512 | 512 | 64 | 640,000 | 49,152/49,152 | > 2,000,000 | + | | | | | | | + | | | | /3,200,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 768 | 768 | 96 | 960,000 | 73,728/73,728 | > 2,000,000 | + | | | | | | | + | | | | /4,800,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ + | 1024 | 1024 | 128 | 1,280,000 | 98,304/98,304 | > 2,000,000 | + | | | | | | | + | | | | /6,400,000 | | | + +---------------+------------------+-----------------------+----------------------------------+---------------------------+-----------------------+ diff --git a/umn/source/service_overview/dcs_instance_types/index.rst b/umn/source/service_overview/dcs_instance_types/index.rst new file mode 100644 index 0000000..d82e661 --- /dev/null +++ b/umn/source/service_overview/dcs_instance_types/index.rst @@ -0,0 +1,20 @@ +:original_name: dcs-pd-200312001.html + +.. _dcs-pd-200312001: + +DCS Instance Types +================== + +- :ref:`Single-Node Redis ` +- :ref:`Master/Standby Redis ` +- :ref:`Proxy Cluster Redis ` +- :ref:`Redis Cluster ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + single-node_redis + master_standby_redis + proxy_cluster_redis + redis_cluster diff --git a/umn/source/service_overview/dcs_instance_types/master_standby_redis.rst b/umn/source/service_overview/dcs_instance_types/master_standby_redis.rst new file mode 100644 index 0000000..70f89b2 --- /dev/null +++ b/umn/source/service_overview/dcs_instance_types/master_standby_redis.rst @@ -0,0 +1,83 @@ +:original_name: CacheMasterSlave.html + +.. _CacheMasterSlave: + +Master/Standby Redis +==================== + +This section describes master/standby DCS Redis instances. Three Redis versions are available for master/standby DCS Redis instances: Redis 3.0, Redis 4.0, and Redis 5.0. + +.. note:: + + You cannot upgrade the Redis version for an instance. For example, a master/standby DCS Redis 3.0 instance cannot be upgraded to a master/standby DCS Redis 4.0 or 5.0 instance. If your service requires the features of higher Redis versions, create a DCS Redis instance of a higher version and then migrate data from the old instance to the new one. + +Features +-------- + +Master/Standby DCS instances have higher availability and reliability than single-node DCS instances. + +Master/Standby DCS instances have the following features: + +#. **Data persistence and high reliability** + + By default, data persistence is enabled by both the master and the standby node of a master/standby instance. + + The standby node of a DCS Redis instance is invisible to you. Only the master node provides data read/write operations. + +#. **Data synchronization** + + Data in the master and standby nodes is kept consistent through incremental synchronization. + + .. note:: + + After recovering from a network exception or node fault, master/standby instances perform a full synchronization to ensure data consistency. + +#. **Automatic master/standby switchover** + + If the master node becomes faulty, the standby node takes over within 30 seconds, without requiring any service interruptions or manual operations. + +#. **DR policies** + + Each master/standby instance can be deployed across AZs with physically isolated power supplies and networks. Applications can also be deployed across AZs to achieve high availability for both data and applications. + +Architecture +------------ + +:ref:`Figure 1 ` shows the architecture of master/standby DCS Redis instances. + +.. note:: + + To access a DCS Redis 3.0 instance, you must use port 6379. To access a DCS Redis 4.0 or 5.0 instance, you can customize the port. If no port is specified, the default port 6379 will be used. In the following architecture, port 6379 is used. If you have customized a port, replace **6379** with the actual port. + +.. _cachemasterslave__fig14477142816340: + +.. figure:: /_static/images/en-us_image_0296786164.png + :alt: **Figure 1** Master/Standby DCS instance architecture + + **Figure 1** Master/Standby DCS instance architecture + +Architecture description: + +- **VPC** + + All server nodes of the instance run in the same VPC. + + .. note:: + + For intra-VPC access, the client and the instance must be in the same VPC with specified security group rule configurations. + + For details, see :ref:`Security Group Configurations `. + +- **Application** + + The Redis client of the instance, which is the application running on the ECS. + + DCS Redis instances are compatible with the Redis protocol, and can be accessed through open-source clients. For details about accessing DCS instances, see :ref:`Accessing an Instance `. + +- **DCS instance** + + Indicates a master/standby DCS instance which has a master node and a standby node. By default, data persistence is enabled and data is synchronized between the two nodes. + + DCS monitors the availability of the instance in real time. If the master node becomes faulty, the standby node becomes the master node and resumes service provisioning. + + DCS Redis instances are accessed through port 6379 by default. diff --git a/umn/source/service_overview/dcs_instance_types/proxy_cluster_redis.rst b/umn/source/service_overview/dcs_instance_types/proxy_cluster_redis.rst new file mode 100644 index 0000000..511171a --- /dev/null +++ b/umn/source/service_overview/dcs_instance_types/proxy_cluster_redis.rst @@ -0,0 +1,78 @@ +:original_name: CacheCluster.html + +.. _CacheCluster: + +Proxy Cluster Redis +=================== + +DCS provides two types of cluster Redis instances: Proxy Cluster and Redis Cluster. Proxy Cluster uses Linux Virtual Server (LVS) and proxies. Redis Cluster is the native distributed implementation of Redis. Proxy Cluster instances are compatible with Redis 3.0, while Redis Cluster instances are compatible with Redis 4.0 and 5.0. + +This section describes Proxy Cluster DCS Redis 3.0 instances. + +.. note:: + + - A Proxy Cluster instance can be connected in the same way that a single-node or master/standby instance is connected, without any special settings on the client. You can use the IP address or domain name of the instance, and do not need to know or use the proxy or shard addresses. + +Proxy Cluster DCS Redis 3.0 Instances +------------------------------------- + +Proxy Cluster DCS Redis 3.0 instances are compatible with `codis `__. The specifications range from 64 GB to 1024 GB, meeting requirements for **millions of concurrent connections** and **massive data cache**. Distributed data storage and access is implemented by DCS, without requiring development or maintenance. + +Each Proxy Cluster instance consists of load balancers, proxies, cluster managers, and :ref:`shards `. + +.. table:: **Table 1** Specifications of Proxy Cluster DCS Redis 3.0 instances + + ============ ======= ====== + Total Memory Proxies Shards + ============ ======= ====== + 64 GB 3 8 + 128 GB 6 16 + 256 GB 8 32 + 512 GB 16 64 + ============ ======= ====== + + +.. figure:: /_static/images/en-us_image_0296786822.png + :alt: **Figure 1** Proxy Cluster DCS Redis instance architecture + + **Figure 1** Proxy Cluster DCS Redis instance architecture + +Architecture description: + +- **VPC** + + All server nodes of the instance run in the same VPC. + + .. note:: + + For intra-VPC access, the client and the instance must be in the same VPC with specified security group rule configurations. + + For details, see :ref:`Security Group Configurations `. + +- **Application** + + The client used to access the instance. + + DCS Redis instances can be accessed through open-source clients. For details about accessing DCS instances, see :ref:`Accessing an Instance `. + +- **LB-M/LB-S** + + The load balancers, which are deployed in master/standby HA mode. The connection addresses (**IP address:Port**) of the cluster DCS Redis instance are the addresses of the load balancers. + +- **Proxy** + + The proxy server used to achieve high availability and process high-concurrency client requests. + + You can connect to a Proxy Cluster instance at the IP addresses of its proxies. + +- **Redis shard** + + A shard of the cluster. + + Each shard consists of a pair of master/standby nodes. If the master node becomes faulty, the standby node automatically takes over cluster services. + + If both the master and standby nodes of a shard are faulty, the cluster can still provide services but the data on the faulty shard is inaccessible. + +- **Cluster manager** + + The cluster configuration managers, which store configurations and partitioning policies of the cluster. You cannot modify the information about the configuration managers. diff --git a/umn/source/service_overview/dcs_instance_types/redis_cluster.rst b/umn/source/service_overview/dcs_instance_types/redis_cluster.rst new file mode 100644 index 0000000..43462b8 --- /dev/null +++ b/umn/source/service_overview/dcs_instance_types/redis_cluster.rst @@ -0,0 +1,57 @@ +:original_name: CacheProxy.html + +.. _CacheProxy: + +Redis Cluster +============= + +This section describes Redis Cluster DCS Redis 4.0 and 5.0 instances. + +Redis Cluster DCS Redis 4.0 and 5.0 Instances +--------------------------------------------- + +The Redis Cluster instance type provided by DCS is compatible with the `native Redis Cluster `__, which uses smart clients and a distributed architecture to perform sharding. + +:ref:`Table 1 ` lists the shard specification for different instance specifications. + +**Specification per shard=Instance specification/Number of shards**. For example, if a 48 GB instance has 6 shards, the specification of each shard is 48 GB/6 = 8 GB. + +.. _cacheproxy__table3552324111: + +.. table:: **Table 1** Specifications of Redis Cluster DCS instances + + =========================== ====== + Total Memory Shards + =========================== ====== + 4 GB/8 GB/16 GB/24 GB/32 GB 3 + 48 GB 6 + 64 GB 8 + 96 GB 12 + 128 GB 16 + 192 GB 24 + 256 GB 32 + 384 GB 48 + 512 GB 64 + 768 GB 96 + 1024 GB 128 + =========================== ====== + +- Distributed architecture + + Any node in a Redis Cluster can receive requests. Received requests are then redirected to the right node for processing. Each node consists of a subset of one master and one (by default) or multiple replicas. The master or replica roles are determined through an election algorithm. + + + .. figure:: /_static/images/en-us_image_0277578727.png + :alt: **Figure 1** Distributed architecture of Redis Cluster + + **Figure 1** Distributed architecture of Redis Cluster + +- Presharding + + There are 16,384 hash slots in each Redis Cluster. The mapping between hash slots and Redis nodes is stored in Redis Servers. To compute what is the hash slot of a given key, simply take the CRC16 of the key modulo 16384. Example command output + + + .. figure:: /_static/images/en-us_image_0000001280621500.png + :alt: **Figure 2** Redis Cluster presharding + + **Figure 2** Redis Cluster presharding diff --git a/umn/source/service_overview/dcs_instance_types/single-node_redis.rst b/umn/source/service_overview/dcs_instance_types/single-node_redis.rst new file mode 100644 index 0000000..cc759d4 --- /dev/null +++ b/umn/source/service_overview/dcs_instance_types/single-node_redis.rst @@ -0,0 +1,69 @@ +:original_name: CacheSingleNode.html + +.. _CacheSingleNode: + +Single-Node Redis +================= + +Three Redis versions are available for single-node DCS Redis instances: Redis 3.0, Redis 4.0, and Redis 5.0. + +Features +-------- + +#. Low system overhead and high QPS + + Single-node instances do not support data synchronization or data persistence, reducing system overhead and supporting higher concurrency. QPS of single-node DCS Redis instances reaches up to 100,000. + +#. Process monitoring and automatic fault recovery + + With an HA monitoring mechanism, if a single-node DCS instance becomes faulty, a new process is started within 30 seconds to resume service provisioning. + +#. Out-of-the-box usability and no data persistence + + Single-node DCS instances can be used out of the box because they do not involve data loading. If your service requires high QPS, you can warm up the data beforehand to avoid strong concurrency impact on the backend database. + +#. Low-cost and suitable for development and testing + + Single-node instances are 40% cheaper than master/standby DCS instances, suitable for setting up development or testing environments. + +In summary, single-node DCS instances support highly concurrent read/write operations, but do not support data persistence. Data will be deleted after instances are restarted. They are suitable for scenarios which do not require data persistence, such as database front-end caching, to accelerate access and ease the concurrency load off the backend. If the desired data does not exist in the cache, requests will go to the database. When restarting the service or the DCS instance, you can pre-generate cache data from the disk database to relieve pressure on the backend during startup. + +Architecture +------------ + +:ref:`Figure 1 ` shows the architecture of single-node DCS Redis instances. + +.. note:: + + To access a DCS Redis 3.0 instance, you must use port 6379. To access a DCS Redis 4.0 or 5.0 instance, you can customize the port. If no port is specified, the default port 6379 will be used. In the following architecture, port 6379 is used. If you have customized a port, replace **6379** with the actual port. + +.. _cachesinglenode__fig15457185394718: + +.. figure:: /_static/images/en-us_image_0296784660.png + :alt: **Figure 1** Single-node DCS Redis instance architecture + + **Figure 1** Single-node DCS Redis instance architecture + +Architecture description: + +- **VPC** + + All server nodes of the instance run in the same VPC. + + .. note:: + + For intra-VPC access, the client and the instance must be in the same VPC with specified security group rule configurations. + + For details, see :ref:`Security Group Configurations `. + +- **Application** + + The client of the instance, which is the application running on an Elastic Cloud Server (ECS). + + DCS Redis instances are compatible with the Redis protocol, and can be accessed through open-source clients. For details about accessing DCS instances, see :ref:`Accessing an Instance `. + +- **DCS instance** + + A single-node DCS instance, which has only one node and one Redis process. + + DCS monitors the availability of the instance in real time. If the Redis process becomes faulty, DCS starts a new process to resume service provisioning. diff --git a/umn/source/service_overview/ha_and_dr_policies.rst b/umn/source/service_overview/ha_and_dr_policies.rst new file mode 100644 index 0000000..96d1aec --- /dev/null +++ b/umn/source/service_overview/ha_and_dr_policies.rst @@ -0,0 +1,64 @@ +:original_name: GlobalDRPolicy.html + +.. _GlobalDRPolicy: + +HA and DR Policies +================== + +Whether you use DCS as the frontend cache or backend data store, DCS is always ready to ensure data reliability and service availability. The following figure shows the evolution of DCS DR architectures. + + +.. figure:: /_static/images/en-us_image_0266235346.png + :alt: **Figure 1** DCS DR architecture evolution + + **Figure 1** DCS DR architecture evolution + +To meet the reliability requirements of your data and services, you can choose to deploy your DCS instance within a single AZ or across AZs. + +Single-AZ HA +------------ + +Single-AZ deployment means deploying an instance within a physical equipment room. DCS provides process/service HA, data persistence, and hot standby DR policies for different types of DCS instances. + +**Single-node DCS instance**: When DCS detects a process fault, a new process is started to ensure service HA. + + +.. figure:: /_static/images/en-us_image_0266235448.png + :alt: **Figure 2** HA for a single-node DCS instance deployed within an AZ + + **Figure 2** HA for a single-node DCS instance deployed within an AZ + +**Master/Standby DCS instance**: Data is persisted to disk in the master node and incrementally synchronized and persisted to the standby node, achieving hot standby and data persistence. + + +.. figure:: /_static/images/en-us_image_0266235321.png + :alt: **Figure 3** HA for a master/standby DCS instance deployed within an AZ + + **Figure 3** HA for a master/standby DCS instance deployed within an AZ + +**Cluster DCS instance**: Similar to a master/standby instance, data in each shard (instance process) of a cluster instance is synchronized between master and standby nodes and persisted on both nodes. + + +.. figure:: /_static/images/en-us_image_0266235394.png + :alt: **Figure 4** HA for a cluster DCS instance deployed within an AZ + + **Figure 4** HA for a cluster DCS instance deployed within an AZ + +Cross-AZ DR +----------- + +The master and standby nodes of a master/standby or cluster DCS instance can be deployed across AZs (in different equipment rooms). Power supplies and networks of different AZs are physically isolated. When a fault occurs in the AZ where the master node is deployed, the standby node connects to the client and takes over data read and write operations. + + +.. figure:: /_static/images/en-us_image_0266235441.png + :alt: **Figure 5** Cross-AZ deployment of a master/standby DCS instance + + **Figure 5** Cross-AZ deployment of a master/standby DCS instance + +.. note:: + + This mechanism applies in a similar way to a cluster DCS instance. Each shard (process) is deployed across AZs. + +When creating a master/standby or cluster DCS instance, select a standby AZ that is different from the primary AZ. + +Backup, configuration modification, and password change functions cannot be used during the fault. diff --git a/umn/source/service_overview/index.rst b/umn/source/service_overview/index.rst new file mode 100644 index 0000000..94577da --- /dev/null +++ b/umn/source/service_overview/index.rst @@ -0,0 +1,36 @@ +:original_name: dcs-pd-0326001.html + +.. _dcs-pd-0326001: + +Service Overview +================ + +- :ref:`What Is DCS? ` +- :ref:`Application Scenarios ` +- :ref:`DCS Instance Types ` +- :ref:`DCS Instance Specifications ` +- :ref:`Command Compatibility ` +- :ref:`HA and DR Policies ` +- :ref:`Comparing Redis Versions ` +- :ref:`Comparing DCS and Open-Source Cache Services ` +- :ref:`Basic Concepts ` +- :ref:`Permissions Management ` +- :ref:`Related Services ` +- :ref:`Accessing DCS ` + +.. toctree:: + :maxdepth: 1 + :hidden: + + what_is_dcs + application_scenarios + dcs_instance_types/index + dcs_instance_specifications/index + command_compatibility/index + ha_and_dr_policies + comparing_redis_versions + comparing_dcs_and_open-source_cache_services + basic_concepts + permissions_management + related_services + accessing_dcs/index diff --git a/umn/source/service_overview/permissions_management.rst b/umn/source/service_overview/permissions_management.rst new file mode 100644 index 0000000..2db433a --- /dev/null +++ b/umn/source/service_overview/permissions_management.rst @@ -0,0 +1,106 @@ +:original_name: dcs-pd-210626001.html + +.. _dcs-pd-210626001: + +Permissions Management +====================== + +If you need to assign different permissions to employees in your enterprise to access your DCS resources, Identity and Access Management (IAM) is a good choice for fine-grained permissions management. IAM provides identity authentication, permissions management, and access control, helping you secure access to your resources. + +With IAM, you can use your account to create IAM users, and assign permissions to the users to control their access to specific resources. For example, some software developers in your enterprise need to use DCS resources but should not be allowed to delete DCS instances or perform any other high-risk operations. In this scenario, you can create IAM users for the software developers and grant them only the permissions required for using DCS resources. + +If your account does not require individual IAM users for permissions management, skip this section. + +DCS Permissions +--------------- + +By default, new IAM users do not have permissions assigned. You need to add a user to one or more groups, and attach permissions policies or roles to these groups. Users inherit permissions from the groups to which they are added and can perform specified operations on cloud services based on the permissions. + +DCS is a project-level service deployed and accessed in specific physical regions. To assign DCS permissions to a user group, specify the scope as region-specific projects and select regions for the permissions to take effect. If **All projects** is selected, the permissions will take effect for the user group in all region-specific projects. When accessing DCS, the users need to switch to a region where they have been authorized to use this service. + +You can grant users permissions by using roles and policies. + +- Roles: A type of coarse-grained authorization mechanism that defines permissions related to user responsibilities. This mechanism provides only a limited number of service-level roles for authorization. When using roles to grant permissions, you must also assign other roles on which the permissions depend to take effect. However, roles are not an ideal choice for fine-grained authorization and secure access control. +- Policies: A type of fine-grained authorization mechanism that defines permissions required to perform operations on specific cloud resources under certain conditions. This mechanism allows for more flexible policy-based authorization, meeting requirements for secure access control. For example, you can grant DCS users only the permissions for operating DCS instances. Fine-grained policies are based on APIs. The minimum granularity of a policy is API actions. For the API actions supported by DCS, see "Permissions Policies and Supported Actions". + +:ref:`Table 1 ` lists all the system-defined roles and policies supported by DCS. + +.. _dcs-pd-210626001__en-us_topic_0170871404_table8486434381: + +.. table:: **Table 1** System-defined roles and policies supported by DCS + + +--------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+------------+ + | Role/Policy Name | Description | Type | Dependency | + +====================+===============================================================================================================================================+=======================+============+ + | DCS FullAccess | All permissions for DCS. Users granted these permissions can operate and use all DCS instances. | System-defined policy | None | + +--------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+------------+ + | DCS UserAccess | Common user permissions for DCS, excluding permissions for creating, modifying, deleting DCS instances and modifying instance specifications. | System-defined policy | None | + +--------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+------------+ + | DCS ReadOnlyAccess | Read-only permissions for DCS. Users granted these permissions can only view DCS instance data. | System-defined policy | None | + +--------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+------------+ + +.. note:: + + The **DCS UserAccess** policy is different from the **DCS FullAccess** policy. If you configure both of them, you cannot create, modify, delete, or scale DCS instances because deny statements will take precedence over allowed statements. + +:ref:`Table 2 ` lists the common operations supported by each system policy of DCS. Please choose proper system policies according to this table. + +.. _dcs-pd-210626001__en-us_topic_0170871404_table12985122891519: + +.. table:: **Table 2** Common operations supported by each system policy + + +---------------------------------------------+----------------+----------------+--------------------+ + | Operation | DCS FullAccess | DCS UserAccess | DCS ReadOnlyAccess | + +=============================================+================+================+====================+ + | Modifying instance configuration parameters | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Deleting background tasks | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Accessing instances using Web CLI | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Modifying instance running status | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Expanding instance capacity | Y | x | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Changing instance passwords | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Modifying DCS instances | Y | x | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Performing a master/standby switchover | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Backing up instance data | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Analyzing big keys or hot keys | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Creating DCS instances | Y | x | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Deleting instance backup files | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Upgrading instance version | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Restoring instance data | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Resetting instance passwords | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Migrating instance data | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Downloading instance backup data | Y | Y | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Deleting DCS instances | Y | x | x | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying instance configuration parameters | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying instance restoration logs | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying instance backup logs | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying DCS instances | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying instance background tasks | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying instance upgrade information | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Querying all instances | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ + | Viewing instance performance metrics | Y | Y | Y | + +---------------------------------------------+----------------+----------------+--------------------+ diff --git a/umn/source/service_overview/related_services.rst b/umn/source/service_overview/related_services.rst new file mode 100644 index 0000000..9f00efd --- /dev/null +++ b/umn/source/service_overview/related_services.rst @@ -0,0 +1,52 @@ +:original_name: dcs-pd-0326006.html + +.. _dcs-pd-0326006: + +Related Services +================ + +DCS is used together with other services, including VPC, ECS, IAM, Cloud Eye, CTS, and Object Storage Service (OBS). + + +.. figure:: /_static/images/en-us_image_0277837533.png + :alt: **Figure 1** Relationships between DCS and other services + + **Figure 1** Relationships between DCS and other services + +VPC +--- + +A VPC is an isolated virtual network environment on the cloud. You can configure IP address ranges, subnets, and security groups in a VPC. + +DCS runs in VPCs. The VPC service manages EIPs and bandwidth, and provides security groups. You can configure access rules for security groups to secure the access to DCS. + +ECS +--- + +An ECS is a cloud server that provides scalable, on-demand computing resources for secure, flexible, and efficient applications. + +You can access and manage your DCS instances using an ECS. + +IAM +--- + +IAM provides identity authentication, permissions management, and access control. + +With IAM, you can control access to DCS. + +Cloud Eye +--------- + +Cloud Eye is a secure, scalable, and integrated monitoring service. With Cloud Eye, you can monitor your DCS service and configure alarm rules and notifications. + +Cloud Trace Service (CTS) +------------------------- + +CTS provides you with a history of operations performed on cloud service resources. With CTS, you can query, audit, and backtrack operations. The traces include the operation requests sent using the management console or open APIs and the results of these requests. + +OBS +--- + +OBS provides secure, cost-effective storage service using objects as storage units. With OBS, you can store and manage the lifecycle of massive amounts of data. + +You can store DCS instance backup files in OBS. diff --git a/umn/source/service_overview/what_is_dcs.rst b/umn/source/service_overview/what_is_dcs.rst new file mode 100644 index 0000000..bf3e09b --- /dev/null +++ b/umn/source/service_overview/what_is_dcs.rst @@ -0,0 +1,61 @@ +:original_name: en-us_topic_0054235826.html + +.. _en-us_topic_0054235826: + +What Is DCS? +============ + +Distributed Cache Service (DCS) is an online, distributed, in-memory cache service compatible with Redis. It is reliable, scalable, usable out of the box, and easy to manage, meeting your requirements for high read/write performance and fast data access. + +- Usability out of the box + + DCS provides single-node, master/standby, and cluster instances with specifications ranging from 128 MB to 1024 GB. DCS instances can be created with just a few clicks on the console, without requiring you to prepare servers. + + DCS Redis 3.0 instances are deployed on VMs. DCS Redis 4.0 and 5.0 instances are containerized and can be created within seconds. + +- Security and reliability + + Instance data storage and access are securely protected through security management services, including Identity and Access Management (IAM), Virtual Private Cloud (VPC), Cloud Eye, and Cloud Trace Service (CTS). + + Master/Standby and cluster instances can be deployed within an availability zone (AZ) or across AZs. + +- Auto scaling + + DCS instances can be scaled up or down online, helping you control costs based on service requirements. + +- Easy management + + A web-based console is provided for you to perform various operations, such as restarting instances, modifying configuration parameters, and backing up and restoring data. RESTful application programming interfaces (APIs) are also provided for automatic instance management. + +- Online migration + + You can create a data migration task on the console to import backup files or migrate data online. + +DCS for Redis +------------- + +Redis is a storage system that supports multiple types of data structures, including key-value pairs. It can be used in such scenarios as data caching, event publication/subscription, and high-speed queuing, as described in :ref:`Application Scenarios `. Redis is written in ANSI C, supporting direct read/write of strings, hashes, lists, sets, streams, and sorted sets. Redis works with an in-memory dataset which can be persisted on disk. + +DCS Redis instances can be customized based on your requirements. + +.. table:: **Table 1** DCS Redis instance configuration + + +-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Instance type | DCS for Redis provides the following three types of instances to suit different service scenarios: | + | | | + | | Single-node: Suitable for caching temporary data in low reliability scenarios. Single-node instances support highly concurrent read/write operations, but do not support data persistence. Data will be deleted after instances are restarted. | + | | | + | | Master/Standby: Each master/standby instance runs on two nodes (one master and one standby). The standby node replicates data synchronously from the master node. If the master node fails, the standby node automatically becomes the master node. | + | | | + | | Cluster: Each cluster DCS instance consists of multiple :ref:`shards ` and each shard includes a master node and zero or multiple replicas. Shards are not visible to users. If the master node fails, a standby node in the same shard takes over. | + +-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Instance specification | DCS for Redis provides instances of different specifications, ranging from 128 MB to 1024 GB. | + +-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Redis version | DCS instances are compatible with open-source Redis 3.0, 4.0, and 5.0. | + +-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Underlying architecture | **Standard** Redis based on VMs: supports up to 100,000 queries per second (QPS) at a single node. | + +-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | High availability (HA) and DR | Master/standby and cluster DCS Redis instances can be deployed across AZs in the same region with physically isolated power supplies and networks. | + +-----------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +For more information about open-source Redis, visit https://redis.io/.