*SOLVED* CentOS5 Template Metadata package? [message #12854] |
Fri, 11 May 2007 18:56  |
 |
dowdle
Messages: 261 Registered: December 2005 Location: Bozeman, Montana
|
Senior Member |
|
|
Greetings,
Any timeframe for a CentOS 5 Template Metadata package? I saw that someone has created a howto upgrade a CentOS 4 VPS to CentOS 5 from which they make a template cache... but how about a metadata package?
Are there any technical reasons keeping this from happening or is it basically a time-to-do-it issue?
Thanks in advance for any consideration!
--
TYL, Scott Dowdle
Belgrade, Montana, USA
[Updated on: Wed, 16 May 2007 06:35] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
|
|
Re: CentOS5 Template Metadata package? [message #15228 is a reply to message #14003] |
Mon, 23 July 2007 11:03   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Anything new to this subject?
I going to move a couple of systems to OpenVZ VPS, and feel it is a little odd to start with centos-4 when centos-5 has been ready for some time.
The problem is that I dont have enough knowledge or experince to create the metadata template my self.
I have found the centos-5-i386-XXX.tar.gz and is able to install a centos-5 system, but without the abillity to run vzyum install or update (because of lacking metadata) it is useless.
Any pointers to contributed centos-5 metadata ?
/Thomas
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15245 is a reply to message #12854] |
Tue, 24 July 2007 07:35   |
steve
Messages: 25 Registered: June 2007 Location: Orange County, California
|
Junior Member |
|
|
OK, I've finally managed to get this to work. (If anything besides frustrating, it's made me appreciate the hard work that's gone into all of this.) After seeing posts from sspt getting the template metadata for CentOS 5 to work using the Fedora 5 package I started combing through the Fedora 5 package to see what was different. As it turns out, the only significant difference is that the dummy package is created so as to provide kernel 2.6.9 which is, of course, too old for many of the packages that come with CentOS 5. Simply changing the value in this package to 2.6.18 appears to work. I then worked my way through the remaining files changing references to CentOS 4 to CentOS 5. I also changed the rpm version from 4.3 to 4.4, updated the repo data, changed the GPG keys, and other small, mostly cosmetic changes.
I'm certainly not an rpm expert, but I have created a new rpm for CentOS 5 metadata. I have successfully installed it and created a CentOS 5 minimal cache file from it with no errors. Perhaps one of the developers can check it out and if it's OK I will be happy to contribute it. As it's only 129kb I've attached the rpm here.
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15253 is a reply to message #15245] |
Tue, 24 July 2007 21:47   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Hey steve
I have tried your RPM.
Build the cache files work fine.
The creation of the VPS went fine:
# vzctl create 206 --ostemplate centos-5-i386-minimal
Creating VE private area (centos-5-i386-minimal)
Performing postcreate actions
VE private area was created
and it seems like it will start:
# vzctl start 206
Starting VE ...
VE is mounted
Setting CPU units: 1000
VE start in progress...
but I cant do any thing useful:
# vzctl enter 206
enter into VE 206 failed
Unable to open pty: No such file or directory
My host system is a FC5 with a /vmlinuz-2.6.18-8.el5.028stab027.1 kernel, and I have no problems creating and running centos 4 VPS.
I have tried to ssh into the centos 5 VPS but it says connection refused, which often means no sshd.
vzctl exec works, and ps shows:
# vzctl exec 206 ps
PID TTY TIME CMD
1 ? 00:00:00 init
16341 ? 00:00:00 udevd
17608 ? 00:00:00 syslogd
17636 ? 00:00:00 ps
Any suggestions?
/Thomas
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15260 is a reply to message #15254] |
Wed, 25 July 2007 07:59   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Hi Steve
I tried again on another of my servers - a FC6 host running the same kernel, and every thing worked. So with a little more work I'm sure the FC5 server will work too.
Thanks for your effort.
regards
Thomas
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15278 is a reply to message #15260] |
Wed, 25 July 2007 18:28   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Hi steve (or others)
I have tried different aproached to getting the centos-5 templates to run on my FC5-server.
The cache has been rebuild, and I have verified that no ressources has run into limits via /proc/user_beancounters.
It seems that /dev causes some problems. As shown in a previous post to this thread udevd seems to hang, and the content of /dev is limits to:
# vzctl exec 208 ls /dev
MAKEDEV
X0R
console
core
fd
initctl
log
loop0
loop1
loop2
loop3
loop4
loop5
loop6
loop7
mapper
net
null
parport0
parport1
parport2
parport3
ppp
pts
shm
stderr
stdin
stdout
tty
urandom
zero
As I mentioned in my last post, a FC6 based server works fine. IT seems like both FC5-host and FC6-host uses udev. But still something around udevs seems to cause trouble in the centos 5 VPS.
Any ideas is apreciated.
/Thomas
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? (udev problem) [message #15280 is a reply to message #15278] |
Wed, 25 July 2007 21:11   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Hi steve (and others)
Now I have found a solution, and have centos-5 vps running on my FC5 server.
BUT I still dont understand til problem.
/sys/class/tty/console is missing.
This causes /sbin/start_udev to fail.
From the web (something about coLinux) a similiar problems was seen. And they changed /etc/rc.d/rc.sysinit line
/sbin/start_udev
to
[ -f /sys/class/tty/console/uevent ] && /sbin/start_udev
If I make this change in the centos 5 VPS and restart it, it seems to work.
If I run /sbin/start_udev manually it complains about "kernel too old for this udev". This seems strange since i'm running the newest el5 kernel (2.6.18-8.1.4.el5.028stab035.1).
I dont like to use this rc.sysinit hack, when i dont understand the problem.
Any ideas about what is going on?
/Thomas
|
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15819 is a reply to message #15245] |
Tue, 14 August 2007 16:06   |
 |
dowdle
Messages: 261 Registered: December 2005 Location: Bozeman, Montana
|
Senior Member |
|
|
Steve,
Say... are you the one that created/posted the pre-created CentOS-5 OS template that is found in the pre-created OS template download section? If so, please edit the default.list file from your vztmpl-centos-5 and add yum to it. As it is, vzyum from the HN doesn't work... and using rpm to install yum from within a CentOS-5 based VPS I created is a MAJOR PAIN as it shows a dependency tree that is very hard to satisfy.
If you do rebuild your centos-5 OS template to include yum... please let me know where I can download it. As it is, having a centos-5 based VPS that I can't easily install software on makes it almost useless.
Thanks in advance for any consideration,
Scott Dowdle
--
TYL, Scott Dowdle
Belgrade, Montana, USA
|
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15902 is a reply to message #15853] |
Wed, 15 August 2007 15:21   |
 |
dowdle
Messages: 261 Registered: December 2005 Location: Bozeman, Montana
|
Senior Member |
|
|
Steve,
No, I tried it on a RHEL5 and a CentOS5 based machine and no matter what I did, I still got those error messages... when trying to vzpkgcache using your vztmpl-centos-5 metadata package... which is really weird... because it seems to be trying to compare the package set to that of the hardware node, yes?
Yes, I'm familiar with the default.list file. In the Introduction to OpenVZ Screencast that I did, I mention that file and edit it before building a CentOS 4 cache. Since I have LAN based copies of all of the repos I use, I also alter the yum.conf file and have it point to my repos rather than the stock ones... and it makes it a lot faster.
I have also run into the issue when I create VPSes from the pre-created centos-5 os template... where when I tried to vzctl enter it, it says that pty is missing and fails. I tried the fix that was mentioned in this thread (edit the start_udev line in the /etc/rc.sysinit) but that works for me sometimes and other times it doesn't. Basically trying to get a centos 5 VPS is problematic but I'm sticking with it. I'm guessing it is something with the dummy-udev package but I have no idea what.
--
TYL, Scott Dowdle
Belgrade, Montana, USA
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15907 is a reply to message #15902] |
Wed, 15 August 2007 18:26   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Hi
I was the one that have described the pty problem earlier on this thread.
I have later found out that it is caused by some kind of error that occurs when running vzpkgcache. I have not been able find out what is wrong.
My original test - that gave the pty error - was when I ran vzpkgcache on a FC5 server behind a firewall (with squid proxy - which means no direct internet access). This test scenario gave me a template-cache from which I could create a VPS - but the VPS had the pty error.
On another location I tries the same with an FC6 server with direct internet access. The templatecache created here with vzpkgcahe work perfectly well.
I thought it was an FC5/FC6 issue, and tried to create the templatecache on a FC6 behind the squid-proxy. This image gave the same pty error in VPS on this FC6 server.
Then I tried to move the template-cache created on the FC6-server with direct internet-access to the original FC5 server behind firewall and squid-proxy. VPS's created from the template worked perfectly well, which out the pty error.
I'm still confused but happy that I don't have to patch any setup files, when using the "well-created" template.
If any one can cast light on this issue, it would be nice.
Any one that have experienced the pty problem can try to download my centos5-i386-minimal-template created from the FC6 with direct internet-access, and see if it works (no pty problem, vzyum working)
It is created from an unmodified version of Steve's template, and required Steve's template to be installed to run vzyum.
It can be found on http:/www.sonnet.dk/centos-5-i386-minimal.tar.gz
look forward to hear feedback.
/Tpso
|
|
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15926 is a reply to message #15902] |
Thu, 16 August 2007 06:58   |
steve
Messages: 25 Registered: June 2007 Location: Orange County, California
|
Junior Member |
|
|
dowdle wrote on Wed, 15 August 2007 08:21 | Steve,
No, I tried it on a RHEL5 and a CentOS5 based machine and no matter what I did, I still got those error messages... when trying to vzpkgcache using your vztmpl-centos-5 metadata package... which is really weird... because it seems to be trying to compare the package set to that of the hardware node, yes?
|
I don't think it compares any packages to the host node. As I see yum operates within the self-contained environment of /vz/templates/centos/5/i386. The vzpkgcache program does reference the host node (/usr/share/vzpkg/functions), but, I believe for other things (still warrants investigation though).
Quote: |
Yes, I'm familiar with the default.list file. In the Introduction to OpenVZ Screencast that I did, I mention that file and edit it before building a CentOS 4 cache. Since I have LAN based copies of all of the repos I use, I also alter the yum.conf file and have it point to my repos rather than the stock ones... and it makes it a lot faster.
|
Great idea on the local repos. I should do that too.
Quote: |
I have also run into the issue when I create VPSes from the pre-created centos-5 os template... where when I tried to vzctl enter it, it says that pty is missing and fails. I tried the fix that was mentioned in this thread (edit the start_udev line in the /etc/rc.sysinit) but that works for me sometimes and other times it doesn't. Basically trying to get a centos 5 VPS is problematic but I'm sticking with it. I'm guessing it is something with the dummy-udev package but I have no idea what.
|
When you say dummy-udev package are you referring to the vzdev package with all of the ptys? If you take the image you generate with vzpkgcache and run tar tzf centos-5-i386-minimal.tar.gz on it do you see the /dev/ptys inside?
One other thing, the package in the contributed section was built by tweaking the FC5 package and not from a metadata package ( http://forum.openvz.org/index.php?t=msg&th=2486&star t=0&) so I'm not sure how well this would work with my template. They even make reference to an "ugly" udev solution. That's what got me started on this in the first place.
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15946 is a reply to message #15926] |
Thu, 16 August 2007 16:36   |
 |
dowdle
Messages: 261 Registered: December 2005 Location: Bozeman, Montana
|
Senior Member |
|
|
Steve,
> I don't think it compares any packages to the host node.
> As I see yum operates within the self-contained environment
> of /vz/templates/centos/5/i386. The vzpkgcache program does
> reference the host node (/usr/share/vzpkg/functions), but,
> I believe for other things (still warrants investigation
> though).
Look again at the error message:
- - - -
Transaction Check Error: file /sbin/insmod conflicts between attempted installs of dummy-centos-5-1.0-4.swsoft and module-init-tools-3.3-0.pre3.1.16.0.1.el5
- - - -
The module-init-tools-3.3-0.pre3.1.16.0.1.el5 is NOT a CentOS package. My hn is running RHEL5 and that package IS installed on the hardware node. I searched the entire vz template cache and could not find the module-init-tools package anywhere... so it looks like it is indeed conflicting with a package on the hardware node. I know that it shouldn't even be comparing to a package on the hardware node, right?... so I'm not sure why this is happening but that is the error message I get when I try to run vzpkgcache.
> When you say dummy-udev package are you referring to the
> vzdev package with all of the ptys? If you take the image
> you generate with vzpkgcache and run tar tzf
> centos-5-i386-minimal.tar.gz on it do you see the
>/dev/ptys inside?
I don't know because I can't generate a template. It figures out all of the deps, downloads all of the packages but when it tries to install them to a temp dir... that is when I get the package conflict error... so the packages are not installed... and a .tar.gz file is never created... so I can't check if the ptys are there. Yes, I was referring to the vzdev package.
It'll be nice if we get a working vztmpl-centos-5 packages someday. At least someone uploaded new pre-created OS templates for CentOS 5 yesterday... and the new one seems to be working for me with the single VPS I've created with it. I don't know if I create more VPSes with it if I'll run into the ptys problem or not. It seemed to me that the previous pre-created OS template would hit or miss for me. Sometimes the VPS would work just fine and other times I'd get the pty error.
--
TYL, Scott Dowdle
Belgrade, Montana, USA
|
|
|
|
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15955 is a reply to message #15925] |
Thu, 16 August 2007 20:38   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
steve wrote on Thu, 16 August 2007 08:40 |
tpso wrote on Wed, 15 August 2007 11:26 | Hi
I was the one that have described the pty problem earlier on this thread.
I have later found out that it is caused by some kind of error that occurs when running vzpkgcache. I have not been able find out what is wrong.
/Tpso
|
tpso-
I really don't get this. The only packages that I think would affect the /dev/pty files in the image are in the /vz/templates/centos/5/i386/vz-addons directory after you install vztmpl-centos-5-2.0-2.i386.rpm. vzdev-3.3.13-1.3.swsoft in particular as it actually contains the /dev/pty's that appear in each VPS. Therefore, I don't think Internet connectivity would matter (it obviously would for the remaining packages, but I don't think those are at issue).
Just out of curiosity what is the full command line when you run vzpkgcache?
Also, if you are able to actually get into one of your created VPS's on the bad system, does the vzdev rpm package exist on the VPS? If you can't get into the VPS, can you see ptys in the /vz/private/{VPSid}/dev/ directory from the host node?
|
Hi again Steve
the vzpkgcache command line was very simple: vzpkgcache centos-5-i386-minimal
I cant enter the bad system, but I can "vzctl exec " and run commands. if I run : vzctl exec 207 rpm -qa
I can see I have vzdev-3.3.13-1.3.swsoft installed, and yes I have plenty of pty special-files in /vz/private/207/dev
Regards
tpso
alias Thomas
|
|
|
|
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15992 is a reply to message #12854] |
Fri, 17 August 2007 21:06   |
alticon-brian
Messages: 27 Registered: February 2006 Location: Washington, DC
|
Junior Member |
|
|
O.k., so i finally got in, but it took a bit of hackery.
Here's what i had to do:
strace -f vzctl enter <VEID>
Then look for something like the following near the end:
[pid 19407] open("/dev/ptmx", O_RDWR) = -1 ENOENT (No such file or directory)
[pid 19407] open("/dev/ptyp0", O_RDWR) = -1 ENOENT (No such file or directory)
Identify the ptyp device then run the following:
vzctl exec <VEID> MAKEDEV ptyp0
(replacing this with your device).
Now, possibly, you will need to run this again. I had to do this twice and afterwards was able to get into the VE properly.
[Updated on: Fri, 17 August 2007 21:07] Report message to a moderator
|
|
|
Re: *SOLVED* CentOS5 Template Metadata package? [message #15996 is a reply to message #15992] |
Fri, 17 August 2007 22:08   |
tpso
Messages: 19 Registered: September 2006 Location: Denmark
|
Junior Member |
|
|
Hi,
This thread describe a number of ways to avoid the pty problem, but the pty problem is a symptom of something going wrong.
That was why I stopped just hacking the rc.sysinit, in newly created VPS's.
As mentioned earlier I have managed to create a template-cache, that when I moves it to systems, showing pty-problems, can create VPS that work perfect in any way with no hacking at all.
If you : David and/or alticon-brian could try to se if the
templatecache I have put on my server works for you, It maybe
possible to find out where template-creation fails.
As mentioned earlier in the thread it can be found on http://www.sonnet.dk/centos-5-i386-minimal.tar.gz
It still requires Steve's template to be installed, since it is only a cache-file.
Regards
Tpso
alias Thomas
|
|
|