Mailing List Archive

Some good words for Gentoo embedded?
Hi,
I'm using Gentoo for few years now, and had some experience in the past with
Gentoo embedded.
Now I'm facing a customer that wants explanation why using Gentoo as an
embedded system will be a good choice.
How do you shrink a 10 years experience to half an hour talk to people that
think Ubuntu is a good embedded choice.
I'm guessing they will ask for type of distros for embedded compared to
Gentoo.
From my head I know just by name Buildroot and Montavista.

What will be the major points I need to make in order to convert their
minds from Ubuntu to Gentoo embedded?
Could you share also some of your experience with Gentoo Embedded?

Thinking about it, its very hard for me to contemplate in words "Why
Gentoo?" for people that don't understand Linux, but are educated and very
experienced in software.

Thanks in advance for your help,
Kfir
Re: Some good words for Gentoo embedded? [ In reply to ]
Kfir Lavi wrote:
> What will be the major points I need to make in order to convert
> their minds from Ubuntu to Gentoo embedded?

It depends. Maybe Ubuntu would actually be a fine choice for the
customer.


> "Why Gentoo?" for people that don't understand Linux, but are
> educated and very experienced in software.

Key words are configurability (security, size, speed benefits),
repeatability (archive all sources and the build tools to recreate
from scratch forever), being source based (easy to stay close to
upstream, noone else makes arbitrary decisions on versions, easy to
also collect all licensing information), unparalleled simplicity and
power in the packaging system (ebuilds are vamped up sh scripts) and
excellent documentation of the same (pms-3.pdf).

Some of the above are significant advantages for some customers, and
major headaches for others. I would suggest that Gentoo will require
more "positive QA" to determine that the finished system behaves as
desired, while something based on Ubuntu requires more "negative QA"
to check if the Ubuntu system still works even if stripped down.

Gentoo also requires being able to make decisions. This means having
an ear to the upstream tracks. For someone who is not interested in
this it is much more comfortable to rely on Canonical's ears to the
tracks, albeit that means giving up much choice.

This is the selling point as a consultant - if you are skilled and
experienced with the open source community, perhaps even a
contributor in one or more projects, then you have a strong case as
being an open source expert.

If that also means that you are experienced enough to appreciate the
versatility of Gentoo, and able to compare it with the Ubuntu way,
then it should be easy to motivate your preference of Gentoo.

Of course, maybe your customer does not want to become, or depend on,
an open source expert - which may still be valid - in which case I
would advise against Gentoo, but in fact also Linux at all.

If they are business people rather than software people then you
could motivate Gentoo with the fact that it allows you to accomplish
virtually any configuration and extension they would like to have in
the future very efficiently, while Ubuntu is generally restricted to
one particular way of doing things.

(And of course Ubuntu above can be replaced with any other binary
distribution.)


//Peter
Re: Some good words for Gentoo embedded? [ In reply to ]
well, the programs installed really aren't going to be all that
different regardless of which distribution is installed. the biggest
differences are probably in the management of the system configuration
and the ease of doing package management.

i use gentoo on my embedded because i find it incredibly easier to get a
working toolchain, build a $root filesystem, and copy it to something
like flash and i'm all set. that's disregarding the fact that i think
gentoo's system configuration is outlandishly better. particularly when
it comes to networking.
Re: Some good words for Gentoo embedded? [ In reply to ]
On 09/12/2010 20:18, Kfir Lavi wrote:
> Hi,
> I'm using Gentoo for few years now, and had some experience in the
> past with Gentoo embedded.
> Now I'm facing a customer that wants explanation why using Gentoo as
> an embedded system will be a good choice.
> How do you shrink a 10 years experience to half an hour talk to people
> that think Ubuntu is a good embedded choice.
> I'm guessing they will ask for type of distros for embedded compared
> to Gentoo.
> From my head I know just by name Buildroot and Montavista.
>
> What will be the major points I need to make in order to convert
> their minds from Ubuntu to Gentoo embedded?
> Could you share also some of your experience with Gentoo Embedded?
>
> Thinking about it, its very hard for me to contemplate in words "Why
> Gentoo?" for people that don't understand Linux, but are educated and
> very experienced in software.

I do get the impression that when people start talking about "distros"
they usually loose sight that they are all 98% the same software, only
slightly different versions and perhaps slightly different config
files... Now for sure that can make a visible difference, especially the
default configs for desktop apps, but one way or another, the question
is really about the "best" way to get a bunch of software compiled and
installed on your device?

I like gentoo for situations where:
- Skilled developer available
- Customisable solution is desired
- Tightly controlled deployment environment
- Repeatable build environment required

I think gentoo is far less acceptable if there isn't a skilled developer
available to help maintain and develop it... Probably that's my main
suggestion on how to size your project?

However, if that developer/administrator is available, then Gentoo is a
marvellous solution for quickly building few MB custom solution, or a
60MB virtual server base installation, or whatever other customised
environment you desire?

Good luck

Ed W
Re: Some good words for Gentoo embedded? [ In reply to ]
Ed W wrote:
>> "Why Gentoo?"
>
> I like gentoo for situations where:
> - Skilled developer available
> - Customisable solution is desired
> - Tightly controlled deployment environment
> - Repeatable build environment required
>
> I think gentoo is far less acceptable if there isn't a skilled developer
> available to help maintain and develop it... Probably that's my main
> suggestion on how to size your project?
>
> However, if that developer/administrator is available, then Gentoo is a
> marvellous solution for quickly building few MB custom solution, or a 60MB
> virtual server base installation, or whatever other customised environment
> you desire?

This is very perceptive, and excellent advice!

I believe firmly in "owning the problem" and for that, Gentoo is a
very good fit. I know many who fiercly resist owning any problem
whatsoever, and they do fine anyway (even better than me) and for
them obviously Gentoo is not at all a goo fit because they would have
to make lots of decisions they do not want to.

Abstracting a little; the more requirements there are, the more
likely it is that without Gentoo, it would be neccessary to start
re-inventing various bits and pieces that Gentoo already offer.

Sometimes requirements come only later, when a production process has
already been established, and can not comfortably be replaced. That's
a bad situation to be in. It will be painful no matter what, but
often people choose the lengthy pain that means sticking with the old
"distribution" living with a less-than-useful environment and
reinventing tools and processes, instead of ripping off the band-aid
and making a switch to Gentoo or something else that fits the
project.


//Peter
Re: Some good words for Gentoo embedded? [ In reply to ]
On Tue, Dec 21, 2010 at 6:20 PM, Peter Stuge <peter@stuge.se> wrote:

> Ed W wrote:
> >> "Why Gentoo?"
> >
> > I like gentoo for situations where:
> > - Skilled developer available
> > - Customisable solution is desired
> > - Tightly controlled deployment environment
> > - Repeatable build environment required
> >
> > I think gentoo is far less acceptable if there isn't a skilled developer
> > available to help maintain and develop it... Probably that's my main
> > suggestion on how to size your project?
> >
> > However, if that developer/administrator is available, then Gentoo is a
> > marvellous solution for quickly building few MB custom solution, or a
> 60MB
> > virtual server base installation, or whatever other customised
> environment
> > you desire?
>
> This is very perceptive, and excellent advice!
>
> I believe firmly in "owning the problem" and for that, Gentoo is a
> very good fit. I know many who fiercly resist owning any problem
> whatsoever, and they do fine anyway (even better than me) and for
> them obviously Gentoo is not at all a goo fit because they would have
> to make lots of decisions they do not want to.
>
> Abstracting a little; the more requirements there are, the more
> likely it is that without Gentoo, it would be neccessary to start
> re-inventing various bits and pieces that Gentoo already offer.
>
> Sometimes requirements come only later, when a production process has
> already been established, and can not comfortably be replaced. That's
> a bad situation to be in. It will be painful no matter what, but
> often people choose the lengthy pain that means sticking with the old
> "distribution" living with a less-than-useful environment and
> reinventing tools and processes, instead of ripping off the band-aid
> and making a switch to Gentoo or something else that fits the
> project.
>
>
> //Peter
>
> Well, switching to Gentoo, is really not probable.
People don't understand Linux, and if they do, usually they know the big
distros.
If they search for embedded distro, Gentoo will not be on the list.
You need to come from Gentoo to understand it's capabilities.
If I start to roll an embedded environment with Gentoo, this will lit
some developers to check the system, because they need to use it.
It seems that when time goes by, and we grow older, we are reluctant to
do the change. Thats includes me too ;-) I have hard time letting Gentoo
off :-)

Regards,
Kfir
Re: virtual server profile [ In reply to ]
On 12/21/10 16:58, Ed W wrote:
> However, if that developer/administrator is available, then Gentoo is a
> marvellous solution for quickly building few MB custom solution, or a 60MB
> virtual server base installation, or whatever other customised environment you
> desire?

Do you have such a setup for virtual server or, maybe, openvpz/vserver? ie.
profile/make.conf/install masks/whatever ready for public consumption you can share?
Re: Some good words for Gentoo embedded? [ In reply to ]
* David Ford <david@blue-labs.org> schrieb:

> i use gentoo on my embedded because i find it incredibly easier to get a
> working toolchain, build a $root filesystem, and copy it to something
> like flash and i'm all set. that's disregarding the fact that i think
> gentoo's system configuration is outlandishly better. particularly when
> it comes to networking.

The drawback of it (and similar systems which originate from mainline
distros) is that they're limited to relatively "large" devices and
tend to be challenged by the fact that the toolsets originally hadn't
be designed for that purpose. On the other hand, they heavily benefit
from the large amount of already ported packages.


cu
--
----------------------------------------------------------------------
Enrico Weigelt, metux IT service -- http://www.metux.de/

phone: +49 36207 519931 email: weigelt@metux.de
mobile: +49 151 27565287 icq: 210169427 skype: nekrad666
----------------------------------------------------------------------
Embedded-Linux / Portierung / Opensource-QM / Verteilte Systeme
----------------------------------------------------------------------
Re: Some good words for Gentoo embedded? [ In reply to ]
Enrico Weigelt wrote:
> > i use gentoo on my embedded because i find it incredibly easier to
> > get a working toolchain, build a $root filesystem, and copy it to
> > something like flash and i'm all set.
..
> The drawback of it (and similar systems which originate from mainline
> distros) is that they're limited to relatively "large" devices

Hm? Define "large" ? Does the definition include anything capable of
having a root filesystem?


> and tend to be challenged by the fact that the toolsets originally
> hadn't be designed for that purpose.

Bare metal? Certainly. We know this fact very well in coreboot, for
example. But also other projects designed to run on bare metal (such
as open source ARM projects) will know this well.


> On the other hand, they heavily benefit from the large amount of
> already ported packages.

The bare-metal projects not so much. They only need a single package,
and I think something like portage is way overkill..


//Peter
Re: Some good words for Gentoo embedded? [ In reply to ]
* Peter Stuge <peter@stuge.se> schrieb:

> > The drawback of it (and similar systems which originate from mainline
> > distros) is that they're limited to relatively "large" devices
>
> Hm? Define "large" ? Does the definition include anything capable of
> having a root filesystem?

Well, something larger than several tens of megabytes.
(To be a bit more precise, we should differenciate betweeen "plain"
embedded and small devices ;-p)

> > and tend to be challenged by the fact that the toolsets originally
> > hadn't be designed for that purpose.
>
> Bare metal? Certainly. We know this fact very well in coreboot, for
> example. But also other projects designed to run on bare metal (such
> as open source ARM projects) will know this well.

I'm more speaking of much more finer granulated build configuration
(esp. feature switching). That's more an issue of invidual ebuilds
and profiles than portage+crossdev.

Some things that seem to be completely missing:

* multiple different targets with equal targettype-tuple at the same time
* minimal sysroots on per-package build (so only dependencies of the
individual package are installed in the sysroot)
* parallel builds (w/ different sysroots instances)
* easy integration of custom postinstall filters/checks
* custom source branches/patches (w/o touching individual ebuilds)


cu
--
----------------------------------------------------------------------
Enrico Weigelt, metux IT service -- http://www.metux.de/

phone: +49 36207 519931 email: weigelt@metux.de
mobile: +49 151 27565287 icq: 210169427 skype: nekrad666
----------------------------------------------------------------------
Embedded-Linux / Portierung / Opensource-QM / Verteilte Systeme
----------------------------------------------------------------------
Re: virtual server profile [ In reply to ]
On 23/12/2010 11:17, Arkadi Shishlov wrote:
> On 12/21/10 16:58, Ed W wrote:
>> However, if that developer/administrator is available, then Gentoo is a
>> marvellous solution for quickly building few MB custom solution, or a 60MB
>> virtual server base installation, or whatever other customised environment you
>> desire?
> Do you have such a setup for virtual server or, maybe, openvpz/vserver? ie.
> profile/make.conf/install masks/whatever ready for public consumption you can share?

Sorry, missed your email

OK, I create

/usr/local/portage/profiles/my-hardened/

this has a file "parent" which contains:
../../../../portage/profiles/hardened/linux/amd64/10.0

Then simply create any overrides for completely global defaults and keywords

I then create various subdirectories:

vserver-host: this holds the generic host config
vserver-guest: this is the base for the various guest configs
(over-rides for all guests go here)

In the vserver-guest I create more directories per vserver type, eg:

vserver-guest/
vserver-guest/proxy
vserver-guest/no-multilib
vserver-guest/www
vserver-guest/www/apache2
vserver-guest/www/nginx
vserver-guest/mysql
vserver-guest/fs
vserver-guest/dns
vserver-guest/glusterfs
vserver-guest/mail


The main thing to remember is that you need a "parent" file containing
".." in each and every directory or else you just failed to inherit from
the top level profile. However, after that just customise what you need
for each guest type!


Oh, further, in my host I have several package directories:
/usr/portage/packages/
/usr/portage/packages/local
/usr/portage/packages/uclibc.host
/usr/portage/packages/uclibc
/usr/portage/packages/guest32
/usr/portage/packages/guest64

The "local" one is for the host and the others are mounted to the
appropriate class of guest. Note this isn't as granular as you desire,
eg the PHP package will normally have different use flags between apache
and nginx guests. However, portage simply uses or rebuilds the php
package as it finds it previously built. This is satisfactory for me.
Mysql is another example where most guests build with "-minimal", but
the servers build the full server. Again handled automatically with a
slight slowdown occasionally


Good luck

Ed W