免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2096 | 回复: 6
打印 上一主题 下一主题

mysql 无法正常安装 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-06-15 15:27 |只看该作者 |倒序浏览
环境:
solaris 10
mysql-5.1.11-beta-solaris10-sparc-64bit.pkg.gz

启动提示信息:
bash-3.00$ Starting mysqld daemon with databases from /opt/mysql/mysql/data
STOPPING server from pid file /opt/mysql/mysql/data/dgswwg.pid
060615 13:55:08 mysqld ended

日志信息:
060615 13:36:57 mysqld started
060615 13:36:57 InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
060615 13:36:57 InnoDB: Starting log scan based on checkpoint at
InnoDB: log sequence number 0 39542.
InnoDB: Doing recovery: scanned up to log sequence number 0 39542
InnoDB: Creating foreign key constraint system tables
InnoDB: Foreign key constraint system tables created
060615 13:36:57 InnoDB: Started; log sequence number 0 39542
/opt/mysql/mysql/bin/mysqld: Table 'mysql.general_log' doesn't exist
060615 13:36:57 [ERROR] Fatal error: Can't open and lock privilege tables: Table
'mysql.host' doesn't exist
060615 13:36:58 mysqld ended

论坛徽章:
0
2 [报告]
发表于 2006-06-15 16:13 |只看该作者
mysql_install_db 这个执行过么?
安装包里面有没有 INSTALL 文件,看看它的说明。

论坛徽章:
0
3 [报告]
发表于 2006-06-15 17:03 |只看该作者
我是先运行了 configure 文件

提示:
./configure
NOTE: This is a MySQL binary distribution. It's ready to run, you don't
need to configure it!

To help you a bit, I am now going to create the needed MySQL databases
and start the MySQL server for you.  If you run into any trouble, please
consult the MySQL manual, that you can find in the Docs directory.

Installing all prepared tables
Fill help tables

To start mysqld at boot time you have to copy support-files/mysql.server
to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/opt/mysql/mysql/bin/mysqladmin -u root password 'new-password'
/opt/mysql/mysql/bin/mysqladmin -u root -h dgswwg password 'new-password'
See the manual for more instructions.

NOTE:  If you are upgrading from a MySQL <= 3.22.10 you should run
the /opt/mysql/mysql/bin/mysql_fix_privilege_tables. Otherwise you will not be
able to use the new GRANT command!

You can start the MySQL daemon with:
cd . ; /opt/mysql/mysql/bin/mysqld_safe &

Please report any problems with the ./bin/mysqlbug script!

The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com
Starting the mysqld server.  You can test that it is up and running
with the command:
./bin/mysqladmin version
$ Starting mysqld daemon with databases from /opt/mysql/mysql/data

$ STOPPING server from pid file /opt/mysql/mysql/data/dgswwg.pid
060615 15:56:22  mysqld ended

论坛徽章:
0
4 [报告]
发表于 2006-06-15 17:17 |只看该作者
$ ./mysql_install_db
Installing all prepared tables
Fill help tables

To start mysqld at boot time you have to copy support-files/mysql.server
to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/usr/local/mysql/bin/mysqladmin -u root password 'new-password'
/usr/local/mysql/bin/mysqladmin -u root -h dgswwg password 'new-password'
See the manual for more instructions.

You can start the MySQL daemon with:
cd . ; /usr/local/mysql/bin/mysqld_safe &

Please report any problems with the ./bin/mysqlbug script!

The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.co

论坛徽章:
0
5 [报告]
发表于 2006-06-15 17:21 |只看该作者
原帖由 飞眉 于 2006-6-15 17:03 发表
我是先运行了 configure 文件

提示:
./configure
NOTE: This is a MySQL binary distribution. It's ready to run, you don't
need to configure it!

注意 NOTE 后面那段话,它告诉你它是二进制包,直接可使用,不需要用 ./configure 方式去编译安装。
如何使用,请看它另外一个文件,可能叫 INSTALL,里面有完整的安装步骤,你照做即可。

论坛徽章:
0
6 [报告]
发表于 2006-06-15 18:12 |只看该作者
Installed mysql on Solaris machine. Created a symbolic link /usr/local/mysql pointing to the installation directory.

Tried to start mysqld_safe and received and a error message on startup "Fatal error: Can't open and lock privilege

tables: Table 'mysql.host' doesn't exist".


Solution:


Created an /etc/my.cnf with the following:


[mysqld]

basedir = /usr/local/mysql

datadir = /usr/local/mysql/data


This cured the startup problem

论坛徽章:
0
7 [报告]
发表于 2006-06-15 18:13 |只看该作者
刚才在MYSQL网站上找到解决办法测试一下通过了
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP