RHEL Kickstart Pre-Install script

Thread Tools Search this Thread
Operating Systems Linux Red Hat RHEL Kickstart Pre-Install script
# 1  
Old 07-15-2011
RHEL Kickstart Pre-Install script

Hey all,

I'm not sure if this possible but I had tested it out manually during the installation (placed a sleep in the pre-installation) and it worked. I'm trying to have a pexpect script to log into the mysql and input a new row for the pre-installation, which will end up displaying on a web page stating the installation is starting. (later in the post installation stating its complete). I'm running out ideas, a beginner can only bang his head against the wall so much Smilie
mkdir /pexpect
mount /pexpect
mount /usr/lib
cd /pexpect/pexpect-2.3/
python setup.py install
#!/usr/bin/env python
import pexpect
import getpass, os
import sys, time
child = pexpect.spawn('ssh root@')
child.expect("Are you sure you want to continue connecting (yes/)?")
child.expect('password: ')
child.sendline('/usr/bin/mysql --user=user --password=pass mysql')
time.sleep (1)
child.sendline('use Test;')
child.sendline("INSERT INTO system_check (Serial_Number,Description")
child.sendline(" VALUES ('KQxXxXx','Kickstart Test');")

---------- Post updated at 08:02 PM ---------- Previous update was at 01:17 PM ----------

I got a little bit farther.

It seems to have been erroring out because it couldn't recognize the import command and needed the libMagick.so.10 file. So added the following to the shell portion

mount /usr/lib64
mount /usr/bin

Its hanging now at 'Running kickstart %%pre script(s)'.

Last edited by karljbaker; 07-15-2011 at 05:54 PM.. Reason: Please use code tags for data and code samples, thank you
# 2  
Old 07-17-2011
While it was hung I tried going to another vty but it couldn't recognize any commands.

Any thought?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

Trouble creating RHEL 6.5 bootable image with custom kickstart file

Hi everyone, I have a custom kickstart file from a software vendor and I'm trying to package that with a RHEL 6.5 and then attach it to a VM and install RHEL with the settings in the kickstarter file. I'm doing this from a windows PC using an app called InfraRecorder. I've extracted the... (0 Replies)
Discussion started by: 911Eric
0 Replies

2. Red Hat

Prevent kickstart to install image on external LUN

on the HP box , when we try to kickstart , the Linux gets installed on external LUN (Storage) .. so we end up unmapping the LUN and rekick , is there a way to disable the kickstart to ignore the external LUN incase we net boot it again (1 Reply)
Discussion started by: skamal4u
1 Replies

3. Red Hat

Rhel upgrade - pre maintenance checklist

I going to be updating a few of our rhel5.5 servers this weekend to rhel5.10. I'll be making a checklist for pre & post maintenance comparisions. so far I'll be checking, services running filesystems netstat ifconfig uname oracleasm multipath just basic stuff if it were you what... (5 Replies)
Discussion started by: mkeyes001
5 Replies

4. Fedora

Rhel 6.1 - How to create a kickstart file?

Can anyone tell me how you create a kickstart file for RHEL 6.1 install? I am new to this and wanting to learn Red Hat. I have a training guide that says to create one but it does not give you instructions on how to do so. (3 Replies)
Discussion started by: Saplmb
3 Replies

5. UNIX for Dummies Questions & Answers

How to install Unix OS with the Kickstart?

I am new to the Kickstart. I have a question: If I have a kickstart script in USB, CentOS CD and a PC without the OS, Can I install the CentOS with the Kickstart script? If I can, How can I identify the location of the kickstart when I boot the computer with the CentOS CD? (0 Replies)
Discussion started by: thsecmaniac
0 Replies

6. Red Hat

OpenSUSE installation using RHEL / CentOS Kickstart

Hi guys I have CentOS installed on my server. I have also installed TFTP server, DHCP server. I am able to install CentOS on remote machines using PXE boot and kickstart cfg file. I would like to install OpenSUSE using CentOS kickstart file. How do I do it ? I am also fine with any other... (2 Replies)
Discussion started by: msohail
2 Replies

7. Red Hat

kickstart minimum install with a gui

What are the packages that you need for a kickstart minimum install with a gui? I commented out the packages I don't think I need. Am I right? %packages @admin-tools @base @core #@editors #@fonts @gnome-desktop #@games #@graphical-internet #@graphics @hardware-support @input-methods... (0 Replies)
Discussion started by: cokedude
0 Replies

8. UNIX for Advanced & Expert Users

How do I configure kickstart server to install different images

How do I configure kickstart server to install workstation using centos image and other workstation using redhat enterprise image. I configured my kickstart server to auto install centos 5.3 and it working fine. However I would like to configure kickstart server, so that workstation with... (1 Reply)
Discussion started by: hassan1
1 Replies

9. Red Hat

how can i know what arguments are passed to a pre install rpm script?

hi, i have an rpm, and i am looking at the presinstall script. i can see it takes in an argument, but what i do not know is how this argument is passed to the script? is there something that calls the preinstall script? i thought the preinstall script was the first thing executed. thanks (2 Replies)
Discussion started by: JamesByars
2 Replies

10. Red Hat

RHEL Kickstart

Hi, I am trying to install RHEL5.3 using kickstart method. Copied the rhel.iso file from DVD to http location. ks.cfg and rhel.iso files are available on a WINDOWS2008 Server (via HTTP). In ks.cfg file, provided the media path as url --url=http://xx.xx.xx.xx/RHEL53. System understanding the... (3 Replies)
Discussion started by: uday123
3 Replies
Login or Register to Ask a Question