If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > MySQL > why can't use "mysql" command

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-01-08, 12:30
ust3 ust3 is offline
Registered User
 
Join Date: Sep 2008
Posts: 4
why can't use "mysql" command

I have already install the mysql package to the debian includes

libdbd-mysql
libmysqlclient
mysql-client
mysql-common
mysql-server
php4-mysql
webmin-mysql

then I want to run "mysql" command to use as mysql client , but it pops "commond not found" , could advise what package that I should install so that I can run "mysql" ? thx
Reply With Quote
  #2 (permalink)  
Old 09-01-08, 14:08
snorp snorp is offline
Registered User
 
Join Date: Apr 2004
Location: Europe->Sweden->Stockholm
Posts: 71
This might be a distribution-related question. Since MySQL is an "optional" application and not bundled with the Linux distribution (I assume all this because you installed it yourself – I have never used Debian) it will not install to a directory in your PATH. (If you do not know what the PATH environment variable is, take a quick read on some of these pages. Then make sure that you set it correctly.)

For example, if MySQL installs to /usr/local/mysql (as it does on Mac OS X that I am familiar with), you want to add /usr/local/mysql/bin to your path.

For more help, I think that a Debian forum might be more appropriate. Another hint might be to have a look at the MySQL manual, in the section regarding installation on Linux.

Hope this helps!
Reply With Quote
  #3 (permalink)  
Old 09-01-08, 19:37
ust3 ust3 is offline
Registered User
 
Join Date: Sep 2008
Posts: 4
Quote:
Originally Posted by snorp
This might be a distribution-related question. Since MySQL is an "optional" application and not bundled with the Linux distribution (I assume all this because you installed it yourself – I have never used Debian) it will not install to a directory in your PATH. (If you do not know what the PATH environment variable is, take a quick read on some of these pages. Then make sure that you set it correctly.)

For example, if MySQL installs to /usr/local/mysql (as it does on Mac OS X that I am familiar with), you want to add /usr/local/mysql/bin to your path.

For more help, I think that a Debian forum might be more appropriate. Another hint might be to have a look at the MySQL manual, in the section regarding installation on Linux.

Hope this helps!
thx reply,

I tried to use dpkg -S mysql | grep bin to find that the mysql is in /usr/bin , but when I run it , it pop no such file , can advise what is wrong ? thx



#dpkg -S mysql | grep bin

"
mysql-client-4.1: /usr/bin/mysql
mysql-client-4.1: /usr/bin/mysqladmin
"
Reply With Quote
  #4 (permalink)  
Old 09-02-08, 04:38
snorp snorp is offline
Registered User
 
Join Date: Apr 2004
Location: Europe->Sweden->Stockholm
Posts: 71
Well, it seems like you should be able to run /usr/bin/mysql. If you can't, see if you can find help in a Debian forum. This seems to be related to package installation in Debian and I don't think that this is the best place to get help with that.
Reply With Quote
  #5 (permalink)  
Old 09-02-08, 05:07
healdem healdem is offline
Jaded Developer
 
Join Date: Nov 2004
Location: out on a limb
Posts: 9,250
have you checked the error logs to see if there is a problem with the MySQL installation
have you checked to make certain there were no installation problems
__________________
I'd rather be riding my Versys or my Tiger 800 let alone the Norton
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On