[Users] tracking down problems adding permanent usrloc record

samuel samu60 at gmail.com
Mon Jan 2 18:34:29 CET 2006


www.google.com is your friend:

         site:mail.iptel.org "error: 400; check if you use aliases"

2006/1/2, Mike Williams <mwilliams at etc1.net>:
> On Monday 02 January 2006 11:11, Juha Heinanen wrote:
> > Mike Williams writes:
> >  > I created the account 11112223333 at mydomain.net to test with, and then I
> >  > attempted to use:
> >  >
> >  > openserctl ul add 11112223333 at etcvoip.net sip:18122228203 at etcvoip.net
> >  >
> >  > but it returned:
> >  >
> >  > error: 400; check if you use aliases in OpenSER
> >  >
> >  > I added the alias_db module to my config, but I still get errors. Any
> >  > advice? Should I add them manually to the location database?
> >
> > i have never used openserctl.  my management application writes
> > permanent contacts directly to location table.  remember to tell via
> > flags field that registration is permanent.
> >
> > -- juha
>
> I modified the openserctl script to give more output:
>
> 400 table (aliases) not found
> error: 400; check if you use aliases in OpenSER
>
> on `openserctl ul add 11112223333 at etcvoip.net sip:18122228203 at etcvoip.net`
>
> I traced this message back to the ul_show_contact function in ul_fifo.c.
> Everything is fine until it gets to line 573, where it calls
> fifo_find_domain, which sets d=0. Then, in line 575, the error message given
> above is returned because d if now false.
>
> static inline void fifo_find_domain(str* _name, udomain_t** _d)
> {
>         dlist_t* ptr;
>
>         ptr = root;
>         while(ptr) {
>                 if ((ptr->name.len == _name->len) &&
>                     !memcmp(ptr->name.s, _name->s, _name->len)) {
>                         break;
>                 }
>                 ptr = ptr->next;
>         }
>
>         if (ptr) {
>                 *_d = ptr->d;
>         } else {
>                 *_d = 0;
>         }
> }
>
> I'm not a C programmer, so I don't really understand what's happening here,
> but it appears to be looping through a list to find a domain, checking to be
> sure their lengths and values match. It keeps looping until it finds one, and
> then quits on the first one. It appears that ptr doesn't point to anything in
> my case; it fails the next if, setting the passed-by-reference d to 0,
> leading me to think that it hasn't found any domains, or couldn't get a
> domain list in the beginning. What does this "ptr = root;" mean?
>
> I then tried running `openserctl domain show`, only to get:
>
> 500 command 'domain_dump' not available
>
> Now, I checked the actual database openser.domain table, and my domain
> appeared correctly. I am also loading the domain module on openser startup.
>
> Any ideas? I realize this is getting awfully deep into code, but I hope
> someone can help. It's probably a simple error on my part. Thanks in advance.
>
> Mike Williams
>
> _______________________________________________
> Users mailing list
> Users at openser.org
> http://openser.org/cgi-bin/mailman/listinfo/users
>




More information about the Users mailing list