{"action":"opened","number":3266,"pull_request":{"url":"https://api.github.com/repos/dcos/dcos/pulls/3266","id":207602705,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA3NjAyNzA1","html_url":"https://github.com/dcos/dcos/pull/3266","diff_url":"https://github.com/dcos/dcos/pull/3266.diff","patch_url":"https://github.com/dcos/dcos/pull/3266.patch","issue_url":"https://api.github.com/repos/dcos/dcos/issues/3266","number":3266,"state":"open","locked":false,"title":"Use total space available in mount disks when creating Mesos resources.","user":{"login":"ArmandGrillet","id":2117580,"node_id":"MDQ6VXNlcjIxMTc1ODA=","avatar_url":"https://avatars0.githubusercontent.com/u/2117580?v=4","gravatar_id":"","url":"https://api.github.com/users/ArmandGrillet","html_url":"https://github.com/ArmandGrillet","followers_url":"https://api.github.com/users/ArmandGrillet/followers","following_url":"https://api.github.com/users/ArmandGrillet/following{/other_user}","gists_url":"https://api.github.com/users/ArmandGrillet/gists{/gist_id}","starred_url":"https://api.github.com/users/ArmandGrillet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ArmandGrillet/subscriptions","organizations_url":"https://api.github.com/users/ArmandGrillet/orgs","repos_url":"https://api.github.com/users/ArmandGrillet/repos","events_url":"https://api.github.com/users/ArmandGrillet/events{/privacy}","received_events_url":"https://api.github.com/users/ArmandGrillet/received_events","type":"User","site_admin":false},"body":"## High-level description\r\n\r\nThis concerns agents and the file `/var/lib/dcos/mesos-resources`.\r\nWe previously used the free space on the agent's mounted volumes\r\nwhen using `make_disk_resources.py` to create the Mesos resources\r\nfile.\r\n\r\nWe recently saw that the Mesos agent would not restart due to this\r\nbehavior for a specific case: a mounted volume is used on an agent\r\nby a framework, the agent is stopped and a second volume is added.\r\nThis is because, when adding an agent, we create again the Mesos\r\nresources file and, if a mounted volume was used, its disk space\r\nwill have decreased. Mesos will then not accept to restart as it\r\ncannot find the volume (due to the change of value).\r\n\r\nTo fix this, we now use the total amount of disk space available on\r\nthe volume. This will not cause problems when upgrading DC/OS as,\r\nwhen `make_disk_resources.py` is first used, the free amount of\r\nspace on a mount volume is likely to be its total amount of space.\r\n\r\n\r\n\r\n## Corresponding DC/OS tickets (obligatory)\r\n\r\nThese DC/OS JIRA ticket(s) must be updated (ideally closed) in the moment this PR lands:\r\n\r\n  - [DCOS_OSS-3921](https://jira.mesosphere.com/browse/DCOS_OSS-3921) COPS-3527 make_disk_resources uses free instead of total amount of disk space available on mount volumes.\r\n\r\n\r\n## Related tickets (optional)\r\n\r\nOther tickets related to this change:\r\n\r\n  - [DCOS_OSS-<number>](https://jira.mesosphere.com/browse/DCOS_OSS-<number>) Foo the Bar so it stops Bazzing.\r\n\r\n\r\n## Checklist for all PRs\r\n\r\n  - [X] Added a comprehensible changelog entry to `CHANGES.md` or explain why this is not a user-facing change:\r\n  - [ ] Included a test which will fail if code is reverted but test is not. If there is no test please explain here:\r\n  - [X] Read the [DC/OS contributing guidelines](https://github.com/dcos/dcos/blob/master/contributing.md)\r\n  - [X] Followed relevant code rules [Rules for Packages and Systemd](https://github.com/dcos/dcos/tree/master/docs)\r\n\r\n\r\n## Checklist for component/package updates:\r\n\r\nIf you are changing components or packages in DC/OS (e.g. you are bumping the sha or ref of anything underneath `packages`), then in addition to the above please also include:\r\n\r\n  - [ ] Change log from the last version integrated (this should be a link to commits for easy verification and review): [example](https://github.com/dcos/dcos-mesos-modules/compare/f6fa27d7c40f4207ba3bb2274e2cfe79b62a395a...6660b90fbbf69a15ef46d0184e36755881d6a5ae)\r\n  - [ ] Test Results: [link to CI job test results for component]\r\n  - [ ] Code Coverage (if available): [link to code coverage report]\r\n___\r\n**PLEASE FILL IN THE TEMPLATE ABOVE** / **DO NOT REMOVE ANY SECTIONS ABOVE THIS LINE**\r\n\r\n\r\n## Instructions and review process\r\n\r\n**What is the review process and when will my changes land?**\r\n\r\nAll PRs require 2 approvals using GitHub's [pull request reviews](https://help.github.com/articles/about-pull-request-reviews/).\r\n\r\nReviewers should be:\r\n* Developers who understand the code being modified.\r\n* Developers responsible for code that interacts with or depends on the code being modified.\r\n\r\nIt is best to proactively ask for 2 reviews by @mentioning the candidate reviewers in the PR comments area. The responsibility is on the developer submitting the PR to follow-up with reviewers and make sure a PR is reviewed in a timely manner. Once a PR has **2 ship-it's**, **no red reviews**, and **all tests are green** it will be included in the [next train](https://github.com/dcos/dcos/blob/master/contributing.md).\r\n","created_at":"2018-08-10T12:51:58Z","updated_at":"2018-08-10T12:51:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/dcos/dcos/pulls/3266/commits","review_comments_url":"https://api.github.com/repos/dcos/dcos/pulls/3266/comments","review_comment_url":"https://api.github.com/repos/dcos/dcos/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dcos/dcos/issues/3266/comments","statuses_url":"https://api.github.com/repos/dcos/dcos/statuses/f664440ed75f189e45820608beba0e11e2f02b0b","head":{"label":"ArmandGrillet:DCOS_OSS-3921","ref":"DCOS_OSS-3921","sha":"f664440ed75f189e45820608beba0e11e2f02b0b","user":{"login":"ArmandGrillet","id":2117580,"node_id":"MDQ6VXNlcjIxMTc1ODA=","avatar_url":"https://avatars0.githubusercontent.com/u/2117580?v=4","gravatar_id":"","url":"https://api.github.com/users/ArmandGrillet","html_url":"https://github.com/ArmandGrillet","followers_url":"https://api.github.com/users/ArmandGrillet/followers","following_url":"https://api.github.com/users/ArmandGrillet/following{/other_user}","gists_url":"https://api.github.com/users/ArmandGrillet/gists{/gist_id}","starred_url":"https://api.github.com/users/ArmandGrillet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ArmandGrillet/subscriptions","organizations_url":"https://api.github.com/users/ArmandGrillet/orgs","repos_url":"https://api.github.com/users/ArmandGrillet/repos","events_url":"https://api.github.com/users/ArmandGrillet/events{/privacy}","received_events_url":"https://api.github.com/users/ArmandGrillet/received_events","type":"User","site_admin":false},"repo":{"id":103262910,"node_id":"MDEwOlJlcG9zaXRvcnkxMDMyNjI5MTA=","name":"dcos","full_name":"ArmandGrillet/dcos","owner":{"login":"ArmandGrillet","id":2117580,"node_id":"MDQ6VXNlcjIxMTc1ODA=","avatar_url":"https://avatars0.githubusercontent.com/u/2117580?v=4","gravatar_id":"","url":"https://api.github.com/users/ArmandGrillet","html_url":"https://github.com/ArmandGrillet","followers_url":"https://api.github.com/users/ArmandGrillet/followers","following_url":"https://api.github.com/users/ArmandGrillet/following{/other_user}","gists_url":"https://api.github.com/users/ArmandGrillet/gists{/gist_id}","starred_url":"https://api.github.com/users/ArmandGrillet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ArmandGrillet/subscriptions","organizations_url":"https://api.github.com/users/ArmandGrillet/orgs","repos_url":"https://api.github.com/users/ArmandGrillet/repos","events_url":"https://api.github.com/users/ArmandGrillet/events{/privacy}","received_events_url":"https://api.github.com/users/ArmandGrillet/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ArmandGrillet/dcos","description":"DC/OS Build and Release tools","fork":true,"url":"https://api.github.com/repos/ArmandGrillet/dcos","forks_url":"https://api.github.com/repos/ArmandGrillet/dcos/forks","keys_url":"https://api.github.com/repos/ArmandGrillet/dcos/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ArmandGrillet/dcos/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ArmandGrillet/dcos/teams","hooks_url":"https://api.github.com/repos/ArmandGrillet/dcos/hooks","issue_events_url":"https://api.github.com/repos/ArmandGrillet/dcos/issues/events{/number}","events_url":"https://api.github.com/repos/ArmandGrillet/dcos/events","assignees_url":"https://api.github.com/repos/ArmandGrillet/dcos/assignees{/user}","branches_url":"https://api.github.com/repos/ArmandGrillet/dcos/branches{/branch}","tags_url":"https://api.github.com/repos/ArmandGrillet/dcos/tags","blobs_url":"https://api.github.com/repos/ArmandGrillet/dcos/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ArmandGrillet/dcos/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ArmandGrillet/dcos/git/refs{/sha}","trees_url":"https://api.github.com/repos/ArmandGrillet/dcos/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ArmandGrillet/dcos/statuses/{sha}","languages_url":"https://api.github.com/repos/ArmandGrillet/dcos/languages","stargazers_url":"https://api.github.com/repos/ArmandGrillet/dcos/stargazers","contributors_url":"https://api.github.com/repos/ArmandGrillet/dcos/contributors","subscribers_url":"https://api.github.com/repos/ArmandGrillet/dcos/subscribers","subscription_url":"https://api.github.com/repos/ArmandGrillet/dcos/subscription","commits_url":"https://api.github.com/repos/ArmandGrillet/dcos/commits{/sha}","git_commits_url":"https://api.github.com/repos/ArmandGrillet/dcos/git/commits{/sha}","comments_url":"https://api.github.com/repos/ArmandGrillet/dcos/comments{/number}","issue_comment_url":"https://api.github.com/repos/ArmandGrillet/dcos/issues/comments{/number}","contents_url":"https://api.github.com/repos/ArmandGrillet/dcos/contents/{+path}","compare_url":"https://api.github.com/repos/ArmandGrillet/dcos/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ArmandGrillet/dcos/merges","archive_url":"https://api.github.com/repos/ArmandGrillet/dcos/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ArmandGrillet/dcos/downloads","issues_url":"https://api.github.com/repos/ArmandGrillet/dcos/issues{/number}","pulls_url":"https://api.github.com/repos/ArmandGrillet/dcos/pulls{/number}","milestones_url":"https://api.github.com/repos/ArmandGrillet/dcos/milestones{/number}","notifications_url":"https://api.github.com/repos/ArmandGrillet/dcos/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ArmandGrillet/dcos/labels{/name}","releases_url":"https://api.github.com/repos/ArmandGrillet/dcos/releases{/id}","deployments_url":"https://api.github.com/repos/ArmandGrillet/dcos/deployments","created_at":"2017-09-12T11:38:37Z","updated_at":"2017-09-12T11:38:40Z","pushed_at":"2018-08-10T12:50:11Z","git_url":"git://github.com/ArmandGrillet/dcos.git","ssh_url":"git@github.com:ArmandGrillet/dcos.git","clone_url":"https://github.com/ArmandGrillet/dcos.git","svn_url":"https://github.com/ArmandGrillet/dcos","homepage":"https://dcos.io","size":6217,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"dcos:master","ref":"master","sha":"550377fe0207e17ce1851eb2e5dd081fe7a3d11c","user":{"login":"dcos","id":17648048,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3NjQ4MDQ4","avatar_url":"https://avatars1.githubusercontent.com/u/17648048?v=4","gravatar_id":"","url":"https://api.github.com/users/dcos","html_url":"https://github.com/dcos","followers_url":"https://api.github.com/users/dcos/followers","following_url":"https://api.github.com/users/dcos/following{/other_user}","gists_url":"https://api.github.com/users/dcos/gists{/gist_id}","starred_url":"https://api.github.com/users/dcos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcos/subscriptions","organizations_url":"https://api.github.com/users/dcos/orgs","repos_url":"https://api.github.com/users/dcos/repos","events_url":"https://api.github.com/users/dcos/events{/privacy}","received_events_url":"https://api.github.com/users/dcos/received_events","type":"Organization","site_admin":false},"repo":{"id":56184050,"node_id":"MDEwOlJlcG9zaXRvcnk1NjE4NDA1MA==","name":"dcos","full_name":"dcos/dcos","owner":{"login":"dcos","id":17648048,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3NjQ4MDQ4","avatar_url":"https://avatars1.githubusercontent.com/u/17648048?v=4","gravatar_id":"","url":"https://api.github.com/users/dcos","html_url":"https://github.com/dcos","followers_url":"https://api.github.com/users/dcos/followers","following_url":"https://api.github.com/users/dcos/following{/other_user}","gists_url":"https://api.github.com/users/dcos/gists{/gist_id}","starred_url":"https://api.github.com/users/dcos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcos/subscriptions","organizations_url":"https://api.github.com/users/dcos/orgs","repos_url":"https://api.github.com/users/dcos/repos","events_url":"https://api.github.com/users/dcos/events{/privacy}","received_events_url":"https://api.github.com/users/dcos/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dcos/dcos","description":"DC/OS - The Datacenter Operating System ","fork":false,"url":"https://api.github.com/repos/dcos/dcos","forks_url":"https://api.github.com/repos/dcos/dcos/forks","keys_url":"https://api.github.com/repos/dcos/dcos/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dcos/dcos/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dcos/dcos/teams","hooks_url":"https://api.github.com/repos/dcos/dcos/hooks","issue_events_url":"https://api.github.com/repos/dcos/dcos/issues/events{/number}","events_url":"https://api.github.com/repos/dcos/dcos/events","assignees_url":"https://api.github.com/repos/dcos/dcos/assignees{/user}","branches_url":"https://api.github.com/repos/dcos/dcos/branches{/branch}","tags_url":"https://api.github.com/repos/dcos/dcos/tags","blobs_url":"https://api.github.com/repos/dcos/dcos/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dcos/dcos/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dcos/dcos/git/refs{/sha}","trees_url":"https://api.github.com/repos/dcos/dcos/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dcos/dcos/statuses/{sha}","languages_url":"https://api.github.com/repos/dcos/dcos/languages","stargazers_url":"https://api.github.com/repos/dcos/dcos/stargazers","contributors_url":"https://api.github.com/repos/dcos/dcos/contributors","subscribers_url":"https://api.github.com/repos/dcos/dcos/subscribers","subscription_url":"https://api.github.com/repos/dcos/dcos/subscription","commits_url":"https://api.github.com/repos/dcos/dcos/commits{/sha}","git_commits_url":"https://api.github.com/repos/dcos/dcos/git/commits{/sha}","comments_url":"https://api.github.com/repos/dcos/dcos/comments{/number}","issue_comment_url":"https://api.github.com/repos/dcos/dcos/issues/comments{/number}","contents_url":"https://api.github.com/repos/dcos/dcos/contents/{+path}","compare_url":"https://api.github.com/repos/dcos/dcos/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dcos/dcos/merges","archive_url":"https://api.github.com/repos/dcos/dcos/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dcos/dcos/downloads","issues_url":"https://api.github.com/repos/dcos/dcos/issues{/number}","pulls_url":"https://api.github.com/repos/dcos/dcos/pulls{/number}","milestones_url":"https://api.github.com/repos/dcos/dcos/milestones{/number}","notifications_url":"https://api.github.com/repos/dcos/dcos/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dcos/dcos/labels{/name}","releases_url":"https://api.github.com/repos/dcos/dcos/releases{/id}","deployments_url":"https://api.github.com/repos/dcos/dcos/deployments","created_at":"2016-04-13T20:31:58Z","updated_at":"2018-08-09T10:49:16Z","pushed_at":"2018-08-10T12:16:59Z","git_url":"git://github.com/dcos/dcos.git","ssh_url":"git@github.com:dcos/dcos.git","clone_url":"https://github.com/dcos/dcos.git","svn_url":"https://github.com/dcos/dcos","homepage":"https://dcos.io","size":6631,"stargazers_count":2019,"watchers_count":2019,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":410,"mirror_url":null,"archived":false,"open_issues_count":116,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":410,"open_issues":116,"watchers":2019,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dcos/dcos/pulls/3266"},"html":{"href":"https://github.com/dcos/dcos/pull/3266"},"issue":{"href":"https://api.github.com/repos/dcos/dcos/issues/3266"},"comments":{"href":"https://api.github.com/repos/dcos/dcos/issues/3266/comments"},"review_comments":{"href":"https://api.github.com/repos/dcos/dcos/pulls/3266/comments"},"review_comment":{"href":"https://api.github.com/repos/dcos/dcos/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dcos/dcos/pulls/3266/commits"},"statuses":{"href":"https://api.github.com/repos/dcos/dcos/statuses/f664440ed75f189e45820608beba0e11e2f02b0b"}},"author_association":"CONTRIBUTOR","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":15,"deletions":5,"changed_files":1}}
{"actor":{"display_login":"ArmandGrillet"}}