[ovs-dev] [PATCH] ovs-bugtool: Ability to collect number of logs through plugins.

Shih-Hao Li shihli at nicira.com
Mon Feb 25 23:09:08 UTC 2013


Sorry for the late reply.
I was wondering is it easy to add a new tag in addition to "type", such as

   <files type="logs" max_rotation=10>
      /var/log/one
   </files>

So users can set the max number of rotations to collect (default 20)
for different logs file.

thanks
Shih-Hao

On Mon, Feb 25, 2013 at 1:28 PM, Gurucharan Shetty <shettyg at nicira.com>wrote:

> On Mon, Feb 25, 2013 at 1:01 PM, Ben Pfaff <blp at nicira.com> wrote:
> > On Mon, Feb 25, 2013 at 12:58:00PM -0800, Gurucharan Shetty wrote:
> >> On Mon, Feb 25, 2013 at 10:20 AM, Ben Pfaff <blp at nicira.com> wrote:
> >> > On Thu, Feb 21, 2013 at 09:21:06AM -0800, Gurucharan Shetty wrote:
> >> >> A new option "--log-days" recently added lets us to control the
> >> >> number of rotated logs included in the debug bundle. This option
> >> >> only works on log files defined inside the ovs-bugtool code.
> >> >>
> >> >> This patch lets us to do the same with logs collected through
> plugins.
> >> >>
> >> >> The example format inside a plugin is:
> >> >> <files type="logs">
> >> >>     /var/log/one
> >> >> </files>
> >> >>
> >> >> This will collect one, one.[1-x], one.[1-x].gz. Where 'x' is 20
> >> >> by default and can be controlled by the option '--log-days' passed
> >> >> to ovs-bugtool.
> >> >>
> >> >> Signed-off-by: Gurucharan Shetty <gshetty at nicira.com>
> >> >
> >> > I am a little worried about this because it means that we will get
> >> > different behavior when we install a given plugin for use by
> >> > ovs-bugtool or for use by xen-bugtool.  So far, we've been able to use
> >> > the same plugins for both.  Do you have any thoughts about that?
> >>
> >> A capability like this seems useful on non-xenserver platforms.  But I
> see
> >> how this can create a Xen debug bundle (through xen-bugtool) with less
> >> number of logs than expected. One can leave this to the discretion of
> the
> >> plugin writer (that uses this to collect logs not found or not
> >> required in xenserver).
> >> Do you have any ideas for a cleaner solution here?
> >
> > I don't have any great ideas.
> >
> > Let's go ahead and push it.  I guess we can always ask for an
> > ovs-bugtool if the xen-bugtool isn't good enough.
>
> Thanks, I pushed this to master.
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openvswitch.org/pipermail/ovs-dev/attachments/20130225/4b1a9b2a/attachment-0003.html>


More information about the dev mailing list