.; NETCMD - execute one command on another node .; .; Usage: .; .; @netcmd .; .; Notes: .; .; 1. Logs into a remote account .; You must define the remote account and password. .; Note that anyone who can read this file also can .; read the account and password. .; .; 2. Programs that prompt for input will fail. .; .;-------------------------------------------------------- .; .enable substitution .enable quiet .disable display .; .sets accnt "" ! set remote account .sets passwd "" ! set remote password .; .open ti: .; .if P1 <> "" .goto havnod .; .asks P1 Which node for command (return to quit): .if P1 = "" .exit .; .havnod: .; .if P2 <> "" .goto havcmd .; .asks cmdlin Enter command to execute on 'P1': .if cmdlin = "" .exit .goto cmdrdy .; .havcmd: .sets cmdlin P2+" "+P3+" "+P4+" "+P5+" "+P6+" "+P7+" "+P8 .; .cmdrdy: .; rex -l netcmd 'P1' 'accnt' 'passwd' .if <> 1 .exit .; rex -s netcmd 'cmdlin' .; rex -o netcmd .; .exit