Reputation: 380
I installed mysql by following this link-"https://www3.ntu.edu.sg/home/ehchua/programming/sql/MySQL_HowTo.html". When I try to start mysql by the command, I get the following error
E:\mysql folder\mysql\bin>mysqld --console
2015-03-23 00:54:03 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2015-03-23 00:54:03 4040 [Note] InnoDB: Using atomics to ref count buffer pool pages
2015-03-23 00:54:03 4040 [Note] InnoDB: The InnoDB memory heap is disabled
2015-03-23 00:54:03 4040 [Note] InnoDB: Mutexes and rw_locks use Windows nterlocked functions
2015-03-23 00:54:03 4040 [Note] InnoDB: Memory barrier is not used
2015-03-23 00:54:03 4040 [Note] InnoDB: Compressed tables use zlib 1.2.3
2015-03-23 00:54:03 4040 [Note] InnoDB: Not using CPU crc32 instructions
2015-03-23 00:54:03 4040 [Note] InnoDB: Initializing buffer pool, size =128.0M
2015-03-23 00:54:03 4040 [Note] InnoDB: Completed initialization of buffer pool
2015-03-23 00:54:03 4040 [ERROR] InnoDB: .\ibdata1 can't be opened in read-write mode
2015-03-23 00:54:03 4040 [ERROR] InnoDB: The system tablespace must be writable!
2015-03-23 00:54:03 4040 [ERROR] Plugin 'InnoDB' init function returned error.
2015-03-23 00:54:03 4040 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2015-03-23 00:54:03 4040 [ERROR] Unknown/unsupported storage engine: InnoDB
2015-03-23 00:54:03 4040 [ERROR] Aborting
2015-03-23 00:54:03 4040 [Note] Binlog end
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'partition'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin'INNODB_FT_DEFAULT_STOPWORD'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_METRICS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_CMPMEM'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_CMP'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_LOCKS'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'INNODB_TRX'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'FEDERATED'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'BLACKHOLE'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'ARCHIVE'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'MRG_MYISAM'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'MyISAM'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'MEMORY'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'CSV'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'sha256_password'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'mysql_old_password'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'mysql_native_password'
2015-03-23 00:54:03 4040 [Note] Shutting down plugin 'binlog'
2015-03-23 00:54:03 4040 [Note] mysqld: Shutdown complete
Also when I start rails server its showing me this error-"Can't connect to MySQL server on 'localhost' (10061)", I guess its because server is not running.How to start the mysql server?
Upvotes: 0
Views: 83
Reputation: 380
After a restart, mysql server started running and then the error was still there of "Can't connect to MySQL server on 'localhost' (10061)". It was resolved by adding the port 8888 in database.yml file.
Upvotes: 0
Reputation: 10673
Seems like you need to enable the explicit_defaults_for_timestamp system variable to get rid of that warning.
From the official doc for MySQL 5.6:
[Warning] TIMESTAMP with implicit DEFAULT value is deprecated.
Please use --explicit_defaults_for_timestamp server option (see
documentation for more details).
As indicated by the warning, to turn off the nonstandard behaviors,
enable the new explicit_defaults_for_timestamp system variable at
server startup. With this variable enabled, the server handles
TIMESTAMP as follows instead:
TIMESTAMP columns not explicitly declared as NOT NULL permit NULL values. Setting such a column to NULL sets it to NULL, not the current timestamp.
No TIMESTAMP column is assigned the DEFAULT CURRENT_TIMESTAMP or ON UPDATE CURRENT_TIMESTAMP attributes automatically. Those attributes must be explicitly specified.
TIMESTAMP columns declared as NOT NULL and without an explicit DEFAULT clause are treated as having no default value. For inserted rows that specify no explicit value for such a column, the result depends on the SQL mode. If strict SQL mode is enabled, an error occurs. If strict SQL mode is not enabled, the column is assigned the implicit default of '0000-00-00 00:00:00' and a warning occurs. This is similar to how MySQL treats other temporal types such as DATETIME.
Upvotes: 1