qa: update 660 to generate index.html, fixing pcp-testsuite runs
[pcp.git] / qa / 645
blob034425fbbc1ff3cb3a5fb616145b4aec92089e9c
1 #! /bin/sh
2 # PCP QA Test No. 645
3 # pmlogger config with hyphens in hostname - #828416
5 # Copyright (c) 1995-2002 Silicon Graphics, Inc. All Rights Reserved.
8 seq=`basename $0`
9 echo "QA output created by $seq"
11 # get standard environment, filters and checks
12 . ./common.product
13 . ./common.filter
14 . ./common.check
16 status=0 # success is the default!
17 $sudo rm -rf $tmp.*
18 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
20 _filter()
22 sed \
23 -e 's/__pmGetAddrInfo(/gethostbyname(/g' \
24 -e 's/__pmGetHostByName(/gethostbyname(/g' \
25 -e '/gethostbyname(/s/ Resolver Error 0 (no error)/ Unknown host/' \
26 -e '/gethostbyname(/s/ No address associated with name/ Unknown host/' \
27 -e '/gethostbyname(/s/ Host name lookup failure/ Unknown host/'
30 # real QA test starts here
31 for host in nosuchhost.pcp.io no-such-host.pcp.io
33 cat <<End-of-File | pmlogger -l $tmp.log $tmp
34 log mandatory on once { hinv.ncpu }
36 [access]
37 allow $host:advisory,mandatory,enquire;
38 End-of-File
40 _filter_pmlogger_log <$tmp.log | _filter
41 done
43 # success, all done
44 exit