[syslog-ng] Config parse error in syslog-ng 2.0.0

Jacek Kalinski jacek_kal at o2.pl
Sun Nov 26 13:15:01 CET 2006


Hi,

I have a config file working fine with syslog-ng-1.6.11.
But the same config won't work with 2.0.0.

Problem (as I've checked, compiling syslog-ng with YYDEBUG) is in:
dir_owner(0); dir_group(0); owner(0); group(0);

2 first lines of config:
options { dir_perm(0700); perm(0600); chain_hostnames(no); stats(1200);
          keep_hostname(yes); dir_owner(0); dir_group(0); owner(0);
group(0); };


Debug from checking syntax:
...
Reducing stack by rule 212 (line 731), KW_STATS_FREQ '(' NUMBER ')' ->
options_item
Stack now 0 4 18 73 156 73 156 73 156
Entering state 73
Reading a token: Next token is token ';' ()
Shifting token ';' ()
Entering state 156
Reading a token: Next token is token KW_KEEP_HOSTNAME ()
Shifting token KW_KEEP_HOSTNAME ()
Entering state 42
Reading a token: Next token is token '(' ()
Shifting token '(' ()
Entering state 125
Reading a token: Next token is token KW_YES ()
Shifting token KW_YES ()
Entering state 206
Reducing stack by rule 271 (line 868), KW_YES -> yesno
Stack now 0 4 18 73 156 73 156 73 156 73 156 42 125
Entering state 211
Reading a token: Next token is token ')' ()
Shifting token ')' ()
Entering state 308
Reducing stack by rule 217 (line 736), KW_KEEP_HOSTNAME '(' yesno ')' ->
options_item
Stack now 0 4 18 73 156 73 156 73 156 73 156
Entering state 73
Reading a token: Next token is token ';' ()
Shifting token ';' ()
Entering state 156
Reading a token: Next token is token KW_DIR_OWNER ()
Shifting token KW_DIR_OWNER ()
Entering state 66
Reading a token: Next token is token '(' ()
Shifting token '(' ()
Entering state 149
Reading a token: Next token is token NUMBER ()
syntax error at 2
Error: popping token '(' ()
Stack now 0 4 18 73 156 73 156 73 156 73 156 73 156 66
Error: popping token KW_DIR_OWNER ()
Stack now 0 4 18 73 156 73 156 73 156 73 156 73 156
Error: popping token ';' ()
Stack now 0 4 18 73 156 73 156 73 156 73 156 73
Error: popping nterm options_item ()
Stack now 0 4 18 73 156 73 156 73 156 73 156
Error: popping token ';' ()
Stack now 0 4 18 73 156 73 156 73 156 73
Error: popping nterm options_item ()
Stack now 0 4 18 73 156 73 156 73 156
Error: popping token ';' ()
Stack now 0 4 18 73 156 73 156 73
Error: popping nterm options_item ()
Stack now 0 4 18 73 156 73 156
Error: popping token ';' ()
Stack now 0 4 18 73 156 73
Error: popping nterm options_item ()
Stack now 0 4 18 73 156
Error: popping token ';' ()
Stack now 0 4 18 73
Error: popping nterm options_item ()
Stack now 0 4 18
Error: popping token '{' ()
Stack now 0 4
Error: popping token KW_OPTIONS ()
Stack now 0
Cleanup: discarding lookahead token NUMBER ()


When I change 'dir_owner' to:
dir_owner(root)
next error found is on 'dir_group':

Reading a token: Next token is token KW_DIR_GROUP ()
Shifting token KW_DIR_GROUP ()
Entering state 67
Reading a token: Next token is token '(' ()
Shifting token '(' ()
Entering state 150
Reading a token: Next token is token NUMBER ()
syntax error at 2


BUT manual, says:
       dir_owner(uid)
              User id.
documantecion says:
â                       â            â              âThe default owner
of     â
âdir_owner()            âuserid      âroot          ânewly
created            â
â                       â            â             
âdirectories.             â

The same problem with: owner and group options (so all options working
with UID/GID).

Is it an error in my configuration, or in docs? :)
Is it possible to keep compatibility with syslog-1.6 (so use UID/GID
instead of username)?

Jacek

-- 
Wortal chelloPL: http://chellopl.one.pl
Forum dyskusyjne: http://chellopl.one.pl/forum/
Bramka news: http://chellopl.one.pl/bramka/
i inne - sprawdź sam!




More information about the syslog-ng mailing list