From: Henish P. <hp...@li...> - 2015-02-26 06:05:41
|
On 01/08/2015 01:56 AM, Nathan Fontenot wrote: > On 12/14/2014 11:39 PM, Vasant Hegde wrote: >> On 12/05/2014 04:11 PM, Henish Patel wrote: >>> snap is not supported on the RHEL 7 onwards, because we have integrated snap >>> functionality in sosreport. So this patch displays a suitable message on >>> usage of snap tool. RHEL 7+ users can use sosreport to collect log data. >>> >> Nathan, >> >> >>> Signed-off-by: Henish Patel <hp...@li...> >> As you are aware we are trying to standardize data collection tool rather than >> having separate tool for Power.. We have made necessary changes in distro >> provided tools (sosreport for RH) to collect required data.. Also any future >> changes goes to distro provided tools only.. >> >> Hence this patch adds necessary message to snap... >> >> >> Reviewed-by: Vasant Hegde <heg...@li...> >> >> >> -Vasant >> >>> --- >>> scripts/snap | 14 +++++++++++++- >>> 1 file changed, 13 insertions(+), 1 deletion(-) >>> >>> diff --git a/scripts/snap b/scripts/snap >>> index 3e547e6..1bede61 100755 >>> --- a/scripts/snap >>> +++ b/scripts/snap >>> @@ -34,7 +34,19 @@ my $outfile = "snap.tar.gz"; # in the working dir. >>> my $cmddir = "snap_commands"; # cmd output dir. >>> my $cmdoutdir = "$outdir/$cmddir"; # in outdir dir. >>> my $rsxx_exists = 0; # Does an IBM Flash Adapter exist? >>> -my $distro_file = "/etc/issue" >>> +my $distro_file = "/etc/issue"; >>> +my $redhat_release_file = "/etc/redhat-release"; >>> + >>> +if (-e $redhat_release_file) { >>> + open(RELEASE, "< $redhat_release_file") or die "open: $!\n"; >>> + $_ = <RELEASE>; >>> + my $redhat_version = (split / /, $_)[6]; >>> + if ($redhat_version > 7.0) { Nathan, I made required changes and sent second version of patch upstream. Thanks, Henish > Did you mean to disable snap for RHEL 7.0? If so this doesn't work, should > be; > if ($redhat_version >= 7.0) > >>> + print "snap: is not supported on the RHEL 7 onwards..!\n"; > Also, I think the colon in this message is not needed, just say "snap is not ...". > > -Nathan > >>> + print "Please use sosreport to collect log data..!! \n"; >>> + exit 1; >>> + } >>> +} >>> >>> our($opt_a, $opt_d, $opt_h, $opt_o, $opt_t, $opt_v); >>> >>> >>> >>> ------------------------------------------------------------------------------ >>> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server >>> from Actuate! Instantly Supercharge Your Business Reports and Dashboards >>> with Interactivity, Sharing, Native Excel Exports, App Integration & more >>> Get technology previously reserved for billion-dollar corporations, FREE >>> http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk >>> _______________________________________________ >>> Powerpc-utils-devel mailing list >>> Pow...@li... >>> https://lists.sourceforge.net/lists/listinfo/powerpc-utils-devel >>> >> >> ------------------------------------------------------------------------------ >> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server >> from Actuate! Instantly Supercharge Your Business Reports and Dashboards >> with Interactivity, Sharing, Native Excel Exports, App Integration & more >> Get technology previously reserved for billion-dollar corporations, FREE >> http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk >> _______________________________________________ >> Powerpc-utils-devel mailing list >> Pow...@li... >> https://lists.sourceforge.net/lists/listinfo/powerpc-utils-devel >> |