[Users] vz7 libvirt integration

Frank Laszlo flaszlo at nexcess.net
Wed Aug 10 07:05:12 PDT 2016


All,

Thanks for the help. I'm headed in the right direction I think. A couple
more things. I'm trying to create a domain, but am having trouble with the
filesystems. I've create an empty ploop volume using the following XML:

<volume type='ploop'>
  <name>testploop</name>
  <allocation unit='MiB'>10240</allocation>
  <capacity unit='MiB'>10240</capacity>
  <target>
    <format type='ploop'/>
    <path>/vz/private/testploop</path>
    <capacity unit='MiB'>10240</capacity>
  </target>
</volume>

This seems to have finished successfully, and it creates what I would
expect to see. However, when I attempt to create a domain using virsh
define and the following XML, I get an error about the filesystem type
being unsupported:

<domain type='vz'>
  <name>testing123.com</name>
  <uuid>5869cd3e-13fc-4e69-b99a-d37c020987b6</uuid>
  <memory unit='KiB'>1024000</memory>
  <currentMemory unit='KiB'>1024000</currentMemory>
  <vcpu placement='static'>1</vcpu>
  <os>
    <type arch='x86_64'>exe</type>
    <init>/sbin/init</init>
  </os>
  <clock offset='utc'/>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>destroy</on_crash>
  <devices>
    <filesystem type='template'>
        <source name='centos-7-x86_64'/>
        <target dir='/'/>
    </filesystem>
    <filesystem type='file' accessmode='passthrough'>
      <driver type='ploop' format='ploop'/>
      <source file='/vz/private/testploop'/>
      <target dir='/'/>
    </filesystem>
    <interface type='bridge'>
      <mac address='fa:16:3e:c6:5c:90'/>
      <source bridge='ovsbr0'/>
      <target dev='veth5869cd3e-13fc-4e69-b99a-d37c020987b6'/>
      <link state='up'/>
    </interface>
    <input type='mouse' bus='parallels'/>
    <input type='keyboard' bus='parallels'/>
    <graphics type='vnc' port='-1' autoport='yes' listen='1.2.3.4'>
      <listen type='address' address='1.2.3.4'/>
    </graphics>
    <video>
      <model type='parallels' heads='1'/>
    </video>
  </devices>
</domain>



How exactly does one specify the template to use for the ploop storage? Is
this done during volume creation? After digging through the code it appears
the vz driver doesnt support the "template" filesystem type, but the openvz
driver does. Any thoughts?



On Wed, Aug 10, 2016 at 7:20 AM, Maxim Nestratov <mnestratov at virtuozzo.com>
wrote:

> 10-Aug-16 13:47, Sergey Bronnikov пишет:
>
>
> On 13:27 Wed 10 Aug , Sergey Bronnikov wrote:
>>
>>> Hi, Frank
>>>
>>> On 09:43 Tue 09 Aug , Frank Laszlo wrote:
>>>
>>>> Hello,
>>>>
>>>> 1) Am I able to create containers using libvirt? (specifically from XML
>>>> passed to virsh) What does this XML look like?
>>>>
>>> BTW you can find XML example on the libvirt site -
>> http://libvirt.org/drvvirtuozzo.html
>>
>> Sergey
>>
> No, it is an example of VM xml, not CT one.
> Replied to the fist letter.
>



-- 
Frank Laszlo
Nexcess - Beyond Hosting
21700 Melrose Ave.
Southfield, MI. 48075
Cell: +1.248.602.6123
Phone: +1.866.639.2377
Fax:   +1.248.281.0473
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvz.org/pipermail/users/attachments/20160810/251e0754/attachment.html>


More information about the Users mailing list