Bug 979296 - Save the value of "Logrotate Max Log Size" into file "/etc/logrotate.d/ovirt-node" failed
Summary: Save the value of "Logrotate Max Log Size" into file "/etc/logrotate.d/ovirt-...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: oVirt
Classification: Retired
Component: ovirt-node
Version: unspecified
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 3.4.1
Assignee: Fabian Deutsch
QA Contact: bugs@ovirt.org
URL:
Whiteboard: node
Depends On:
Blocks: 1023452 1023456
TreeView+ depends on / blocked
 
Reported: 2013-06-28 07:53 UTC by haiyang,dong
Modified: 2014-04-30 11:21 UTC (History)
12 users (show)

Fixed In Version:
Clone Of:
: 1023452 1023456 (view as bug list)
Environment:
Last Closed: 2014-04-30 11:21:53 UTC
oVirt Team: ---
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 16223 0 None None None Never

Description haiyang,dong 2013-06-28 07:53:13 UTC
Description of problem:
Enter into Logging page, then set the value of "Logrotate Max Log Size" as "2048",
check that the file "/etc/logrotate.d/ovirt-node"
[root@dhcp-10-202 admin]# cat /etc/logrotate.d/ovirt-node 
/var/log/ovirt*.log{
    rotate 3
    compress
    missingok
    size 1M
    create
}

the size was still "1M", not we set value "2048"

Maybe the root cause happen here:
>>> import ovirtnode.ovirtfunctions as _functions
>>> _functions.augtool("set", "/files/etc/logrotate.d/ovirt-node/rule/size", "2048")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/site-packages/ovirtnode/ovirtfunctions.py", line 109, in augtool
  File "/usr/lib/python2.7/site-packages/augeas.py", line 346, in save
IOError: Unable to save to file!
>>> 



Version-Release number of selected component (if applicable):
ovirt-node-iso-3.0.0-0.999.999.20130625144130gitd26f7bf.2621.fc18

How reproducible:
100%


Steps to Reproduce:



Actual results:


Expected results:


Additional info:

Comment 1 Fabian Deutsch 2013-06-28 10:52:01 UTC
Augeas couldn't save the file because the syntax of the configuration file was broken.

The syntax is now updated.
Tested with augtool to see if augeas recognizes the file:
augtool ls /files/etc/logrotate.d/ovirt-node

Comment 2 Sandro Bonazzola 2014-03-04 09:17:05 UTC
This is an automated message.
Re-targeting all non-blocker bugs still open on 3.4.0 to 3.4.1.


Note You need to log in before you can comment on or make changes to this bug.