{"action":"created","issue":{"url":"https://api.github.com/repos/wal-e/wal-e/issues/242","repository_url":"https://api.github.com/repos/wal-e/wal-e","labels_url":"https://api.github.com/repos/wal-e/wal-e/issues/242/labels{/name}","comments_url":"https://api.github.com/repos/wal-e/wal-e/issues/242/comments","events_url":"https://api.github.com/repos/wal-e/wal-e/issues/242/events","html_url":"https://github.com/wal-e/wal-e/pull/242","id":150811590,"number":242,"title":"Fix excessive logging by wal-fetch when standby_mode=on","user":{"login":"earsdown","id":10148059,"avatar_url":"https://avatars.githubusercontent.com/u/10148059?v=3","gravatar_id":"","url":"https://api.github.com/users/earsdown","html_url":"https://github.com/earsdown","followers_url":"https://api.github.com/users/earsdown/followers","following_url":"https://api.github.com/users/earsdown/following{/other_user}","gists_url":"https://api.github.com/users/earsdown/gists{/gist_id}","starred_url":"https://api.github.com/users/earsdown/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/earsdown/subscriptions","organizations_url":"https://api.github.com/users/earsdown/orgs","repos_url":"https://api.github.com/users/earsdown/repos","events_url":"https://api.github.com/users/earsdown/events{/privacy}","received_events_url":"https://api.github.com/users/earsdown/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-04-25T10:09:23Z","updated_at":"2016-05-01T07:54:36Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/wal-e/wal-e/pulls/242","html_url":"https://github.com/wal-e/wal-e/pull/242","diff_url":"https://github.com/wal-e/wal-e/pull/242.diff","patch_url":"https://github.com/wal-e/wal-e/pull/242.patch"},"body":"When running wal-fetch on slaves with standby_mode = on (in recovery.conf), log files fill up with this brain-dead message every 5 seconds, even when --terse mode is enabled:\r\n```\r\nwal_e.blobstore.s3.s3_util WARNING     MSG: could no longer locate object while performing wal restore\r\n        DETAIL: The absolute URI that could not be located is s3://XXXXXXXX/XXXXXXXX/wal_005/00000001000000000000008A.lzo.\r\n        HINT: This can be normal when Postgres is trying to detect what timelines are available during restoration.\r\n        STRUCTURED: time=2016-04-25T09:52:04.977582-00 pid=22160\r\n```\r\nPR is a simple fix to log these messages at INFO level.\r\n\r\nNote: I still get `lzop: <stdin>: not a lzop file` in the log file every 5 seconds, but this is a bit harder to fix properly because the pipeline code doesn't handle stderr at all. Workaround is to use a recovery.conf restore_command like this:\r\n```\r\nrestore_command = 'AWS_REGION=xxxxxxx wal-e --s3-prefix=s3://xxxxxxx/xxxxx --terse --aws-instance-profile wal-fetch \"%f\" \"%p\" 2>&1 | egrep -v \"not a lzop file\"'\r\n```\r\n\r\n**EDIT**: restore_command workaround above is broken because postgresql will get egrep's exit status when it should get wal-e's exit status. Using this restore_command instead fixes that issue:\r\n\r\n```bash\r\n  restore_command = '. /etc/bashrc ; o=\"`AWS_REGION=xxxxxxx wal-e --terse --s3-prefix=s3://mybucket --aws-instance-profile wal-fetch \"%f\" \"%p\" 2>&1`\" ; r=$? ; echo \"$o\" | egrep -v \"not a lzop file\" ; exit $r'\r\n```"},"comment":{"url":"https://api.github.com/repos/wal-e/wal-e/issues/comments/216023858","html_url":"https://github.com/wal-e/wal-e/pull/242#issuecomment-216023858","issue_url":"https://api.github.com/repos/wal-e/wal-e/issues/242","id":216023858,"user":{"login":"earsdown","id":10148059,"avatar_url":"https://avatars.githubusercontent.com/u/10148059?v=3","gravatar_id":"","url":"https://api.github.com/users/earsdown","html_url":"https://github.com/earsdown","followers_url":"https://api.github.com/users/earsdown/followers","following_url":"https://api.github.com/users/earsdown/following{/other_user}","gists_url":"https://api.github.com/users/earsdown/gists{/gist_id}","starred_url":"https://api.github.com/users/earsdown/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/earsdown/subscriptions","organizations_url":"https://api.github.com/users/earsdown/orgs","repos_url":"https://api.github.com/users/earsdown/repos","events_url":"https://api.github.com/users/earsdown/events{/privacy}","received_events_url":"https://api.github.com/users/earsdown/received_events","type":"User","site_admin":false},"created_at":"2016-05-01T07:54:36Z","updated_at":"2016-05-01T07:54:36Z","body":"@fdr  ... no public email alias available either, sorry."}}