Re: %post script for swapfile

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

 



I'd also recommend using /bin/ash if you want to test drive any wierd or convoluted logic you're going to put into the %pre section. /bin/bash works for testing %post stuff, but the %pre interpreter isn't a full-fledged bash shell, so you can't do fancy stuff like ${parameter//pattern/string} like you can do in bash. I'm not 100% sure if ash is even the interpreter used in %pre, but it's been a perfect simulator for me so far.

Also, if you don't want to sleep for an eternity, you could put something like this in %pre or %post:
exec < /dev/tty3 > /dev/tty3
chvt 3
echo "Press <Enter> to continue with installation."
read foo
chvt 1
......

Then you could go mess around in Alt-F2 for as long as you like; and just Alt-F3, <Enter> when you're ready to continue the build.

Shabazian, Chip wrote:

When testing/debugging, I put a sleep 99999999999 in my %pre and %post.
You can then go into the Alt-F2 shell and test whatever you want.  When
it works the way you want, just kill the sleep process, and the build
will continue.

Chip
-----Original Message-----
From: kickstart-list-bounces@xxxxxxxxxx
[mailto:kickstart-list-bounces@xxxxxxxxxx] On Behalf Of Robert Citek
Sent: Wednesday, March 15, 2006 1:00 PM
To: Discussion list about Kickstart
Subject: Re: %post script for swapfile


On Mar 15, 2006, at 2:05 PM, Shabazian, Chip wrote:
That should work just fine as is

Thanks, Chip.

The reason I asked is because there doesn't seem to be any easy way to
test/debug a %post script.  That is, the only way to test/debug is to
run the entire install process again.  So, it's nice to know in advance
that a post script should work.

Regards,
- Robert
http://www.cwelug.org/downloads
Help others get OpenSource software.  Distribute FLOSS for Windows,
Linux, *BSD, and MacOS X with BitTorrent

_______________________________________________
Kickstart-list mailing list
Kickstart-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/kickstart-list

_______________________________________________
Kickstart-list mailing list
Kickstart-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/kickstart-list



[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