当前位置: 技术问答>linux和unix
linux下安装mysql的问题
来源: 互联网 发布时间:2017-03-04
本文导语: 我是刚学linux的新手,在linux安装mysql的时候进行:scripts/mysql_install_db --user=mysql时出现 scripts/mysql_install_db: line 244: ./bin/my_print_defaults: cannot execute binary file Neither host 'localhost.localdomain' nor 'localhost' could be looked...
我是刚学linux的新手,在linux安装mysql的时候进行:scripts/mysql_install_db --user=mysql时出现
scripts/mysql_install_db: line 244: ./bin/my_print_defaults: cannot execute binary file
Neither host 'localhost.localdomain' nor 'localhost' could be looked up with
./bin/resolveip
Please configure the 'hostname' command to return a correct
hostname.
If you want to solve this at a later stage, restart this script
with the --force option
我的hosts已经改成
127.0.0.1 hostname localhost.localdomain localhost了,
然后我强制生成
scripts/mysql_install_db --user=mysql --force
出现问题:
scripts/mysql_install_db: line 244: ./bin/my_print_defaults: cannot execute binary file
Installing MySQL system tables...
scripts/mysql_install_db: line 392: ./bin/mysqld: cannot execute binary file
Installation of system tables failed! Examine the logs in
./data for more information.
You can try to start the mysqld daemon with:
shell> ./bin/mysqld --skip-grant &
and use the command line tool ./bin/mysql
to connect to the mysql database and look at the grant tables:
shell> ./bin/mysql -u root mysql
mysql> show tables
Try 'mysqld --help' if you have problems with paths. Using --log
gives you a log in ./data that may be helpful.
新手求教!谢谢大家
scripts/mysql_install_db: line 244: ./bin/my_print_defaults: cannot execute binary file
Neither host 'localhost.localdomain' nor 'localhost' could be looked up with
./bin/resolveip
Please configure the 'hostname' command to return a correct
hostname.
If you want to solve this at a later stage, restart this script
with the --force option
我的hosts已经改成
127.0.0.1 hostname localhost.localdomain localhost了,
然后我强制生成
scripts/mysql_install_db --user=mysql --force
出现问题:
scripts/mysql_install_db: line 244: ./bin/my_print_defaults: cannot execute binary file
Installing MySQL system tables...
scripts/mysql_install_db: line 392: ./bin/mysqld: cannot execute binary file
Installation of system tables failed! Examine the logs in
./data for more information.
You can try to start the mysqld daemon with:
shell> ./bin/mysqld --skip-grant &
and use the command line tool ./bin/mysql
to connect to the mysql database and look at the grant tables:
shell> ./bin/mysql -u root mysql
mysql> show tables
Try 'mysqld --help' if you have problems with paths. Using --log
gives you a log in ./data that may be helpful.
新手求教!谢谢大家
|
核对下版本,是32位还是64位机器用的。