有2個方法
一、可以修改my.ini 配置參數(shù)(linux下面是 my.cnf);
[quote][client]
port=3306
default-character-set=utf8
host=localhost
user=root
password=1[/quote]
具體的其他參數(shù)都可以在這里修改
二、可以修改環(huán)境變量
MYSQL_HOST 代表主機名
USER 為用戶名
MYSQL_PWD 為密碼
更多的參數(shù)請自行查看mysql的幫助文檔,下面是英文的表格
| Variable | Description |
CXX | The name of your C++ compiler (for running configure ). |
CC | The name of your C compiler (for running configure ). |
CFLAGS | Flags for your C compiler (for running configure ). |
CXXFLAGS | Flags for your C++ compiler (for running configure ). |
DBI_USER | The default user name for Perl DBI. |
DBI_TRACE | Trace options for Perl DBI. |
HOME | The default path for the mysql history file is $HOME/.mysql_history . |
LD_RUN_PATH | Used to specify the location of libmysqlclient.so . |
MYSQL_DEBUG | Debug trace options when debugging. |
MYSQL_GROUP_SUFFIX | Option group suffix value (like specifying --defaults-group-suffix ). |
MYSQL_HISTFILE | The path to the mysql history file. If this variable is set, its value overrides the default for $HOME/.mysql_history . |
MYSQL_HOME | The path to the directory in which the server-specific my.cnf file resides (as of MySQL 5.0.3). |
MYSQL_HOST | The default host name used by the mysql command-line client. |
MYSQL_PS1 | The command prompt to use in the mysql command-line client. |