[CentOS] how to 'yum update' in a %post

Fri Jun 2 14:45:38 UTC 2006
Matt Hyclak <hyclak at math.ohiou.edu>

On Fri, Jun 02, 2006 at 03:44:01PM +0100, Tom Brown enlightened us:
> >you need to run this without the --nochroot option, there is no yum
> >included in the installer system, and the only yum you will get working
> >is the one inside the chroot.
> 
> OK thanks makes sense - however is there anyway to make some things run 
> with --nochroot and others with it? Just that there is other things 
> allready going on that need the --nochroot
>

First thing that comes to mind is:

%post --nochroot
# Some non-chroot stuff

chroot /mnt/sysimage

# All the chrooted stuff here

yum -y update

> >also, what made you install bash in /usr/local/bin ????
> 
> i didn't - taken over systems and when i check a system that is allready 
> kickstarted it says that bash is in /usr/local/bin
> 

I would investigate that. It seems, well, less than intelligent in an
RPM-based system.

Matt

-- 
Matt Hyclak
Department of Mathematics 
Department of Social Work
Ohio University
(740) 593-1263