{"id":323037,"date":"2021-05-13T09:01:37","date_gmt":"2021-05-13T09:01:37","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=323037"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=323037","title":{"rendered":"\u0420\u043e\u0432\u043d\u044f\u0435\u043c \u0448\u0430\u0440\u0434\u044b"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/8fb\/882\/d0e\/8fb882d0e1537254ee1bc4476b6bcbdb.png\" alt=\"image\" align=\"right\">  <\/p>\n<p>&quot;\u0420\u0430\u0437\u043c\u044b\u0448\u043b\u0435\u043d\u0438\u044f \u0431\u0435\u0437 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0438 \u043f\u0440\u0438\u0432\u043e\u0434\u044f\u0442 \u043a \u0437\u0430\u0431\u043b\u0443\u0436\u0434\u0435\u043d\u0438\u044e, \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430 \u0431\u0435\u0437 \u0440\u0430\u0437\u043c\u044b\u0448\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0437\u0430\u0442\u0440\u0443\u0434\u043d\u0435\u043d\u0438\u044e.&quot;<\/p>\n<p>  <\/p>\n<p>\u041c\u044b \u0432\u0435\u0434\u0451\u043c \u0432\u043e\u0439\u043d\u0443 \u0441 \u0438\u043d\u0434\u0438\u0432\u0438\u0434\u0443\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e \u0443 \u0448\u0430\u0440\u0434\u043e\u0432 \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435 MongoDB.<br \/>  \u042d\u0442\u043e \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/553556\">\u0428\u0430\u0440\u0434\u0438\u043d\u0433 \u043e\u0442 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043e\u0442\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f<\/a>, \u0430 \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u043d\u0430\u0441\u0442\u0443\u043f\u0438\u043b\u0430 \u043f\u043e\u0440\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u0438\u043a\u0438.<\/p>\n<p>  <\/p>\n<p>\u041a\u0430\u043a \u044f \u0438 \u043e\u0431\u0435\u0449\u0430\u043b, \u0437\u0434\u0435\u0441\u044c \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0443 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0448\u0430\u0440\u0434\u043e\u0432<\/li>\n<li>\u0440\u0430\u0441\u0447\u0435\u0442 \u043f\u043e\u043f\u0440\u0430\u0432\u043e\u043a \u0434\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u0438 \u0433\u0440\u0430\u043d\u0438\u0446<\/li>\n<li>\u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f\u0445<a name=\"habracut\"><\/a><\/li>\n<\/ul>\n<p>  <\/p>\n<h2 id=\"shardequalizer\">ShardEqualizer<\/h2>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u0432\u043f\u043e\u043b\u043d\u0435 \u0441\u0435\u0431\u0435 \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442. \u041e\u043d \u0445\u043e\u0442\u044c \u0438 \u0432 \u0431\u0435\u0442\u0430 \u0432\u0435\u0440\u0441\u0438\u0438, \u043d\u043e \u0441 \u0435\u0433\u043e \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0430 <a href=\"https:\/\/smartcat.com\" rel=\"nofollow noopener noreferrer\">Smartcat<\/a> \u043e\u0447\u0435\u043d\u044c \u0434\u0430\u0436\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u0435\u043c 3.5Tb \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0430 9\u0442\u0438 \u0448\u0430\u0440\u0434\u0430\u0445.<\/p>\n<p>  <\/p>\n<p>\u041d\u0430\u043f\u0438\u0441\u0430\u043d \u043d\u0430 C# \u0438 \u043e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u043a\u0430\u043a <a href=\"https:\/\/docs.microsoft.com\/dotnet\/core\/tools\/global-tools\" rel=\"nofollow noopener noreferrer\">dotnet tool<\/a><br \/>  \u0412\u043e\u0442 <a href=\"https:\/\/www.nuget.org\/packages\/ShardEqualizer\" rel=\"nofollow noopener noreferrer\">\u0442\u0443\u0442<\/a> \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0435\u0433\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u0432\u0435\u0440\u0441\u0438\u044e. <\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0432\u0441\u0435\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0439 \u0441 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u043e\u043c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e readonly \u043f\u0440\u0430\u0432.<br \/>  \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u043c \u043b\u044e\u0431\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0431\u0443\u0434\u0435\u0442 \u043b\u0438\u0431\u043e \u043e\u0442\u0447\u0435\u0442 \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438, \u043b\u0438\u0431\u043e \u0444\u0430\u0439\u043b \u0441\u043e \u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438 \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e \u0432\u0441\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0441\u043f\u0440\u0430\u0432\u043a\u0443 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043b\u044e\u0447\u0430 <code>--help<\/code><\/p>\n<p>  <\/p>\n<h2 id=\"opravdaniya\">\u041e\u043f\u0440\u0430\u0432\u0434\u0430\u043d\u0438\u044f<\/h2>\n<p>  <\/p>\n<p>\u0412\u0441\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u043d\u0430\u0434 \u0441\u0432\u043e\u0438\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0432\u044b \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0435 \u043d\u0430 \u0441\u0432\u043e\u0439 \u0441\u0442\u0440\u0430\u0445 \u0438 \u0440\u0438\u0441\u043a.<\/p>\n<p>  <\/p>\n<p>\u0424\u0430\u0439\u043b\u044b \u0441\u043e \u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438 \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u043d\u043e \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0438\u0437\u0443\u0447\u0438\u0442\u044c. \u0422\u0430\u043c \u043c\u0435\u0441\u0442\u0430\u043c\u0438 \u0434\u0430\u0436\u0435 \u0435\u0441\u0442\u044c \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438.<\/p>\n<p>  <\/p>\n<p>\u0414\u043e \u0442\u0435\u0445 \u043f\u043e\u0440 \u043f\u043e\u043a\u0430 \u0432\u044b \u043d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043b\u0438 \u0443\u0442\u043e\u0447\u043d\u0435\u043d\u0438\u0435 \u043a\u043b\u044e\u0447\u0430 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0432\u044b \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0437\u043e\u043d\u044b \u0438 \u0432\u0435\u0440\u043d\u0443\u0442\u044c\u0441\u044f \u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435.<\/p>\n<p>  <\/p>\n<p>\u0411\u0435\u0442\u0430 \u0432\u0435\u0440\u0441\u0438\u044f \u2014 \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u043f\u0440\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u044b \u0432\u0441\u0435 happy path. \u041d\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0448\u0438\u0431\u043a\u0438 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438, \u043a\u0440\u0430\u0439\u043d\u0438\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u044f (\u0442\u043e\u043b\u044c\u043a\u043e 1 \u0448\u0430\u0440\u0434) \u0438\u043b\u0438 \u043d\u0435\u0448\u0442\u0430\u0442\u043d\u044b\u0435 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0438 (\u043e\u0442\u0432\u0430\u043b\u0438\u043b\u0441\u044f \u0448\u0430\u0440\u0434 \u0438\u043b\u0438 \u043f\u0440\u043e\u043f\u0430\u043b\u0430 \u0441\u0432\u044f\u0437\u044c \u0446\u0435\u043b\u0438\u043a\u043e\u043c) \u043c\u043e\u0433\u0443\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u043a\u0430\u043a \u043e\u0448\u0438\u0431\u043a\u0438. \u041d\u0435 \u0441\u0442\u043e\u0438\u0442 \u043f\u0443\u0433\u0430\u0442\u044c\u0441\u044f, \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u043d\u0435 \u043c\u043e\u0436\u0435\u0442 \u043d\u0430\u0432\u0440\u0435\u0434\u0438\u0442\u044c \u0432\u0430\u0448\u0438\u043c \u0434\u0430\u043d\u043d\u044b\u043c. \u041e\u043d\u0430 \u043d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u044e\u0449\u0438\u0445 \u043a\u043e\u043c\u0430\u043d\u0434.<\/p>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0432\u0430\u043c \u043a\u0430\u0436\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0432\u044b\u0434\u0430\u0435\u0442 \u043d\u0435\u043e\u0436\u0438\u0434\u0430\u043d\u043d\u044b\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b, \u0442\u043e \u0443 \u0432\u0430\u0441 \u043a\u0443\u0447\u0430 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0435\u0439. \u0412\u0441\u0435 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0438 <a href=\"https:\/\/github.com\/ExM\/ShardEqualizer\" rel=\"nofollow noopener noreferrer\">\u0442\u0443\u0442<\/a>, \u0430 \u044f \u043d\u0430 \u0441\u0432\u044f\u0437\u0438!<\/p>\n<p>  <\/p>\n<h2 id=\"chto-my-rovnyaem\">\u0427\u0442\u043e \u043c\u044b \u0440\u043e\u0432\u043d\u044f\u0435\u043c<\/h2>\n<p>  <\/p>\n<p>\u041d\u0430\u0448\u0430 \u0438\u0441\u0445\u043e\u0434\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u2014 \u0432\u044b\u0440\u043e\u0432\u043d\u044f\u0442\u044c \u043e\u0431\u044a\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u044b \u043d\u0430 \u0434\u0438\u0441\u043a\u0430\u0445 \u0448\u0430\u0440\u0434\u043e\u0432. \u041d\u043e, \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u043d\u0430 \u043d\u0435\u0433\u043e \u0432\u043b\u0438\u044f\u0442\u044c \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e. \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043a\u043b\u044e\u0447\u0435\u0432\u044b\u0435 \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440\u0438\u0441\u0442\u0438\u043a\u0438 \u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n<p>  <\/p>\n<p>\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0430\u043c \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0434\u043b\u044f \u043f\u0435\u0440\u0432\u0438\u0447\u043d\u043e\u0439 \u043e\u0446\u0435\u043d\u043a\u0438 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0430 \u0448\u0430\u0440\u0434\u0430\u0445:<\/p>\n<p>  <\/p>\n<ul>\n<li><a href=\"https:\/\/docs.mongodb.com\/manual\/reference\/command\/dbStats\/\" rel=\"nofollow noopener noreferrer\">db.stats()<\/a> \u2014 \u0432\u044b\u0432\u043e\u0434 \u043e\u0431\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u0438\u0441\u0442\u0438\u043a\u0438 \u043f\u043e \u0411\u0414.<\/li>\n<li><a href=\"https:\/\/docs.mongodb.com\/manual\/reference\/method\/db.collection.stats\/\" rel=\"nofollow noopener noreferrer\">db.collection.stats()<\/a> \u2014 \u0432\u044b\u0432\u043e\u0434 \u0441\u0442\u0430\u0442\u0438\u0441\u0442\u0438\u043a\u0438 \u043f\u043e \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438. <\/li>\n<li><a href=\"https:\/\/docs.mongodb.com\/manual\/reference\/method\/db.collection.getShardDistribution\/\" rel=\"nofollow noopener noreferrer\">db.collection.getShardDistribution()<\/a> \u2014 \u0432\u044b\u0432\u043e\u0434 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0447\u0430\u043d\u043a\u043e\u0432. <\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0412 \u0440\u0430\u0437\u043d\u044b\u0445 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f\u0445 \u0438\u0437 \u0432\u044b\u0448\u0435\u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0435\u043d\u043d\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u0434\u0430\u043d\u043d\u044b\u0445:<\/p>\n<p>  <\/p>\n<ul>\n<li>size \u2014 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043e\u0431\u044a\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0445. \u041f\u043e \u0441\u0443\u0442\u0438 \u044d\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u0431\u044a\u0435\u043c BSON \u0432\u0441\u0435\u0433\u043e, \u0447\u0442\u043e \u043c\u044b \u0445\u0440\u0430\u043d\u0438\u043c \u0432 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438. <\/li>\n<li>storageSize \u2014 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u043c\u044b\u0439 \u043e\u0431\u044a\u0435\u043c \u043d\u0430 \u0434\u0438\u0441\u043a\u0435. \u0421 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u043c\u0438 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e WiredTiger \u0436\u043c\u0451\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0432 2 \u0440\u0430\u0437\u0430. <\/li>\n<li>indexSize \u2014 \u0440\u0430\u0437\u043c\u0435\u0440 \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u0432.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u0434\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f, \u043a\u0430\u043a\u043e\u0439 \u0436\u0435 \u0438\u0437 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043d\u0430\u043c \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0434\u043b\u044f \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438. <\/p>\n<p>  <\/p>\n<p>\u041d\u0435\u0441\u0436\u0430\u0442\u044b\u0439 \u043e\u0431\u044a\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0439 (size) \u2014 \u0438\u043d\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0435\u043d, \u0442.\u043a. \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043d\u0430\u0431\u043e\u0440 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0431\u0443\u0434\u0435\u0442 \u0438\u043c\u0435\u0442\u044c \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u043d\u0430 \u043b\u044e\u0431\u043e\u043c \u0448\u0430\u0440\u0434\u0435.<\/p>\n<p>  <\/p>\n<p>\u0425\u0440\u0430\u043d\u0438\u043c\u044b\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u0438 \u0438\u043d\u0434\u0435\u043a\u0441\u044b \u0431\u0443\u0434\u0443\u0442 \u043c\u0435\u043d\u044f\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440 \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0443\u0441\u043b\u043e\u0432\u0438\u0439 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0430\u0446\u0438\u0438. \u041f\u043e\u0441\u043b\u0435 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u0438\u043b\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f \u0438\u0445 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u043d\u0430 \u0434\u0438\u0441\u043a\u0435. \u0418\u043d\u0434\u0435\u043a\u0441\u044b \u0436\u0435 \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0443\u043c\u0435\u043d\u044c\u0448\u0430\u044e\u0442\u0441\u044f \u0432 \u0440\u0430\u0437\u043c\u0435\u0440\u0435 \u043f\u043e\u0441\u043b\u0435 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0430\u043c \u043e\u0441\u0442\u0430\u0451\u0442\u0441\u044f \u2014 \u044d\u0442\u043e \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043e\u0431\u044a\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n<p>  <\/p>\n<p>\u041c\u044b \u043c\u043e\u0436\u0435\u043c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0442\u043e\u0447\u043d\u043e \u0438 \u043f\u0440\u0435\u0434\u0441\u043a\u0430\u0437\u0443\u0435\u043c\u043e \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440 \u043d\u0435\u0441\u0436\u0430\u0442\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445, \u043d\u043e \u044d\u0442\u043e \u043d\u0435 \u043e\u0442\u043c\u0435\u043d\u044f\u0435\u0442 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433\u0430 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u043c\u043e\u0433\u043e \u043c\u0435\u0441\u0442\u0430 \u043d\u0430 \u0434\u0438\u0441\u043a\u0430\u0445. \u0417\u0430\u043d\u0438\u043c\u0430\u0435\u043c\u043e\u0435 \u043c\u0435\u0441\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u043f\u0440\u043e\u043f\u043e\u0440\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e \u043e\u0431\u044a\u0435\u043c\u0443 \u043d\u0435\u0441\u0436\u0430\u0442\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0441\u0440\u0430\u0437\u0443 \u043f\u043e\u0441\u043b\u0435 <a href=\"https:\/\/docs.mongodb.com\/manual\/tutorial\/resync-replica-set-member\/\" rel=\"nofollow noopener noreferrer\">resync<\/a>. \u0421 \u0442\u0435\u0447\u0435\u043d\u0438\u0435\u043c \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0431\u0443\u0434\u0435\u0442 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u0435\u0440\u0435\u043a\u043e\u0441 \u043f\u043e \u0448\u0430\u0440\u0434\u0430\u043c. \u0415\u0441\u043b\u0438 \u043e\u043d \u0431\u0443\u0434\u0435\u0442 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u0432\u044b\u0448\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0433\u043e, \u0442\u043e \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0432\u0442\u043e\u0440\u0438\u0442\u044c resync. <\/p>\n<p>  <\/p>\n<p>\u041f\u0440\u043e\u0435\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0448\u0430\u0440\u0434\u0438\u043d\u0433\u0430 \u2014 \u044d\u0442\u043e \u0445\u043e\u0442\u044c \u0438 \u043f\u043e\u043b\u0435\u0437\u043d\u0430\u044f, \u043d\u043e \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0437\u0430\u0442\u0440\u0430\u0442\u043d\u0430\u044f \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044f. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u0439 \u0436\u0438\u0437\u043d\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u0441\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e \u043d\u0435 \u0431\u0443\u0434\u0443\u0442 \u0441 \u044d\u0442\u0438\u043c \u0442\u043e\u0440\u043e\u043f\u0438\u0442\u044c\u0441\u044f.<\/p>\n<p>  <\/p>\n<p>\u0417\u043d\u0430\u0447\u0438\u0442, \u043a\u0440\u043e\u043c\u0435 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u0443 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c \u0435\u0449\u0435 \u0438 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435. \u0418, \u0441\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e, \u0431\u0443\u0434\u0443\u0442 \u0434\u0430\u0436\u0435 \u0446\u0435\u043b\u044b\u0435 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0411\u0414.<\/p>\n<p>  <\/p>\n<p>\u041d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u043b\u0435\u0436\u0430\u0442 \u043d\u0430 \u043e\u0434\u043d\u043e\u043c \u0448\u0430\u0440\u0434\u0435. \u0415\u0441\u043b\u0438 \u0438\u0445 \u043d\u0435 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u0442\u044c, \u0442\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u043e\u0432 \u0447\u0430\u0441\u0442\u0435\u0439 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u0442 \u043a \u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u043f\u0435\u0440\u0432\u0438\u0447\u043d\u044b\u0439 \u0448\u0430\u0440\u0434 \u0431\u0443\u0434\u0435\u0442 \u0432\u0441\u0435\u0433\u0434\u0430 &quot;\u043f\u0435\u0440\u0435\u0433\u0440\u0443\u0436\u0435\u043d&quot; \u044d\u0442\u0438\u043c\u0438 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c\u0438 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f\u043c\u0438. \u0427\u0442\u043e\u0431\u044b \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b\u043e, \u043c\u044b \u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f \u0431\u0443\u0434\u0435\u043c \u043a\u043e\u043c\u043f\u0435\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u0437\u0430 \u0441\u0447\u0435\u0442 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0447\u0430\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0445 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u043d\u0430 \u0434\u0440\u0443\u0433\u0438\u0435 \u0448\u0430\u0440\u0434\u044b.<\/p>\n<p>  <\/p>\n<h2 id=\"kak-my-rovnyaem\">\u041a\u0430\u043a \u043c\u044b \u0440\u043e\u0432\u043d\u044f\u0435\u043c<\/h2>\n<p>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u043e\u043f\u0440\u043e\u0441\u0438\u0432 \u0441\u0442\u0430\u0442\u0438\u0441\u0442\u0438\u043a\u0443 \u043a\u0430\u0436\u0434\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435, \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043d\u0430\u0431\u043e\u0440 \u0447\u0438\u0441\u0435\u043b:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u0421\u0443\u043c\u043c\u0430 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u0448\u0430\u0440\u0434\u0435 \u2014 \u044d\u0442\u043e \u0432\u0441\u0435 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438. \u0418\u0445 \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0430\u0442\u044c, \u043d\u043e \u0438\u0445 \u0440\u0430\u0437\u043c\u0435\u0440 \u0443\u0447\u0430\u0441\u0442\u0432\u0443\u0435\u0442 \u0432 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0438 \u0438 \u0435\u0433\u043e \u043d\u0430\u0434\u043e \u0431\u0443\u0434\u0435\u0442 \u043a\u043e\u043c\u043f\u0435\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c.<\/li>\n<li>\u0420\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 \u043a\u0430\u0436\u0434\u043e\u0439 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u043f\u043e \u0448\u0430\u0440\u0434\u0430\u043c \u2014 \u044d\u0442\u0438 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043c\u0435\u043d\u044f\u0442\u044c.<\/li>\n<\/ul>\n<p>  <\/p>\n<h3 id=\"nemnogo-matematiki\">\u041d\u0435\u043c\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u043a\u0438<\/h3>\n<p>  <\/p>\n<p>\u0412\u0441\u0435 \u0447\u0442\u043e \u043c\u044b \u043e\u043f\u0438\u0441\u0430\u043b\u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043a\u0430\u043a \u0437\u0430\u0434\u0430\u0447\u0430 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438. \u0410 \u0442\u0430\u043a\u0438\u0435 \u0437\u0430\u0434\u0430\u0447\u0438 \u0443\u0434\u043e\u0431\u043d\u043e \u0440\u0435\u0448\u0430\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9E%D0%BF%D1%82%D0%B8%D0%BC%D0%B8%D0%B7%D0%B0%D1%86%D0%B8%D1%8F_(%D0%BC%D0%B0%D1%82%D0%B5%D0%BC%D0%B0%D1%82%D0%B8%D0%BA%D0%B0)\" rel=\"nofollow noopener noreferrer\">\u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/a>. \u041c\u044b \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u0443\u0434\u043e\u0431\u043d\u0443\u044e &quot;\u0432\u044b\u043f\u0443\u043a\u043b\u0443\u044e&quot; \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u043e\u0448\u0438\u0431\u043a\u0438 \u2014 \u0441\u0440\u0435\u0434\u043d\u0435\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u043d\u043e\u0435 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435 \u043e\u0442 \u043e\u043f\u0442\u0438\u043c\u0443\u043c\u0430. \u042d\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u043d\u0430\u043c \u043f\u0435\u0440\u0435\u0439\u0442\u0438 \u0432 \u043a\u043b\u0430\u0441\u0441 \u0437\u0430\u0434\u0430\u0447 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9A%D0%B2%D0%B0%D0%B4%D1%80%D0%B0%D1%82%D0%B8%D1%87%D0%BD%D0%BE%D0%B5_%D0%BF%D1%80%D0%BE%D0%B3%D1%80%D0%B0%D0%BC%D0%BC%D0%B8%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5\" rel=\"nofollow noopener noreferrer\">\u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/a>. \u0418\u0445 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u043c\u043e\u0436\u043d\u043e \u043b\u0435\u0433\u043a\u043e \u0437\u0430\u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u0442\u044c.<\/p>\n<p>  <\/p>\n<p>\u041e\u043f\u0438\u0448\u0435\u043c \u043f\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u0437\u0430\u0434\u0430\u0447\u0438.<\/p>\n<p>  <\/p>\n<h4 id=\"prostranstvo-resheniy\">\u041f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u0439<\/h4>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/47e\/792\/77d\/47e79277dc17c254743475ff05980a53.svg\" alt=\"$C$\" data-tex=\"inline\"><\/math> \u2014 \u043e\u0431\u0449\u0435\u0435 \u0447\u0438\u0441\u043b\u043e \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d58\/d0b\/549\/d58d0b5495650bca169509a28e735811.svg\" alt=\"$c=1..C$\" data-tex=\"inline\"><\/math> \u2014 \u0438\u043d\u0434\u0435\u043a\u0441 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/cb6\/d45\/cf9\/cb6d45cf916546ae1085088c0c5dcd09.svg\" alt=\"$S$\" data-tex=\"inline\"><\/math> \u2014 \u043e\u0431\u0449\u0435\u0435 \u0447\u0438\u0441\u043b\u043e \u0448\u0430\u0440\u0434\u043e\u0432<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/bdd\/bc9\/cbc\/bddbc9cbc3e03cd34c1c8a35b0232434.svg\" alt=\"$s = 1..S$\" data-tex=\"inline\"><\/math> \u2014 \u0438\u043d\u0434\u0435\u043a\u0441 \u0448\u0430\u0440\u0434\u043e\u0432<br \/>  \u041f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u0439 \u2014 \u044d\u0442\u043e \u0440\u0430\u0437\u043c\u0435\u0440\u044b \u0447\u0430\u0441\u0442\u0435\u0439 (partition) \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439.<br \/>  \u041e\u0431\u043e\u0437\u043d\u0430\u0447\u0438\u043c \u0438\u0445 \u043a\u0430\u043a <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/c1c\/40e\/bf6\/c1c40ebf654a05ff53e4eec739feb727.svg\" alt=\"$p_{c,s}$\" data-tex=\"inline\"><\/math> \u2014 \u0440\u0430\u0437\u043c\u0435\u0440 \u0447\u0430\u0441\u0442\u0438 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 <code>\u0441<\/code> \u043d\u0430 \u0448\u0430\u0440\u0434\u0435 <code>s<\/code><\/p>\n<p>  <\/p>\n<p>\u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/781\/d23\/e63\/781d23e6380917ff7ec1285371f56ee6.svg\" alt=\"$p = \\begin{pmatrix} p_{1,1} &amp; \\cdots &amp; p_{1,S} &amp; p_{2,1} &amp; \\cdots &amp; p_{2,S} &amp; \\cdots &amp; p_{C,1} &amp; \\cdots &amp; p_{C,S} \\end{pmatrix}$\" data-tex=\"inline\"><\/math><br \/>  \u044d\u0442\u043e \u0432\u0435\u043a\u0442\u043e\u0440 \u0438\u0437 \u0432\u0441\u0435\u0445 \u044d\u0442\u0438\u0445 \u0447\u0438\u0441\u0435\u043b.<\/p>\n<p>  <\/p>\n<p>\u0421\u0443\u043c\u043c\u0430 \u0447\u0430\u0441\u0442\u0435\u0439 \u043e\u0434\u043d\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u043f\u043e \u0432\u0441\u0435\u043c \u0448\u0430\u0440\u0434\u0430\u043c \u2014 \u044d\u0442\u043e \u043e\u0431\u0449\u0438\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438.<br \/>  \u041f\u0440\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u0438 \u0434\u0430\u043d\u043d\u044b\u0445 \u043c\u0435\u0436\u0434\u0443 \u0448\u0430\u0440\u0434\u0430\u043c\u0438 \u044d\u0442\u0430 \u0441\u0443\u043c\u043c\u0430 \u043d\u0435 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f.<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/ce4\/f21\/5f7\/ce4f215f7eecfbae43e614428ba96507.svg\" alt=\"$K_c=\\sum\\limits_{s=1}^{S}p_{c,s}$\" data-tex=\"inline\"><\/math> \u2014 \u044d\u0442\u043e \u043e\u0431\u0449\u0438\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 <code>c<\/code>.<br \/>  \u0417\u0430 \u0441\u0447\u0435\u0442 \u044d\u0442\u043e\u0433\u043e \u0440\u0430\u0432\u0435\u043d\u0441\u0442\u0432\u0430 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u043d\u0438\u0437\u0438\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0441\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430 \u0440\u0435\u0448\u0435\u043d\u0438\u0439.<br \/>  \u0412\u044b\u0440\u0430\u0437\u0438\u043c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u0447\u0430\u0441\u0442\u044c \u043a\u0430\u0436\u0434\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u0447\u0435\u0440\u0435\u0437 \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435:<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/5f2\/d7a\/755\/5f2d7a755c1337735feda43237c0f0f8.svg\" alt=\"$p_{c,S}=K_c - \\sum\\limits_{s=1}^{S-1}p_{c,s}$\" data-tex=\"inline\"><\/math><br \/>  \u0427\u0438\u0441\u043b\u043e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0443\u043c\u0435\u043d\u044c\u0448\u0438\u043b\u043e\u0441\u044c \u043d\u0430 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/47e\/792\/77d\/47e79277dc17c254743475ff05980a53.svg\" alt=\"$C$\" data-tex=\"inline\"><\/math>.<\/p>\n<p>  <\/p>\n<h4 id=\"ogranicheniya\">\u041e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f<\/h4>\n<p>  <\/p>\n<p>\u041a\u0430\u0436\u0434\u0430\u044f \u0447\u0430\u0441\u0442\u044c \u0432\u0441\u0435\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u0434\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0443\u043b\u044f \u0438 \u043c\u0435\u043d\u044c\u0448\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u044d\u0442\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/de0\/125\/436\/de0125436a62dbbf51f65fbfc892bf88.svg\" alt=\"$0 \\le p_{c,s} \\le K_c$\" data-tex=\"inline\"><\/math><\/p>\n<p>  <\/p>\n<p>\u0418\u0441\u0445\u043e\u0434\u044f \u0438\u0437 \u0430\u043d\u0430\u043b\u0438\u0437\u0430 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0441\u0442\u0440\u043e\u0436\u0435. \u0415\u0441\u043b\u0438 \u0448\u0430\u0440\u0434 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0442\u043e\u043b\u044c\u043a\u043e jumbo-\u0447\u0430\u043d\u043a\u0438, \u0437\u043d\u0430\u0447\u0438\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u0443\u043c\u0435\u043d\u044c\u0448\u0438\u0442\u044c \u043d\u0435\u043b\u044c\u0437\u044f.<\/p>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u043c\u044b \u043d\u0435 \u0445\u043e\u0442\u0438\u043c \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 <code>\u0441<\/code> \u043d\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c \u0448\u0430\u0440\u0434\u0435 <code>s<\/code>, \u0442\u043e \u0432\u043d\u043e\u0441\u0438\u043c \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6dd\/bb9\/155\/6ddbb9155841125d120f4c9810d898cd.svg\" alt=\"$p_{c,s} = 0$\" data-tex=\"inline\"><\/math><\/p>\n<p>  <\/p>\n<h4 id=\"celevaya-funkciya\">\u0426\u0435\u043b\u0435\u0432\u0430\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f<\/h4>\n<p>  <\/p>\n<p>\u0420\u0430\u0437\u043c\u0435\u0440 \u0448\u0430\u0440\u0434\u0430 <code>s<\/code> \u043e\u043f\u0438\u0448\u0435\u043c \u0444\u043e\u0440\u043c\u0443\u043b\u043e\u0439<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/f78\/128\/bc5\/f78128bc5e0cd24630868d5ced41e0c6.svg\" alt=\"$B_s(p)=\\sum\\limits_{c=1}^{C}p_{c,s} + U_s$\" data-tex=\"inline\"><\/math><br \/>  \u0433\u0434\u0435 <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/61f\/44a\/d43\/61f44ad4350ce7e9a1f2094bc7786e44.svg\" alt=\"$U_s$\" data-tex=\"inline\"><\/math> \u2014 \u044d\u0442\u043e \u043e\u0431\u044a\u0435\u043c \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0448\u0430\u0440\u0434\u0430 <code>s<\/code>.<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/175\/f98\/839\/175f98839ab732db76d5f20cd6ce2ce9.svg\" alt=\"$T$\" data-tex=\"inline\"><\/math> \u2014 \u043e\u0431\u0449\u0438\u0439 \u043e\u0431\u044a\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0445<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/bbe\/b47\/1d6\/bbeb471d62109c04be2740367a6f755b.svg\" alt=\"$D = {T \\over S}$\" data-tex=\"inline\"><\/math> \u2014 \u044d\u0442\u043e \u0441\u0440\u0435\u0434\u043d\u0438\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u0448\u0430\u0440\u0434\u0430.<br \/>  \u041a \u044d\u0442\u043e\u043c\u0443 \u0447\u0438\u0441\u043b\u0443 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u0442\u0430\u0440\u0430\u0442\u044c\u0441\u044f \u043f\u0440\u0438\u0431\u043b\u0438\u0437\u0438\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0448\u0430\u0440\u0434\u0430.<\/p>\n<p>  <\/p>\n<p><math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/d1a\/804\/e71\/d1a804e71593a7a0c1dbbe955a9fe413.svg\" alt=\"$M_c = { K_{c} \\over C}$\" data-tex=\"inline\"><\/math> \u2014 \u0441\u0440\u0435\u0434\u043d\u0438\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u0447\u0430\u0441\u0442\u0438 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 <code>c<\/code> \u043f\u043e \u0448\u0430\u0440\u0434\u0430\u043c.<br \/>  \u041a \u044d\u0442\u043e\u043c\u0443 \u0447\u0438\u0441\u043b\u0443 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u0442\u0430\u0440\u0430\u0442\u044c\u0441\u044f \u043f\u0440\u0438\u0431\u043b\u0438\u0437\u0438\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440 \u0447\u0430\u0441\u0442\u0435\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 <code>c<\/code>.<\/p>\n<p>  <\/p>\n<p>\u0426\u0435\u043b\u0435\u0432\u0430\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u0443 \u043d\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0441\u0442\u043e\u044f\u0442\u044c \u0438\u0437 2-\u0445 \u0441\u043b\u0430\u0433\u0430\u0435\u043c\u044b\u0445:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u041f\u0435\u0440\u0432\u043e\u0435 \u0441\u043b\u0430\u0433\u0430\u0435\u043c\u043e\u0435 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0448\u0430\u0440\u0434\u043e\u0432 \u2014 \u044d\u0442\u043e \u043a\u0432\u0430\u0434\u0440\u0430\u0442 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f \u043e\u0442 \u0441\u0440\u0435\u0434\u043d\u0435\u0433\u043e \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0448\u0430\u0440\u0434\u0430.<\/li>\n<li>\u0412\u0442\u043e\u0440\u043e\u0435 \u0441\u043b\u0430\u0433\u0430\u0435\u043c\u043e\u0435, \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0447\u0430\u0441\u0442\u0435\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u043d\u0430 \u0448\u0430\u0440\u0434\u0430\u0445 \u2014 \u044d\u0442\u043e \u043a\u0432\u0430\u0434\u0440\u0430\u0442 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u044f \u043e\u0442 \u0441\u0440\u0435\u0434\u043d\u0435\u0433\u043e \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0447\u0430\u0441\u0442\u0438 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u041d\u0430\u0448\u0430 \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0438\u043e\u0440\u0438\u0442\u0435\u0442\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u2014 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0448\u0430\u0440\u0434\u043e\u0432. \u0412\u0442\u043e\u0440\u043e\u0441\u0442\u0435\u043f\u0435\u043d\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u2014 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0447\u0430\u0441\u0442\u0435\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u043d\u0430 \u0448\u0430\u0440\u0434\u0430\u0445. \u0427\u0442\u043e\u0431\u044b \u044d\u0442\u043e\u0433\u043e \u0434\u043e\u0431\u0438\u0442\u044c\u0441\u044f, \u0432\u0435\u0441 \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u0441\u043b\u0430\u0433\u0430\u0435\u043c\u043e\u0433\u043e \u043f\u043e\u043d\u0438\u0437\u0438\u043c \u0432 1000 \u0440\u0430\u0437. \u041a\u043e\u044d\u0444\u0444\u0438\u0446\u0438\u0435\u043d\u0442 \u043f\u043e\u0434\u0431\u0438\u0440\u0430\u043b \u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435, \u0438 \u0442\u0430\u043a \u043e\u043d \u0434\u0430\u0435\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e 0.1% \u043e\u0448\u0438\u0431\u043a\u0438 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f \u0448\u0430\u0440\u0434\u043e\u0432. <\/p>\n<p>  <\/p>\n<p>\u041e\u0431\u0449\u0430\u044f \u0444\u043e\u0440\u043c\u0443\u043b\u0430 \u0446\u0435\u043b\u0435\u0432\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0438:<br \/>  <math><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/formulas\/6e3\/001\/564\/6e300156457f3f5c3b83a471f175cf6f.svg\" alt=\"$E(p) = \\sum\\limits_{s=1}^{S}\\left({B_s(p) - D \\over T}\\right)^2 + {1 \\over 1000} * \\sum\\limits_{c=1}^{C}\\sum\\limits_{s=1}^{S}\\left({p_{c,s} - M_c \\over K_c}\\right)^2$\" data-tex=\"inline\"><\/math><br \/>  \u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u044d\u0442\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0438 \u043d\u0430\u0434\u043e \u043c\u0438\u043d\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c.<\/p>\n<p>  <\/p>\n<h4 id=\"reshenie\">\u0420\u0435\u0448\u0435\u043d\u0438\u0435<\/h4>\n<p>  <\/p>\n<p>\u0417\u0434\u0435\u0441\u044c \u0431\u0443\u0434\u0443\u0442 \u0445\u043e\u0440\u043e\u0448\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u0435 \u0438\u0442\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b. \u041d\u043e \u0434\u043b\u044f \u043d\u0438\u0445 \u043d\u0443\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0431\u044b \u043e\u0442\u0432\u0435\u0447\u0430\u043b\u043e \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f\u043c \u2014 \u044d\u0442\u043e \u043d\u0430\u0448\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435.<br \/>  \u0427\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u043c\u0443 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438, \u044f \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0441\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u043e\u0439 <a href=\"https:\/\/www.nuget.org\/packages\/Accord.Math\/\" rel=\"nofollow noopener noreferrer\">Accord.Math<\/a>. \u0412 \u043d\u0435\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043e \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432. \u042f \u0432\u044b\u0431\u0440\u0430\u043b \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c <a href=\"http:\/\/accord-framework.net\/docs\/html\/T_Accord_Math_Optimization_GoldfarbIdnani.htm\" rel=\"nofollow noopener noreferrer\">GoldfarbIdnani<\/a>. \u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u043d\u0430 \u043d\u0430\u0448\u0435\u0439 \u0437\u0430\u0434\u0430\u0447\u0435 \u043e\u043d \u043e\u043a\u0430\u0437\u0430\u043b\u0441\u044f \u0441\u0430\u043c\u044b\u043c \u0448\u0443\u0441\u0442\u0440\u044b\u043c \u0438 \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u044b\u043c. \u041a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e, \u043d\u0435 \u0441\u043c\u043e\u0433 \u043d\u0430\u0439\u0442\u0438 \u0435\u0433\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043f\u0440\u043e\u0433\u043e\u043d\u0430 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c &quot;\u0438\u0434\u0435\u0430\u043b\u044c\u043d\u043e\u0435&quot; \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 \u043a\u0430\u0436\u0434\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u043f\u043e \u0448\u0430\u0440\u0434\u0430\u043c.<\/p>\n<p>  <\/p>\n<h3 id=\"dvigaem-granicy\">\u0414\u0432\u0438\u0433\u0430\u0435\u043c \u0433\u0440\u0430\u043d\u0438\u0446\u044b<\/h3>\n<p>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u0443 \u043d\u0430\u0441 \u0438\u0437\u0432\u0435\u0441\u0442\u0435\u043d \u0436\u0435\u043b\u0430\u0435\u043c\u044b\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u043a\u0430\u0436\u0434\u043e\u0439 \u0435\u0433\u043e \u0447\u0430\u0441\u0442\u0438 \u043d\u0430 \u0448\u0430\u0440\u0434\u0435. \u0422\u0430\u043a\u0436\u0435 \u043c\u044b \u0437\u043d\u0430\u0435\u043c \u0442\u0435\u043a\u0443\u0449\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u044b \u0447\u0430\u0441\u0442\u0435\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438.<\/p>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440 \u0434\u043b\u044f \u043f\u044f\u0442\u0438 \u0448\u0430\u0440\u0434\u043e\u0432:<br \/>  \u0422\u0435\u043a\u0443\u0449\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u044b (\u0432 Gb) \u2014 15, 26, 9, 18, 30<br \/>  \u0416\u0435\u043b\u0430\u0435\u043c\u044b\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u044b \u2014 18, 20, 20, 20, 20 (\u043f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u043c \u0447\u0442\u043e \u043d\u0430 \u043f\u0435\u0440\u0432\u043e\u043c \u0448\u0430\u0440\u0434\u0435 \u0435\u0449\u0435 2Gb \u043d\u0435 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445)<\/p>\n<p>  <\/p>\n<p>\u0423 \u043d\u0430\u0441 4 \u0433\u0440\u0430\u043d\u0438\u0446\u044b. \u041d\u0435\u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0440\u0430\u0441\u0447\u0435\u0442\u044b \u0434\u0430\u0434\u0443\u0442 \u043d\u0430\u043c \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0435 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0433\u0440\u0430\u043d\u0438\u0446:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/bab\/61f\/409\/bab61f4097053d9e9849d0f0ad462a65.png\">  <\/p>\n<p>\u0414\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u0433\u0440\u0430\u043d\u0438\u0446\u044b \u043c\u044b \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u043c \u0440\u0430\u0437\u043c\u0435\u0440\u044b \u0447\u0430\u043d\u043a\u043e\u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0432 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u044f.<br \/>  Jumbo \u0447\u0430\u043d\u043a\u0438 \u043c\u044b \u043f\u0440\u043e\u043f\u0443\u0441\u043a\u0430\u0435\u043c.<\/p>\n<p>  <\/p>\n<p>\u041d\u0430\u0431\u0438\u0440\u0430\u0435\u043c \u0441\u0443\u043c\u043c\u0443 \u0447\u0430\u043d\u043a\u043e\u0432, \u0440\u0430\u0437\u043c\u0435\u0440 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u043e\u043c\u0443 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u044e \u044d\u0442\u043e\u0439 \u0433\u0440\u0430\u043d\u0438\u0446\u044b. \u0418 \u0444\u0438\u043a\u0441\u0438\u0440\u0443\u0435\u043c \u0433\u0440\u0430\u043d\u0438\u0446\u0443 \u0441 \u043d\u043e\u0432\u044b\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c \u043a\u043b\u044e\u0447\u0430 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430 \u0433\u0440\u0430\u043d\u0438\u0446\u0435 \u0447\u0430\u043d\u043a\u043e\u0432.<\/p>\n<p>  <\/p>\n<p>\u0427\u0442\u043e\u0431\u044b \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0433\u0440\u0430\u043d\u0438\u0446 \u0432 \u0411\u0414, \u043d\u0430\u043c \u043d\u0430\u0434\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0432\u0441\u0435 \u0441\u0442\u0430\u0440\u044b\u0435 \u0437\u043e\u043d\u044b \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <code>sh.removeTagRange<\/code>, \u0430 \u043f\u043e\u0442\u043e\u043c \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u043e\u0432\u044b\u0435 \u0437\u043e\u043d\u044b \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <code>sh.addTagRange<\/code>.<\/p>\n<p>  <\/p>\n<h2 id=\"praktika\">\u041f\u0440\u0430\u043a\u0442\u0438\u043a\u0430<\/h2>\n<p>  <\/p>\n<p>\u0423\u0434\u043e\u0431\u043d\u0435\u0435 \u0432\u0441\u0435\u0433\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0442\u0440\u0435\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u0445 \u043d\u0438\u043a\u043e\u043c\u0443 \u043d\u0435 \u043d\u0443\u0436\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445.<br \/>  \u0412 <a href=\"https:\/\/github.com\/ExM\/MongoDB_DataBalance\" rel=\"nofollow noopener noreferrer\">\u044d\u0442\u043e\u043c \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0438<\/a> \u044f \u0441\u043e\u0431\u0440\u0430\u043b \u0432\u0441\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u0434\u043b\u044f \u043e\u043f\u044b\u0442\u043e\u0432.<br \/>  \u0412 docker compose \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u043e\u0434\u043d\u044f\u0442\u044c \u0441\u0435\u0431\u0435 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0442\u0435\u0440. \u0410 \u043d\u0435\u0441\u043b\u043e\u0436\u043d\u0430\u044f \u043a\u043e\u043d\u0441\u043e\u043b\u044c\u043d\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u043a\u0430 \u0437\u0430\u043f\u043e\u043b\u043d\u0438\u0442 \u043d\u0430\u043c \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044e \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0441 \u043d\u0443\u0436\u043d\u044b\u043c \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435\u043c.<\/p>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0437\u0430\u0432\u0435\u0434\u0435\u043c \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u043f\u043e\u0434 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0438.<br \/>  \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u0432 \u043d\u0435\u0435 <a href=\"https:\/\/www.nuget.org\/packages\/ShardEqualizer\" rel=\"nofollow noopener noreferrer\">ShardEqualizer<\/a> \u0438 \u043f\u0440\u0438\u0441\u0442\u0443\u043f\u0438\u043c \u043a \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0441\u043e\u043f\u0440\u043e\u0432\u043e\u0436\u0434\u0435\u043d\u0438\u044f \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430.<br \/>  \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u044d\u0442\u0430\u043f\u044b \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u0441\u043e\u0437\u0434\u0430\u0435\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 (\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043a \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0443 MongoDB, \u0442\u0435\u0433\u0438 \u0448\u0430\u0440\u0434\u043e\u0432 \u0438 \u0442.\u0434.)<\/li>\n<li>\u0443\u0442\u043e\u0447\u043d\u044f\u0435\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439<\/li>\n<li>\u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0440\u0430\u0441\u0447\u0435\u0442 \u0433\u0440\u0430\u043d\u0438\u0446 \u0437\u043e\u043d<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0421\u043e\u043f\u0440\u043e\u0432\u043e\u0436\u0434\u0435\u043d\u0438\u0435 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430 \u044d\u0442\u043e:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li>\u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u043e\u0432 \u0448\u0430\u0440\u0434\u043e\u0432<\/li>\n<li>\u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043f\u0443\u0441\u0442\u044b\u0445 \u0447\u0430\u043d\u043a\u043e\u0432<\/li>\n<\/ul>\n<p>  <\/p>\n<h3 id=\"inicializaciya\">\u0418\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f<\/h3>\n<p>  <\/p>\n<p>\u0412\u044b\u0434\u0435\u043b\u044f\u0435\u043c \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430.<br \/>  \u042d\u0442\u0443 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u043e\u0436\u0438\u0442\u044c \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044f \u0432\u0435\u0440\u0441\u0438\u0439, \u0434\u043b\u044f \u0443\u0434\u043e\u0431\u043d\u043e\u0433\u043e \u0441\u043e\u043f\u0440\u043e\u0432\u043e\u0436\u0434\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438.<\/p>\n<p>  <\/p>\n<p>\u041b\u0443\u0447\u0448\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u0443\u044e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u0443\u0442\u0438\u043b\u0438\u0442\u044b. \u0422\u0430\u043a, \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0449\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0432\u0435\u0440\u0441\u0438\u0435\u0439 \u0443\u0442\u0438\u043b\u0438\u0442\u044b.<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet new tool-manifest dotnet tool install ShardEqualizer --version 1.0.0-beta.6<\/code><\/pre>\n<p>  <\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet ShardEqualizer config-init -h localhost<\/code><\/pre>\n<p>  <\/p>\n<p>\u0411\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u043d \u0444\u0430\u0439\u043b <a href=\"https:\/\/github.com\/ExM\/MongoDB_DataBalance\/blob\/master\/configuration.xml\" rel=\"nofollow noopener noreferrer\">configuration.xml<\/a> \u0441\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438 \u0441\u0435\u043a\u0446\u0438\u044f\u043c\u0438:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043a \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0443 <\/li>\n<li>\u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0448\u0430\u0440\u0434\u043e\u0432 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e <\/li>\n<li>\u0441\u043f\u0438\u0441\u043e\u043a \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0418\u043c\u044f \u0444\u0430\u0439\u043b\u0430 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u0432\u044b\u0431\u0440\u0430\u043d\u043e \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, \u043d\u043e \u0435\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u043e\u043f\u0446\u0438\u0435\u0439 <code>-\u0441<\/code><br \/>  \u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435.<br \/>  \u0422\u0430\u043a\u0436\u0435 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u043d \u0444\u0430\u0439\u043b <code>commandPlan_*.js<\/code> \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0437\u043e\u043d.<br \/>  \u041c\u043e\u0436\u0435\u0442\u0435 \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0438\u0445 \u0438\u043b\u0438 \u0437\u0430\u0432\u0435\u0441\u0442\u0438 \u043d\u043e\u0432\u044b\u0435 \u043f\u043e \u0441\u0432\u043e\u0435\u043c\u0443 \u0443\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0438\u044e. \u0415\u0441\u043b\u0438 \u0431\u0443\u0434\u0435\u0442\u0435 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0441\u0432\u043e\u0438 \u0437\u043e\u043d\u044b, \u0442\u043e \u0432\u043d\u0435\u0441\u0438\u0442\u0435 \u0438\u0445 \u0432 \u0444\u0430\u0439\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438:<\/p>\n<p>  <\/p>\n<pre><code class=\"xml\">&lt;Defaults zones=&quot;shardA,shardB,shardC&quot; \/&gt;<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438 \u0432 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u043c \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0435 zones \u043c\u043e\u0436\u043d\u043e \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0441\u0432\u043e\u0439 \u043d\u0430\u0431\u043e\u0440 \u0438\u043b\u0438 \u0434\u0440\u0443\u0433\u043e\u0439 \u043f\u043e\u0440\u044f\u0434\u043e\u043a \u0437\u043e\u043d \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f.<\/p>\n<p>  <\/p>\n<pre><code class=\"xml\">&lt;Interval nameSpace=&quot;disbalance.jobs&quot; zones=&quot;shardB,shardC&quot; \/&gt; &lt;Interval nameSpace=&quot;disbalance.locks&quot; zones=&quot;shardC,shardB&quot; \/&gt;<\/code><\/pre>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u044f\u0432\u043d\u043e \u0440\u0430\u0437\u043d\u0435\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u0443\u044e\u0442 \u043f\u043e \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0435.<\/p>\n<p>  <\/p>\n<p>\u0417\u0434\u0435\u0441\u044c \u043c\u044b \u043d\u0435 \u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u0435\u0439, \u043d\u043e \u0435\u0441\u043b\u0438 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0438\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438 \u043f\u0430\u0440\u043e\u043b\u044c, \u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u043d \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c\u044b\u0439 \u0444\u0430\u0439\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u0432\u044b\u0448\u0435 \u043f\u043e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438.<\/p>\n<p>  <\/p>\n<h3 id=\"predvaritelnoe-razbienie\">\u041f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0437\u0431\u0438\u0435\u043d\u0438\u0435<\/h3>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u043d\u043e\u0432\u044b\u0445 \u0433\u0440\u0430\u043d\u0438\u0446 \u043d\u0430\u0434\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 <code>presplit<\/code>:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet ShardEqualizer presplit<\/code><\/pre>\n<p>  <\/p>\n<p>\u0423\u0442\u0438\u043b\u0438\u0442\u0430 \u043f\u0440\u043e\u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 \u0447\u0430\u043d\u043a\u0438 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u0438 \u0440\u0430\u0437\u043e\u0431\u044c\u0435\u0442 \u0438\u0445 \u043d\u0430 \u0440\u0430\u0432\u043d\u044b\u0435 \u0447\u0430\u0441\u0442\u0438 \u043f\u043e \u0447\u0438\u0441\u043b\u0443 \u0447\u0430\u043d\u043a\u043e\u0432. \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u0435\u0440\u0432\u043e\u0435 \u043f\u0440\u0438\u0431\u043b\u0438\u0436\u0435\u043d\u0438\u0435 \u043a \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044e. \u0421\u0435\u0439\u0447\u0430\u0441, \u043a\u043e\u0433\u0434\u0430 \u0434\u0430\u043d\u043d\u044b\u0435 \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u044b, \u0431\u0435\u0437 \u043f\u043e\u043b\u043d\u043e\u0433\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0447\u0430\u043d\u043a\u043e\u0432, \u043b\u0443\u0447\u0448\u0435\u0433\u043e \u0440\u0430\u0437\u0431\u0438\u0435\u043d\u0438\u044f \u043d\u0435 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u0442\u044c.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d \u043f\u043e\u0440\u044f\u0434\u043e\u043a \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u043e\u043d \u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438. \u0415\u0441\u043b\u0438 \u043e\u043d \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f, \u0442\u043e \u0432 \u0441\u043a\u0440\u0438\u043f\u0442\u0435 \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u0447\u0438\u0441\u0442\u043a\u0430 \u0441\u0442\u0430\u0440\u044b\u0445 \u0437\u043e\u043d. \u0415\u0441\u043b\u0438 \u043d\u0435 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f, \u0442\u043e \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f \u0443\u0436\u0435 \u0434\u0435\u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0430 \u0438 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u043f\u0443\u0449\u0435\u043d\u0430.<\/p>\n<p>  <\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u043c \u0440\u0430\u0431\u043e\u0442\u044b \u0431\u0443\u0434\u0435\u0442 \u0441\u043a\u0440\u0438\u043f\u0442 \u0441 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435\u043c \u0437\u043e\u043d \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a\u043e\u0439:<\/p>\n<p>  <\/p>\n<pre><code class=\"javascript\">\/\/ presplit commands for disbalance.jobs sh.addTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : MinKey }, { &quot;projectId&quot; : NumberInt(342) }, &quot;shardA&quot;); sh.addTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : NumberInt(342) }, { &quot;projectId&quot; : NumberInt(683) }, &quot;shardB&quot;); sh.addTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : NumberInt(683) }, { &quot;projectId&quot; : MaxKey }, &quot;shardC&quot;); \/\/ ---<\/code><\/pre>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u043b\u044e\u0447 <code>--renew-current-zones<\/code>, \u0442\u043e \u044d\u0442\u043e \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u0442 \u043a \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u043c\u0443 \u043f\u0435\u0440\u0435\u0440\u0430\u0437\u0431\u0438\u0435\u043d\u0438\u044e \u0432\u0441\u0435\u0445 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u043f\u043e\u0442\u0440\u0435\u0431\u043e\u0432\u0430\u0442\u044c\u0441\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u0440\u0438 \u043c\u0430\u0441\u0441\u043e\u0432\u044b\u0445 \u043d\u0435\u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u044b\u0445 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0438\u043b\u0438 \u043f\u0440\u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0448\u0430\u0440\u0434\u0430.<\/p>\n<p>  <\/p>\n<h3 id=\"monitoring-peremescheniya-chankov\">\u041c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433 \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0447\u0430\u043d\u043a\u043e\u0432<\/h3>\n<p>  <\/p>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0447\u0430\u043d\u043a\u043e\u0432 \u0431\u0443\u0434\u0435\u0442 \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0435\u0439. \u042d\u0442\u043e \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u0442 \u043a \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0435 \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430. \u0415\u0441\u043b\u0438 \u044d\u0442\u043e \u043d\u0435\u0436\u0435\u043b\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0432 \u043f\u0440\u0430\u0439\u043c-\u0442\u0430\u0439\u043c, \u0442\u043e \u0441\u0442\u043e\u0438\u0442 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0449\u0438\u043a\u0430 \u0432 <a href=\"https:\/\/docs.mongodb.com\/manual\/tutorial\/manage-sharded-cluster-balancer\/#schedule-the-balancing-window\" rel=\"nofollow noopener noreferrer\">\u0443\u0434\u043e\u0431\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f<\/a>.<\/p>\n<p>  <\/p>\n<p>\u0427\u0442\u043e\u0431\u044b \u0443\u0437\u043d\u0430\u0442\u044c, \u0447\u0442\u043e \u0432\u0441\u0435 \u0447\u0430\u043d\u043a\u0438 \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u043d\u0430 \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0445 \u0438\u043c \u043c\u0435\u0441\u0442\u0430\u0445, \u043d\u0430\u0434\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 <code>balancer<\/code>:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet ShardEqualizer balancer<\/code><\/pre>\n<p>  <\/p>\n<p>\u0417\u0434\u0435\u0441\u044c \u043c\u044b \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u043c \u0437\u043e\u043d\u044b \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0447\u0430\u043d\u043a\u043e\u0432 \u0438 \u0438\u0449\u0435\u043c \u0447\u0430\u043d\u043a\u0438 \u0432 \u043d\u0435\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0445 \u0433\u0440\u0430\u043d\u0438\u0446\u0430\u0445.<br \/>  \u0411\u0443\u0434\u0435\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a\u043e\u0439 \u043e\u0442\u0447\u0435\u0442:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">Scan intervals ... found 11 chunks awaiting movement. disbalance.jobs:   tag range 'shardB' waits for 6 chunks from 'shardA' shards   tag range 'shardC' waits for 5 chunks from 'shardB' shards<\/code><\/pre>\n<p>  <\/p>\n<p>\u041e\u0431\u0449\u0435\u0435 \u0447\u0438\u0441\u043b\u043e \u043d\u0435\u0434\u043e\u0435\u0445\u0430\u0432\u0448\u0438\u0445 \u0447\u0430\u043d\u043a\u043e\u0432 \u0438 \u0438\u0445 \u0440\u0430\u0437\u0431\u0438\u0432\u043a\u0430 \u043f\u043e \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f\u043c.<\/p>\n<p>  <\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 \u0432\u0441\u0435 \u0434\u043e\u0435\u0445\u0430\u043b\u043e, \u043d\u0430\u0434\u043e \u043f\u043e\u0434\u043e\u0436\u0434\u0430\u0442\u044c \u0435\u0449\u0435 10-20 \u043c\u0438\u043d\u0443\u0442. \u041a\u043b\u0430\u0441\u0442\u0435\u0440 \u0431\u0443\u0434\u0435\u0442 <a href=\"https:\/\/docs.mongodb.com\/manual\/core\/sharding-balancer-administration\/#asynchronous-chunk-migration-cleanup\" rel=\"nofollow noopener noreferrer\">\u043f\u043e\u0434\u0447\u0438\u0449\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435<\/a>. \u041d\u0443 \u0438\u043b\u0438 \u043c\u043e\u0436\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u0435 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f, \u043d\u043e \u044d\u0442\u043e \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0442 \u043e\u0431\u0449\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0447\u0430\u043d\u043a\u043e\u0432.<\/p>\n<p>  <\/p>\n<h3 id=\"ocenka-raspredeleniya\">\u041e\u0446\u0435\u043d\u043a\u0430 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f<\/h3>\n<p>  <\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 \u0447\u0430\u043d\u043a\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u044b \u043c\u043e\u0436\u043d\u043e \u043e\u0446\u0435\u043d\u0438\u0442\u044c \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0445.<br \/>  \u041a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <code>deviation<\/code> \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u0435 \u043e\u0442\u0447\u0435\u0442\u044b \u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0438 \u0434\u0430\u043d\u043d\u044b\u0445<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet ShardEqualizer deviation -sM --format=md --layouts=&quot;default,balance&quot;<\/code><\/pre>\n<p>  <\/p>\n<p>\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043b\u044e\u0447\u0438:<\/p>\n<p>  <\/p>\n<ul>\n<li><code>--scale<\/code> \u2014 \u043c\u0430\u0441\u0448\u0442\u0430\u0431 \u0440\u0430\u0437\u043c\u0435\u0440\u0430; \u0437\u0430\u0434\u0430\u0435\u0442\u0441\u044f \u0431\u0443\u043a\u0432\u043e\u0439 \u043f\u0440\u0435\u0444\u0438\u043a\u0441\u0430 \u043e\u0442 K (\u043a\u0438\u043b\u043e\u0431\u0430\u0439\u0442) \u0434\u043e E (\u044d\u043a\u0437\u0430\u0431\u0430\u0439\u0442)<\/li>\n<li><code>--format<\/code> \u2014 \u0444\u043e\u0440\u043c\u0430\u0442 \u0432\u044b\u0432\u043e\u0434\u0430 \u0442\u0430\u0431\u043b\u0438\u0446; \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0432 CSV \u0438\u043b\u0438 Markdown<\/li>\n<li><code>--layouts<\/code> \u2014 \u0441\u043e\u0441\u0442\u0430\u0432 \u043a\u043e\u043b\u043e\u043d\u043e\u043a \u0442\u0430\u0431\u043b\u0438\u0446:<br \/> \n<ul>\n<li><code>default<\/code> \u2014 \u043a\u043e\u043b\u043e\u043d\u043a\u0438 \u043f\u043e \u0432\u0441\u0435\u043c \u0442\u0438\u043f\u0430\u043c \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li><code>balance<\/code> \u2014 \u0441\u043e\u043a\u0440\u0430\u0449\u0435\u043d\u043d\u044b\u0439 \u043d\u0430\u0431\u043e\u0440 \u0434\u043b\u044f \u0431\u044b\u0441\u0442\u0440\u043e\u0439 \u043e\u0446\u0435\u043d\u043a\u0438 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0430 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 \u0442\u0430\u043a \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u043e\u0442\u0447\u0435\u0442 \u043e\u0442\u0440\u0435\u043d\u0434\u0435\u0440\u0435\u043d\u043d\u044b\u0439 \u0432 Markdown \u0432 YouTrack<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/4cd\/a0f\/af9\/4cda0faf96ffc0bb6b0f1a1b4948e65e.png\">  <\/p>\n<p>\u0412 \u043f\u0435\u0440\u0432\u043e\u0439 \u043a\u043e\u043b\u043e\u043d\u043a\u0435 \u0438\u0434\u0443\u0442 \u0438\u043c\u0435\u043d\u0430 \u0448\u0430\u0440\u0434\u043e\u0432 \u0438 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0441\u0442\u0440\u043e\u043a \u0441 \u0441\u0443\u043c\u043c\u043e\u0439 \u0438 \u0441\u0440\u0435\u0434\u043d\u0438\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c.<\/p>\n<p>  <\/p>\n<p>\u041e\u0431\u043e\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u044f\u0445 \u043a\u043e\u043b\u043e\u043d\u043e\u043a:<\/p>\n<p>  <\/p>\n<ul>\n<li><code>DSize<\/code> \u2014 \u0440\u0430\u0437\u043c\u0435\u0440 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 BSON (\u0431\u0435\u0437 \u0441\u0436\u0430\u0442\u0438\u044f)<\/li>\n<li><code>DStore<\/code> \u2014 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u043c\u044b\u0439 \u043e\u0431\u044a\u0435\u043c \u043d\u0430 \u0434\u0438\u0441\u043a\u0435<\/li>\n<li><code>Index<\/code> \u2014 \u0440\u0430\u0437\u043c\u0435\u0440 \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u0432<\/li>\n<li><code>Total<\/code> \u2014 \u0432\u0441\u0435 \u0442\u0438\u043f\u044b \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439<\/li>\n<li><code>UnShrd<\/code> \u2014 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438<\/li>\n<li><code>Sharded<\/code> \u2014 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438<\/li>\n<li><code>Managed<\/code> \u2014 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u043d\u0430\u0448\u0435\u0439 \u0443\u0442\u0438\u043b\u0438\u0442\u043e\u0439, \u0438 \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438. <\/li>\n<li><code>Fixed<\/code> \u2014 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438, \u0443 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d\u043e (\u0432\u044b\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0430\u0442\u0440\u0438\u0431\u0443\u0442 <code>adjustable=&quot;false&quot;<\/code> \u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438) \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u043e \u0434\u043b\u044f \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0447\u0430\u0441\u0442\u043e \u043c\u0435\u043d\u044f\u044e\u0449\u0438\u0445\u0441\u044f \u0434\u0430\u043d\u043d\u044b\u0445.<\/li>\n<li><code>Delta<\/code> \u2014 \u0432 \u043a\u043e\u043b\u043e\u043d\u043a\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043e \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u043e\u0442 \u0441\u0440\u0435\u0434\u043d\u0435\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0412 \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0411\u0414 \u044f \u0434\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0438\u043b \u043d\u0435\u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044e \u043d\u0430 \u0448\u0430\u0440\u0434\u0435 <code>shardC<\/code>.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e \u0442\u0430\u0431\u043b\u0438\u0446\u0435 <code>Balance report<\/code> \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u043e\u043d\u044f\u0442\u044c, \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043b\u0438 \u043d\u0430\u043c \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u044f.<br \/>  \u041a\u043e\u043b\u043e\u043d\u043a\u0443 <code>Managed DSize Delta<\/code> \u0431\u0443\u0434\u0435\u043c \u0441\u0442\u0440\u0435\u043c\u0438\u0442\u044c\u0441\u044f \u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043d\u0430 \u043e\u043a\u043e\u043b\u043e \u043d\u0443\u043b\u0435\u0432\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u0445. \u042d\u0442\u043e \u0438 \u0435\u0441\u0442\u044c \u0442\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u044b \u0441\u0442\u0440\u0435\u043c\u0438\u043c\u0441\u044f \u0432\u044b\u0440\u043e\u0432\u043d\u044f\u0442\u044c.<\/p>\n<p>  <\/p>\n<h3 id=\"vyravnivanie\">\u0412\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435<\/h3>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0440\u0430\u0437\u043c\u0435\u0440 \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0430 \u0448\u0430\u0440\u0434\u0430\u0445 \u0441\u0442\u0430\u043b \u0441\u0438\u043b\u044c\u043d\u043e \u043e\u0442\u043b\u0438\u0447\u0430\u0442\u044c\u0441\u044f, \u0442\u043e \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet ShardEqualizer equalize<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u044b \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0433\u0440\u0430\u043d\u0438\u0446 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0438.<br \/>  \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432\u0434\u043e\u043b\u044c \u0433\u0440\u0430\u043d\u0438\u0446 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u0439.<br \/>  \u041f\u043e \u043c\u0435\u0440\u0435 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u043d \u0444\u0430\u0439\u043b \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438 \u043d\u0430 \u0437\u0430\u043c\u0435\u043d\u0443 \u0437\u043e\u043d \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445.<br \/>  \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043b\u044e\u0447\u0438:<\/p>\n<p>  <\/p>\n<ul>\n<li><code>--dry-run<\/code> \u2014 \u0440\u0435\u0436\u0438\u043c &quot;\u043c\u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u043f\u0440\u043e\u0441\u0438\u0442\u044c&quot;. \u0412\u044b\u0432\u043e\u0434 \u043e\u0442\u0447\u0435\u0442\u0430 \u0441 \u043e\u043f\u0442\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u043c \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c \u0433\u0440\u0430\u043d\u0438\u0446, \u0431\u0435\u0437 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0433\u0440\u0430\u043d\u0438\u0446.<\/li>\n<li><code>--correction-percent<\/code> \u2014 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0447\u0430\u0441\u0442\u0438\u0447\u043d\u043e\u0435 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0433\u0440\u0430\u043d\u0438\u0446 \u043d\u0430 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0439 \u043f\u0440\u043e\u0446\u0435\u043d\u0442 \u043a \u043e\u043f\u0442\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u043c\u0443 \u0440\u0435\u0448\u0435\u043d\u0438\u044e.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u043e\u0447\u0435\u043d\u044c \u0441\u0438\u043b\u044c\u043d\u043e \u0440\u0430\u0437\u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u043d, \u0442\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043d\u044f\u0442\u044c \u043c\u043d\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438. \u0412\u0441\u0435 \u044d\u0442\u043e \u0432\u0440\u0435\u043c\u044f \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0431\u0443\u0434\u0443\u0442 \u0438\u0437\u0431\u044b\u0442\u043e\u0447\u043d\u043e \u043d\u0430\u0433\u0440\u0443\u0436\u0435\u043d\u044b. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u0438 \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u043c\u0438 \u043f\u043e\u0440\u0446\u0438\u044f\u043c\u0438.<\/p>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 \u0442\u0430\u043a \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u043e\u0442\u0447\u0435\u0442 \u043e \u043f\u043b\u0430\u043d\u0438\u0440\u0443\u0435\u043c\u043e\u0439 \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u0438 \u0433\u0440\u0430\u043d\u0438\u0446<\/p>\n<p>  <\/p>\n<pre> Find solution         Found solution with max deviation of 342.79 Kb between shards Data move plan:   disbalance.jobs     Require move: 230.93 Mb     Equalize details (in Mb)     | shard  | current | target | delta  | incoming | left accepted    | right accepted   |     | shardA |  833.42 | 766.71 | -66.71 |     0.00 |                  |  66.71 -&gt; shardB |     | shardB |  864.22 | 766.71 | -97.50 |    66.71 | shardA -&gt;  66.71 | 164.22 -&gt; shardC |     | shardC |  569.02 | 733.24 | 164.22 |   164.22 | shardB -&gt; 164.22 |                  |  Total update pressure:   [shardA] 0 b   [shardB] 66.71 Mb   [shardC] 164.22 Mb <\/pre>\n<p>  <\/p>\n<p>\u0417\u0434\u0435\u0441\u044c \u0443 \u043d\u0430\u0441 \u043d\u0430\u0439\u0434\u0435\u043d\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0441 \u043e\u0442\u043a\u043b\u043e\u043d\u0435\u043d\u0438\u0435\u043c \u043e\u0442 \u0441\u0440\u0435\u0434\u043d\u0435\u0433\u043e \u0432 342.79 Kb.<br \/>  \u041d\u0430\u043c \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u043e \u043f\u0435\u0440\u0435\u043c\u0435\u0441\u0442\u0438\u0442\u044c 66.71 Mb c <code>shardA<\/code> \u043d\u0430 <code>shardB<\/code> \u0438 164.22 Mb c <code>shardB<\/code> \u043d\u0430 <code>shardC<\/code>.<br \/>  <code>shardA<\/code> \u0431\u0443\u0434\u0435\u0442 \u0443\u043c\u0435\u043d\u044c\u0448\u0435\u043d \u043d\u0430 66.71 Mb<br \/>  <code>shardB<\/code> \u0431\u0443\u0434\u0435\u0442 \u0443\u043c\u0435\u043d\u044c\u0448\u0435\u043d \u043d\u0430 97.50 Mb<br \/>  <code>shardC<\/code> \u0431\u0443\u0434\u0435\u0442 \u0443\u0432\u0435\u043b\u0438\u0447\u0435\u043d \u043d\u0430 164.22 Mb<\/p>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 \u0442\u0430\u043a\u043e\u0439 \u0444\u0430\u0439\u043b \u0441 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438 \u043d\u0430 \u0441\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0433\u0440\u0430\u043d\u0438\u0446 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u043d \u043f\u043e\u0441\u043b\u0435 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. <\/p>\n<p>  <\/p>\n<pre><code class=\"javascript\">\/\/ Found solution with max deviation of 342.79 Kb between shards \/\/ Equalize shards from disbalance.jobs \/\/ [shardA] &gt; 96.46 Mb &gt; [shardB] &gt; 193.11 Mb &gt; [shardC] \/\/ change tags sh.removeTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : MinKey }, { &quot;projectId&quot; : NumberInt(342) }, &quot;shardA&quot;); sh.removeTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : NumberInt(342) }, { &quot;projectId&quot; : NumberInt(683) }, &quot;shardB&quot;); sh.removeTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : NumberInt(683) }, { &quot;projectId&quot; : MaxKey }, &quot;shardC&quot;); sh.addTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : MinKey }, { &quot;projectId&quot; : NumberInt(304) }, &quot;shardA&quot;); sh.addTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : NumberInt(304) }, { &quot;projectId&quot; : NumberInt(607) }, &quot;shardB&quot;); sh.addTagRange( &quot;disbalance.jobs&quot;, { &quot;projectId&quot; : NumberInt(607) }, { &quot;projectId&quot; : MaxKey }, &quot;shardC&quot;); \/\/ --- \/\/     Chunks to be moved: 6 \/\/     Incoming data by shard: \/\/         [shardA] 0 b \/\/         [shardB] 96.46 Mb \/\/         [shardC] 193.11 Mb<\/code><\/pre>\n<p>  <\/p>\n<p>\u0415\u0433\u043e \u043d\u0430\u0434\u043e \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043f\u043e\u0434 \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u044c\u044e \u0441 \u043f\u0440\u0430\u0432\u0430\u043c\u0438 clusterManager.<br \/>  \u0411\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0449\u0438\u043a \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0435 \u0432\u044b\u043a\u043b\u044e\u0447\u0430\u0442\u044c, \u0442.\u043a. \u043e\u043d \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0441 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0437\u0430\u0434\u0435\u0440\u0436\u043a\u043e\u0439 \u0438 \u043d\u0435 \u043d\u0430\u0447\u043d\u0435\u0442 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u0442\u044c \u0447\u0430\u043d\u043a\u0438 \u043d\u0430 \u043c\u043e\u043c\u0435\u043d\u0442 \u043f\u0435\u0440\u0435\u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0433\u0440\u0430\u043d\u0438\u0446.<\/p>\n<p>  <\/p>\n<p>\u041d\u0443 \u0438 \u0434\u0430\u043b\u0435\u0435 \u043c\u044b \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c\u0441\u044f \u043a \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0443 <a href=\"#monitoring-peremescheniya-chankov\">\u041c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433 \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0447\u0430\u043d\u043a\u043e\u0432<\/a> \u0438 \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u0437\u0430\u043c\u043a\u043d\u0443\u0442\u044b\u0439 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043d\u0430\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u044f \u0438 \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u0439 \u0433\u0440\u0430\u043d\u0438\u0446 \u043f\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438. <\/p>\n<p>  <\/p>\n<h3 id=\"udalenie-pustyh-chankov\">\u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043f\u0443\u0441\u0442\u044b\u0445 \u0447\u0430\u043d\u043a\u043e\u0432<\/h3>\n<p>  <\/p>\n<p>\u041f\u0440\u0438\u0447\u0438\u043d\u0430 \u043f\u0443\u0441\u0442\u044b\u0445 \u0447\u0430\u043d\u043a\u043e\u0432 \u2014 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u0433\u0440\u0443\u043f\u043f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432.<br \/>  \u0415\u0441\u043b\u0438 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440 \u0433\u0440\u0443\u043f\u043f\u044b \u043d\u0435 \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0443 \u043d\u0435\u0433\u043e \u0442\u0438\u043f GUID \u0438\u043b\u0438 ObjectId), \u0442\u043e \u043d\u043e\u0432\u044b\u0445 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0441 \u0442\u0430\u043a\u0438\u043c \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u043e\u043c \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442.<\/p>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u043c\u044b \u043d\u0435 \u0443\u0442\u043e\u0447\u043d\u044f\u043b\u0438 \u043a\u043b\u044e\u0447 \u0448\u0430\u0440\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0442\u043e \u043f\u0443\u0441\u0442\u044b\u0435 \u0447\u0430\u043d\u043a\u0438 \u2014 \u044d\u0442\u043e \u0431\u044b\u0432\u0448\u0438\u0435 jumbo-\u0447\u0430\u043d\u043a\u0438 \u0441 \u043e\u0447\u0435\u043d\u044c \u0443\u0437\u043a\u0438\u043c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u043e\u043c \u043a\u043b\u044e\u0447\u0435\u0439.<br \/>  \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0440\u043e\u0432\u043d\u043e \u0434\u043b\u044f \u043e\u0434\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430:<\/p>\n<p>  <\/p>\n<pre><code class=\"javascript\">{   min: { projectId: 228 },   max: { projectId: 229 }, }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0443\u0442\u043e\u0447\u043d\u044f\u043b\u0438, \u0442\u043e \u044d\u0442\u043e \u0431\u0443\u0434\u0443\u0442 \u0447\u0430\u043d\u043a\u0438 \u0443 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0433\u0440\u0430\u043d\u0438\u0446\u044b \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0432 \u043f\u0435\u0440\u0432\u043e\u043c \u043f\u043e\u043b\u0435.<\/p>\n<p>  <\/p>\n<pre><code class=\"javascript\">{   min: { projectId: 3, name: &quot;Job IG5U&quot; },   max: { projectId: 3, name: &quot;Job M7JPO&quot; }, }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043e\u0431\u043e\u0438\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043f\u043e\u0447\u0442\u0438 \u043d\u0435\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u0447\u0442\u043e \u0432 \u044d\u0442\u043e\u0442 \u0447\u0430\u043d\u043a \u043f\u043e\u043f\u0430\u0434\u0443\u0442 \u043d\u043e\u0432\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435.<br \/>  \u041a\u043e\u043f\u0438\u0442\u044c \u043f\u0443\u0441\u0442\u044b\u0435 \u0447\u0430\u043d\u043a\u0438 \u043d\u0435 \u0441\u0442\u043e\u0438\u0442, \u0442.\u043a. \u043e\u043d\u0438 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0437\u0430\u043c\u0435\u0434\u043b\u044f\u044e\u0442 \u0440\u0430\u0431\u043e\u0442\u0443 \u0440\u043e\u0443\u0442\u0435\u0440\u043e\u0432 \u0438 \u0441\u0438\u043b\u044c\u043d\u043e \u0431\u0443\u0434\u0443\u0442 \u0437\u0430\u043c\u0435\u0434\u043b\u044f\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u0443\u0442\u0438\u043b\u0438\u0442\u044b.<br \/>  \u041a \u0441\u0447\u0430\u0441\u0442\u044c\u044e, \u0438 \u0438\u0441\u043a\u0430\u0442\u044c \u043f\u0443\u0441\u0442\u044b\u0435 \u0447\u0430\u043d\u043a\u0438 \u043d\u0435 \u043d\u0430\u0434\u043e. \u041c\u044b \u0431\u0443\u0434\u0435\u043c \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u044f\u0442\u044c \u0432\u0435\u0441\u044c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0448\u0430\u0440\u0434\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">dotnet ShardEqualizer merge<\/code><\/pre>\n<p>  <\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u2014 \u0444\u0430\u0439\u043b \u0441\u043e \u0441\u043a\u0440\u0438\u043f\u0442\u0430\u043c\u0438 \u043d\u0430 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u0447\u0430\u043d\u043a\u043e\u0432.<\/p>\n<p>  <\/p>\n<pre><code class=\"javascript\">\/\/ merge chunks on disbalance.jobs \/\/   shard: shardA db.adminCommand({ mergeChunks: &quot;disbalance.jobs&quot;, bounds: [ { &quot;projectId&quot; : MinKey, &quot;name&quot; : MinKey }, { &quot;projectId&quot; : NumberInt(4), &quot;name&quot; : &quot;8P9PJRVUX&quot; } ] }); \/\/   shard: shardB db.adminCommand({ mergeChunks: &quot;disbalance.jobs&quot;, bounds: [ { &quot;projectId&quot; : NumberInt(4), &quot;name&quot; : &quot;8P9PJRVUX&quot; }, { &quot;projectId&quot; : NumberInt(38), &quot;name&quot; : MinKey } ] }); \/\/   shard: shardC db.adminCommand({ mergeChunks: &quot;disbalance.jobs&quot;, bounds: [ { &quot;projectId&quot; : NumberInt(76), &quot;name&quot; : MinKey }, { &quot;projectId&quot; : MaxKey, &quot;name&quot; : MaxKey } ] }); \/\/  --<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0433\u0438\u0433\u0430\u043d\u0442\u0441\u043a\u0438\u0435 \u0447\u0430\u043d\u043a\u0438. \u041d\u043e \u043d\u0435 \u0441\u0442\u043e\u0438\u0442 \u0431\u0435\u0441\u043f\u043e\u043a\u043e\u0438\u0442\u044c\u0441\u044f. \u041f\u0440\u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0438 \u0438\u043b\u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0432 \u043d\u0438\u0445, \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0449\u0438\u043a \u043e\u043f\u044f\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0434\u0435\u0442 \u0440\u0430\u0437\u0431\u0438\u0432\u043a\u0443. \u042d\u0442\u043e \u0437\u0430\u0439\u043c\u0435\u0442 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f, \u0430 \u0434\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u0438 \u0433\u0440\u0430\u043d\u0438\u0446 \u0442\u0440\u0435\u0431\u0443\u044e\u0442\u0441\u044f \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u0435 \u0447\u0430\u043d\u043a\u0438. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u043e\u0434\u0447\u0438\u0441\u0442\u043a\u0443 \u043f\u0443\u0441\u0442\u044b\u0445 \u0447\u0430\u043d\u043a\u043e\u0432 \u043b\u0443\u0447\u0448\u0435 \u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0440\u0430\u0437\u0443 \u043f\u043e\u0441\u043b\u0435 \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0433\u043e \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f. \u0427\u0442\u043e\u0431\u044b \u043a \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c\u0443 \u0434\u0438\u0441\u0431\u0430\u043b\u0430\u043d\u0441\u0443 \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0448\u0430\u0440\u0434\u043e\u0432, \u0447\u0430\u043d\u043a\u0438 \u0443\u0436\u0435 \u0431\u044b\u043b\u0438 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d\u044b.<\/p>\n<p>  <\/p>\n<h2 id=\"naputstvie\">\u041d\u0430\u043f\u0443\u0442\u0441\u0442\u0432\u0438\u0435<\/h2>\n<p>  <\/p>\n<p>\u0423\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0445 \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u043c\u0435\u043d\u0435\u0435 \u0441\u0442\u0440\u0430\u0448\u043d\u044b\u043c, \u0447\u0435\u043c \u043f\u0435\u0440\u0432\u044b\u0439 \u0440\u0430\u0437 \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u0442\u044c\u0441\u044f \u0441 \u0440\u0430\u0437\u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u043e\u0439 \u0434\u0430\u043d\u043d\u044b\u0445. \u041d\u0430\u043c \u043d\u0435 \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0443\u043d\u0438\u0432\u0435\u0440\u0441\u0430\u043b\u044c\u043d\u044b\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u043d\u0430 \u0432\u0441\u0435 \u0441\u043b\u0443\u0447\u0430\u0438 \u0436\u0438\u0437\u043d\u0438, \u0438 \u0437\u0434\u0435\u0441\u044c \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043b\u0438 \u0432\u0441\u0435\u0433\u043e \u043e\u0434\u0438\u043d \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u044b\u0439 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439.<\/p>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u0434\u0440\u0443\u0433\u0438\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u0448\u0430\u0440\u0434\u0438\u043d\u0433\u0430 \u2014 \u043e\u0431\u0440\u0430\u0449\u0430\u0439\u0442\u0435\u0441\u044c, \u0431\u0443\u0434\u0435\u0442 \u0447\u0442\u043e \u043e\u0431\u0441\u0443\u0434\u0438\u0442\u044c!<\/p>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/553606\/\"> https:\/\/habr.com\/ru\/post\/553606\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/post_images\/8fb\/882\/d0e\/8fb882d0e1537254ee1bc4476b6bcbdb.png\" alt=\"image\" align=\"right\">  <\/p>\n<p>&quot;\u0420\u0430\u0437\u043c\u044b\u0448\u043b\u0435\u043d\u0438\u044f \u0431\u0435\u0437 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0438 \u043f\u0440\u0438\u0432\u043e\u0434\u044f\u0442 \u043a \u0437\u0430\u0431\u043b\u0443\u0436\u0434\u0435\u043d\u0438\u044e, \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430 \u0431\u0435\u0437 \u0440\u0430\u0437\u043c\u044b\u0448\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0437\u0430\u0442\u0440\u0443\u0434\u043d\u0435\u043d\u0438\u044e.&quot;<\/p>\n<p>  <\/p>\n<p>\u041c\u044b \u0432\u0435\u0434\u0451\u043c \u0432\u043e\u0439\u043d\u0443 \u0441 \u0438\u043d\u0434\u0438\u0432\u0438\u0434\u0443\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e \u0443 \u0448\u0430\u0440\u0434\u043e\u0432 \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435 MongoDB.<br \/>  \u042d\u0442\u043e \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/553556\">\u0428\u0430\u0440\u0434\u0438\u043d\u0433 \u043e\u0442 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043e\u0442\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f<\/a>, \u0430 \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u043d\u0430\u0441\u0442\u0443\u043f\u0438\u043b\u0430 \u043f\u043e\u0440\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u0438\u043a\u0438.<\/p>\n<p>  <\/p>\n<p>\u041a\u0430\u043a \u044f \u0438 \u043e\u0431\u0435\u0449\u0430\u043b, \u0437\u0434\u0435\u0441\u044c \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0443 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u044f \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0448\u0430\u0440\u0434\u043e\u0432<\/li>\n<li>\u0440\u0430\u0441\u0447\u0435\u0442 \u043f\u043e\u043f\u0440\u0430\u0432\u043e\u043a \u0434\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0446\u0438\u0438 \u0433\u0440\u0430\u043d\u0438\u0446<\/li>\n<li>\u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u043a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f\u0445<br \/>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-323037","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/323037","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=323037"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/323037\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=323037"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=323037"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=323037"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}