Kickstart-list Digest, Vol 132, Issue 3

Spike White spikewhitetx at gmail.com
Sat Jun 20 17:34:05 UTC 2015


<CR><LF> terminators in a ks.cfg file are a strange beast.

Apparently the anaconda parser can tolerate them.  So it works in a
%packages section, or other anaconda-parsed sections.  Like the top,
overall section.

However, anaconda passes off %pre sections and %post sections to the bash
interpreter.  Which doesn't tolerate <CR><LF> terminators.  So you can't
have <CR><LF> in a %pre or %post section.

%include literally embeds the content of the specified file in place.  So
by extension, the same rules apply.  <CR><LF> in that file would be
tolerated in certain sections, not in the %pre or %post section.

Spike

On Sat, Jun 20, 2015 at 11:00 AM, <kickstart-list-request at redhat.com> wrote:

> Send Kickstart-list mailing list submissions to
>         kickstart-list at redhat.com
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         https://www.redhat.com/mailman/listinfo/kickstart-list
> or, via email, send a message with subject or body 'help' to
>         kickstart-list-request at redhat.com
>
> You can reach the person managing the list at
>         kickstart-list-owner at redhat.com
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Kickstart-list digest..."
>
> Today's Topics:
>
>    1. RE: Not finding /tmp/include created in %pre (Bledsoe, Alton)
>
>
> ---------- Forwarded message ----------
> From: "Bledsoe, Alton" <Alton.Bledsoe at vce.com>
> To: "kickstart-list at redhat.com" <kickstart-list at redhat.com>
> Cc:
> Date: Fri, 19 Jun 2015 20:07:28 -0400
> Subject: RE: Not finding /tmp/include created in %pre
>
> My bad. Need to adjust my glasses. The parser caught me on the file
> extension; .ks versus .sh. All is well now.
>
>
>
> But for the first point, I have never seen anyone comment on carriage
> returns showing up at the end of command execution if the %pre script is
> embedded in the Kickstart file. The clue for the work around was in an
> Oracle doc showing the script %included in the kickstart file.
>
>
>
> *From:* Bledsoe, Alton
> *Sent:* Thursday, June 18, 2015 7:21 PM
> *To:* 'kickstart-list at redhat.com'
> *Subject:* Not finding /tmp/include created in %pre
>
>
>
> First, I had to work around the fact that the execution of shell commands
> are terminated with a carriage return including file names that are created
> during %pre. The work around was simply:
>
> %pre
>
> %include http://<ip>/path/to/script.sh
>
> %post
>
>
>
> In this script.sh I write out network commands for 4 interfaces after
> capturing input from tty6.
>
> I write to /tmp/net-include and, using alt-F2 shell terminal, I can
> readily see it in /tmp
>
>
>
> The %include /tmp/net-config in the kickstart file is generating a *PYCURL
> ERROR 22 … 404 not found* once parsed after the %pre section %end’s.
>
>
>
> Why are these simple looking things that have many similar examples on the
> web not working?
>
>
>
> RHEL6.6
>
>
>
> Al Bledsoe
>
> ++l|l++----+l||l+l||++l|||l++++-------+++--
>
> PD&E Solutions Architect, Richardson, TX
>
> Cell: 214-533-1698 Desk: 972-656-5341
>
> Alton.Bledsoe at vce.com
>
> Somebody’s gotta do it.
>
>
>
> _______________________________________________
> Kickstart-list mailing list
> Kickstart-list at redhat.com
> https://www.redhat.com/mailman/listinfo/kickstart-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/kickstart-list/attachments/20150620/f48ff880/attachment.htm>


More information about the Kickstart-list mailing list