Re: clearpart -all warning

Patrick Lists <[email protected]>
Newsgroups gmane.linux.redhat.kickstart.general
Message-ID <[email protected]>
On 04/11/2012 03:41 PM, jon public wrote:
> Hi there
>
> I've customized my kickstart to delete all partitions ( clearpart --all
> ). I've noticed that the installer only shows a warning message when the
> disk does not have a valid partition ( like new virtual machines ).
>
> I'm afraid that someone might wipe his entire disk if booting by mistake
> from the customized disk. Is there any way of forcing anaconda to always
> ask for user confirmation before erasing disk partitions?
>
> Thanks for you help!

You could use something like the snippet below. All credit goes to the 
presentation "Kickstart Tips & Tricks" by Chip Shabazian (caution: lines 
may be wrapped).

%pre
#!/bin/sh
exec < /dev/tty3 > /dev/tty3 2>&1
chvt 3
install="no"
while [ "$install" != "yes" ]; do
clear
echo
echo 
'********************************************************************************'
echo '*
W A R N I N G
*'
echo '*
*‘
echo ‘*This process will install a completely new operating system and
*‘
echo '*
*'
echo '* Do you wish to continue? (Type the entire word "yes" to proceed.)
*'
echo '*
*'
echo 
'********************************************************************************'
echo
read -p "Proceed with install? " install done clear chvt 1 #%end


More instructions at 
http://www.trueblade.com/techblog/user-input-during-a-fedora-kickstart

Regards,
Patrick
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.