[Users] Gentoo/Slackware

Mark Johanson mjohanson at a2hosting.com
Tue Nov 14 03:05:27 MSK 2017


Hello Dmitry,

Yeah that was my blindness on the distribution file. Saw the desc/summary have the same info and scrolled right past the distribution entry. 

I tried to do that test with adding the distribution file, but (and I am going to guess this might be due to a Solus thing) the template will fail to build due to this:

2017-11-13T18:57:42-0500 vzctl : CT 320 : running: /usr/sbin/vzpkg info -q --config ve-320.conf-sample --ostemplate gentoo-2011-x86_64-default --vefstype ext4
2017-11-13T18:57:42-0500 vzctl : CT 320 : Cached package set 'gentoo-2011-x86_64-default' is not found, run create cache utility...
2017-11-13T18:57:42-0500 vzctl : CT 320 : running: /usr/sbin/vzpkg create cache gentoo-2011-x86_64-default --vefstype ext4
2017-11-13T18:57:42-0500 vzctl : CT 320 : Creating OS template cache for gentoo-2011-x86_64-default template
2017-11-13T18:57:42-0500 vzctl : CT 320 : Looking for the precreated template cache /vz/template/cache/gentoo-2011-x86_64-default.tar.gz
2017-11-13T18:57:42-0500 vzctl : CT 320 : Error: Config directory for the selected template already exists: /vz/template/gentoo/2011/x86_64/config/os/default
2017-11-13T18:57:42-0500 vzctl : CT 320 : Error: Remove this config directory and run the script again
2017-11-13T18:57:42-0500 vzctl : CT 320 : Error: Failed to convert the precreated cache /vz/template/cache/gentoo-2011-x86_64-default.tar.gz

But if I delete the complaining directory, then so goes the distribution file that is not being generated.

Until openvz7 we never switch to ploop files, so much of this is new to me and a very frustrating change (as one can probably imagine). 

I will look at it more tomorrow when I am less distracted by another node thats causing me grief.

Thanks for the info though Dmitry, this is very likely the issue I have been having with both the slackware and gentoo templates and both did not have the distribution files in the respective cache directories.

On 11/13, Dmitry Konstantinov wrote:
> There's a per ve aka container config file under /vz/private/<uuid>/
> directory. 
> 
> the distribution file is not empty. 
> 
> > > 'distrubution' file:
> > > # cat /vz/template/gentoo/22/x86_64/config/os/default/distribution
> > > gentoo
> 
> 
> 
> On Monday, November 13, 2017 5:47:25 PM EST Mark Johanson wrote:
> > Hello Dmitry,
> > 
> > Which ve.conf file? You mean the vz.conf file?
> > 
> > I noticed one difference with yours and what is generated when I use our
> > production template or a freshly downloaded gentoo from openvz website.
> > Yours has a distribution file that ours is missing.
> > 
> > /vz/template/gentoo/2011/x86_64/config/os/default
> > 
> > root [0.28 ] default #ls -l
> > total 8
> > -rw-r--r-- 1 root root 40 Oct 26 12:47 description
> > -rw-r--r-- 1 root root  0 Oct 26 12:47 mirrorlist
> > -rw-r--r-- 1 root root  0 Oct 26 12:47 no_pkg_actions
> > -rw-r--r-- 1 root root  0 Oct 26 12:47 package_manager
> > -rw-r--r-- 1 root root  0 Oct 26 12:47 packages
> > -rw-r--r-- 1 root root 40 Oct 26 12:47 summary
> > 
> > I wonder if that missing file is whats causing the issues I'm having. The
> > distribution file is empty?
> > 
> > Thanks,
> > 
> > On 11/13, Dmitry Konstantinov wrote:
> > > I had to create the following dummy "template":
> > > # tree /vz/template/gentoo/22
> > > /vz/template/gentoo/22
> > > └── x86_64
> > > 
> > >     └── config
> > >     
> > >         └── os
> > >         
> > >             └── default
> > >             
> > >                 ├── description
> > >                 ├── distribution
> > >                 ├── mirrorlist
> > >                 ├── no_pkg_actions
> > >                 ├── package_manager
> > >                 ├── packages
> > >                 └── summary
> > > 
> > > 4 directories, 7 files
> > > #
> > > 
> > > and use
> > > 
> > > OSTEMPLATE="gentoo-22-x86_64"
> > > 
> > > in the ve.conf file.
> > > 
> > > "22" is just a random number, without it vzctl weren't able to
> > > pick up network script(s) .
> > > 
> > >  'description' an 'summary' files have the same content:
> > > # cat /vz/template/gentoo/22/x86_64/config/os/default/description
> > > gentoo 22 (for x86_64) OpenVZ template
> > > 
> > > 'distrubution' file:
> > > # cat /vz/template/gentoo/22/x86_64/config/os/default/distribution
> > > gentoo
> > > 
> > > the remaining four files are empty.
> > > 
> > > On Thursday, November 9, 2017 7:10:49 PM EST Mark Johanson wrote:
> > > > Hello,
> > > > 
> > > > Thanks for the info Scott. I'll have read through that all and see if I
> > > > can
> > > > figure out what needs to change. The templates having issues are our
> > > > production (vz legacy) templates on centos6 nodes and never had a
> > > > problem.
> > > > The originals are all from the openvz temlpate download page. So
> > > > probably
> > > > just missing that small info that is causing the failures.
> > > > 
> > > > Thanks again (off to do some more reading *bleh* :) )
> > > > 
> > > > On 11/09, Scott Dowdle wrote:
> > > > > Greetings,
> > > > > 
> > > > > ----- Original Message -----
> > > > > 
> > > > > > If OpenVZ 7 indeed uses a similar system, you can probably copy over
> > > > > > a few things and monkey-see-monkey-do.
> > > > > 
> > > > > I asked mechleg in the #openvz IRC channel who knows OpenVZ 7 better
> > > > > than
> > > > > I do and for convenience, I'll just paste the IRC lines here:
> > > > > 
> > > > > - - - - -
> > > > > 
> > > > > ‎[16:17] ‎<‎dowdle‎>‎ mechleg: You subscribe to the OpenVZ Users
> > > > > mailing
> > > > > list? ‎
> > > > > [16:18] ‎<‎dowdle‎>‎ mechleg: There was just an email on there with
> > > > > someone asking about getting Slackware and Gentoo working on OpenVZ
> > > > > 7...
> > > > > with the problem that it wasn't configuring the container's
> > > > > networking.
> > > > > I responded with what I thought might help fix it... but not having a
> > > > > VZ7
> > > > > system to look at (especially here at home rather than work), I'm just
> > > > > guessing. ‎
> > > > > [16:18] ‎<‎mechleg‎>‎ no, mostly just skim it when i'm looking for
> > > > > something specific ‎
> > > > > [16:19] ‎<‎dowdle‎>‎ mechleg: If you have time, look at this thread
> > > > > and
> > > > > see what you think:
> > > > > https://lists.openvz.org/pipermail/users/2017-November/thread.html> > > > > [16:28] ‎<‎mechleg‎>‎ looks like right answer, but the location was
> > > > > changed for version 7.  the new location is
> > > > > /usr/libexec/libvzctl/dists/
> > > > > and they would have to make a template with all the right connections
> > > > > (which I do not remember being a hard requirement, but with recent
> > > > > experience finding it may be at this point) ‎
> > > > > [16:29] ‎<‎mechleg‎>‎ without the proper template, openvz does not
> > > > > know
> > > > > which script to use so it uses the default ‎
> > > > > [16:29] ‎<‎mechleg‎>‎ my recent finding is showing that without an
> > > > > installed template, it does not want to do anything ‎
> > > > > [16:30] ‎<‎dowdle‎>‎ mechleg: How does it determine which scripts to
> > > > > use?
> > > > > I OL (OpenVZ Legacy) I think it goes by the first part of the
> > > > > OSTEMPLATE=
> > > > > value in the container config... and matches it to a file with the
> > > > > same
> > > > > name in /etc/vz/dists/.  Does that sound right? ‎
> > > > > [16:32] ‎<‎mechleg‎>‎ with the new templating system, it determines
> > > > > the
> > > > > script to use based on the contents of the template file
> > > > > /vz/template/centos/7/x86_64/config/os/default/distribution ‎
> > > > > [16:33] ‎<‎mechleg‎>‎ and that string would match a file in
> > > > > /usr/libexec/libvzctl/dists/ ‎
> > > > > [16:34] ‎<‎dowdle‎>‎ mechleg: Mind if I copy the IRC lines into a
> > > > > follow-up mailing list email? ‎
> > > > > [16:36] ‎<‎mechleg‎>‎ i have been meaning to subscribe to that list,
> > > > > but
> > > > > feel free to send that along.  to make compatible templates, these are
> > > > > the official docs:
> > > > > https://docs.virtuozzo.com/virtuozzo_7_users_guide/advanced-tasks/crea
> > > > > tin
> > > > > g-customized-containers.html  and also
> > > > > https://docs.virtuozzo.com/virtuozzo_7_users_guide/advanced-tasks/crea
> > > > > tin
> > > > > g-configuration-files-for-new-linux-distributions.html
> > > > > 
> > > > > - - - - -
> > > > > 
> > > > > I hope that helps some.
> > > > > 
> > > > > TYL,
> > > > 
> > > > _______________________________________________
> > > > Users mailing list
> > > > Users at openvz.org
> > > > https://lists.openvz.org/mailman/listinfo/users
> > > 
> > > _______________________________________________
> > > Users mailing list
> > > Users at openvz.org
> > > https://lists.openvz.org/mailman/listinfo/users
> > 
> > _______________________________________________
> > Users mailing list
> > Users at openvz.org
> > https://lists.openvz.org/mailman/listinfo/users
> 
> 
> 
> _______________________________________________
> Users mailing list
> Users at openvz.org
> https://lists.openvz.org/mailman/listinfo/users


More information about the Users mailing list