[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[augeas-devel] logrotate and prerotate/postrotate



Hello,

I'm having trouble understanding how I'm supposed to declare/modify
postrotate statements using augeas on logrotate files.

test_logrotate.aug works fine, but the following fails:

augtool> get /files/etc/logrotate.d/snmpd/rule/postrotate
/files/etc/logrotate.d/snmpd/rule/postrotate =         /sbin/service snmpd condrestart 2> /dev/null > /dev/null || true

augtool> set /files/etc/logrotate.d/snmpd/rule/postrotate foobar
augtool> save
Saving failed
augtool> get /augeas/files/etc/logrotate.d/snmpd/error/message
/augeas/files/etc/logrotate.d/snmpd/error/message = Value 'foobar' does not match regexp /(([    ][      ]*e|e)ndscript[         ][      ]*[^   
 ].*
|([      ][      ]*e|e)ndscript[^
 ].*
|([      ][      ]*e|e)ndscrip([^
t].*
|
)|([     ][      ]*e|e)ndscri([^
p].*
|
)|([     ][      ]*e|e)ndscr([^
i].*
|
)|([     ][      ]*e|e)ndsc([^
r].*
|
)|([     ][      ]*e|e)nds([^
c].*
|
)|([     ][      ]*e|e)nd([^
s].*
|
)|([     ][      ]*e|e)n([^
d].*
|
)|([     ][      ]*e|e)([^
n].*
|
)|[      ][      ]*([^  
 e].*
|
)|[^
 e].*
|
)*/ in store lens


Any idea ?

Thanks !
Marc



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]