4

Need a script to add mutiple printers in solaris box

view full story
linux-howto

http://www.unix.com – Hi , i need to configure around 80 printers in a server. can someone please help me with the script. i have a file that has printer name and its ip. like. Code: printer1 1.1.1.1 printer2 0.0.0.0 and so on.. can some one please help me to do it via script. i am using solaris 10 After lot of thinking i could figure out the below script :) Code: j=1; for i in `cat prntlist` do ipaddr=`awk -v a=$j '(NR==a){print $1}' iplist` echo $i:$ipaddr ###i can add lpadmin cmd here with $i for printername and $ipaddr for printer ip j=$((j+1)) done i know with unix there would be many wa (HowTos)