( ** Go back to PARENTPAGE ../Script-pathcompare-aspl.html)
( ** Go back to HOMESITE https://www.tcnd.com)
( ** Go back to SetSphere https://www.setsphere.com)

How to call ASPL script to compare system PATH between UNIX hosts in a cloud

In a cloud environment we use ASPL to compare the system PATH between two hosts. The following script reads the system PATH of two hosts and display their similarities and differences.

ASPL 1> DEF FN cmp2sets := {gU {g\, %%1 %%2}{g\, %%2 %%1}{g&, %%1 %%2}}
define the function cmp2sets() to compare two groups

ASPL 2> timeout 300
set timeout to 300 seconds

ASPL 3> displayoff
turn off display

ASPL 4> print ** GETTING mm01 ENV

ASPL 5> p1 = ggpathR(grp1,mm01,hostname,mm01,ENVNAME,PATH)
p1 is assigned the PATH on host mm01

ASPL 6> print ** GETTING vienna ENV

ASPL 7> p2 = ggpathR(grp1,vienna,hostname,vienna,ENVNAME,PATH)
p2 is assigned the PATH on host vienna

ASPL 8> displayon
turn display on

ASPL 9> ks chksum size mtime ffl
set ks-vector to chksum size mtime ffl

ASPL 10> print ############################################

ASPL 11> print # SHOWING SET COMPARISONS BETWEEN mm01 and vienna

ASPL 12> print ############################################

ASPL 13> FN cmp2sets(p1,p2)
run function cmp2sets(p1,p2) to display the comparison between system PATH on mm01 and vienna

ASPL 18> print ############################################

ASPL 19> print # SHOWING SET SIMILARITY BETWEEN mm01 and vienna

ASPL 20> print ############################################

ASPL 21> sim p1 p2
display similarity

ASPL 22> sim`c p1 p2
display similarity based on checksum

ASPL 23> sim`f p1 p2
display similarity based on value of env var

ASPL 24> sim`ffl p1 p2
display similarity based on value of env var

ASPL 25> println