Description of problem: Very recently VDSM stopped to configure automatically libvirt logs to debug (http://gerrit.ovirt.org/31135) for many good reasons, e.g. to avoid flood logs on node instances. While the reasons for less verbose logs still stand strong, we need a way to easily restore libvirt debug logs, in order to make troubleshooting easy, or at least not harder than before. Since vdsm-tool already manipulates libvirt config, I believe this is the right place to achieve that. I propose new commandline like: vdsm-tool configure --module libvirt --debug on|off with "--debug on" vdsm-tool should enable libvirt debug logs, like it was before 31135. With "--debug off" should make it silent again. Version-Release number of selected component (if applicable): 3.5.0 How reproducible: N/A Steps to Reproduce: 1. N/A 2. 3. Actual results: There is no simple automated way to enable libvirt debug logs Expected results: vdsm-tool should provide such a way Additional info:
its quite complicated, as configure is generic verb and doesn't accept specific flags for specific configure. but we can have separate verb to redirect libvirt log... passing --module libvirt to configure call is quite misleading , as configure libvirt also touch qemu.conf and other related files. we aim to change the name to something more meaningful later on . anyhow, back to the core discussion, the admin only needs to add log_outputs field to /etc/libvirt/libvirtd.conf . do we really need vdsm-tool verb for that or is it reasonable to ask the administrator to do it manually ? ..
(In reply to Yaniv Bronhaim from comment #1) > its quite complicated, as configure is generic verb and doesn't accept > specific flags for specific configure. > but we can have separate verb to redirect libvirt log... Good enough for me > passing --module libvirt to configure call is quite misleading , as > configure libvirt also touch qemu.conf and other related files. we aim to > change the name to something more meaningful later on . Same. We just need an easy and safe way to get these debug logs back. > anyhow, back to the core discussion, the admin only needs to add log_outputs > field to /etc/libvirt/libvirtd.conf . do we really need vdsm-tool verb for > that or is it reasonable to ask the administrator to do it manually ? .. log_output _and_ log_filter, because we want the extra verbosiness back to help debug. Actually, I *do* believe that is easy and practical enough to be done manually, but many people seem to disagree, so I think we should provide a super-easy way at least for the short term.
I like Francesco first idea, we need to pass (all) the parsed args to our different modules. If a module supports an additional parameter he will check for it e.g if args.debug I would aim for both of these to work: vdsm-tool configure --force --debug on|off vdsm-tool configure --force --module libvirt --debug on|off One question I do have is should maybe think about getting this functionality from the new feature to edit vdsm configuration trough engine. Not sure if it's related since i'm not sure what is the scope of that rfe. Yaniv?
Maybe better have those kind of configuration editable as RFE Bug 1115171 intend to do from the engine side. If admin will want to do it locally nothing prevents it. maybe enough to say that and avoid adding it to vdsm-tool. it won't hurt anyhow..
Until we get such request from customers or someone in the field that really needs such option with good and convincing reason, I don't want vdsm to define how libvirt log works at all. libvirt has their defaults and conf file and vdsm shouldn't define that in any case. If you still think differently or heard about actual usecase that requires that please reopen
Well, I see your point. As workaround, I'll put some documentation on the oVirt wiki about how to achieve the same result manually.
(In reply to Yaniv Bronhaim from comment #5) > Until we get such request from customers or someone in the field that really > needs such option with good and convincing reason, I don't want vdsm to > define how libvirt log works at all. > > libvirt has their defaults and conf file and vdsm shouldn't define that in > any case. > If you still think differently or heard about actual usecase that requires > that please reopen note it is a frequent complaint. Not sure, perhaps it should be more prominent on wiki or we indeed need the tool.
Well, I think such an option would really be very helpful. vdsm is already a wrapper for libvirt (at least from my user perspective) so what's bothering you so hard that you do not want such an option? I think the advantages are pretty obvious, do I really need to write them down? I will if you really need it written down, but imho you should know the advantages yourself (quickly enable debug log in case of worst-case scenarios etc.) HTH Sven
(In reply to Francesco Romani from comment #6) > Well, I see your point. > > As workaround, I'll put some documentation on the oVirt wiki about how to > achieve the same result manually. For the record: We settled for http://www.ovirt.org/index.php?title=Vdsm_Log_Files as reference page. Done in http://www.ovirt.org/index.php?title=Vdsm_Log_Files#Libvirt_debug_logs
(In reply to Francesco Romani from comment #9) > (In reply to Francesco Romani from comment #6) > > Well, I see your point. > > > > As workaround, I'll put some documentation on the oVirt wiki about how to > > achieve the same result manually. > > For the record: > We settled for http://www.ovirt.org/index.php?title=Vdsm_Log_Files as > reference page. Done in > http://www.ovirt.org/index.php?title=Vdsm_Log_Files#Libvirt_debug_logs Thanks for the workaround, so it is at least documented somewhere :)