From rjoost at redhat.com Wed Jun 13 23:23:49 2018 From: rjoost at redhat.com (=?utf-8?B?UsOzbWFu?= Joost) Date: Thu, 14 Jun 2018 09:23:49 +1000 Subject: %traceback and %onerror support Message-ID: <20180613232349.ios2qupdupdsn53b@khan.usersys.redhat.com> Hi guys, I've stumbled over the Anaconda documentation and saw the documented %traceback http://pykickstart.readthedocs.io/en/latest/kickstart-docs.html#chapter-8-handling-tracebacks and %onerror http://pykickstart.readthedocs.io/en/latest/kickstart-docs.html#chapter-4-handling-errors directives. We want to make Beaker's installation failure detection more reliable[1]. At the moment we're scraping the console logs for typical Anaconda errors we know about, but as you can imagine it has it's own downsides. I'm wondering with what Fedora/RHEL release these elements were made available (or are planned to be available). I've seen RHEL 7 documention which seemed ot indicate %onerror is supported. I've played around with it during provisioning of a RHEL7 machine, to include: %post --erroronfail #!/bin/bash return 1 %end %onerror --log=/dev/console set -xe # signal Beaker the installation has failed fetch - http://beaker-server-lc.beaker:8000/install_failure/32 %end and I get (anaconda.log): 03:31:58,542 INFO anaconda: Running kickstart %%post script(s) 03:32:47,117 ERR anaconda: Error code 1 running the kickstart script at line 370 which is good, but it seems the %onerror was never executed. Anaconda version is: anaconda 21.48.22.134-1 Any pointers? [1] - https://bugzilla.redhat.com/show_bug.cgi?id=1588895 PS: Happy to share more logs/details/whatever is needed. Kind Regards, -- R?man Joost Senior Software Engineer, Products & Technologies Operations (Brisbane) Red Hat -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 833 bytes Desc: not available URL: From petro at cpetro.us Thu Jun 14 15:17:21 2018 From: petro at cpetro.us (C. Petro) Date: Thu, 14 Jun 2018 09:17:21 -0600 Subject: --ignoremissing and other %package line controls. Message-ID: I've been trying to build a custom RHEL7 ISO for installing secure(ish) servers in a DMZ. Basically I am trying to minimize the packages installed. I had a working set based on RHEL 7.2, and tried to just copy that package list and use RHEL7.5. Of course, dependencies have changed. So I tried to add: %packages --ignoremissing Which did not work--it still attempts to access a non-local repo and install additional packages--10 tries at 30 seconds each! So I set: %packages --ignoremissing --retries=2 --timeout=2 And got no behavior change. What am I missing here? Regards, Petro. :wq -------------- next part -------------- An HTML attachment was scrubbed... URL: From petro at cpetro.us Thu Jun 14 21:50:43 2018 From: petro at cpetro.us (C. Petro) Date: Thu, 14 Jun 2018 15:50:43 -0600 Subject: --ignoremissing and other %package line controls. In-Reply-To: References: Message-ID: Oh, and also does anyone know a good way to check to make sure that the contents of your isolinux/Package directory contains all the depedencies that your %packages section is asking for? The script I found...missed 20 or 30 things. On Thu, Jun 14, 2018 at 9:17 AM, C. Petro wrote: > I've been trying to build a custom RHEL7 ISO for installing secure(ish) > servers in a DMZ. > > Basically I am trying to minimize the packages installed. I had a working > set based on RHEL 7.2, and tried to just copy that package list and use > RHEL7.5. Of course, dependencies have changed. > > So I tried to add: > > %packages --ignoremissing > > Which did not work--it still attempts to access a non-local repo and > install additional packages--10 tries at 30 seconds each! > > So I set: > %packages --ignoremissing --retries=2 --timeout=2 > > And got no behavior change. > > What am I missing here? > > > Regards, > Petro. > :wq > -------------- next part -------------- An HTML attachment was scrubbed... URL: From oliver.greg at gmail.com Thu Jun 14 22:06:17 2018 From: oliver.greg at gmail.com (Greg Oliver) Date: Thu, 14 Jun 2018 17:06:17 -0500 Subject: --ignoremissing and other %package line controls. In-Reply-To: References: Message-ID: On Thu, Jun 14, 2018 at 4:50 PM, C. Petro wrote: > Oh, and also does anyone know a good way to check to make sure that the > contents of your isolinux/Package directory contains all the depedencies > that your %packages section is asking for? > > The script I found...missed 20 or 30 things. > > On Thu, Jun 14, 2018 at 9:17 AM, C. Petro wrote: > >> I've been trying to build a custom RHEL7 ISO for installing secure(ish) >> servers in a DMZ. >> >> Basically I am trying to minimize the packages installed. I had a working >> set based on RHEL 7.2, and tried to just copy that package list and use >> RHEL7.5. Of course, dependencies have changed. >> >> So I tried to add: >> >> %packages --ignoremissing >> >> Which did not work--it still attempts to access a non-local repo and >> install additional packages--10 tries at 30 seconds each! >> >> So I set: >> %packages --ignoremissing --retries=2 --timeout=2 >> >> And got no behavior change. >> >> What am I missing here? >> >> >> Regards, >> Petro. >> :wq >> > ?I originally was not going to chime in, but it seems you are looking for an ISO for installation that has already baked bread and wine. What I do is cp -al the current mirror I have, then rsync mirror the current repo and add that as a repo in my kickstart file. I know I will always the same exact packages for the duration. It is really not much data to mirror by today's standards and you will not have to ever worry about missing packages.. ? Of course, you did not share any specifics, so no telling what you are battling. -Greg -------------- next part -------------- An HTML attachment was scrubbed... URL: From petro at cpetro.us Thu Jun 14 23:22:57 2018 From: petro at cpetro.us (C. Petro) Date: Thu, 14 Jun 2018 17:22:57 -0600 Subject: --ignoremissing and other %package line controls. In-Reply-To: References: Message-ID: ?I had a ISO that I built for this client 2 years ago based off REHL7.2 that worked a treat. I was updating it to RHEL 7.5 for some new server builds, and fixing some minor issues (some additional packages like Nano, telnet and adcli because they're a windows shop). "Ideally" I'd do something like this out of Cobbler or whatever they're calling it these days, or do a local package mirror. But they have such a small Linux footprint that it's not really worth it, And these servers are in a DMZ, so they're really isolated network wise. ? On Thu, Jun 14, 2018 at 4:06 PM, Greg Oliver wrote: > On Thu, Jun 14, 2018 at 4:50 PM, C. Petro wrote: > >> Oh, and also does anyone know a good way to check to make sure that the >> contents of your isolinux/Package directory contains all the depedencies >> that your %packages section is asking for? >> >> The script I found...missed 20 or 30 things. >> >> On Thu, Jun 14, 2018 at 9:17 AM, C. Petro wrote: >> >>> I've been trying to build a custom RHEL7 ISO for installing secure(ish) >>> servers in a DMZ. >>> >>> Basically I am trying to minimize the packages installed. I had a >>> working set based on RHEL 7.2, and tried to just copy that package list and >>> use RHEL7.5. Of course, dependencies have changed. >>> >>> So I tried to add: >>> >>> %packages --ignoremissing >>> >>> Which did not work--it still attempts to access a non-local repo and >>> install additional packages--10 tries at 30 seconds each! >>> >>> So I set: >>> %packages --ignoremissing --retries=2 --timeout=2 >>> >>> And got no behavior change. >>> >>> What am I missing here? >>> >>> >>> Regards, >>> Petro. >>> :wq >>> >> > ?I originally was not going to chime in, but it seems you are looking for > an ISO for installation that has already baked bread and wine. > > > What I do is cp -al the current mirror I have, then rsync mirror the > current repo and add that as a repo in my kickstart file. I know I will > always the same exact packages for the duration. It is really not much > data to mirror by today's standards and you will not have to ever worry > about missing packages.. ? > > Of course, you did not share any specifics, so no telling what you are > battling. > > -Greg > > _______________________________________________ > 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: From oliver.greg at gmail.com Fri Jun 15 01:20:19 2018 From: oliver.greg at gmail.com (Greg Oliver) Date: Thu, 14 Jun 2018 20:20:19 -0500 Subject: --ignoremissing and other %package line controls. In-Reply-To: References: Message-ID: On Thu, Jun 14, 2018 at 6:22 PM, C. Petro wrote: > ?I had a ISO that I built for this client 2 years ago based off REHL7.2 > that worked a treat. > > I was updating it to RHEL 7.5 for some new server builds, and fixing some > minor issues (some additional packages like Nano, telnet and adcli because > they're a windows shop). > > "Ideally" I'd do something like this out of Cobbler or whatever they're > calling it these days, or do a local package mirror. But they have such a > small Linux footprint that it's not really worth it, And these servers are > in a DMZ, so they're really isolated network wise. > > ?I have done the same thing. You apparently ripped apart the 7.2 iso back then, so rip apart the 7.5 iso and the packages should already be on it.. Not sure I understand..? > On Thu, Jun 14, 2018 at 4:06 PM, Greg Oliver > wrote: > >> On Thu, Jun 14, 2018 at 4:50 PM, C. Petro wrote: >> >>> Oh, and also does anyone know a good way to check to make sure that the >>> contents of your isolinux/Package directory contains all the depedencies >>> that your %packages section is asking for? >>> >>> The script I found...missed 20 or 30 things. >>> >>> On Thu, Jun 14, 2018 at 9:17 AM, C. Petro wrote: >>> >>>> I've been trying to build a custom RHEL7 ISO for installing secure(ish) >>>> servers in a DMZ. >>>> >>>> Basically I am trying to minimize the packages installed. I had a >>>> working set based on RHEL 7.2, and tried to just copy that package list and >>>> use RHEL7.5. Of course, dependencies have changed. >>>> >>>> So I tried to add: >>>> >>>> %packages --ignoremissing >>>> >>>> Which did not work--it still attempts to access a non-local repo and >>>> install additional packages--10 tries at 30 seconds each! >>>> >>>> So I set: >>>> %packages --ignoremissing --retries=2 --timeout=2 >>>> >>>> And got no behavior change. >>>> >>>> What am I missing here? >>>> >>>> >>>> Regards, >>>> Petro. >>>> :wq >>>> >>> >> ?I originally was not going to chime in, but it seems you are looking for >> an ISO for installation that has already baked bread and wine. >> >> >> What I do is cp -al the current mirror I have, then rsync mirror the >> current repo and add that as a repo in my kickstart file. I know I will >> always the same exact packages for the duration. It is really not much >> data to mirror by today's standards and you will not have to ever worry >> about missing packages.. ? >> >> Of course, you did not share any specifics, so no telling what you are >> battling. >> >> -Greg >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: