{"action":"created","issue":{"url":"https://api.github.com/repos/saltstack/salt/issues/29199","labels_url":"https://api.github.com/repos/saltstack/salt/issues/29199/labels{/name}","comments_url":"https://api.github.com/repos/saltstack/salt/issues/29199/comments","events_url":"https://api.github.com/repos/saltstack/salt/issues/29199/events","html_url":"https://github.com/saltstack/salt/issues/29199","id":118884597,"number":29199,"title":"2015.8.1 and 2015.5.6: salt-minion self-restart doesn't work in daemon mode. Works when not a daemon","user":{"login":"hubez","id":243338,"avatar_url":"https://avatars.githubusercontent.com/u/243338?v=3","gravatar_id":"","url":"https://api.github.com/users/hubez","html_url":"https://github.com/hubez","followers_url":"https://api.github.com/users/hubez/followers","following_url":"https://api.github.com/users/hubez/following{/other_user}","gists_url":"https://api.github.com/users/hubez/gists{/gist_id}","starred_url":"https://api.github.com/users/hubez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hubez/subscriptions","organizations_url":"https://api.github.com/users/hubez/orgs","repos_url":"https://api.github.com/users/hubez/repos","events_url":"https://api.github.com/users/hubez/events{/privacy}","received_events_url":"https://api.github.com/users/hubez/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-11-25T17:19:05Z","updated_at":"2015-11-25T17:29:11Z","closed_at":null,"body":"salt-minion in daemon mode process dies instead of restarting itself\r\n\r\nThe salt-minion is configured to give up and restart itself when no masters are reachable after all the retries are exhausted so that it self recovers.\r\n\r\nWhen I run salt-minion in daemon mode:\r\n```\r\nsalt-minion -l trace -d\r\ntail -f /var/log/salt/minion\r\n```\r\nThis is the end of the log and the salt-minion process never comes back:\r\n```\r\n2015-11-25 16:01:42,672 [salt.scripts                             ][WARNING ][10770] ** Restarting minion **\r\n2015-11-25 16:01:42,672 [salt.scripts                             ][INFO    ][10770] Sleeping random_reauth_delay of 6 seconds\r\n```\r\nps -ef | grep salt returns no salt-minion processes.\r\n\r\nIf I run this not as a daemon:\r\n```\r\nsalt-minion -l trace\r\n```\r\nIt correctly restarts itself and stays alive.\r\n\r\n\r\nThis is a problem because typically we run salt-minion using the service, which runs it in daemon mode.\r\ni.e. service salt-minion start\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/saltstack/salt/issues/comments/159681611","html_url":"https://github.com/saltstack/salt/issues/29199#issuecomment-159681611","issue_url":"https://api.github.com/repos/saltstack/salt/issues/29199","id":159681611,"user":{"login":"hubez","id":243338,"avatar_url":"https://avatars.githubusercontent.com/u/243338?v=3","gravatar_id":"","url":"https://api.github.com/users/hubez","html_url":"https://github.com/hubez","followers_url":"https://api.github.com/users/hubez/followers","following_url":"https://api.github.com/users/hubez/following{/other_user}","gists_url":"https://api.github.com/users/hubez/gists{/gist_id}","starred_url":"https://api.github.com/users/hubez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hubez/subscriptions","organizations_url":"https://api.github.com/users/hubez/orgs","repos_url":"https://api.github.com/users/hubez/repos","events_url":"https://api.github.com/users/hubez/events{/privacy}","received_events_url":"https://api.github.com/users/hubez/received_events","type":"User","site_admin":false},"created_at":"2015-11-25T17:29:11Z","updated_at":"2015-11-25T17:29:11Z","body":"Hoping there is a workaround. Had a frustrating morning because the salt-minion process died on all my machines, and I had to go SSH to each one and restart them."}}