VMware

This Question is Answered

1 2 Previous Next 23 Replies Last post: Aug 3, 2009 9:00 AM by rt7500  

ESX 4 no more kickstart from harddisk: ks=hd:sda1/ks.cfg ? posted: Jun 24, 2009 12:53 AM

Click to view NCC1470's profile Novice 7 posts since
Jun 16, 2009
Hi,

I am running a scripted install for 3.5.0 by placing the kickstart file on a "disposable" FAT partition and boot the installation with:

label text
kernel /pxeboot/vmlinuz
append initrd=/pxeboot/initrd.img text ks=hd:sda1/ks.cfg
default text

...I was trying to install ESX 4 the same way but the kickstart file does not get read!

The installation guide is inconsistent here it gives: Default installation script, FTP, HTTP/HTTPS, NFS, USB flash drive (what reads for me as ks=hd...), Local disk

but only this kickstart locations for the boot: ks=cdrom:, ks=file://<path>/ks.cfg, ks=ftp://<server>/<path>/ks.cfg, ks=http://<server>/<path>/ks.cfg, nfs=nfs://<server>/<path>/ks.cfg

Any ideas?

Max
Click to view K-MaC's profile Expert 531 posts since
Jun 16, 2008
Hello Max. Please take a look at the following page for help.

http://blog.laspina.ca/ubiquitous/automating-vsphere-esx4-host-installations

Cheers

Kevin
Click to view mike.laspina's profile Virtuoso vExpert 2,273 posts since
May 26, 2006
Hi,

You cannot specify the linux kickstart hd method combined with a pxeboot based method. Keep in mind that the ESX 4 VMware install is not fully compatible with kickstart as specified in the docs.Many commands will not work.


The vSphere documentation specifies that you can use an extended partition ks spec on the local system using a UUID format. Never tried it myself and frankly I would not want to (ugly!).

ks=UUID:<partition-UUID>:/<path> Performs a scripted installation with a script located on the ext
partition with the given UUID.


http://blog.laspina.ca/
vExpert 2009

Click to view kqian's profile Novice 3 posts since
Oct 23, 2008
Hi, Max,

ks=hd is not supported in vSphere 4.0.

If you have ks file on disk, you can use ks=UUID:<partition-UUID>:/<path>.
For details, please refer to ESX and vCenter Server Installation Guide(http://www.vmware.com/pdf/vsphere4/r40/vsp_40_esx_vc_installation_guide.pdf), page 26.

Thanks.

Kern.
Click to view TaupoJohn's profile Enthusiast 19 posts since
Feb 7, 2008

ncc,

I'm using altiris and trying to get it to deploy vSphere. It does something very similar to your method, and injects a ks file into initrd.

Like this:

  1. Inject kickstart file into initrd
pushd .
cd $hddir/init
mkdir mountedinit
mv initrd.img initrd.gz
gunzip initrd.gz
mount initrd ./mountedinit -o loop
cp -af ks.cfg ./mountedinit
umount ./mountedinit
gzip initrd
mv initrd.gz initrd.img
popd
http:// ! -e $hddir/init/initrd.img && ErrorHandle 248

My problem is when I try using:

title RDP Linux Loader
root (hd0,0)
kernel /init/vmlinuz $k1 ks=file:///init/ks.cfg mem=512M
initrd /init/initrd.img

It says that ks.cfg does not exist. Altiris is using grub 0.97, and if I go to the command line and cat /init/ks.cfg, it is there and it is correct.

I've tried ks=file:///ks/cfg (not found)

ks=file:/ks/cfg (this works for ESX 3.5 - but for vsphere it just ignores it and doesn't even try to load a ks file)

and every other permutation I can think of.

What exact syntax are you using?

rgds,


Click to view TaupoJohn's profile Enthusiast 19 posts since
Feb 7, 2008

NCC1470,

Thanks a lot for your reply - that's exactly what I was needing. This is new to me so I've been struggling. These steps are performed in a script on the altiris server - so I can change the script. I'm not sure where to put the cpio though, as I'm not really sure where the script actually runs. The altiris deployment server is running on a Windows server, but there must be a linux environment that this script runs in (?) and that is where the cpio needs to go.

I might just try changing the script first - and see what happens.

rgds,


Click to view TaupoJohn's profile Enthusiast 19 posts since
Feb 7, 2008

Max,

I've figured out how to get the cpio onto the altiris server, and my script (with your new commands) seems to run OK. The problem is still exactly the same ks.cfg does not exist. I know it does exist, as I can cat it from a grub command prompt. Once the kernel loads and weasel starts running, I don't know where the file is anymore (ie how you specifiy a path to it).

I think I'm going to have to redo how pxe is loading the kernel for ESX 4 :-(

Click to view TaupoJohn's profile Enthusiast 19 posts since
Feb 7, 2008

FYI - I've gotten this to work. Thanks a lot for your help, as we wouldn't have gotten this far without it.

NOTE: In altiris, I had to make a big grub partition for all this unzipping etc. 500MB wasn't big enough, so I went to 2GB and that did the trick ;-)

Re: 500MB

12. Jul 8, 2009 2:07 AM in response to: NCC1470
Click to view TaupoJohn's profile Enthusiast 19 posts since
Feb 7, 2008

You are the only one (that I have found) who has posted any information on this. Documentation for altiris and vsphere seems pretty thin on the ground. My next challenge is to get a kickstart file that actually works (now that I'm finally able to process it).

Thanks again for your help.


Click to view rt7500's profile Enthusiast vExpert 92 posts since
Dec 6, 2004

Which file specifically did you modify to increase the grub.img and what line did you modify?

I've been trying the C:\Program Files\Altiris\eXpress\Deployment Server\PXE\MasterImages\MenuOption160\X86PC\pxelinux.cfg and C:\Program Files\Altiris\eXpress\Deployment Server\PXE\\MenuOption160\X86PC\pxelinux.cfg with no luck when increasing the ramdisk_size=500000


Click to view TaupoJohn's profile Enthusiast 19 posts since
Feb 7, 2008

rt,

I didn't change a file or change the size of the grub image - I changed the size of the partition that gets created when the grub image is pushed down. I've attached a screenshot from the altiris job in the deployment console. In the step that pushes down grub.img - click on the advanced button.

Attachments:

VMware Beta Programs

Want to be Considered for Future Beta Programs?

Learn More

VMware Developer

Download SDKs, APIs, videos,
training, and more in the Developer community.

Learn More

Developer
Sample Code

Increase your developer productivity with VMware API sample code.

Learn More

VMworld
Sessions & Labs

Online access to the latest VMworld Sessions & Labs and online services.

Learn more

Purchase PSO Credits Online

Purchase credits to redeem training and consulting services online.

Buy Now

Community Hardware Software

View reported configurations or report your own.

Learn More

Only VMware ... Delivers Nexus 1000V

Ensure consistent, policy-based network capabilities to virtual machines across your data center.

Learn More

Communities