module GetNodeList def get_node_list(filename) f = open(filename,"r") nodes = [] f.each { |line| if /.+jp/ =~ line then nodes.push(line.chomp) end } hostname = `hostname` mynum = 0 if /[0-9]+/ =~ hostname then mynum = $&.to_i end nodes = nodes.rotate(mynum) return nodes end end