[PATCH 8/8] dnf should put its logs in /tmp/

Brian C. Lane bcl at redhat.com
Thu Jul 10 15:18:56 UTC 2014


On Thu, Jul 10, 2014 at 10:35:44AM -0400, Chris Lumens wrote:
> > diff --git a/data/post-scripts/99-copy-logs.ks b/data/post-scripts/99-copy-logs.ks
> > index d1c273a..fc15844 100644
> > --- a/data/post-scripts/99-copy-logs.ks
> > +++ b/data/post-scripts/99-copy-logs.ks
> > @@ -10,6 +10,8 @@ mkdir -p $ANA_INSTALL_PATH/var/log/anaconda
> >  [ -e /tmp/storage.log ] && cp /tmp/storage.log $ANA_INSTALL_PATH/var/log/anaconda/anaconda.storage.log
> >  [ -e /tmp/ifcfg.log ] && cp /tmp/ifcfg.log $ANA_INSTALL_PATH/var/log/anaconda/anaconda.ifcfg.log
> >  [ -e /tmp/yum.log ] && cp /tmp/yum.log $ANA_INSTALL_PATH/var/log/anaconda/anaconda.yum.log
> > +[ -e /tmp/dnf.log ] && cp /tmp/dnf.log $ANA_INSTALL_PATH/var/log/anaconda/anaconda.dnf.log
> > +[ -e /tmp/dnf.rpm.log ] && cp /tmp/dnf.rpm.log $ANA_INSTALL_PATH/var/log/anaconda/anaconda.dnf.rpm.log
> >  cp /tmp/ks-script*.log $ANA_INSTALL_PATH/var/log/anaconda/
> >  journalctl -b > $ANA_INSTALL_PATH/var/log/anaconda/anaconda.journal.log
> >  chmod 0600 $ANA_INSTALL_PATH/var/log/anaconda/*
> 
> The anaconda. prefix on all the log files stems from ye olde days where
> we'd just toss everything into /var/log on the installed system.  We can
> probably stop doing that now, at least for new logs.  Old ones... I
> guess there might be scripts somewhere looking for these specific files?
> But maybe we can get away with breaking them.

I was thinking that as well. I think we can just drop the prefix, meh is
the only thing that grabs the logs and that's from /tmp/ not the target
system. If anything is grabbing them from /var/log/anaconda/ it should
just be snarfing up the whole directory.

I'll change them in my working copy.

-- 
Brian C. Lane | Anaconda Team | IRC: bcl #anaconda | Port Orchard, WA (PST8PDT)


More information about the anaconda-patches mailing list