error handling in %post (was: Re: trying to mount the dvd during post install.)

Ed Brown ebrown at lanl.gov
Wed Aug 30 23:32:25 UTC 2006


Lambert Tran wrote:
> 
> The trick at time was how to know the installation CD was actually is
> /tmp/cdrom... (your may be /tmp/dvd). To find out, we had a sleep 600 at the
> %post section, and went look around.

%post (and %pre) scripts are versatile and powerful tools, so why does 
the kickstart environment have a reputation of being difficult to work 
in?  How many questions to this list revolve around figuring out how 
to determine what the heck is going on in %pre and %post scripts?  Who 
has chosen to do things with scripts that execute on firstboot, rather 
than try to get something done in %post?  How many of us resort to 
inserting sleeps or other tricks to buy time at a commandline to debug 
problems?  How hard would it be to provide a debug mode, where 
non-zero return codes for commands (either all commands, or possibly 
only for specially-indicated commands) results in seeing the command 
that failed, and the reason/output if any, followed by a shell prompt? 
  Would this be useful for anyone here?  (Is this the wrong list, 
should it be posted to anaconda-devel instead (or also)?)

-Ed?




More information about the Kickstart-list mailing list