Jason Edgecombe wrote:
Hi,
I would like to have a unified kickstart file for both my i386 and
x86_64 installs. So I have two questions:
1. Is there some way to detect whether the processor is 32/64 bit in a
%pre script?
2. Will the 32-bt installer install the 64bit rpms if I point it at a
64bit install tree?
Thanks,
Jason
_______________________________________________
Kickstart-list mailing list
Kickstart-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/kickstart-list
I'm not sure about the pre detection thing (I'm sure it's doable), but
you really do have to specify different trees.
What I do, and I apologize if this feels like advocacy (it kind of is),
is I use the same kickstart template with cobbler
(http://cobbler.et.redhat.com) and just add the line "url
--url=TEMPLATE::tree" in the kickstart so each kickstart uses a
different tree. Basically most of the kickstart lines remain the same
and I only need to trade out the tree parameter depending on which
kickstart profile is using it.
# first, add the distro, "foo" might really be RHEL4, so name appropriately
cobbler distro add --name="fooi386" --kernel=blah --initrd=blah
cobbler distro add --name="foox86_64" --kernel=blah --initrd=blah
# now add two profiles, each using the same kickstart, but template in a
different tree parameter
cobbler profile add --name="fooi386profile" --distro="fooi386"
--ksmeta="tree=http://myserver/path/to/tree" --kickstart=/path/to/kickstart
cobbler profile add --name="foox86_64profile" --distro ="foox86_64"
--ksmeta="tree=http://myserver/path/to/other/tree"
--kickstart=/path/to/kickstart
# now specify what systems use what profile, by MAC address
cobbler system add --name="AA:BB:CC:DD:EE:FF" --profile="fooi386profile"
cobbler system add --name="DD:EE:AA:DD::BE:EF" --profile="foox86_64profile"
# by default, use i386
cobbler system add --name="default" --profile="fooi386profile"
# apply the changes
cobbler sync
See the manpages at http://cobbler.et.redhat.com for more info, or ask
on et-mgmt-tools@xxxxxxxxxx
If you do need to do an "if" area in the kickstart in pre or post, you
can set another template parameter using the "--ksmeta" and then write
an "if" statement in the kickstart as if it was a shell script.
If that doesn't quite make sense hopefully I can clarify.
--Michael