Skip to content
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

Make use of libvirt's volume API #39

Open
zeenix opened this issue Dec 3, 2019 · 7 comments
Open

Make use of libvirt's volume API #39

zeenix opened this issue Dec 3, 2019 · 7 comments
Assignees

Comments

@zeenix
Copy link

zeenix commented Dec 3, 2019

We should be doing this, if not for anything else then at least to avoid copying images without having to rely on external qemu-img command.

@zeenix zeenix self-assigned this Dec 3, 2019
@zeenix
Copy link
Author

zeenix commented Dec 5, 2019

Just remembered that using volume API also implies storage pool API AFAIK. This isn't a problem on it's own. We can create a dir pool and put the volume there but it means that the location of disk image will be different on different platforms then and a bit more work than I previously thought. The latter is not a problem if the former is not though. WDYT?

@cfergeau
Copy link

cfergeau commented Dec 5, 2019

but it means that the location of disk image will be different on different platforms

I don't understand this one. libvirt is only used on linux.

@zeenix
Copy link
Author

zeenix commented Dec 5, 2019

I don't understand this one. libvirt is only used on linux.

that's why the path will be different on Linux (sorry could have worded it better) and that's why on Linux the path will be different. Not sure if it's an issue though.

@cfergeau
Copy link

cfergeau commented Dec 5, 2019

Still not quite clear what you mean :( The dir pool could point at ~/.crc/machines/crc, so the image would still be in the same location as other platforms. I'm totally missing your point and concern :(

@zeenix
Copy link
Author

zeenix commented Dec 5, 2019

The dir pool could point at ~/.crc/machines/crc

Yeah but then the dir belongs to the pool and deletion will remove it, which may not always be what we want.

@cfergeau
Copy link

cfergeau commented Dec 5, 2019

Ok, so you are suggesting pointing the pool at a path outside of ~/.crc/machines/crc ?
Removing the pool behind crc back sounds like something unsupported, so I would say losing ~/.crc/machines/crc in that case would not be that bad.

@zeenix
Copy link
Author

zeenix commented Dec 5, 2019

Ok, so you are suggesting pointing the pool at a path outside of ~/.crc/machines/crc ?

I was thinking of a subdir there actually but now I also remembered that currently the driver keeps room for multiple machines in the future (crc machine name is not hard coded) so a directory outside that would be best, yes.

Removing the pool behind crc back sounds like something unsupported,

No, I wasn't thinking of that. I was thinking that we might not want everything in that dir to be always deleted at the same time as we delete the pool, in the future. Also the other way around: not deleting the pool but deleting the dir still. The main issue i see here is the dir becoming a property of the pool and it's not exactly the case here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants