{"action":"created","issue":{"url":"https://api.github.com/repos/kubernetes/kubernetes/issues/57185","repository_url":"https://api.github.com/repos/kubernetes/kubernetes","labels_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/57185/labels{/name}","comments_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/57185/comments","events_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/57185/events","html_url":"https://github.com/kubernetes/kubernetes/issues/57185","id":282019068,"node_id":"MDU6SXNzdWUyODIwMTkwNjg=","number":57185,"title":"Support online file system resize for PVs","user":{"login":"mlmhl","id":7688266,"node_id":"MDQ6VXNlcjc2ODgyNjY=","avatar_url":"https://avatars2.githubusercontent.com/u/7688266?v=4","gravatar_id":"","url":"https://api.github.com/users/mlmhl","html_url":"https://github.com/mlmhl","followers_url":"https://api.github.com/users/mlmhl/followers","following_url":"https://api.github.com/users/mlmhl/following{/other_user}","gists_url":"https://api.github.com/users/mlmhl/gists{/gist_id}","starred_url":"https://api.github.com/users/mlmhl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlmhl/subscriptions","organizations_url":"https://api.github.com/users/mlmhl/orgs","repos_url":"https://api.github.com/users/mlmhl/repos","events_url":"https://api.github.com/users/mlmhl/events{/privacy}","received_events_url":"https://api.github.com/users/mlmhl/received_events","type":"User","site_admin":false},"labels":[{"id":267761362,"node_id":"MDU6TGFiZWwyNjc3NjEzNjI=","url":"https://api.github.com/repos/kubernetes/kubernetes/labels/kind/feature","name":"kind/feature","color":"c7def8","default":false},{"id":169428334,"node_id":"MDU6TGFiZWwxNjk0MjgzMzQ=","url":"https://api.github.com/repos/kubernetes/kubernetes/labels/sig/storage","name":"sig/storage","color":"d2b48c","default":false}],"state":"open","locked":false,"assignee":{"login":"gnufied","id":278,"node_id":"MDQ6VXNlcjI3OA==","avatar_url":"https://avatars0.githubusercontent.com/u/278?v=4","gravatar_id":"","url":"https://api.github.com/users/gnufied","html_url":"https://github.com/gnufied","followers_url":"https://api.github.com/users/gnufied/followers","following_url":"https://api.github.com/users/gnufied/following{/other_user}","gists_url":"https://api.github.com/users/gnufied/gists{/gist_id}","starred_url":"https://api.github.com/users/gnufied/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gnufied/subscriptions","organizations_url":"https://api.github.com/users/gnufied/orgs","repos_url":"https://api.github.com/users/gnufied/repos","events_url":"https://api.github.com/users/gnufied/events{/privacy}","received_events_url":"https://api.github.com/users/gnufied/received_events","type":"User","site_admin":false},"assignees":[{"login":"gnufied","id":278,"node_id":"MDQ6VXNlcjI3OA==","avatar_url":"https://avatars0.githubusercontent.com/u/278?v=4","gravatar_id":"","url":"https://api.github.com/users/gnufied","html_url":"https://github.com/gnufied","followers_url":"https://api.github.com/users/gnufied/followers","following_url":"https://api.github.com/users/gnufied/following{/other_user}","gists_url":"https://api.github.com/users/gnufied/gists{/gist_id}","starred_url":"https://api.github.com/users/gnufied/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gnufied/subscriptions","organizations_url":"https://api.github.com/users/gnufied/orgs","repos_url":"https://api.github.com/users/gnufied/repos","events_url":"https://api.github.com/users/gnufied/events{/privacy}","received_events_url":"https://api.github.com/users/gnufied/received_events","type":"User","site_admin":false}],"milestone":null,"comments":11,"created_at":"2017-12-14T08:31:46Z","updated_at":"2018-09-16T14:40:12Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"<!-- This form is for bug reports and feature requests ONLY! \r\n\r\nIf you're looking for help check [Stack Overflow](https://stackoverflow.com/questions/tagged/kubernetes) and the [troubleshooting guide](https://kubernetes.io/docs/tasks/debug-application-cluster/troubleshooting/).\r\n-->\r\n\r\n**Is this a BUG REPORT or FEATURE REQUEST?**:\r\n\r\n> Uncomment only one, leave it on its own line: \r\n>\r\n> /kind bug\r\n\r\n/kind feature\r\n\r\n**What happened**:\r\n\r\nIn current implement, we only support offline file system resize for PVs in kubelet, as this operation is executed by the `MountVolume` operation. If a resize request was submitted after the volume mounted, it won't be resized.\r\n\r\n**What you expected to happen**:\r\n\r\nSupport online file system resize for PVs.\r\n\r\n**Anything else we need to know?**:\r\n\r\nI think the key point is how kubelet to discover volumes need resize operation. If kubelet just watch all PVCs, it will receive the whole PVCs in the cluster, including ones not attached to this node, so this approach maybe increase the pressure of apiserver/etcd as the scale of the cluster increases(in other words, more kbuelets in cluster).\r\n\r\nA feasible solution maybe:\r\n\r\n1. Add a label  `expandable-volume-mounted-{nodeName}=yes` or something like this to PVC, indicated that this PVC has been mounted to `{nodeName}`, we can do this after the mount operation succeeded, and remove it after the umount operation finished. Thus the kubelet can only watch PVCs mounted to itself. For better performance, we can add this label only for expandable volumes. Of course, we need a `reconciler` to promise this label.\r\n2. Kubelet watches all PVCs mounted to itself with a label selector, and checks whether the PVC in `Resizing` state or not. If so, puts a `VolumeToResize` object, or something like this, to the cache.\r\n3. Add an resize operation to the `VolumeManager`'s `reconcile` go routine, follows the attach/mount operation. This resize operation will processes all `VolumeToResize` objects. Of course, we need to check whether the volume exactly mounted in the `ActualStateOfWorld`.\r\n4. Maybe we need to add a `OnlineResizeSupported` method for the volume plugin, used to check whether the volume type and file system supports online resize or not.\r\n\r\nDo we have any plan for this feature? If not, can I submit a more detailed proposal for this?"},"comment":{"url":"https://api.github.com/repos/kubernetes/kubernetes/issues/comments/421775730","html_url":"https://github.com/kubernetes/kubernetes/issues/57185#issuecomment-421775730","issue_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/57185","id":421775730,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMTc3NTczMA==","user":{"login":"fejta-bot","id":30488982,"node_id":"MDQ6VXNlcjMwNDg4OTgy","avatar_url":"https://avatars1.githubusercontent.com/u/30488982?v=4","gravatar_id":"","url":"https://api.github.com/users/fejta-bot","html_url":"https://github.com/fejta-bot","followers_url":"https://api.github.com/users/fejta-bot/followers","following_url":"https://api.github.com/users/fejta-bot/following{/other_user}","gists_url":"https://api.github.com/users/fejta-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/fejta-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fejta-bot/subscriptions","organizations_url":"https://api.github.com/users/fejta-bot/orgs","repos_url":"https://api.github.com/users/fejta-bot/repos","events_url":"https://api.github.com/users/fejta-bot/events{/privacy}","received_events_url":"https://api.github.com/users/fejta-bot/received_events","type":"User","site_admin":false},"created_at":"2018-09-16T14:40:12Z","updated_at":"2018-09-16T14:40:12Z","author_association":"NONE","body":"Issues go stale after 90d of inactivity.\nMark the issue as fresh with `/remove-lifecycle stale`.\nStale issues rot after an additional 30d of inactivity and eventually close.\n\nIf this issue is safe to close now please do so with `/close`.\n\nSend feedback to sig-testing, kubernetes/test-infra and/or [fejta](https://github.com/fejta).\n/lifecycle stale"}}
{"actor":{"display_login":"fejta-bot"}}