Re: Building a C5 chroot on a C6 machine

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Fri, Dec 14, 2012 at 07:58:17PM +0100, Nicolas Thierry-Mieg wrote:
> Stephen Harris wrote:

> > The rpm database is in the format of C6, so the C5 programs can't
> > read it!

> perhaps if you kept the rpms that were installed by yum, you could
> rpm -i --justdb *.rpm
> within your chroot.
> 
> If necessary first remove the rpm database and rpm --initdb or some such.

Interesting idea!

  yum --setopt=keepcache=1 --disablerepo=* --enablerepo=c5* -y --installroot=$ROOT install $rpms

  # Fix up RPM database
  rm $ROOT/var/lib/rpm/*
  chroot $ROOT /bin/rpm --initdb
  chroot $ROOT /bin/rpm -i --justdb '/var/cache/yum/*/packages/*.rpm'

And y'know what?  it worked!

Very good idea.  Thanks!

-- 

rgds
Stephen
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux