-
Notifications
You must be signed in to change notification settings - Fork 222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A wanring message 'Failed to expand filesystem' is logged during successful file system expansion. #560
Comments
Was the volume expansion successful? We ran into that issue today as well with trident |
Also, I found this https://kb.netapp.com/Advice_and_Troubleshooting/Cloud_Services/Trident_Openshift/Resize_of_PVC_leaves_it_in_a_faulted_state and I am wondering if this the same issue expressed via trident logs? |
Hi @ffilippopoulos, Was the message "There are errors in the filesystem, so online resizing is not allowed" logged on your case? In my case, this line records that online expansion was completed successfully. trident-csi-m2bmv trident-main time="2021-03-30T05:58:28Z" level=debug msg="<<<< osutils.execCommand." command=resize2fs error="" output="resize2fs 1.44.5 (15-Dec-2018)\nFilesystem at /dev/dm-0 is mounted on /var/lib/kubelet/pods/8b8de3d6-fd5e-4300-9f23-5d8379ffc3b3/volumes/kubernetes.io~csi/pvc-eee6497c-9670-46eb-96ed-2061141e421a/mount; on-line resizing required\nold_desc_blocks = 1, new_desc_blocks = 1\nThe filesystem on /dev/dm-0 is now 786432 (4k) blocks long.\n" requestID=2789d22d-e0d5-4fcd-a911-64e0407534bf requestSource=CSI IMHO, Trident just called os utilitty 'resize2fs' for already mounted file system. |
I don't think we know this. What we saw was a container failing to start, the logs on the driver:
After we performed manual actions the filesystem ended up in a corrupt state. However we have also successfully recovered a volume from the above state, driver logs:
We suspect Trident unmounts the volume after a failed resize. We then ran
And we able to successfully mount the volume after. |
I will tell you first, this is my private opinion because I'm not a developer nor a engineer of trident.
https://github.com/NetApp/trident/blob/master/utils/osutils.go#L1280-L1285 Once temporary mount(of tmp_dir) is succeeded, trident calls removeMountPoint as a defer func(L1285) regardless of success/failure resizing. |
We investigated resize2fs and it will fail with "Permission denied to resize filesystem" when the filesystem is in an inconsistent state during online resize. It is very likely that the filesystem was in an inconsistent state before the resize operation occurred. |
Fixes issue NetApp#507 * Makes DOCKER_PLUGIN_MODE settable to allow users to upgrade from <=20.07 * Allows users to set config with absolute path * Ensures utilities are in PATH
This was fixed in commit 16e84e6 and will be included in the Trident 21.10.0 release. |
Describe the bug
A wanring message is logged during successful file system expansion with incorrect filesystem size information.
trident-csi-m2bmv trident-main time="2021-03-30T05:58:28Z" level=warning msg="Failed to expand filesystem; size=132224544768" requestID=2789d22d-e0d5-4fcd-a911-64e0407534bf requestSource=CSI
Environment
Our customer reporeted with
To Reproduce
Expected behavior
After expanding the file system, check the file system size correctly and do not issue a warning message.
Additional context
The message is logged here.
trident/utils/osutils.go
Line 1319 in e4b47c2
trident-csi-m2bmv trident-main time="2021-03-30T05:58:28Z" level=warning msg="Failed to expand filesystem; size=132224544768" requestID=2789d22d-e0d5-4fcd-a911-64e0407534bf requestSource=CSI
The reported size is for the root '/' filesystem.
Here are full debug logs.
The text was updated successfully, but these errors were encountered: