{"action":"created","issue":{"url":"https://api.github.com/repos/edenlabllc/ehealth.api/issues/1822","repository_url":"https://api.github.com/repos/edenlabllc/ehealth.api","labels_url":"https://api.github.com/repos/edenlabllc/ehealth.api/issues/1822/labels{/name}","comments_url":"https://api.github.com/repos/edenlabllc/ehealth.api/issues/1822/comments","events_url":"https://api.github.com/repos/edenlabllc/ehealth.api/issues/1822/events","html_url":"https://github.com/edenlabllc/ehealth.api/issues/1822","id":296383521,"number":1822,"title":"test backups restoration process, automatically","user":{"login":"vsirius","id":27923097,"avatar_url":"https://avatars3.githubusercontent.com/u/27923097?v=4","gravatar_id":"","url":"https://api.github.com/users/vsirius","html_url":"https://github.com/vsirius","followers_url":"https://api.github.com/users/vsirius/followers","following_url":"https://api.github.com/users/vsirius/following{/other_user}","gists_url":"https://api.github.com/users/vsirius/gists{/gist_id}","starred_url":"https://api.github.com/users/vsirius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vsirius/subscriptions","organizations_url":"https://api.github.com/users/vsirius/orgs","repos_url":"https://api.github.com/users/vsirius/repos","events_url":"https://api.github.com/users/vsirius/events{/privacy}","received_events_url":"https://api.github.com/users/vsirius/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"vsirius","id":27923097,"avatar_url":"https://avatars3.githubusercontent.com/u/27923097?v=4","gravatar_id":"","url":"https://api.github.com/users/vsirius","html_url":"https://github.com/vsirius","followers_url":"https://api.github.com/users/vsirius/followers","following_url":"https://api.github.com/users/vsirius/following{/other_user}","gists_url":"https://api.github.com/users/vsirius/gists{/gist_id}","starred_url":"https://api.github.com/users/vsirius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vsirius/subscriptions","organizations_url":"https://api.github.com/users/vsirius/orgs","repos_url":"https://api.github.com/users/vsirius/repos","events_url":"https://api.github.com/users/vsirius/events{/privacy}","received_events_url":"https://api.github.com/users/vsirius/received_events","type":"User","site_admin":false},"assignees":[{"login":"vsirius","id":27923097,"avatar_url":"https://avatars3.githubusercontent.com/u/27923097?v=4","gravatar_id":"","url":"https://api.github.com/users/vsirius","html_url":"https://github.com/vsirius","followers_url":"https://api.github.com/users/vsirius/followers","following_url":"https://api.github.com/users/vsirius/following{/other_user}","gists_url":"https://api.github.com/users/vsirius/gists{/gist_id}","starred_url":"https://api.github.com/users/vsirius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vsirius/subscriptions","organizations_url":"https://api.github.com/users/vsirius/orgs","repos_url":"https://api.github.com/users/vsirius/repos","events_url":"https://api.github.com/users/vsirius/events{/privacy}","received_events_url":"https://api.github.com/users/vsirius/received_events","type":"User","site_admin":false}],"milestone":null,"comments":0,"created_at":"2018-02-12T13:58:29Z","updated_at":"2018-02-12T15:12:16Z","closed_at":null,"author_association":"COLLABORATOR","body":"\r\n"},"comment":{"url":"https://api.github.com/repos/edenlabllc/ehealth.api/issues/comments/364951612","html_url":"https://github.com/edenlabllc/ehealth.api/issues/1822#issuecomment-364951612","issue_url":"https://api.github.com/repos/edenlabllc/ehealth.api/issues/1822","id":364951612,"user":{"login":"vsirius","id":27923097,"avatar_url":"https://avatars3.githubusercontent.com/u/27923097?v=4","gravatar_id":"","url":"https://api.github.com/users/vsirius","html_url":"https://github.com/vsirius","followers_url":"https://api.github.com/users/vsirius/followers","following_url":"https://api.github.com/users/vsirius/following{/other_user}","gists_url":"https://api.github.com/users/vsirius/gists{/gist_id}","starred_url":"https://api.github.com/users/vsirius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vsirius/subscriptions","organizations_url":"https://api.github.com/users/vsirius/orgs","repos_url":"https://api.github.com/users/vsirius/repos","events_url":"https://api.github.com/users/vsirius/events{/privacy}","received_events_url":"https://api.github.com/users/vsirius/received_events","type":"User","site_admin":false},"created_at":"2018-02-12T15:12:16Z","updated_at":"2018-02-12T15:12:16Z","author_association":"COLLABORATOR","body":"### **Starting restoration process il db**.  \r\n - IL db basebackup  arhive size - 8.95 GB .\r\n - last xlog segment 000000010000003B0000004D \r\n - PGHOARD RECOVERY TARGET TIME  set to \"2018-02-12T15:30:00Z\"\r\n - RECOVERY process start at 15:51 12/02/2018  \r\n - RECOVERY process end at 16:11 12/02/2018\r\n \r\n\r\nRECOVERY process monitoring snapshot:\r\n<img width=\"1818\" alt=\"screen shot 2018-02-12 at 16 25 21\" src=\"https://user-images.githubusercontent.com/27923097/36101223-625bafa0-1011-11e8-8e36-a01e469f7c31.png\">\r\npghoard-restore logs\r\n[pghoard-restore_logs.txt](https://github.com/edenlabllc/ehealth.api/files/1716575/pghoard-restore_logs.txt)\r\n\r\n### **Rudimentary check**\r\n\r\nNo new xlog segment repllicated to backups during the test! \r\n\r\n**Prod IL** \r\n total amount of records inserted into declaration_requests table\r\n``` \r\nkubectl exec db-0 --namespace il  -- psql --dbname il --username db -c \"select count (*) from public.declaration_requests\" ; \r\n count\r\n-------\r\n 32825\r\n(1 row) \r\n```\r\n amount of records inserted  into  declaration_requests  table 2018-02-12 00:00 to 2018-02-12 16:30\r\n```\r\nkubectl exec db-0 --namespace il  -- psql --dbname il --username db -c \"select count (*) from public.declaration_requests where inserted_at >= '2018-02-12'::date;\" ;\r\n count\r\n-------\r\n   541\r\n(1 row) \r\n```\r\n\r\n**Recovered IL**\r\n\r\n```\r\nkubectl exec pghoard-restore  --namespace monitoring  -- psql --dbname il --username db -c \"select count (*) from public.declaration_requests\" ;\r\n count\r\n-------\r\n 32778\r\n(1 row)\r\n```\r\n\r\n```\r\n count\r\n-------\r\n   493\r\n(1 row)\r\n```\r\nDifferences =  23 rows.\r\n\r\n### **Сonclusion**\r\n\r\nBackup process was successful. Il db recovered from backup point in time and ready to accept connections.\r\n"}}
{"actor":{"display_login":"vsirius"}}