Cannot connect to MySQL through the command line

Questions regaring MySQL and PHP may go here
Forum rules
Please note the disclaimer before modifying your Synology Product.
mariachimike
I'm New!
I'm New!
Posts: 2
Joined: Sun Jan 10, 2010 5:51 am

Cannot connect to MySQL through the command line

Postby mariachimike » Sun Jan 10, 2010 5:56 am

Hi,

I've enabled PHP and MySQL through the Web Station and have verified that Apache and PHP are working properly.
In fact, phpMyAdmin is working alright and seems to be connecting the MySQL server correctly.

However, I need to import a database through the command line (contains stored procedures) but when I login to my Synology through SSH, it can't find mysql.

Code: Select all

NAS> ./mysql -u root -p
-ash: ./mysql: not found


I'm logged in as root, so it can't be a permissions issue. Can anybody tell me where I've gone wrong?

El Mariachi
User avatar
HarryPotter
Honorary Moderator
Honorary Moderator
Posts: 16394
Joined: Mon Oct 23, 2006 12:48 pm
Location: Switzerland

Re: Cannot connect to MySQL through the command line

Postby HarryPotter » Sun Jan 10, 2010 12:30 pm

Wrong path:

Code: Select all

 /usr/syno/mysql/bin/mysql -u root -p
*Please do not Private Message me for support questions; leave it on the forum so all members can learn. Thanks!*

DS415+ / DSM 6.0-7274 / 2 x HD204UI (RAID0)
DS713+ / DSM 6.0-7274 / HD501LJ + HD502IJ (RAID0)
DS712+ / DSM 6.0-7274 / HD154UI + ST31000340AS (RAID0)

2 Squeezebox 3 + Boom

APC Smart UPS SUA750i
mariachimike
I'm New!
I'm New!
Posts: 2
Joined: Sun Jan 10, 2010 5:51 am

Re: Cannot connect to MySQL through the command line

Postby mariachimike » Sun Jan 10, 2010 2:53 pm

Thanks, it works!
mvalent
Novice
Novice
Posts: 41
Joined: Tue Nov 14, 2006 2:48 am

Re: Cannot connect to MySQL through the command line

Postby mvalent » Thu Mar 24, 2011 6:35 pm

I have the DS410 and I don't find mysql in "/usr/syno/mysql/bin"...
Any idea where I can find it ?

Return to “MySQL/PHP Mods”

Who is online

Users browsing this forum: No registered users and 1 guest