-
Notifications
You must be signed in to change notification settings - Fork 55
Conversation
efd509a
to
56932ee
Compare
The code here is now in such shape that tests pass:
Next I tried cluster-mode using system in test/ with 4xVM with qemu-device.
Namespace of 8GB had been created correctly on that VM. When I attach to running pmem-csi container, I can see same failure from mkfs.ext4.
In container:
What causes /dev/pmem0.4 becoming a file instead of device, |
c923f20
to
25cba82
Compare
tested to work:
|
25cba82
to
947a19c
Compare
renamed both flushDevice and clearDevice to start with capital, to make those public |
4ec79dd
to
846ed2a
Compare
I had to put back double dealing with size alignment as we need to do it in different style in LVM2 and direct mode. |
Use error.Wrap to expose error msg from inner call. Note that there may be multiple errors in the loop, but we can capture only the last one using Wrap. Earlier ones are logged. runtime-deps.csv: Adding pkg/errors
dev.manager: moved FlushDevice to separate file pmd-util.go FlushDevice: added argument how many blocks to clear/shred: so that we can optionally use this function in the role where nullify() has been previously. Both device managers:ndctl,lvm use deviceFlush same way via common wrapper function. Device manager: clear start of block device after volume creation: Even though we clear data area after device deletion, let's reduce chances even further that old data remains there and becomes recognized as file system.
nullify() has been unreliable, so we implemented different approach to clear device in Device Manager side. We keep code and call point for reference as commented out, just in case
Caused by how libndctl creates namespaces, we have to adjust our creation request. libndctl v63 creates 1GB smaller size than we request, if alignment is set to 1GB, and fails to create if request is smaller than 2 GB. We have to pass sanity testing where small volumes are created as well. In devicemode:LVM2, we want to allocate as much as we can, but we don't care about sizes. In devicemode:direct, we want the size to be not less what we want. In both cases, we want 1GB alignment.
After recent cleanup in driver, driver does not create directory, means we need to paths tester script. lifecycle script: make size larger 1G, change default erase=true. Unified mode test: move run_driver into util, create direct-nvdimm variant renamed scripts to express the devicemode in script name.
There is also source of diagrams (program 'dia' was used).
New yaml file specifies use of driver in direct mode. Two pre-stages are skipped, devicemode arg is added. We change existing pmem-csi.yaml to be symlink to original deployment manifest that we rename to be lvm specific, to maintain existing use cases pointing to it and reduce parallel documenting needs.
846ed2a
to
6b962e3
Compare
combining some changes here, related to getting direct-nvdimm mode working