Public Alpha of the new Metal-as-a-Service feature

Hi all,

As some of you may know, we've been working on adding a feature to
Foreman to allow you 'discover' hardware, and then consume it at later
date. This follows a process where:

Hardware is booted into a small ramdisk environment
Ramdisk registers with Foreman
Ramdisk waits for further instructions
Admin chooses a piece of hardware to be provisioned with an OS
Hardware reboots and installs the chosen OS

Since I'm aware that a few people are really keen to play with this,
I'm excited to announce that I'm putting up the first alpha version to
start playing with. The instructions are at:

The code for Foreman itself is at:

https://github.com/GregSutcliffe/foreman/tree/discovery

The necessary disclaimer: This is alpha! Half the test suite is
broken, and there are no tests as yet for the new functionality. Do
not use this in production! It may eat your hardware, burn your toast
or give you a wedgie :slight_smile:

The assumption for now is that the hardware to be 'discovered' is on
the same network segment as the Foreman server. I would strongly
advise setting up an independant test environment :slight_smile:

Any issues or questions, reply here or comment on Github. The branch
is likely to continue to undergo change for some while yet, but I'll
try and announce here if there are any major breaking changes.

Regards,
Greg

> Hi all,
>
> As some of you may know, we've been working on adding a feature to
> Foreman to allow you 'discover' hardware, and then consume it at later
> date. This follows a process where:

So what 'state' is such a discovered server presumed to be in
as far as Foreman is concerned?

> Hardware is booted into a small ramdisk environment
> Ramdisk registers with Foreman
> Ramdisk waits for further instructions
> Admin chooses a piece of hardware to be provisioned with an OS
> Hardware reboots and installs the chosen OS

This sounds pretty interesting, but could you please elaborate
how it is different from Foreman owning that said server the minute
it appears in the datacenter? You don't have to do anything with
it as far configuration is concerned, of course, but other than that
it'll be as first class citizen as any other piece of hardware.

Thanks,
Roman.

··· On Thu, Jan 10, 2013 at 7:39 AM, Greg Sutcliffe wrote:

>> Hi all,
>>
>> As some of you may know, we've been working on adding a feature to
>> Foreman to allow you 'discover' hardware, and then consume it at later
>> date. This follows a process where:
>
> So what 'state' is such a discovered server presumed to be in
> as far as Foreman is concerned?

Any discovered hardware is presumed unused and availble for
deployment. Obviously, any machine already known to Foreman will have
a TFTP boot file for Localboot, and therefore will not end up in the
discover image.

However, by default the discovery ramdisk makes no changes, so if you
have hardware which is in-use, but not yet know to foreman, it's non
destructive - simply add the host to foreman, disable build, and
reboot the server, it should come back up just fine.

Obviously right now this is aimed at a network fully controlled by
Foreman. I've got some thoughts about how to handle heterogeneous
networks for the next version :wink:

>> Hardware is booted into a small ramdisk environment
>> Ramdisk registers with Foreman
>> Ramdisk waits for further instructions
>> Admin chooses a piece of hardware to be provisioned with an OS
>> Hardware reboots and installs the chosen OS
>
> This sounds pretty interesting, but could you please elaborate
> how it is different from Foreman owning that said server the minute
> it appears in the datacenter? You don't have to do anything with
> it as far configuration is concerned, of course, but other than that
> it'll be as first class citizen as any other piece of hardware.

(MFridh might weigh in here, this was his idea orginally…) You're
right, ofc, but if you've just received a lot of hardware, entering
all of it into Foreman is time-consuming and error-prone - I hate
typing MACs in manually, and that's made worse if you're relying on
remote hands to do the racking and send you the MACs.

Consider the situation where 50 servers have arrived at your
datacenter. You've racked them up, but you're not sure yet what you're
going to use all of them for. So, you switch them all on (with no
pre-registration of data in Foreman) and then they boot to Discovery,
and register themselves in Foreman. Now, at some later time, you can
think "Oh, I need a new webserver", go to the Discovered Hosts, browse
the Fact data to find one with, say, enough memory or disk space for
the role, and then provision it. Also, when you delete a machine from
Foreman, you can reboot it, and it goes back into the pool of
Discovered Hosts for re-use.

It's also useful as a pre-install environment to apply BIOS/Firmware
updates, or do Hardware Raid configuration, or anything else which
would be difficult to squeeze into the installation environment.

In all, what you suggest is correct, I just feel the flow if this is
slightly more natural, especially if machines are changing roles or
hardware is being shared among teams.

Hope that helps,
Greg

··· On 14 January 2013 04:53, Roman Shaposhnik wrote: > On Thu, Jan 10, 2013 at 7:39 AM, Greg Sutcliffe > wrote:

>

> > This sounds pretty interesting, but could you please elaborate
> > how it is different from Foreman owning that said server the minute
> > it appears in the datacenter? You don't have to do anything with
> > it as far configuration is concerned, of course, but other than that
> > it'll be as first class citizen as any other piece of hardware.

That's just what Greg added to Foreman… Previously servers did not
"appear". The idea is that now they will.

> (MFridh might weigh in here, this was his idea orginally…) You're
> right, ofc, but if you've just received a lot of hardware, entering
> all of it into Foreman is time-consuming and error-prone - I hate
> typing MACs in manually, and that's made worse if you're relying on
> remote hands to do the racking and send you the MACs.

+1 Greg! This to me is the one missing thing for bare metal. Now can
automatically check servers off against whatever other inventory system you
may use when ordering new hardware. Servers may now "exist" even when
they're "deleted" from Foreman (moved back into the bare metal pool). Build
a custom plugin that does whatever you want on new server discovery event
etc…

Mikael

··· On 14 Jan 2013 14:05, "Greg Sutcliffe" wrote: > On 14 January 2013 04:53, Roman Shaposhnik wrote:

+1 to this project.

I hate search for a particulary type of baremetal server when I need to
make a install for some project. Also I´m fed up with investigate a
network/software issue and 2 hours later realize than the MAC address was
incorrect on the database because somebody typed it wrong.

··· El sábado, 26 de enero de 2013 10:45:38 UTC+1, Mikael Fridh escribió: > > > On 14 Jan 2013 14:05, "Greg Sutcliffe" <greg.su...@gmail.com > > wrote: > > > > On 14 January 2013 04:53, Roman Shaposhnik <ro...@shaposhnik.org> > wrote: > > > > This sounds pretty interesting, but could you please elaborate > > > how it is different from Foreman owning that said server the minute > > > it appears in the datacenter? You don't have to do anything with > > > it as far configuration is concerned, of course, but other than that > > > it'll be as first class citizen as any other piece of hardware. > > That's just what Greg added to Foreman... Previously servers _did not_ > "appear". The idea is that now they will. > > > (MFridh might weigh in here, this was his idea orginally...) You're > > right, ofc, but if you've just received a lot of hardware, entering > > all of it into Foreman is time-consuming and error-prone - I hate > > typing MACs in manually, and that's made worse if you're relying on > > remote hands to do the racking and send you the MACs. > > +1 Greg! This to me is the one missing thing for bare metal. Now can > automatically check servers off against whatever other inventory system you > may use when ordering new hardware. Servers may now "exist" even when > they're "deleted" from Foreman (moved back into the bare metal pool). Build > a custom plugin that does whatever you want on new server discovery event > etc... > > Mikael >