Unattended build problem and questions

So I've finally deployed puppet and foreman in our environment. So
far so good.

Now I want to work on setting up unattended installs.

What I've done so far is:

  • Setup TFTP/DHCP server and put it under smart proxy control
  • Setup foreman to 'see' the smart proxy
  • Configured install source media path in foreman
  • Configured a PXELinux template (pretty much a copy of base SUSE one
    right now)
  • Configured a provision template (SLES AutoYast)
  • Editted OS and associated the install media, PXELinux tempate and
    provision tempate to it

I then used the https://foreman/unattended/provision?spoof=<ip> and
saw it generate an AY for that host. I then did the same for PXELinux
using https://foreman/unattended/PXELinux?spoof=<ip> and it gives me:

The following error message was observed:
undefined method `configTemplate' for nil:NilClass

Not sure what is causing this and not sure where to start
troubleshooting it.

Next, I'm trying to figure out where <%= @kernel %> and <%= @initrd %>
are resolved from in my PXELinux template. I'm not sure where to be
putting the kernel/initrd on my tftpboot server so they can be used.

Finally I'm trying to understand how smart proxy works with
determining the next available IP when building a system. Does it
just ping the network for unresponsive IPs? Or does it also refer to
the hosts managed by foreman knowing they are using IPs? What I'm
basically wondering is if a system has multiple IPs on it for the same
network how would it know not to use those IPs? I get if the system
is up it should just ping and get a response, but what if the system
was down (for maintenance or something) then what would it do?

Thanks,
Jake

> So I've finally deployed puppet and foreman in our environment. So
> far so good.
>
> Now I want to work on setting up unattended installs.
>
> What I've done so far is:
>
> * Setup TFTP/DHCP server and put it under smart proxy control
> * Setup foreman to 'see' the smart proxy
> * Configured install source media path in foreman
You missed a couple of steps here:

  1. edit your subnet (create one if you dont have it) and assign the
    tftp and dhcp proxies.
    > * Configured a PXELinux template (pretty much a copy of base SUSE one
    > right now)
    > * Configured a provision template (SLES AutoYast)
    > * Editted OS and associated the install media, PXELinux tempate and
    > provision tempate to it
    >
    > I then used the https://foreman/unattended/provision?spoof=<ip> and
    > saw it generate an AY for that host. I then did the same for PXELinux
    > using https://foreman/unattended/PXELinux?spoof=<ip> and it gives me:
    >
    > The following error message was observed:
    > undefined method `configTemplate' for nil:NilClass
    >
    > Not sure what is causing this and not sure where to start
    > troubleshooting it.
    >
    > Next, I'm trying to figure out where <%= @kernel %> and <%= @initrd %>
    > are resolved from in my PXELinux template. I'm not sure where to be
    > putting the kernel/initrd on my tftpboot server so they can be used.
    The proxy takes care for getting the boot files (and putting them in
    the right place) if your medium is based on http.
    >
    > Finally I'm trying to understand how smart proxy works with
    > determining the next available IP when building a system. Does it
    > just ping the network for unresponsive IPs? Or does it also refer to
    > the hosts managed by foreman knowing they are using IPs? What I'm
    > basically wondering is if a system has multiple IPs on it for the same
    > network how would it know not to use those IPs? I get if the system
    > is up it should just ping and get a response, but what if the system
    > was down (for maintenance or something) then what would it do?
    The current logic is:
    figure the subnet to use, remove all dhcp active leases and
    reservations, and then start pinging.

for the specific case of a server is not active… good question, do
you use that ip in foreman? (then foreman would complain the IP is
already used) if not, one way could be to have some sort of an exclude
file on the proxy, which we could put inside all unwanted ip
addresses?

··· On Tue, Sep 20, 2011 at 12:10 AM, Jake - USPS wrote:

Thanks,
Jake


You received this message because you are subscribed to the Google Groups “Foreman users” group.
To post to this group, send email to foreman-users@googlegroups.com.
To unsubscribe from this group, send email to foreman-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/foreman-users?hl=en.

I actually did create the subnet and assigned it. I was able to test
it 'finding' an IP to use. So even with that setup I was getting the
PXELinux error described.

Also, I was wondering where the kernel and initrd are located because
currently I have a customized initrd (which would also require a
specific kernel) … may not need it after I figure out how to use the
unattended installs but was curious where I would put it if I did need
it. It has additinal commands/libraries in for our current AutoYast
but also so if we boot a system from it in rescue mode for
troubleshooting.

As for IPs, its pretty dynamic so maintaining an exclude could be
difficult. I didn't know if maybe you could associate additional IPs
to a system somehow. Like you have a primary build IP/hostname, then
additional IPs assigned just so you can track where they are and so
foreman wouldn't try and use them.

Thanks!
Jake

··· On Sep 20, 1:06 am, Ohad Levy wrote: > On Tue, Sep 20, 2011 at 12:10 AM, Jake - USPS wrote:> So I've finally deployed puppet and foreman in our environment. So > > far so good. > > > Now I want to work on setting up unattended installs. > > > What I've done so far is: > > > * Setup TFTP/DHCP server and put it under smart proxy control > > * Setup foreman to 'see' the smart proxy > > * Configured install source media path in foreman > > You missed a couple of steps here: > 1. edit your subnet (create one if you dont have it) and assign the > tftp and dhcp proxies. > > > > > > > > > * Configured a PXELinux template (pretty much a copy of base SUSE one > > right now) > > * Configured a provision template (SLES AutoYast) > > * Editted OS and associated the install media, PXELinux tempate and > > provision tempate to it > > > I then used thehttps://foreman/unattended/provision?spoof= and > > saw it generate an AY for that host. I then did the same for PXELinux > > usinghttps://foreman/unattended/PXELinux?spoof= and it gives me: > > > The following error message was observed: > > undefined method `configTemplate' for nil:NilClass > > > Not sure what is causing this and not sure where to start > > troubleshooting it. > > > Next, I'm trying to figure out where <%= @kernel %> and <%= @initrd %> > > are resolved from in my PXELinux template. I'm not sure where to be > > putting the kernel/initrd on my tftpboot server so they can be used. > > The proxy takes care for getting the boot files (and putting them in > the right place) if your medium is based on http. > > > Finally I'm trying to understand how smart proxy works with > > determining the next available IP when building a system. Does it > > just ping the network for unresponsive IPs? Or does it also refer to > > the hosts managed by foreman knowing they are using IPs? What I'm > > basically wondering is if a system has multiple IPs on it for the same > > network how would it know not to use those IPs? I get if the system > > is up it should just ping and get a response, but what if the system > > was down (for maintenance or something) then what would it do? > > The current logic is: > figure the subnet to use, remove all dhcp active leases and > reservations, and then start pinging. > > for the specific case of a server is not active.. good question, do > you use that ip in foreman? (then foreman would complain the IP is > already used) if not, one way could be to have some sort of an exclude > file on the proxy, which we could put inside all unwanted ip > addresses? > > > > > > > > > > > Thanks, > > Jake > > > -- > > You received this message because you are subscribed to the Google Groups "Foreman users" group. > > To post to this group, send email to foreman-users@googlegroups.com. > > To unsubscribe from this group, send email to foreman-users+unsubscribe@googlegroups.com. > > For more options, visit this group athttp://groups.google.com/group/foreman-users?hl=en.