Problem I'm able to understand:
Suppose I have
$NUMDISKS that can be 1 or 2 ... or n
and
$DISKS that can be
sda, or
sda sdb
or sda sdb sdc
(so a string with the didks separated by space)
I want to assign
DRIVE1=sda
DRIVE2=sdb
...
DRIVEN=sdn
if I script
for i in $(seq 1 $NUMDISKS)
do
On Fri, May 30, 2008 at 04:39:48PM +0200, Gianluca Cecchi wrote:
Problem I'm able to understand:
Suppose I have
$NUMDISKS that can be 1 or 2 ... or n
and
$DISKS that can be
sda, or
sda sdb
or sda sdb sdc
(so a string with the didks separated by space)
Personally, I'd go with arrays: