Section [SQLConfig]

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

 



 
  I am using 2 GKs and DGK (Directory Gatekeeper) in test the [SQLConfig], and I ´m using in [SQLConfig] the option "NeighborsQuery", but GNUGK don´t known about my  n eighbors and don´t start the call.
 
 If I use tcpdump I saw that the GK only access Postgres when I write in port 7000/TCP  the command "reload", or when I start GK.
 
  Has  the "NeighborsQuery" problem in version 2.2.3-2 (GK)?
 
 I am need to put the neighbors in postgres because I have a lot of GKs in my network, then if I put the neighbors in [RasSrv::Neighbors] is not good, because if I change or add one GK I Would need to change all the   [RasSrv::Neighbors] in configuration file.
 
 What would I need to do?
 
PS: If I don´t use postgres to neighbors configuration, the call don´t start, because I think that new GK version has problema if DGK, LRQ and LCF.
 
 
 I am using these configuration in GK  and Postgres that I will show below:
 
1 - IPs:
GK A IP is 10.10.10.1
GK B IP is 10.10.10.2
DGK  and Postgres IP is 10.10.10.3
 
------------------- DGK ----------------------------------
2 - DGK (IP=10.10.10.3):
[Gatekeeper::Main]
Fourtytwo=42
Name=DGK
 
[RasSrv::Neighbors]
GKA=10.10.10.1;*
GKB=10.10.10.2;*
 
[RasSrv::LRQFeatures]
AlwaysForwardLRQ=1
 
[GKStatus::Auth]
shutdown=forbid
rule=regex
regex=^10\.10\.10\.([0-9])|^127\.0\.0\.1$
 
-------------------- GK A ----------------------------------
 
3 - GK A (IP=10.10.10.1):
[Gatekeeper::Main]
Fourtytwo=42
Name=GKA
TimeToLive=500

[RasSrv::Neighbors]
DGK=10.10.10.3;*

[SQLConfig]
Driver=PostgreSQL
Host=10.10.10.3
Database=postgres
Username=postgres
Password= XXX
NeighborsQuery=SELECT nip,nid,nport,npfxtext,password,dynamicIP FROM neighbor WHERE nip = '%1'

[RoutedMode]
GKRouted=1
AcceptUnregisteredCalls=0
H245Routed=1

[GKStatus::Auth]
shutdown=forbid
rule=regex
regex=^(10\.10\.10\.1)|(127\.0\.0\.1)$

[Proxy]
Enable=1
RTPPortRange=50000-50999

------------------- GK B ---------------------------
 
4 - GK B (IP=10.10.10.2):
[Gatekeeper::Main]
Fourtytwo=42
Name=GKB
TimeToLive=500

[SQLConfig]
Driver=PostgreSQL
Host=10.10.10.3
Database=postgres
Username=postgres
Password= XXX
NeighborsQuery=SELECT nip,nid,nport,npfxtext,password,dynamicip FROM neighbor WHERE nip = '%1'

[RasSrv::Neighbors]
DGK=10.10.10.3;*

[RoutedMode]
GKRouted=1
AcceptUnregisteredCalls=0
H245Routed=1

[GKStatus::Auth]
shutdown=forbid
rule=regex
regex=^(10\.10\.10\.2)|(127\.0\.0\.1)$

[Proxy]
Enable=1
RTPPortRange=50000-50999

---------------------- PosgreSQL ------------------------------

 5 - My PosgreSQL (10.10.10.3):

$ psql -U postgres -h localhost -d postgres
Password:  XXX

Welcome to psql 7.4.7, the PostgreSQL interactive terminal.

Type:  \copyright for distribution terms
       \h for help with SQL commands
       \? for help on internal slash commands
       \g or terminate with semicolon to execute query
       \q to quit

postgres=# SELECT * from neighbor ;
nid     |       nip       | nport |   npfxtext  | password | dynamicip
-----+-----------------+-------+----------+----------+-----------
 GKA | 10.10.10.1 |          | 1100        |                    |
 GKB | 10.10.10.2 |          | 1010        |                    |
 DGK | 10.10.10.3 |          | *               |                   |
(3 rows)

 PS: In Postgres (table neighbor) I already used in the npfxtext "*" to GKA and GKB, but the call didn´t start too. 

 


[Index of Archives]     [SIP]     [Open H.323]     [Gnu Gatekeeper]     [Asterisk PBX]     [ISDN Cause Codes]     [Yosemite News]

  Powered by Linux