hi all,
am trying to modify a ksh script to group server names together depending on the cluster they sit in. currently the script does a
find . -name '*.pid'
to find all running servers and prints out their pids and names.
current output looks something like this :
serverA 512
serverB 513
serverC 514
serverD 515
serverE 516
and i wanted to group the output based on their cluster i.e
Cluster1
serverD 515
serverA 512
serverC 514
Cluster2
serverB 513
serverE 516
i know the cluster so i can hardcode the server names but i dont know how to print them out since it involves moving the cursor at runtime depending on the name of the server from the "find" command above.
any suggestions ??
---------- Post updated at 05:40 PM ---------- Previous update was at 05:30 PM ----------
when i try putting [code] tags around the find code it displays blank line in mozilla !!