Creating MySQL Database ERROR!!!... @ mysql>

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Creating MySQL Database ERROR!!!... @ mysql>

Postby Koymack » Fri Jan 05, 2007 3:45 pm

hi... i'm following the SCRATH INSTALL and I'm at: SUBPHASE 6.1... but I'm getting this error after the 'use asterisk;' part...

mysql> create database asterisk;
ERROR 1007: Can't create database 'asterisk'; database exists

mysql> GRANT SELECT,INSERT,UPDATE,DELETE on asterisk.* TO cron@'%' IDENTIFIED BY '1234';
Query OK, 0 rows affected (0.00 sec)


mysql> GRANT SELECT,INSERT,UPDATE,DELETE on asterisk.* TO cron@localhost IDENTIFIED BY '1234';
Query OK, 0 rows affected (0.00 sec)


mysql> UPDATE mysql.user set password=OLD_PASSWORD('1234') where user='cron';
Query OK, 2 rows affected (0.00 sec)
Rows matched: 2 Changed: 2 Warnings: 0


mysql> use asterisk;
Database changed

mysql> \. /usr/src/astguiclient/MySQL_AST_CREATE_tables.sql
ERROR:
Failed to open file '/usr/src/astguiclient/MySQL_AST_CREATE_tables.sql', error: 2

mysql>\. /usr/src/astguiclient/astguiclient/MySQL_AST_CREATE_tables.sql
ERROR:
Failed to open file '/usr/src/astguiclient/astguiclient/MySQL_AST_CREATE_tables.sql', error: 2

mysql> GRANT SELECT on asterisk.phones TO idcheck@'%' IDENTIFIED BY '1234';
ERROR 1146: Table 'asterisk.phones' doesn't exist

mysql> GRANT SELECT on asterisk.phones TO idcheck@localhost IDENTIFIED BY '1234';
ERROR 1146: Table 'asterisk.phones' doesn't exist

mysql> insert into servers (server_id,server_description,server_ip,active,asterisk_version)values('TESTasterisk','Test install of Asterisk server', '192.168.0.3','Y','1.2.14');
ERROR 1146: Table 'asterisk.servers' doesn't exist

mysql> insert into server_updater values('192.168.0.3','');
ERROR 1146: Table 'asterisk.server_updater' doesn't exist

mysql> insert into phones (extension, dialplan_number, voicemail_id, phone_ip, computer_ip, server_ip, login, pass, status, active, phone_type, fullname, company, picture, messages, old_messages, protocol) values('gs102','102','102','10.10.10.16','10.10.9.16','10.10.10.15','gs102','test', 'ADMIN','Y','Grandstream BT 102','Test Admin Phone','TEST','','0','0','SIP');
ERROR 1146: Table 'asterisk.phones' doesn't exist



what's going on here?.... did i miss something?...


In advance:
MANY THANKS for all of your HELP... :D
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby diyanat » Fri Jan 05, 2007 4:23 pm

don't go to next steps if u get errors, do the install step by step

either the file MySQL_AST_CREATE_tables.sql is not in the path you are giving or u dont have permisions to read the file

check the location of the file, depending on where u unzipped and installed your astguiclient*.zip

the following command should show u the path of the file

locate MySQL_AST_CREATE_tables.sql

if your slocate database is old give the command 'updatedb' first




Diyanat
diyanat
 
Posts: 30
Joined: Fri Dec 22, 2006 3:45 pm
Location: Hyderabad - India

Postby Koymack » Sun Jan 07, 2007 1:54 pm

Thanks 4 the info.. I have seem 2 complete the installation.. But why am i getting a page not found wen i try to acces the vcdial admin page? How do i troubleshoot?
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby diyanat » Sun Jan 07, 2007 4:39 pm

1) is your httpd service running?
2) have u installed astguiclient in the correct web folder accessible over http
3) if you are running a firewall have you opened port 80

Diyanat
diyanat
 
Posts: 30
Joined: Fri Dec 22, 2006 3:45 pm
Location: Hyderabad - India

Postby Koymack » Mon Jan 08, 2007 11:19 am

Thanks again.. Im new 2 Linux and CentOS.. How do i check httpd or mysql?.. I do have a firewall w CenOs how do i check the port?..
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby ramindia » Mon Jan 08, 2007 12:21 pm

Hi

if you are running centos

you can check the status

/etc/rc.d/init.d/httpd status
/etc/rc.d/init.d/mysqld status

try to flush the iptables and see if that works

iptables -F

ram
ramindia
 
Posts: 688
Joined: Wed Oct 11, 2006 4:06 am
Location: India

Postby Koymack » Tue Jan 09, 2007 3:29 am

thanks again for your assistance... i was able to finish the whole installation and was able to acces the ADMIN page and i thanks you for all your support...

but when i turned the server off and reboot the next day the admin page (http://192.168.0.3/vicidial/admin.php) says PAGE NOT FOUND.... i checked 192.168.0.3 and apache is running...


is this normal?... how do you turn it on again?...

after reboot what else should i turn on so that VICIDIAL and ASTERISK runs properly?...
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby ramindia » Tue Jan 09, 2007 11:34 am

if you have followed the scratch_install
it has all the information what files to add to /etc/rc.local

if not run "ntsysv"

and select these services to run at boot time.

httpd
mysqld

other related to services

then reboot and see,
ram
ramindia
 
Posts: 688
Joined: Wed Oct 11, 2006 4:06 am
Location: India

Postby Koymack » Fri Jan 12, 2007 9:19 pm

hi... i think i am really finished with my installation... but i have some questions:

why can't i make any calls outside?... i edited my sip.conf according to my VoIP provider(Telasip) but still can't dial out... on my Asterisk debug I'm getting this:

*CLI> sip show peers
Name/username Host Dyn Nat ACL Port Status
spa2001/spa2001 (Unspecified) D 0 UNKNOWN
spa2000/spa2000 (Unspecified) D 0 UNKNOWN
gs102/gs102 192.168.0.12 D 5060 OK (4 ms)
telasip-gw/oc3net 4.79.19.56 N 5060 OK (293 ms)
4 sip peers [2 online , 2 offline]
-- Executing Congestion("SIP/gs102-08198fc0", "") in new stack
== Spawn extension (from-sip, 8004391248, 1) exited non-zero on 'SIP/gs102-08198fc0'

-- Executing Congestion("SIP/gs102-081a0468", "") in new stack
== Spawn extension (from-sip, 8004391248, 1) exited non-zero on 'SIP/gs102-081a0468'

*CLI>

.
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby ramindia » Sat Jan 13, 2007 1:08 am

Hi


First step you need to test the call
directly with out using vicidial

from your hard phone or soft Phone try to make a call
and see, if that works, you can go further and start testing in Vici

if you are not able to make calls using Soft or hard Phones

then check the configuration of sip register
and extension.conf dial methods, and configure how your provider accept the calls,


ram
ramindia
 
Posts: 688
Joined: Wed Oct 11, 2006 4:06 am
Location: India

Postby Koymack » Wed Jan 17, 2007 1:39 pm

hi RAM... pardon me for my late reply i was busy and all...

I know am able to make the call using the GRAND STREAM phone that i am using with the ASTERISK SERVER... quality is good... but when i try to dial MANUALLY under http://192.168.0.3/agc/astguiclient.php# nothing happens... how do i know that my VCDIAL is dialling out?....
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby ramindia » Thu Jan 18, 2007 1:34 am

Hi

check in asterisk console out put by enabling debug of the call

ram
ramindia
 
Posts: 688
Joined: Wed Oct 11, 2006 4:06 am
Location: India

Postby Koymack » Thu Jan 18, 2007 8:36 pm

hi... these are the logs i got:

First i dialed through the GRANDSTREAM... after that i used manual dial from the http://192.168.0.3/agc/astguiclient.php#(WEB CLIENT) and got the "Got SIP response 503..."

*CLI> -- Executing Dial("SIP/gs102-0a12cb08", "SIP/telasip-gw/8004391248||r") in new stack
-- Called telasip-gw/8004391248
== Spawn extension (from-internal, 8004391248, 1) exited non-zero on 'SIP/gs102-0a12cb08'
-- Got SIP response 503 "Service Unavailable" back from 4.79.19.56
Koymack
 
Posts: 21
Joined: Mon Dec 18, 2006 8:18 pm

Postby vctor » Tue Jan 23, 2007 3:34 am

You need to check if you are registering with your provider and configurations are correct
vctor
 
Posts: 49
Joined: Tue Jun 13, 2006 9:32 pm


Return to Support

Who is online

Users browsing this forum: No registered users and 90 guests