Unable to download the kickstart file (VMware Workstation)

1,688 views
Skip to first unread message

to...@c2cschools.com

unread,
Sep 17, 2014, 9:21:20 AM9/17/14
to packe...@googlegroups.com

I am attempting to create a CentOS 6.5 Packer image using VMWare and am getting the "Unable to download kickstart file" error. Here is where it is getting stuck:

If I attempt to go to this path from the actual host I am getting a 404 error:


I went through to make sure that the file was actually there on my host and it was:











Here is a copy of the json file I am running in order to do this build:

{
   
"variables"       : {
       
"mirror"       : "http://mirrors.kernel.org/centos"
   
},
   
"builders"        : [
       
{
           
"boot_command"        : [
               
"<tab> text ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/centos-6.5/ks.cfg<enter><wait>"
           
],
           
"boot_wait"           : "10s",
           
"disk_size"           : 40960,
           
"guest_os_type"       : "centos-64",
           
"http_directory"      : "http",
           
"iso_checksum"        : "3a9662cb65f9d59677d76acfdb73289da43b4599",
           
"iso_checksum_type"   : "sha1",
           
"iso_url"             : "http://mirrors.kernel.org/centos/6.5/isos/x86_64/CentOS-6.5-x86_64-netinstall.iso",
           
"output_directory"    : "c2c-raw-centos-6.5-x64-vmware",
           
"shutdown_command"    : "echo 'vagrant'|sudo -S /sbin/halt -h -p",
           
"ssh_password"        : "vagrant",
           
"ssh_port"            : 22,
           
"ssh_username"        : "vagrant",
           
"ssh_wait_timeout"    : "10000s",
           
"tools_upload_flavor" : "linux",
           
"type"                : "vmware-iso",
           
"vm_name"             : "c2c-raw-centos-6.5-x64",
           
"vmx_data"            : {
               
"cpuid.coresPerSocket" : "1",
               
"memsize"              : "768",
               
"numvcpus"             : "2"        
           
}    
       
}
   
],
   
"post-processors" : [
       
{
           
"output"              : "../../builds/{{.Provider}}/raw/centos-6.5-x64.box",
           
"type"                : "vagrant",
           
"keep_input_artifact" : true
       
}
   
],
   
"provisioners"    : [
       
{
           
"execute_command" : "echo 'vagrant' | {{.Vars}} sudo -S -E bash '{{.Path}}'",
           
"scripts"         : [
               
"./centos-6.5/scripts/centos/fix-slow-dns.sh", "./common/scripts/sshd.sh",
               
"./common/scripts/vagrant.sh", "./common/scripts/vmtools.sh",
               
"./centos-6.5/scripts/centos/cleanup.sh", "./common/scripts/minimize.sh"
           
],
           
"type"            : "shell"
       
}
   
]
}



I did some research and some people mentioned using bridged networking instead of the NAT, but I was able find the proper "vmx_data" settings to force this. I am hoping someone here has seen this and can advise. Below is some additional information:

I am running this on a Windows 2008 R2 server with the firewall currently disabled. I am running Packer version 0.7.1 and VMWare Workstation 10.0.3.

Thanks in advance!

to...@c2cschools.com

unread,
Sep 17, 2014, 9:26:31 AM9/17/14
to packe...@googlegroups.com
I see a flaw already in my json file with the output type and the actual output. I have already corrected this in my json file. This was a copy and paste from our Vagrant build. This should still have zero impact on the actual kickstart problem.

-Todd

Alvaro Miranda Aguilera

unread,
Sep 17, 2014, 5:49:47 PM9/17/14
to packe...@googlegroups.com
just as a test.


can you try to put the file on the directory you are sharing?

I haven't tested path/path/file, but I know path/file work


From:

"<tab> text ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/centos-6.5/ks.cfg<enter><wait>"


"http_directory"      : "http",


to:

"<tab> text ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/ks.cfg<enter><wait>"

"http_directory"      : "http/centos-6.5",





--
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

to...@c2cschools.com

unread,
Sep 18, 2014, 1:51:01 PM9/18/14
to packe...@googlegroups.com
I made the suggested change and came up with the same result. I also tested the access through the browser once the VM was up and still ended up with a 404 error.

Anthony Spring

unread,
Sep 19, 2014, 10:06:23 AM9/19/14
to packe...@googlegroups.com
From which directory are you running the packer process?  PackerBase/packer?  or PackerBase/packer/raw?

to...@c2cschools.com

unread,
Sep 19, 2014, 12:13:01 PM9/19/14
to packe...@googlegroups.com
I am running packer from the C:\Packer\c2c-raw directory. Its a completely different directory than the actual packer directory, but I have run a test where I created a child directory under the main packer directory (called test-build) and still ended up with the same results.

Jason Beranek

unread,
Sep 20, 2014, 11:51:32 PM9/20/14
to packe...@googlegroups.com
Could you please run Packer with debugging enabled (http://www.packer.io/docs/other/debugging.html), upload the log output to service such as GitHub Gist, and provide a link for review.  If you'd like, feel free to submit an issue on this to the GitHub project.  The log output should help identify what may be happening.

There are some issues with networking behavior on Windows, that could be why the file isn't being presented, but we'd need a bit more information on what Packer is saying.

V/r,

Jason

to...@c2cschools.com

unread,
Sep 22, 2014, 4:37:58 PM9/22/14
to packe...@googlegroups.com
Jason,

Here is the link to the debug file. This basically is just me running the packer command, and letting it get to the point where it cannot find the kickstart file.

https://gist.github.com/anonymous/6d4c2765d1a9c4ec0f5c

I appreciate your help!!

-Todd

Jason Beranek

unread,
Sep 22, 2014, 5:24:00 PM9/22/14
to packe...@googlegroups.com
Todd,

Thanks for the information, I mainly wanted to verify there wasn't anything obvious I could catch. 

I've seen similar issues to this. When I have,  the cause has usually been an error in the network Packer is using within VMware Workstation. I've seen the same behavior when checking the url in the browser using the ip chosen by packer (I.e. A 404 error), but can often see the files if I pick a different ip on that host (give it a try and see). If that works, then you could hard code, or use user variables to define, that ip in the template. 

NaT vs bridged shouldn't affect this behavior. 

Let me know what you see. 

-Jason 

to...@c2cschools.com

unread,
Sep 23, 2014, 12:30:44 PM9/23/14
to packe...@googlegroups.com
Jason,

I will give this a try today. Thanks again!

-Todd
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool+unsubscribe@googlegroups.com.

to...@c2cschools.com

unread,
Sep 29, 2014, 1:43:07 PM9/29/14
to packe...@googlegroups.com
Jason,

No luck. I have tried all adapters on the system and am still getting a 404 error when trying to access the ks.cfg. Do you have any other ideas I can try?

-Todd
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool+unsubscribe@googlegroups.com.

Alvaro Miranda Aguilera

unread,
Sep 30, 2014, 5:18:25 AM9/30/14
to packe...@googlegroups.com
did test with firewall off? i just re-read and seems the host is windows. can you disable the host windows firewall and test?

if still doesn't work, the json template is still the same as the original message? can you share a zip file including the ks, etc

i would like to give it a go.. thanks

to...@c2cschools.com

unread,
Oct 1, 2014, 11:29:55 AM10/1/14
to packe...@googlegroups.com
The Windows firewall is off. I can paste up the json file and the ks file I am trying to use if you would like to see it. I am lost right now. I am not sure what to do next.

-Todd
Reply all
Reply to author
Forward
0 new messages