[OpenSIPS-Users] Error in opensips.cfg file
Alejandro Mejia Evertsz
amejia at voxdatacomm.com
Thu Aug 31 14:33:48 UTC 2023
Hello Phrathib
It seems you're using some commands used in version 2.
You may need to look for the correct syntax to use them on version 3.
There is a document on the website that explains migrating from 2 to 3.
https://www.opensips.org/Documentation/Migration-2-4-0-to-3-0-0
Hope it helps
On Wed, Aug 30, 2023, 11:17 PM Prathibha B <prathibhab.tvm at gmail.com> wrote:
> Aug 31 04:14:49 [339966] CRITICAL:Traceback (last included file at the
> bottom):
> Aug 31 04:14:49 [339966] CRITICAL: 0. //etc/opensips/opensips.cfg
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:12-14: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:
> Aug 31 04:14:49 [339966] CRITICAL: # check if the clients are using
> WebSockets or WebSocketSecure
> Aug 31 04:14:49 [339966] CRITICAL: if (proto == "WS" || proto ==
> "WSS")
> Aug 31 04:14:49 [339966] CRITICAL: ^~~
> Aug 31 04:14:49 [339966] CRITICAL: setflag(SRC_WS);
> Aug 31 04:14:49 [339966] CRITICAL:
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:12-14: bare word <proto> found, command
> calls need '()'
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:12-14: bad command!)
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:16-17: bad command!)
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:18-20: bad command!)
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:27-29: bare word <proto> found, command
> calls need '()'
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:27-29: bad command: missing ';'?
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:31-32: bad command!)
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:183:32-33: bad command!)
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:184:17-18: bad arguments for command <setflag>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:193:17-23: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:193:23-24: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:194:13-19: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:194:19-20: bad arguments for command <setbflag>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:239:16-22: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:239:22-23: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:239:38-44: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:239:44-45: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:241:21-27: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:241:27-28: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:241:44-50: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:241:50-51: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:243:22-28: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:243:28-29: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:243:44-50: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:243:50-51: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:245:22-28: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:245:28-29: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:245:45-51: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:245:51-52: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:257:16-22: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:257:22-23: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:257:38-44: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:257:44-45: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:259:21-27: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:259:27-28: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:259:44-50: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:259:50-51: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:261:22-28: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:261:28-29: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:261:44-50: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:261:50-51: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:263:22-28: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:263:28-29: bad arguments for command <isflagset>
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:263:45-51: syntax error
> Aug 31 04:14:49 [339966] CRITICAL:core:yyerror: parse error in
> //etc/opensips/opensips.cfg:263:51-52: bad arguments for command
> <isbflagset>
> Aug 31 04:14:49 [339966] ERROR:core:parse_opensips_cfg: bad config file
> (46 errors)
> Aug 31 04:14:49 [339966] ERROR:core:main: failed to parse config file
> (null)
> Aug 31 04:14:49 [339966] NOTICE:core:main: Exiting....
>
> On Thu, 31 Aug 2023 at 10:04, Prathibha B <prathibhab.tvm at gmail.com>
> wrote:
>
>> bare word <proto> found, command calls need '()'
>>
>> On Mon, 21 Aug 2023 at 13:34, Prathibha B <prathibhab.tvm at gmail.com>
>> wrote:
>>
>>> if(proto === WSS)
>>>
>>> On Mon, 21 Aug 2023 at 13:33, Prathibha B <prathibhab.tvm at gmail.com>
>>> wrote:
>>>
>>>> Aug 21 08:02:24 [210480] CRITICAL:Traceback (last included file at the
>>>> bottom):
>>>> Aug 21 08:02:24 [210480] CRITICAL: 0. //etc/opensips/opensips.cfg
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:250:16-18: syntax error
>>>> Aug 21 08:02:24 [210480] CRITICAL: if (is_method("REGISTER"))
>>>> Aug 21 08:02:24 [210480] CRITICAL: {
>>>> Aug 21 08:02:24 [210480] CRITICAL: if(proto_wss == WSS) {
>>>> Aug 21 08:02:24 [210480] CRITICAL: ^~~
>>>> Aug 21 08:02:24 [210480] CRITICAL:
>>>> fix_nated_register();
>>>> Aug 21 08:02:24 [210480] CRITICAL: }
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:250:16-18: bare word <proto_wss> found, command
>>>> calls need '()'
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:250:16-18: bad command!)
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:250:22-23: bare word <WSS> found, command calls
>>>> need '()'
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:250:22-23: bad command: missing ';'?
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:250:24-25: bad command!)
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:256:3-5: syntax error
>>>> Aug 21 08:02:24 [210480] CRITICAL:core:yyerror: parse error in
>>>> //etc/opensips/opensips.cfg:256:3-5:
>>>> Aug 21 08:02:24 [210480] ERROR:core:parse_opensips_cfg: bad config file
>>>> (8 errors)
>>>> Aug 21 08:02:24 [210480] ERROR:core:main: failed to parse config file
>>>> (null)
>>>> Aug 21 08:02:24 [210480] NOTICE:core:main: Exiting....
>>>>
>>>> --
>>>> Regards,
>>>> B.Prathibha
>>>>
>>>
>>>
>>> --
>>> Regards,
>>> B.Prathibha
>>>
>>
>>
>> --
>> Regards,
>> B.Prathibha
>>
>
>
> --
> Regards,
> B.Prathibha
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20230831/7c2b7b59/attachment-0001.html>
More information about the Users
mailing list