[bitbake-devel] [PATCH 1/2] V2 Disk space monitoring

Richard Purdie richard.purdie at linuxfoundation.org
Tue Jan 10 17:51:09 UTC 2012


On Tue, 2012-01-10 at 20:45 +0800, Robert Yang wrote:
> * Problems:
> 
>   1) The disk space monitor is running in a sub process of
>      bin/bitbake, so it can't use the same logger as bitbake(or I don't
>      know how to use it, I've tried to use the logger.warn('some
>      information'), but it would print nothing in the subprocess),
>      another solution maybe use an independent logger in the subprocess,
>      but it seems that it doesn't worth because of the two reasons:
>      a) The logger of bin/bitbake can't control the monitor's
>         independent logger
>      b) The monitor doesn't need print many things
> 
>      It would be great if anyone could give me more instructions.

This is an issue unfortunately since its fine to have the warnings about
low space but its not much use unless bitbake can act on the warnings
somehow (stop executing more tasks for example).

I agree with Chris' comments about being able to specify the warning
threshold per directory being monitored too.

So I think before this can merge its going to need some further work. I
can't give pointers to the right way to send log messages from the
subprocess right at the moment. Perhaps you can insert yourself as an
"idle" task into bitbake's "main loop" instead of running as a
subprocess? This would also make it simpler to stop executing more
tasks. There probably should be a way for the user to choose
"immediately abort, no new tasks, show warning" as the options for
running out of space.

Cheers,

Richard





More information about the bitbake-devel mailing list