Libvirt Experimental#2780
Conversation
|
Thanks for opening this pull request! Make sure
|
|
Testing this today, I noted there's something odd with the IO, I don't know if it's with network or disk or what, but provisioning process is quite sluggish with CPU idling after I started adding sites from my earlier VirtualBox config. Initially thought it was something with Ubuntu US server yesterday as I'm learning libvirt myself so there might be mistakes, and might need to run back to VBox setup on another laptop to do some work this week but I'll see if I could figure this out eventually. |
|
Not sure if relevant but provisioning got stuck with some odd warnings. Site config: Provisioning output: Cancelled after it hung for a while. |
|
Discarded the Provisioner, while diagnosing some slowness at parts still, went through a bunch of custom site declarations that I migrated from earlier VirtualBox First live site got imported fine (using https://github.com/jasalt/bvv), off to do some client work then with VVV running on libvirt..
|
|
Note that if libvirt isn't quite there yet and virtualbox is unstable, the docker provider is always an option.
This is likely happening in user land in PHP so probably not a libvirt issue, but if it was it might file system related. I have no clues beyond that for you though, and I'd expect such weirdness to apply to far more than a JPEG file if that were the case. I know that database engines can be sensitive to that sutf but if you're executing WP Admin PHP that likely rules that out |
|
@tomjn yes, Docker has been on mind as potential direction too, especially if it's starting to be considered a stable part of VVV (only have had it working on MacOS so far myself for quick testing). Sharing the kernel would be handy on Linux but rootless container engine would be preferrable. Quick trial before touching libvirt didn't work straight out of box with Debian repo Docker Engine (configured rootless) or Podman (rootless by default), but I'll probably experiment with those approaches a bit later, either if libvirt fails or as a step to getting more efficient setup (no VM). Thank's for tips. |
|
Things pretty much working so far but file/folder permissions with virtiofs in the provider script don't seem correct (trying to follow how ownerships are setup with VBox provider): Leads to For some reason Quick fix seems to be to run Have been able to accomplish some work with the setup so it's looking positive, continuing and trying to get XDebug also working in a bit. |
|
Have you considered: override.vm.synced_folder 'www/', '/srv/www', owner: 'www-data', group: 'www-data', type: 'virtiofs' |
|
I'll test this |
|
XDebug step debugging working almost out of box. There was log permission issue with following happening often that I haven't seen with VBox provider, e.g. when starting up Looking at permissions on functional VVV(VBox) setup: With this libvirt setup it is: Fixed by: |
|
Aside, my host system UFW firewall was running and blocked the XDebug connections coming from VM to port 9003 by default. Inside guest VVV libvirt VM box So fixed on host by allowing allowing all traffic from the subnet: sudo ufw allow from 192.168.121.0/24 to any port 9003
sudo ufw reloadDebugger is stopping at a breakpoint on host as with VBox provider. |
|
Just small update that I haven't noticed any new issues while working on a couple client sites locally using this setup. XDebug works for stepping and profiling, external database connection from host works as with VBox and so on. The shared folder permissions with Linux host work bit differently but it has been pretty straightforward with chmod / chown adjustments. Looking to finish and clean this up in near future before setting PR ready for review. |
Creates a PR for libvirt experimentation @jasalt has been working on
Checks
developbranch not thestablebranch.