[Freeswitch-users] Where are table definitions of database for freewsitch (latest GIT version)
king2kin
xing2kin at yahoo.com
Sun Dec 18 14:23:34 MSK 2011
Hi there,
On Dec. 18, 2011, I dowloaded the latest GIT version of freeswitch source codes by
git clone git://git.freeswitch.org/freeswitch.git
Then, I compiled the project solution with vs2008, and run FreeSwitch.exe from command-line on windows 2003. I got a bunch of errors complaining about SQL errors, for example,
{
switch_core_sqldb.c:890 SQL ERR [no such table: sip_registrations]
[delete from sip_registrations where (contact like '%TCP%' or status like '%TCP%' or status like '%TLS%') and hostname='W2k3T602' and network_ip like '%' and network_port like '%' and sip_username like '%' and mwi_user like '%' and mwi_host like '%' and orig_server_host like '%' and orig_hostname like '%']
}
Unlike old version, the new version on windows system seems to require setting up extra database tables according to
log file [freeswitch.log].The log file gave basic definitions (see below) of these SQL tables, however, primary key and/or constraints are NOT provided.
Could anyone tell me where to find the full definition of these SQL tables that are required by the latest GIT version of freeswitch? Thanks in adavance!
==== table definitions gave in freeswitch.log =========================
--
-- table [sip_registrations]
--
CREATE TABLE sip_registrations (
call_id VARCHAR(255),
sip_user VARCHAR(255),
sip_host VARCHAR(255),
presence_hosts VARCHAR(255),
contact VARCHAR(1024),
status VARCHAR(255),
rpid VARCHAR(255),
expires INTEGER,
user_agent VARCHAR(255),
server_user VARCHAR(255),
server_host VARCHAR(255),
profile_name VARCHAR(255),
hostname VARCHAR(255),
network_ip VARCHAR(255),
network_port VARCHAR(6),
sip_username VARCHAR(255),
sip_realm VARCHAR(255),
mwi_user VARCHAR(255),
mwi_host VARCHAR(255),
orig_server_host VARCHAR(255),
orig_hostname VARCHAR(255)
);
--
-- table [sip_subscriptions]
--
CREATE TABLE sip_subscriptions (
proto VARCHAR(255),
sip_user VARCHAR(255),
sip_host VARCHAR(255),
sub_to_user VARCHAR(255),
sub_to_host VARCHAR(255),
presence_hosts VARCHAR(255),
event VARCHAR(255),
contact VARCHAR(1024),
call_id VARCHAR(255),
full_from VARCHAR(255),
full_via VARCHAR(255),
expires INTEGER,
user_agent VARCHAR(255),
accept VARCHAR(255),
profile_name VARCHAR(255),
hostname VARCHAR(255),
network_port VARCHAR(6),
network_ip VARCHAR(255),
version INTEGER DEFAULT 0 NOT NULL,
orig_proto VARCHAR(255),
full_to VARCHAR(255)
);
--
-- table [sip_dialogs]
--
CREATE TABLE sip_dialogs (
call_id VARCHAR(255),
uuid VARCHAR(255),
sip_to_user VARCHAR(255),
sip_to_host VARCHAR(255),
sip_from_user VARCHAR(255),
sip_from_host VARCHAR(255),
contact_user VARCHAR(255),
contact_host VARCHAR(255),
state VARCHAR(255),
direction VARCHAR(255),
user_agent VARCHAR(255),
profile_name VARCHAR(255),
hostname VARCHAR(255),
contact VARCHAR(255),
presence_id VARCHAR(255),
presence_data VARCHAR(255),
call_info VARCHAR(255),
call_info_state VARCHAR(255),
expires INTEGER default 0,
status VARCHAR(255),
rpid VARCHAR(255),
sip_to_tag VARCHAR(255),
sip_from_tag VARCHAR(255),
rcd INTEGER not null default 0
);
--
-- table [sip_presence]
--
CREATE TABLE sip_presence (
sip_user VARCHAR(255),
sip_host VARCHAR(255),
status VARCHAR(255),
rpid VARCHAR(255),
expires INTEGER,
user_agent VARCHAR(255),
profile_name VARCHAR(255),
hostname VARCHAR(255),
network_ip VARCHAR(255),
network_port VARCHAR(6),
open_closed VARCHAR(255)
);
--
-- table [sip_authentication]
--
CREATE TABLE sip_authentication (
nonce VARCHAR(255),
expires INTEGER, profile_name VARCHAR(255),
hostname VARCHAR(255),
last_nc INTEGER
);
--
-- table [sip_shared_appearance_subscriptions]
--
CREATE TABLE sip_shared_appearance_subscriptions (
subscriber VARCHAR(255),
call_id VARCHAR(255),
aor VARCHAR(255),
profile_name VARCHAR(255),
hostname VARCHAR(255),
contact_str VARCHAR(255),
network_ip VARCHAR(255)
);
--
-- table [sip_shared_appearance_dialogs]
--
CREATE TABLE sip_shared_appearance_dialogs (
profile_name VARCHAR(255),
hostname VARCHAR(255),
contact_str VARCHAR(255),
call_id VARCHAR(255),
network_ip VARCHAR(255),
expires INTEGER
);
--
-- table [sip_recovery]
--
CREATE TABLE sip_recovery (
runtime_uuid VARCHAR(255),
profile_name VARCHAR(255),
hostname VARCHAR(255),
uuid VARCHAR(255),
metadata text
);
--
-- table [fifo_outbound]
--
create table fifo_outbound (
uuid varchar(255),
fifo_name varchar(255),
originate_string varchar(255),
simo_count integer,
use_count integer,
timeout integer,
lag integer,
next_avail integer not null default 0,
expires integer not null default 0,
static integer not null default 0,
outbound_call_count integer not null default 0,
outbound_fail_count integer not null default 0,
hostname varchar(255),
taking_calls integer not null default 1,
status varchar(255),
outbound_call_total_count integer not null default 0,
outbound_fail_total_count integer not null default 0,
active_time integer not null default 0,
inactive_time integer not null default 0,
manual_calls_out_count integer not null default 0,
manual_calls_in_count integer not null default 0,
manual_calls_out_total_count integer not null default 0,
manual_calls_in_total_count integer not null default 0,
ring_count integer not null default 0,
start_time integer not null default 0,
stop_time integer not null default 0
);
--
-- table [fifo_bridge]
--
create table fifo_bridge (
fifo_name varchar(1024) not null,
caller_uuid varchar(255) not null,
caller_caller_id_name varchar(255),
caller_caller_id_number varchar(255),
consumer_uuid varchar(255) not null,
consumer_outgoing_uuid varchar(255),
bridge_start integer
);
--
-- table [fifo_callers]
--
create table fifo_callers (
fifo_name varchar(255) not null,
uuid varchar(255) not null,
caller_caller_id_name varchar(255),
caller_caller_id_number varchar(255),
timestamp integer
);
--
-- table [voicemail_msgs]
--
CREATE TABLE voicemail_msgs (
created_epoch INTEGER,
read_epoch INTEGER,
username VARCHAR(255),
domain VARCHAR(255),
uuid VARCHAR(255),
cid_name VARCHAR(255),
cid_number VARCHAR(255),
in_folder VARCHAR(255),
file_path VARCHAR(255),
message_len INTEGER,
flags VARCHAR(255),
read_flags VARCHAR(255),
forwarded_by VARCHAR(255)
);
--
-- table [voicemail_prefs]
--
CREATE TABLE voicemail_prefs (
username VARCHAR(255),
domain VARCHAR(255),
name_path VARCHAR(255),
greeting_path VARCHAR(255),
password VARCHAR(255)
);
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20111218/e6b4f735/attachment-0001.html
Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users
mailing list