Solution to mysql innodb data file creation failure

Source: Internet
Author: User


Troubleshooting of data file creation failure in mysql innodb/etc/my. cnf configuration www.2cto.com [mysqld] datadir =/var/lib/mysqlsocket =/var/lib/mysql. sockuser = mysql # Default to using old password format for compatibility with mysql 3.x# clients (those using the mysqlclient10 compatibility package ). old_passwords = 1 # Disabling symbolic-links is recommended to prevent assorted security risks; # to do so, uncomment this line: # symbolic-links = 0 Default-character-set = utf8default-storage-engine = innodb # Uncomment the following if you are using InnoDB tablesinnodb_data_home_dir =/var/mysql/innodb/innodb_data_file_path = ibdata1: 2000 M; ibdata2: 10 M: autoextendinnodb_log_group_home_dir =/var/mysql/innodb/log/innodb_log_arch_dir =/var/mysql/innodb/log/www.2cto.com # You can set .. _ buffer_pool_size up to 50-80% # of RAM but beware of setting Memory usage too highinnodb_buffer_pool_size = 1024Minnodb_additional_mem_pool_size = 20 M # Set .. _ log_file_size to 25% of buffer pool Limit = bytes = 1innodb_lock_wait_timeout = 50 [client] default-character-set = gbk [mysqld_safe] log-error =/var/log/mysqld. logpid-file =/var/run/mysqld. pid failed to start mysqld, directory permission is set to 777, And/u Sr/bin/mysql_install_db -- user = mysql it seems that the innodb data directory must be in the subdirectory configured by datadir! View logs/var/log/mysqld. log ......................... 120817 13:08:17 InnoDB: Operating system error number 13 in a file operation. innoDB: The error means mysqld does not have the access rights toInnoDB: the directory. innoDB: File name/var/mysql/innodb/ibdata1InnoDB: File operation call: 'create '. innoDB: Cannot continue operation.120817 13:08:17 mysqld ended Modify/etc/my. configure www.2cto.com [mysqld] datad for cnf Ir =/var/lib/mysqlsocket =/var/lib/mysql. sockuser = mysql # Default to using old password format for compatibility with mysql 3.x# clients (those using the mysqlclient10 compatibility package ). old_passwords = 1 # Disabling symbolic-links is recommended to prevent assorted security risks; # to do so, uncomment this line: # symbolic-links = 0 default-character-set = utf8default-storage-engine = innodb # Uncom Ment the following if you are using InnoDB tablesinnodb_data_home_dir =/var/lib/mysql/innodb/innodb_data_file_path = ibdata1: 2000 M; ibdata2: 10 M: autoextendinnodb_log_group_home_dir =/var/lib/mysql/innodb/log/innodb_log_arch_dir =/var/lib/mysql/innodb/log/# You can set .. _ buffer_pool_size up to 50-80% # of RAM but beware of setting memory usage too highinnodb_buffer_pool_size = 1024Minnodb_additional_mem _ Pool_size = 20 M # Set .. _ log_file_size to 25% of buffer pool Limit = bytes = 1innodb_lock_wait_timeout = 50 www.2cto.com [client] default-character-set = gbk [mysqld_safe] log-error =/var/log/mysqld. logpid-file =/var/run/mysqld. pid started successfully.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.