Hello,
Having the same problem here. It seems that the error is generated on AMPPS shutdown (PC restart or log off).
In my case the problem is with phpMyAdmin table :
Code 2017-12-12 20:39:34 2552 [Warning] You need to use --log-bin to make --binlog-format work.
2017-12-12 20:39:34 2552 [Note] Plugin 'FEDERATED' is disabled.
2017-12-12 20:39:34 2552 [Note] InnoDB: Using atomics to ref count buffer pool pages
2017-12-12 20:39:34 2552 [Note] InnoDB: The InnoDB memory heap is disabled
2017-12-12 20:39:34 2552 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2017-12-12 20:39:34 2552 [Note] InnoDB: Memory barrier is not used
2017-12-12 20:39:34 2552 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-12-12 20:39:34 2552 [Note] InnoDB: Not using CPU crc32 instructions
2017-12-12 20:39:34 2552 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2017-12-12 20:39:34 2552 [Note] InnoDB: Completed initialization of buffer pool
2017-12-12 20:39:34 2552 [Note] InnoDB: Highest supported file format is Barracuda.
2017-12-12 20:39:34 2552 [Note] InnoDB: The log sequence numbers 46315784 and 46315784 in ibdata files do not match the log sequence number 46315794 in the ib_logfiles!
2017-12-12 20:39:34 2552 [Note] InnoDB: Database was not shutdown normally!
2017-12-12 20:39:34 2552 [Note] InnoDB: Starting crash recovery.
2017-12-12 20:39:34 2552 [Note] InnoDB: Reading tablespace information from the .ibd files...
2017-12-12 20:39:34 2552 [ERROR] InnoDB: Attempted to open a previously opened tablespace. Previous tablespace mysql/innodb_table_stats uses space ID: 1 at filepath: .\mysql\innodb_table_stats.ibd. Cannot open tablespace phpmyadmin/pma__bookmark which uses space ID: 1 at filepath: .\phpmyadmin\pma__bookmark.ibd
InnoDB: Error: could not open single-table tablespace file .\phpmyadmin\pma__bookmark.ibd
InnoDB: We do not continue the crash recovery, because the table may become
InnoDB: corrupt if we cannot apply the log records in the InnoDB log to it.
InnoDB: To fix the problem and start mysqld:
InnoDB: 1) If there is a permission problem in the file and mysqld cannot
InnoDB: open the file, you should modify the permissions.
InnoDB: 2) If the table is not needed, or you can restore it from a backup,
InnoDB: then you can remove the .ibd file, and InnoDB will do a normal
InnoDB: crash recovery and ignore that table.
InnoDB: 3) If the file system or the disk is broken, and you cannot remove
InnoDB: the .ibd file, you can set innodb_force_recovery >0 in my.cnf
InnoDB: and force InnoDB to continue crash recovery here.
When correctly shutting down the Mysql Daemon (From Ampps Console) then restarting, everything is ok.
I did make a batch windows file to make this happens automatically:
Code
Echo /// Shut down AMPPS correctly///
REM MYSQL
Echo Mysql Shutdown
Echo ---------------
mysqladmin.exe -u root -p1234 shutdown
Echo ---------------
Echo Apache Shutdown
Echo ---------------
taskkill /F /IM httpd.exe /T
Echo ---------------
Echo Filezilla FtpServer Shutdown
Echo ---------------
"Filezilla server" /stop
Echo ---------------
Therefore, this batch must be run as admin which is a pain in the *** in windows 10, so using the BAT to EXE (http://www.bdargo.com/) to compile this into some executable that could be (with right click, proprieties) run as administrator.
-p1234 is the password of your Mysql root user, here it is as example, don't put spaces between -p and the password
I also mention that the Ampps folders "c:\ampps\mysql\bin" "c:\ampps\FilleZilla" "c:\ampps\apache\bin" "c:\ampps" (in my case it is installed in c:) must be added to PATH variable in Windows otherwise it will not find the files.
Hope it helps while Devs could fix this possible bug.
Cheers.
|