I just did this successfully:

created the files subdirectory within the DVD working directory:

[root@myhost respin]# ls -l |egrep "^d"
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 EFI
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 HighAvailability
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 images
dr-xr-xr-x. 2 root root   4096 Mar 23 14:52 isolinux
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 LoadBalancer
dr-xr-xr-x. 2 root root 258048 Mar 23 15:06 Packages
drwxr-xr-x. 2 root root   4096 Mar 23 15:08 repodata
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 ResilientStorage
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 ScalableFileSystem
dr-xr-xr-x. 3 root root   4096 Mar 23 14:52 Server
drwxr-xr-x. 2 root root   4096 Mar 23 13:53 files


[root@myhost respin]# ls -l files/
total 160872
-rw-r--r--. 1 root root 164712460 Mar 23 13:36 distribution.tar.gz
-r--r--r--. 1 root root      4197 Mar 23 13:36 sudoers

cat << EOF > /tmp/installnet
interface=$interface ip=$IPADDR netmask=$NETMASK gateway=$GATEWAY host=
$HOSTNAME dns=$DNSSERVER domain=$DOMAIN ntpserver=$NTPSERVER
EOF



In the post install section:
---------------------------------------------------------------

%post --nochroot --log=/mnt/sysimage/root/post-nochroot.txt
mkdir -p /mnt/sysimage/root/sotafiles
cp -f /mnt/source/files/* /mnt/sysimage/root/sotafiles/
cp /tmp/installnet /mnt/sysimage/tmp/installnet
%end

%post --log=/root/sotasrv_post_install.log
#!/bin/sh 
source /tmp/installnet
...
...
mv /root/files/sudoers /etc/sudoers
chmod 0440 /etc/sudoers
mv /root/files/distribution.tar.gz /home/${USERNAME}/distribution.tar.gz
...
...
%end

---------------------------------------------------------------




On Sat, 2014-03-22 at 12:00 -0400, [email protected]
wrote:
> Send Kickstart-list mailing list submissions to
>       [email protected]
> 
> To subscribe or unsubscribe via the World Wide Web, visit
>       https://www.redhat.com/mailman/listinfo/kickstart-list
> or, via email, send a message with subject or body 'help' to
>       [email protected]
> 
> You can reach the person managing the list at
>       [email protected]
> 
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Kickstart-list digest..."
> Today's Topics:
> 
>    1. Want to create custom iso (Anant)
>    2. Re: Want to create custom iso (Mats Karlsson)
>    3. Re: Want to create custom iso (Anant)
> email message attachment
> > -------- Forwarded Message --------
> > From: Anant <[email protected]>
> > Reply-to: Discussion list about Kickstart
> > <[email protected]>
> > To: [email protected]
> > Subject: Want to create custom iso
> > Date: Sat, 22 Mar 2014 13:44:25 +0530
> > 
> > 
> > Hi Guys,
> > 
> > I have made custom Centos DVD , I have copied ks.cfg in top directory of
> > my DVD. and it is working fine.
> > My ks.cfg looks like :
> > 
> > 
> > %post --log=/root/my-post-log
> > 
> > yum remove libreoffice* -y ;
> > /usr/bin/wget http://210.X.X.52/LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz ;
> > tar -xvzf LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz ;
> > cd LibreOffice_4.1.5.3_Linux_x86-64_rpm/RPMS/ ;
> > yum install *.rpm -y ;
> > 
> > %end
> > 
> > 
> > I am downloading LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz from
> > 210.X.X.52 , which consume bandwidth each time , So i want to keep this
> > package in side my DVD,
> > So i need Suggestion how can i do that , and access it on POST script
> > run time.
> > 
> > Like how can i mount my dvd in any /tmp folder OR any suggestion..
> > 
> > I tried that also
> > 
> > %post --nochroot --log=/mnt/sysimage/root/my-post-log
> > 
> > #!/bin/bash
> > # Copying EXTRAS folder from CDROM to /root/EXTRAS
> > mkdir /tmp/c
> > mount -t iso9660 /tmp/cdrom /tmp/c
> > mkdir -p /mnt/sysimage/root/EXTRAS
> > cp -arv /tmp/c/Packages/Ex/* /mnt/sysimage/root/EXTRAS
> > umount /tmp/c
> > 
> > %end
> > 
> > But it gives me /tmp/cdrom doesnt exist . So where was cdrom mounted during 
> > installation
> > 
> >   Thanks in Advance :)
> > 
> > 
> > 
> > 
> > 
> > 
> email message attachment
> > -------- Forwarded Message --------
> > From: Mats Karlsson <[email protected]>
> > Reply-to: Discussion list about Kickstart
> > <[email protected]>
> > To: Discussion list about Kickstart <[email protected]>
> > Subject: Re: Want to create custom iso
> > Date: Sat, 22 Mar 2014 09:57:59 +0100
> > 
> > On 2014-03-22 09:14, Anant wrote:
> > 
> > > Hi Guys, 
> > > 
> > > I have made custom Centos DVD , I have copied ks.cfg in top
> > > directory of 
> > > my DVD. and it is working fine. 
> > > My ks.cfg looks like :
> > > 
> > > %post --log=/root/my-post-log 
> > > 
> > > yum remove libreoffice* -y ; 
> > > /usr/bin/wget
> > > http://210.X.X.52/LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz ; 
> > > tar -xvzf LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz ; 
> > > cd LibreOffice_4.1.5.3_Linux_x86-64_rpm/RPMS/ ; 
> > > yum install *.rpm -y ; 
> > > 
> > > %end 
> > > 
> > > 
> > > I am downloading LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz from 
> > > 210.X.X.52 , which consume bandwidth each time , So i want to keep
> > > this 
> > > package in side my DVD, 
> > > So i need Suggestion how can i do that , and access it on POST
> > > script 
> > > run time. 
> > > 
> > > Like how can i mount my dvd in any /tmp folder OR any
> > > suggestion.. 
> > > 
> > > I tried that also 
> > > 
> > > %post --nochroot --log=/mnt/sysimage/root/my-post-log 
> > > 
> > > #!/bin/bash 
> > > # Copying EXTRAS folder from CDROM to /root/EXTRAS 
> > > mkdir /tmp/c 
> > > mount -t iso9660 /tmp/cdrom /tmp/c 
> > > mkdir -p /mnt/sysimage/root/EXTRAS 
> > > cp -arv /tmp/c/Packages/Ex/* /mnt/sysimage/root/EXTRAS 
> > > umount /tmp/c 
> > > 
> > > %end 
> > > 
> > > But it gives me /tmp/cdrom doesnt exist . So where was cdrom
> > > mounted during installation 
> > > 
> > >  Thanks in Advance :) 
> > 
> > I would suggest to you that you replace the LibreOffice RPM on the
> > DVD and then rebuild the comps.xml
> > 
> > Example:
> > http://markliggett.wordpress.com/2009/11/30/custom-installation-centosrhel-dvd/
> > 
> > And for your kickstart %post work, what
> > does /mnt/sysimage/root/my-post-log say ?
> > 
> > 
> > /Mats
> > -- 
> > 
> > Mats Karlsson
> email message attachment
> > -------- Forwarded Message --------
> > From: Anant <[email protected]>
> > Reply-to: Discussion list about Kickstart
> > <[email protected]>
> > To: [email protected]
> > Subject: Re: Want to create custom iso
> > Date: Sat, 22 Mar 2014 14:56:11 +0530
> > 
> > Hello Mats,
> > 
> > Actully i have tried that but I have 2 hurdels in fron of me 
> > 
> > 1. Unable to resolve dependencies
> > 2. I have to do many things in my Post scripts , which dont have
> > RPMs , let me attach my ks.cfg for you , So what i am thinking is
> > Paste that all setup files in DVD and use it at post installation
> > time.
> > 
> > 
> > On Saturday 22 March 2014 02:27 PM, Mats Karlsson wrote:
> > 
> > > On 2014-03-22 09:14, Anant wrote:
> > > 
> > > > Hi Guys, 
> > > > 
> > > > I have made custom Centos DVD , I have copied ks.cfg in top
> > > > directory of 
> > > > my DVD. and it is working fine. 
> > > > My ks.cfg looks like :
> > > > 
> > > > %post --log=/root/my-post-log 
> > > > 
> > > > yum remove libreoffice* -y ; 
> > > > /usr/bin/wget
> > > > http://210.X.X.52/LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz ; 
> > > > tar -xvzf LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz ; 
> > > > cd LibreOffice_4.1.5.3_Linux_x86-64_rpm/RPMS/ ; 
> > > > yum install *.rpm -y ; 
> > > > 
> > > > %end 
> > > > 
> > > > 
> > > > I am downloading LibreOffice_4.1.5_Linux_x86-64_rpm.tar.gz from 
> > > > 210.X.X.52 , which consume bandwidth each time , So i want to
> > > > keep this 
> > > > package in side my DVD, 
> > > > So i need Suggestion how can i do that , and access it on POST
> > > > script 
> > > > run time. 
> > > > 
> > > > Like how can i mount my dvd in any /tmp folder OR any
> > > > suggestion.. 
> > > > 
> > > > I tried that also 
> > > > 
> > > > %post --nochroot --log=/mnt/sysimage/root/my-post-log 
> > > > 
> > > > #!/bin/bash 
> > > > # Copying EXTRAS folder from CDROM to /root/EXTRAS 
> > > > mkdir /tmp/c 
> > > > mount -t iso9660 /tmp/cdrom /tmp/c 
> > > > mkdir -p /mnt/sysimage/root/EXTRAS 
> > > > cp -arv /tmp/c/Packages/Ex/* /mnt/sysimage/root/EXTRAS 
> > > > umount /tmp/c 
> > > > 
> > > > %end 
> > > > 
> > > > But it gives me /tmp/cdrom doesnt exist . So where was cdrom
> > > > mounted during installation 
> > > > 
> > > >  Thanks in Advance :) 
> > > 
> > > I would suggest to you that you replace the LibreOffice RPM on the
> > > DVD and then rebuild the comps.xml
> > > 
> > > Example:
> > > http://markliggett.wordpress.com/2009/11/30/custom-installation-centosrhel-dvd/
> > > 
> > > And for your kickstart %post work, what
> > > does /mnt/sysimage/root/my-post-log say ?
> > > 
> > > 
> > > /Mats
> > > -- 
> > > 
> > > Mats Karlsson
> > > 
> > > 
> > > _______________________________________________
> > > Kickstart-list mailing list
> > > [email protected]
> > > https://www.redhat.com/mailman/listinfo/kickstart-list
> > 
> > 
> > -- 
> > Anant Saraswat
> > System Admin (RHCVA,RHCE,RHCSA)
> > 
> > FOR AND ON BEHALF OF:
> > Techblue Software Pvt. Ltd.
> > 73, Sector-5
> > IMT Manesar
> > Haryana
> > 
> > E: [email protected]
> > W: www.techblue.co.uk
> > 
> > 
> > The contents of this email are confidential and may be privileged, and are 
> > intended only for the use of the person or company named herein. Any views 
> > or opinions presented are solely those of the author and do not necessarily 
> > represent those of Technology Blueprint Limited.
> > If you are not the intended recipient of this email or a person responsible 
> > for delivering it to the intended recipient, you are hereby notified that 
> > any distribution, copying or dissemination of the information herein is 
> > strictly prohibited.
> _______________________________________________
> Kickstart-list mailing list
> [email protected]
> https://www.redhat.com/mailman/listinfo/kickstart-list

_______________________________________________
Kickstart-list mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/kickstart-list

Reply via email to