LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
LinkBack Search this Thread
Old 08-06-2009, 08:54 PM   #1
samhoover
LQ Newbie
 
Registered: May 2007
Posts: 3

Rep: Reputation: 0
kickstart installation issue with %post


I am trying to do a kickstart install; generally I never had any problems, but in this case the %post section is never executing. The rest of the installation goes through fine. I am posting my cfg file, any suggestions would be greatly appreciated:

install
cdrom
key --skip
lang en_US.UTF-8
keyboard us
network --device eth0 --bootproto dhcp
#network --device eth0 --onboot yes --bootproto static --ip 192.168.203.8 --netmask 255.255.255.0 --gateway 192.168.203.2 --nameserver 192.168.203.104
rootpw --iscrypted $1$yNzidLli$.mvja4xO61CLfrBBqI0UH/
firewall --disabled
authconfig --enableshadow --enablemd5
selinux --disabled
timezone --utc America/Toronto
bootloader --location=mbr --driveorder=sda
clearpart --all --initlabel
part / --fstype ext3 --size=100 --grow
part swap --size=256 --grow --maxsize=512
zerombr yes
reboot --eject

%packages
@editors
@text-internet
@core
@base
@server-cfg
-mysql-devel
arpwatch
sysstat
dstat
lynx
-aide
kexec-tools
device-mapper-multipath
imake
-mysql
-unixODBC
-MySQL-python
-mysql-connector-odbc
-libdbi-dbd-mysql
-emacs-leim
-psgml
-emacspeak
-zisofs-tools
-vnc
-xdelta
-OpenIPMI-tools
-openldap-clients
-bluez-hcidump
-zsh
-bluez-gnome
-slrn
-fetchmail
-mutt
-elinks
-cadaver
-nss_ldap
-readahead
-krb5-workstation


%post --nochroot
(
echo
echo "################################"
echo "# Running Post Configuration #"
echo "################################"

# Get latest RPM updates via ftp
echo "ftp connect to server... "
ftp -n 192.168.1.9 <<EOF
user anonymous -ks@`hostname`
binary
prompt
mget *.rpm
quit
EOF
rpm -Uvh *.rpm
/sbin/chkconfig acpid off
/sbin/chkconfig avahi-daemon off
/sbin/chkconfig iptables off
/sbin/chkconfig mcstrans off
/sbin/chkconfig microcode_ctl off
/sbin/chkconfig restorecond off
/usr/sbin/groupadd amc
mkdir -p /pool/home/
/usr/sbin/useradd -d /pool/home/joe/ joe
/bin/chgrp -R amc /pool/home/joe
/usr/sbin/usermod -p '$1$LeHv25Si$ijh8SrkMBPDGE.TnxB03' joe
) 1>/root/post_install.log 2>&1
 
Old 08-08-2009, 08:43 AM   #2
rayfordj
Member
 
Registered: Feb 2008
Location: Texas
Distribution: Fedora, RHEL, CentOS
Posts: 452

Rep: Reputation: 68
Quote:
%post --nochroot
Since you are installing/upgrading RPMs and performing other tasks that should be done on the just-installed-OS, would you not want to do this in the chroot environment so that all the pathing is correct?

 
Old 08-09-2009, 11:22 PM   #3
samhoover
LQ Newbie
 
Registered: May 2007
Posts: 3

Original Poster
Rep: Reputation: 0
That was my initial step, but I read on another discussion that to install rpms it needs to be done outside the chroot. But I will try again with chroot.
 
Old 09-12-2009, 09:21 AM   #4
Vimuth
Member
 
Registered: Sep 2009
Posts: 36

Rep: Reputation: 15
Quote:
Originally Posted by samhoover View Post
I am trying to do a kickstart install; generally I never had any problems, but in this case the %post section is never executing. The rest of the installation goes through fine. I am posting my cfg file, any suggestions would be greatly appreciated:

install
cdrom
key --skip
lang en_US.UTF-8
keyboard us
network --device eth0 --bootproto dhcp
#network --device eth0 --onboot yes --bootproto static --ip 192.168.203.8 --netmask 255.255.255.0 --gateway 192.168.203.2 --nameserver 192.168.203.104
rootpw --iscrypted $1$yNzidLli$.mvja4xO61CLfrBBqI0UH/
firewall --disabled
authconfig --enableshadow --enablemd5
selinux --disabled
timezone --utc America/Toronto
bootloader --location=mbr --driveorder=sda
clearpart --all --initlabel
part / --fstype ext3 --size=100 --grow
part swap --size=256 --grow --maxsize=512
zerombr yes
reboot --eject

%packages
@editors
@text-internet
@core
@base
@server-cfg
-mysql-devel
arpwatch
sysstat
dstat
lynx
-aide
kexec-tools
device-mapper-multipath
imake
-mysql
-unixODBC
-MySQL-python
-mysql-connector-odbc
-libdbi-dbd-mysql
-emacs-leim
-psgml
-emacspeak
-zisofs-tools
-vnc
-xdelta
-OpenIPMI-tools
-openldap-clients
-bluez-hcidump
-zsh
-bluez-gnome
-slrn
-fetchmail
-mutt
-elinks
-cadaver
-nss_ldap
-readahead
-krb5-workstation


%post --nochroot
(
echo
echo "################################"
echo "# Running Post Configuration #"
echo "################################"

# Get latest RPM updates via ftp
echo "ftp connect to server... "
ftp -n 192.168.1.9 <<EOF
user anonymous -ks@`hostname`
binary
prompt
mget *.rpm
quit
EOF
rpm -Uvh *.rpm
/sbin/chkconfig acpid off
/sbin/chkconfig avahi-daemon off
/sbin/chkconfig iptables off
/sbin/chkconfig mcstrans off
/sbin/chkconfig microcode_ctl off
/sbin/chkconfig restorecond off
/usr/sbin/groupadd amc
mkdir -p /pool/home/
/usr/sbin/useradd -d /pool/home/joe/ joe
/bin/chgrp -R amc /pool/home/joe
/usr/sbin/usermod -p '$1$LeHv25Si$ijh8SrkMBPDGE.TnxB03' joe
) 1>/root/post_install.log 2>&1
Yes just do this under %post, It must work. If not however let me know will send you one of my ks files that I created to carryout a very similar installtion like yours.

Regards

Vimuth..
 
Old 09-13-2009, 11:27 AM   #5
samhoover
LQ Newbie
 
Registered: May 2007
Posts: 3

Original Poster
Rep: Reputation: 0
Thank you for your response; I've tried it like mentioned above but it does not seems to work. I would appreciate if I could see your ks file.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Issue with Kickstart Installation? your_shadow03 Linux - Newbie 2 04-14-2009 10:39 PM
Post script in kickstart qiuzhihong Linux - Software 1 04-19-2008 03:52 AM
kickstart post-installation abhi2778 Linux - Software 2 01-16-2007 10:04 AM
Kickstart installation. Access to cdrom in %post mrcash Fedora - Installation 2 07-21-2005 11:29 AM
Unable to run post-Installation kickstart scripts zoulo Linux - Enterprise 0 07-05-2005 03:26 AM


All times are GMT -5. The time now is 06:03 AM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration