Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v5.0.3: "kamctl domain show" not showing all domains #1251

Closed
00Asgaroth00 opened this issue Sep 27, 2017 · 4 comments
Closed

v5.0.3: "kamctl domain show" not showing all domains #1251

00Asgaroth00 opened this issue Sep 27, 2017 · 4 comments

Comments

@00Asgaroth00
Copy link

00Asgaroth00 commented Sep 27, 2017

Description

Using the DBTEXT database engine I add a couple domains to the table, issue a reload and then attempt to list the domains loaded. The output of the listing only shows the 1st entry in the domain table, however, testing with a sip client, I can confirm that all domains are actually loaded, it appears that the listing of the domains is what is at fault here.

domain data:

# cat domain
id(int,auto) domain(string) did(string,null) last_modified(int)
1:testing.one.two:1:1506437399
2:testing.one.three:2:1506437399
3:testing.two.one:3:1506437399
4:testing.two.two:3:1506437399

domain showdb

# kamctl domain showdb
[1, 'testing.one.two', '1', 1506437399]
[2, 'testing.one.three', '2', 1506437399]
[3, 'testing.two.one', '3', 1506437399]
[4, 'testing.two.two', '3', 1506437399]

domain show

# kamctl domain show  
{
  "jsonrpc":  "2.0",
  "result": {
    "domain": "testing.one.two",
    "did":  "1"
  },
  "id": 32341
}

If I add some domain attributes the output is different again, domain data is the same as above with the addition of some domain attributes.

domain_attrs:

# cat domain_attrs
id(int,auto) did(string) name(string) type(int) value(string) last_modified(int)
1:1:test_name:2:test_value:1506535015

domain show:

# kamctl domain show
{
  "jsonrpc":  "2.0",
  "result": {
    "did":  "1",
    "attr": "test_name"
  },
  "id": 32468
}

I'm using the following version of kamailio, compiled from the kamailio v5.0.3 sourc code.

kamailio version:

# kamailio -V
version: kamailio 5.0.3 (x86_64/linux) 
flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: unknown 
compiled on 17:43:41 Sep 15 2017 with gcc 4.8.5

Running onCentOS 7:

# uname -a
Linux klb01.home.ie 3.10.0-693.2.2.el7.x86_64 #1 SMP Tue Sep 12 22:26:13 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

Any thoughts?

@miconda
Copy link
Member

miconda commented Sep 29, 2017

Can you try with latest branch 5.0? I just pushed a patch for it, the format for rpc result in this was not valid.

@00Asgaroth00
Copy link
Author

okay, thanks, i will report back once i have it built and tested.

@00Asgaroth00
Copy link
Author

Hi, I can confirm that the output of domain show now works as expected with your patch. Thank you for taking a look at the issue.

@miconda
Copy link
Member

miconda commented Sep 29, 2017

Thanks for testing!

@miconda miconda closed this as completed Sep 29, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants