|
|
| RAID 1 without specifying devices |

|
2006-09-14 17:42:55 |
Hello all
I'm usually installing my systems with Software RAID 1 and
have up to
now specified the hard drives to be used by their device
names (/dev/hda
etc...), ie
part raid.01 --bytes-per-inode=4096
--fstype="raid" --ondisk=hda
--size=10000
Is there a way to create the RAID without specifying
--ondisk?
There will always be two disks on these systems, but not
necessarily in
the same position each time.
Johnny C
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 17:42:55 |
Hello all
I'm usually installing my systems with Software RAID 1 and
have up to
now specified the hard drives to be used by their device
names (/dev/hda
etc...), ie
part raid.01 --bytes-per-inode=4096
--fstype="raid" --ondisk=hda
--size=10000
Is there a way to create the RAID without specifying
--ondisk?
There will always be two disks on these systems, but not
necessarily in
the same position each time.
Johnny C
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 18:01:49 |
On 9/14/06, Johnny Ljunggren <johnny navtek.no> wrote:
>
> Hello all
>
> I'm usually installing my systems with Software RAID 1
and have up to
> now specified the hard drives to be used by their
device names (/dev/hda
> etc...), ie
> part raid.01 --bytes-per-inode=4096
--fstype="raid" --ondisk=hda
> --size=10000
>
> Is there a way to create the RAID without specifying
--ondisk?
> There will always be two disks on these systems, but
not necessarily in
> the same position each time.
>
It's not pretty, but you can do this...
%include /tmp/kspart
%pre --interpreter /usr/bin/python
import os
import sys
import parted
sys.path.append('/usr/lib/anaconda')
import isys
drives = isys.hardDriveDict().keys()
drives.sort()
f = open("/tmp/kspart","w")
f.write( "part raid.01 --ondisk=%s\n" %
drives[0] );
f.write( "part raid.02 --ondisk=%s\n" %
drives[1] );
f.close()
--
Jason Kohles
email jasonkohles.com - http://www.jasonkohles.co
m/
"A witty saying proves nothing." -- Voltaire
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 18:01:49 |
On 9/14/06, Johnny Ljunggren <johnny navtek.no> wrote:
>
> Hello all
>
> I'm usually installing my systems with Software RAID 1
and have up to
> now specified the hard drives to be used by their
device names (/dev/hda
> etc...), ie
> part raid.01 --bytes-per-inode=4096
--fstype="raid" --ondisk=hda
> --size=10000
>
> Is there a way to create the RAID without specifying
--ondisk?
> There will always be two disks on these systems, but
not necessarily in
> the same position each time.
>
It's not pretty, but you can do this...
%include /tmp/kspart
%pre --interpreter /usr/bin/python
import os
import sys
import parted
sys.path.append('/usr/lib/anaconda')
import isys
drives = isys.hardDriveDict().keys()
drives.sort()
f = open("/tmp/kspart","w")
f.write( "part raid.01 --ondisk=%s\n" %
drives[0] );
f.write( "part raid.02 --ondisk=%s\n" %
drives[1] );
f.close()
--
Jason Kohles
email jasonkohles.com - http://www.jasonkohles.co
m/
"A witty saying proves nothing." -- Voltaire
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 18:04:50 |
I've made my installs generic by doing some work in the
%pre, then using
%include /tmp/partinfo in the command section.
something like this is what I use in the %pre
# Determine how many drives we have
set $(list-harddrives)
let numd=$#/2
d1=$1
d2=$3
# Use this scheme for two or more drives
if [ $numd -ge 2 ] ; then
cat << EOF >> /tmp/partinfo
YOUR SETUP --ondisk=$d1
YOUR SETUP --ondisk=$d2
EOF
else
# Use this scheme for one drive
cat << EOF >> /tmp/partinfo
YOUR SETUP --ondisk=$d1
EOF
fi
-----Original Message-----
From: kickstart-list-bounces redhat.com
[mailto:kickstart-list-bounces redhat.com] On Behalf Of
Johnny Ljunggren
Sent: Thursday, September 14, 2006 10:43 AM
To: kickstart-list redhat.com
Subject: RAID 1 without specifying devices
Hello all
I'm usually installing my systems with Software RAID 1 and
have up to
now specified the hard drives to be used by their device
names (/dev/hda
etc...), ie part raid.01 --bytes-per-inode=4096
--fstype="raid"
--ondisk=hda --size=10000
Is there a way to create the RAID without specifying
--ondisk?
There will always be two disks on these systems, but not
necessarily in
the same position each time.
Johnny C
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 18:04:50 |
I've made my installs generic by doing some work in the
%pre, then using
%include /tmp/partinfo in the command section.
something like this is what I use in the %pre
# Determine how many drives we have
set $(list-harddrives)
let numd=$#/2
d1=$1
d2=$3
# Use this scheme for two or more drives
if [ $numd -ge 2 ] ; then
cat << EOF >> /tmp/partinfo
YOUR SETUP --ondisk=$d1
YOUR SETUP --ondisk=$d2
EOF
else
# Use this scheme for one drive
cat << EOF >> /tmp/partinfo
YOUR SETUP --ondisk=$d1
EOF
fi
-----Original Message-----
From: kickstart-list-bounces redhat.com
[mailto:kickstart-list-bounces redhat.com] On Behalf Of
Johnny Ljunggren
Sent: Thursday, September 14, 2006 10:43 AM
To: kickstart-list redhat.com
Subject: RAID 1 without specifying devices
Hello all
I'm usually installing my systems with Software RAID 1 and
have up to
now specified the hard drives to be used by their device
names (/dev/hda
etc...), ie part raid.01 --bytes-per-inode=4096
--fstype="raid"
--ondisk=hda --size=10000
Is there a way to create the RAID without specifying
--ondisk?
There will always be two disks on these systems, but not
necessarily in
the same position each time.
Johnny C
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 18:07:39 |
Jason Kohles skrev:
>> Is there a way to create the RAID without
specifying --ondisk?
>> There will always be two disks on these systems,
but not necessarily in
>> the same position each time.
>>
> It's not pretty, but you can do this...
<snip>
Thanks a lot to both Jason and Chip. I'll try them out
first thing tomorrow.
Johnny L
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|
| RAID 1 without specifying devices |

|
2006-09-14 18:07:39 |
Jason Kohles skrev:
>> Is there a way to create the RAID without
specifying --ondisk?
>> There will always be two disks on these systems,
but not necessarily in
>> the same position each time.
>>
> It's not pretty, but you can do this...
<snip>
Thanks a lot to both Jason and Chip. I'll try them out
first thing tomorrow.
Johnny L
_______________________________________________
Kickstart-list mailing list
Kickstart-list redhat.com
https://www.redhat.com/mailman/listinfo/kickstart-list
|
|