Re: good example for %pre section???

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 2 Jun 2002, rpjday wrote:

>
>   in aid of designing good ks docs, anyone got a *good* example for
> a sample %pre section?  the red hat course rh133 shows the example:
>
>   %pre
>   mknod /tmp/hda
>   dd if=/mnt/source/pub/mbr.img of=/tmp/hda
>
> which will create disk partitions simply by dumping a pre-configured MBR
> with partition table to the hard disk.  while this may be a valid example,
> will it adequately demonstrate what the %pre section might be used for,
> as opposed to the %post section?
>
> anyone got better examples for %pre?
>

Here's what we use to partition a 9GB SCSI disk prior to installation so
that we get the disk layout we want.  The default way that kickstart (disk
druid) did it would put the smallest partitions at the end of the disk.
Not good when you don't want a /boot partition, and / is smaller than your
4GB /usr partition.

We have a different one for use with 18GB systems.  The values you put
into the fdisk command will depend on your hard disk, the type and
geometry.

Carl G. Riches
Software Engineer
Department of Mathematics
Box 354350			voice:     206-543-5082 or 206-616-3636
University of Washington	fax:       206-543-0397
Seattle, WA  98195-4350		internet:  riches@xxxxxxxxxxxxxxxxx
# P R E - I N S T A L L A T I O N   C O M M A N D S
%pre

# create the disk device
mknod /dev/sda

# partition the disk
echo | fdisk /dev/sda <<EOF
o
w
EOF

echo | fdisk /dev/sda <<EOF
n
p
1
1
33
n
e
2
34
1106
n
l
34
66
n
l
67
194
n
l
195
704
n
l
705
705
974
n
l
975
1040
n
l
1041
1106
t
6
82
w
EOF


[Index of Archives]     [Red Hat General]     [CentOS Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux