MySql Crashed When Starting Xampp? - php

When I started the MYSQL from Xampp it crashed. It gave me this error:
8:32:33 AM [mysql] Attempting to start MySQL app...
8:32:33 AM [mysql] Status change detected: running
8:32:37 AM [mysql] Status change detected: stopped
8:32:37 AM [mysql] Error: MySQL shutdown unexpectedly.
8:32:37 AM [mysql] This may be due to a blocked port, missing dependencies, 8:32:37 AM [mysql] improper privileges, a crash, or a shutdown by another method. 8:32:37 AM [mysql] Press the Logs button to view error logs and check
8:32:37 AM [mysql] the Windows Event Viewer for more clues 8:32:37 AM [mysql] If you need more help, copy and post this
8:32:37 AM [mysql] entire log window on the forums
error log InnoDB: using atomic writes.
2020-05-13 8:26:07 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2020-05-13 8:26:07 0 [Note] InnoDB: Uses event mutexes
2020-05-13 8:26:07 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-05-13 8:26:07 0 [Note] InnoDB: Number of pools: 1
2020-05-13 8:26:07 0 [Note] InnoDB: Using SSE2 crc32 instructions
2020-05-13 8:26:07 0 [Note] InnoDB: Initializing buffer pool, total size = 16M, instances = 1, chunk size = 16M
2020-05-13 8:26:07 0 [Note] InnoDB: Completed initialization of buffer pool
2020-05-13 8:26:07 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
2020-05-13 8:26:07 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2020-05-13 8:26:07 0 [Note] InnoDB: Setting file 'C:\xampp\mysql\data\ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2020-05-13 8:26:07 0 [Note] InnoDB: File 'C:\xampp\mysql\data\ibtmp1' size is now 12 MB.
2020-05-13 8:26:07 0 [Note] InnoDB: Waiting for purge to start
2020-05-13 8:26:07 0 [Note] InnoDB: 10.4.11 started; log sequence number 73242724; transaction id 45388
2020-05-13 8:26:07 0 [Note] InnoDB: Loading buffer pool(s) from C:\xampp\mysql\data\ib_buffer_pool
2020-05-13 8:26:07 0 [Note] Plugin 'FEEDBACK' is disabled.
2020-05-13 8:26:07 0 [Note] Server socket created on IP: '::'.
Can someone please help me and tell what actually is happening

Probably your port is busy. If you use Linux you can try to run "lsof -i" to detect what is using your port.

Well I also used to get this kind of problem. I resolved this error like this:
1) Open the Xampp control panel and click Services
2)Find the MYSQL08 option. It might show the service is started.
3)Stop the service and try starting the mysql again
Hope so it might help you.

Related

XAMPP - MySQL Shut down Unexpectedly at start in XAMPP control

When I open XAMPP control application and click start MySQL button it won't start and it gives me an error. It starts and after a couple of seconds it shutdowns automatically. the errors from the XAMPP control application is mentioned in below.
12:03:32 PM [mysql] Attempting to start MySQL app...
12:03:32 PM [mysql] Status change detected: running
12:03:34 PM [mysql] Status change detected: stopped
12:03:34 PM [mysql] Error: MySQL shutdown unexpectedly.
12:03:34 PM [mysql] This may be due to a blocked port, missing
dependencies,
12:03:34 PM [mysql] improper privileges, a crash, or a shutdown by
another method.
12:03:34 PM [mysql] Press the Logs button to view error logs and
check
12:03:34 PM [mysql] the Windows Event Viewer for more clues
12:03:34 PM [mysql] If you need more help, copy and post this
12:03:34 PM [mysql] entire log window on the forums
The Following are the errors from my error log
2021-12-21 12:03:32 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2021-12-21 12:03:32 0 [Note] InnoDB: Uses event mutexes
2021-12-21 12:03:32 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2021-12-21 12:03:32 0 [Note] InnoDB: Number of pools: 1
2021-12-21 12:03:32 0 [Note] InnoDB: Using SSE2 crc32 instructions
2021-12-21 12:03:32 0 [Note] InnoDB: Initializing buffer pool, total size = 16M, instances = 1, chunk size = 16M
2021-12-21 12:03:32 0 [Note] InnoDB: Completed initialization of buffer pool
2021-12-21 12:03:32 0 [Note] InnoDB: Starting crash recovery from checkpoint LSN=300288
2021-12-21 12:03:32 0 [Warning] InnoDB: Are you sure you are using the right ib_logfiles to start up the database? Log sequence number in the ib_logfiles is 300288, less than the log sequence number in the first system tablespace file header, 300360.
2021-12-21 12:03:32 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
2021-12-21 12:03:32 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2021-12-21 12:03:32 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2021-12-21 12:03:32 0 [Note] InnoDB: Setting file 'D:\XAMMP\mysql\data\ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2021-12-21 12:03:32 0 [Note] InnoDB: File 'D:\XAMMP\mysql\data\ibtmp1' size is now 12 MB.
2021-12-21 12:03:32 0 [Note] InnoDB: Waiting for purge to start
2021-12-21 12:03:32 0 [Note] InnoDB: 10.4.22 started; log sequence number 300297; transaction id 170
2021-12-21 12:03:32 0 [Note] InnoDB: Loading buffer pool(s) from D:\XAMMP\mysql\data\ib_buffer_pool
2021-12-21 12:03:32 0 [Note] Plugin 'FEEDBACK' is disabled.
2021-12-21 12:03:32 0 [Note] Server socket created on IP: '::'.
2021-12-21 12:03:32 0 [ERROR] Can't start server: Bind on TCP/IP port. Got error: 10048: Only one usage of each socket address (protocol/network address/port) is normally permitted.
2021-12-21 12:03:32 0 [ERROR] Do you already have another mysqld server running on port: 3306 ?
2021-12-21 12:03:32 0 [ERROR] Aborting
what may cause the problem and how can I resolve them? Thank you in advance
I Got it worked. Didn't change the port and kept it default as 3306. Did the following.
renamed the XAMMP\mysql\data folder to any other name you wish (say data_old )
make a new folder in XAMMP\mysql name data and copy all the files in it including ibdata1
close all running programs and restart XAMPP
No need to copy files from data_old but if you do have previously constructed databases then you may copy some files from data_old.
Special Thanks for everyone who supported.
The easiest way is change port to 3307 or other than 3306 from my.ini and edit "\xamppphp\MyAdmin\config.inc.php"add extra line under
$cfg['Servers'][$i]['AllowNoPassword'] = true;
$cfg['Servers'][$i]['port'] = 3308;
if u need explaination I've made Youtube video sE2UkEcth0w
https://www.youtube.com/watch?v=sE2UkEcth0w
seems like following error from the message
Either port is blocked
Or Application doesn't have enough permission to access those port and serve web application.
To fix this
Right click on XAMPP and Click on Run as Administrator
This will prompt you for password or confirmation.
Allow by providing password or permission
This will run XAMPP in highest privilege, so you won't be facing permission issue anymore.
If this works, you can do few more step to avoid running as administrator manually every time.
Right click on XAMPP icon
Go to properties
Look for option > Run as administrator
[*] check the option and save
This will ask for confirmation/password every time when you run XAMPP.
Hope this solves your issue.

XAMPP Control Panel v 3.3.0 - Error: MySQL shutdown unexpectedly

Tried to start my apache server today and MySQL is not running, this is the error that it shows:
10:15:28 AM [mysql] Status change detected: running
10:15:32 AM [mysql] Status change detected: stopped
10:15:32 AM [mysql] Error: MySQL shutdown unexpectedly.
10:15:32 AM [mysql] This may be due to a blocked port, missing dependencies,
10:15:32 AM [mysql] improper privileges, a crash, or a shutdown by another method.
10:15:32 AM [mysql] Press the Logs button to view error logs and check
10:15:32 AM [mysql] the Windows Event Viewer for more clues
10:15:32 AM [mysql] If you need more help, copy and post this
10:15:32 AM [mysql] entire log window on the forums
This is the log error from the xampp control panel:
2021-06-10 10:15:28 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2021-06-10 10:15:28 0 [Note] InnoDB: Uses event mutexes
2021-06-10 10:15:28 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2021-06-10 10:15:28 0 [Note] InnoDB: Number of pools: 1
2021-06-10 10:15:28 0 [Note] InnoDB: Using SSE2 crc32 instructions
2021-06-10 10:15:28 0 [Note] InnoDB: Initializing buffer pool, total size = 16M, instances = 1, chunk size = 16M
2021-06-10 10:15:28 0 [Note] InnoDB: Completed initialization of buffer pool
2021-06-10 10:15:29 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
2021-06-10 10:15:29 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2021-06-10 10:15:29 0 [Note] InnoDB: Setting file 'C:\xampp\mysql\data\ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2021-06-10 10:15:29 0 [Note] InnoDB: File 'C:\xampp\mysql\data\ibtmp1' size is now 12 MB.
2021-06-10 10:15:29 0 [Note] InnoDB: Waiting for purge to start
2021-06-10 10:15:29 0 [Note] InnoDB: 10.4.19 started; log sequence number 47133; transaction id 8
2021-06-10 10:15:29 0 [Note] InnoDB: Loading buffer pool(s) from C:\xampp\mysql\data\ib_buffer_pool
2021-06-10 10:15:29 0 [Note] Plugin 'FEEDBACK' is disabled.
2021-06-10 10:15:29 0 [Note] InnoDB: Buffer pool(s) load completed at 210610 10:15:29
2021-06-10 10:15:29 0 [Note] Server socket created on IP: '::'.
Tried to:
Rename the folder mysql/data to mysql/data_old (you can use any name)
Create a new folder mysql/data
Copy the content that resides in mysql/backup to the new mysql/data folder
Copy all your database folders that are in mysql/data_old to mysql/data (skipping the mysql, performance_schema, and phpmyadmin folders from data_old)
Finally copy the ibdata1 file from mysql/data_old and replace it inside mysql/data folder
Start MySQL from XAMPP control panel
Also tried:
exit Xampp server
go to your C:\xampp\mysql\data directory
delete the ibdata1 file
restart xampp server
Who knows the solution?
If anyone will be interested in the answer, just reinstalled the xammp control panel since it was still giving me errors
btw for future reference this can happen when you shut down your computer with xampp still running.

mysqli_real_connect(): (HY000/2006): MySQL server has gone away - max_allowed_packet no good

I have seen about 20 pages pertaining to this error on StackExchange's sites (and others) and they all point towards doing:
C:\wamp64\bin\mariadb\mariadb10.4.10\my.ini: max_allowed_packet = 128M (or higher)`
C:\wamp64\bin\mariadb\mariadb10.4.10\my.ini: wait_timeout = 28800 (or higher)
which we have tried, but it's still reporting the "mysql has gone away" error.
We have also tried those config settings under the [wampmariadb64] and [mysqld] sections, to which we discovered that the [wampmariadb64] takes presidence when using WAMP, and those settings were applied, but no we're still getting the error intermittently..
There was also a suggestion to try to set ssl settings:
$cfg['Servers'][$i]['ssl'] = false;
But that didn't work.
They also suggest that we might have a loop problem in our php, which it originally was, but then we fixed it, and we're still getting the error.
Hints:
a) We've only been getting the error since the PHP loop problem which we've fixed.
b) Our log files in WAMP's "C:\wamp64\bin\mariadb\mariadb10.4.10\data" are maxed out to 64Mb, which is what we set it to, but it maxes out on the initial use (on startup and first loading a statement). Is this normal? The log files are named: "ib_logfile0" and "ib_logfile1".
c) About 50 (or so) singular statements after startup it gives the error. The error goes away after an hour of no statement executions, apprx (not always but just about an hour or two later).
Could I please just get some pages to read on troubleshooting the error like this page:
http://ronaldbradford.com/: mysql server has gone away 2013-01-02
Thanks.
Update
I was meaning that we've been editing and trying to change the settings in the C:\wamp64\bin\mariadb\mariadb10.4.10\my.ini file, and not the php.ini sorry. Have corrected above sentences to clarify.
Update
I discovered that a script that automates the creation of a database.sql via mysqydump has sometimes been creating 0kb .sql files, which is required for the other scripts to move on.
I'm looking at the following command, which I have just removed 2>&1 from and going to try that:
exec("mysqldump --port={$GLOBALS['SQL_Port']} --user={$GLOBALS['SQL_Username']} --password={$GLOBALS['SQL_Password']} --host={$GLOBALS['SQL_Host_NoPort']} {$Database} --result-file={$DumpDatabase}.sql");
// 2>&1
Update
This error is now showing up:
Error in processing request
Error code: 200
Error text: OK (rejected)
It seems that the connection to server has been lost. Please check your network connectivity and server status.
Update
Discovered the mariadb logs but they don't say much:
InnoDB: using atomic writes.
2020-07-23 19:16:23 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2020-07-23 19:16:23 0 [Note] InnoDB: Uses event mutexes
2020-07-23 19:16:23 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-07-23 19:16:23 0 [Note] InnoDB: Number of pools: 1
2020-07-23 19:16:23 0 [Note] InnoDB: Using SSE2 crc32 instructions
2020-07-23 19:16:23 0 [Note] InnoDB: Initializing buffer pool, total size = 256M, instances = 1, chunk size = 128M
2020-07-23 19:16:23 0 [Note] InnoDB: Completed initialization of buffer pool
2020-07-23 19:16:23 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
2020-07-23 19:16:23 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2020-07-23 19:16:23 0 [Note] InnoDB: Setting file '.\ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2020-07-23 19:16:23 0 [Note] InnoDB: File '.\ibtmp1' size is now 12 MB.
2020-07-23 19:16:23 0 [Note] InnoDB: Waiting for purge to start
2020-07-23 19:16:23 0 [Note] InnoDB: 10.4.10 started; log sequence number 140336; transaction id 21
2020-07-23 19:16:23 0 [Note] InnoDB: Loading buffer pool(s) from c:\wamp64\bin\mariadb\mariadb10.4.10\data\ib_buffer_pool
2020-07-23 19:16:23 0 [Note] Plugin 'FEEDBACK' is disabled.
2020-07-23 19:16:23 0 [Note] InnoDB: Buffer pool(s) load completed at 200723 19:16:23
2020-07-23 19:16:23 0 [Note] Server socket created on IP: '::'.
2020-07-23 19:16:23 0 [Note] Reading of all Master_info entries succeeded
2020-07-23 19:16:23 0 [Note] Added new Master_info '' to hash table
2020-07-23 19:16:23 0 [Note] wampmariadb64: ready for connections.
Version: '10.4.10-MariaDB' socket: '' port: 3306 mariadb.org binary distribution
2020-07-23 19:27:43 0 [Note] wampmariadb64 (initiated by: unknown): Normal shutdown
2020-07-23 19:27:43 0 [Note] Event Scheduler: Purging the queue. 0 events
2020-07-23 19:27:43 0 [Note] InnoDB: FTS optimize thread exiting.
2020-07-23 19:27:43 0 [Note] InnoDB: Starting shutdown...
2020-07-23 19:27:43 0 [Note] InnoDB: Dumping buffer pool(s) to c:\wamp64\bin\mariadb\mariadb10.4.10\data\ib_buffer_pool
2020-07-23 19:27:43 0 [Note] InnoDB: Buffer pool(s) dump completed at 200723 19:27:43
2020-07-23 19:27:44 0 [Note] InnoDB: Shutdown completed; log sequence number 140345; transaction id 22
2020-07-23 19:27:44 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2020-07-23 19:27:44 0 [Note] wampmariadb64: Shutdown complete
It had something to do with starting WAMP in Windows 10 Scheduled Task Manager, starting it as a new task. Probably because I didn't start it with Administrator privileges.
Once I removed the Scheduled Task: Start WAMP # Logon -it seemed to work again.

MySQL refuses to start after installing WordPress

After running the wordpress installation and tried to login to wp-admin on my Ubuntu server, I got "error establishing connection to db" error. This is the error.log after running the WP install:
170708 6:05:02 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full n$
170708 6:05:02 [Note] Plugin 'FEDERATED' is disabled.
170708 6:05:02 InnoDB: The InnoDB memory heap is disabled
170708 6:05:02 InnoDB: Mutexes and rw_locks use GCC atomic builtins
170708 6:05:02 InnoDB: Compressed tables use zlib 1.2.8
170708 6:05:02 InnoDB: Using Linux native AIO
170708 6:05:02 InnoDB: Initializing buffer pool, size = 128.0M
170708 6:05:02 InnoDB: Completed initialization of buffer pool
170708 6:05:02 InnoDB: highest supported file format is Barracuda.
InnoDB: Log scan progressed past the checkpoint lsn 1332282360
170708 6:05:02 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...
InnoDB: Doing recovery: scanned up to log sequence number 1332887786
InnoDB: 1 transaction(s) which must be rolled back or cleaned up
InnoDB: in total 1 row operations to undo
InnoDB: Trx id counter is 13E200
170708 6:05:02 InnoDB: Starting an apply batch of log records to the database...
InnoDB: Progress in percents: 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 6$
InnoDB: Apply batch completed
InnoDB: Cleaning up trx with id 13DA6A
170708 6:05:02 InnoDB: Waiting for the background threads to start
170708 6:05:03 InnoDB: 5.5.37 started; log sequence number 1332887786
170708 6:05:03 [Note] Server hostname (bind-address): '127.0.0.1'; port: 3306
170708 6:05:03 [Note] - '127.0.0.1' resolves to '127.0.0.1';
170708 6:05:03 [Note] Server socket created on IP: '127.0.0.1'.
170708 6:05:03 InnoDB: Assertion failure in thread 139675398293248 in file trx0purge.c line 840
InnoDB: Failing assertion: purge_sys->purge_trx_no <= purge_sys->rseg->last_trx_no
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
10:05:03 UTC - mysqld got signal 6 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.
key_buffer_size=16777216
read_buffer_size=131072
max_used_connections=0
max_threads=151
thread_count=0
connection_count=0
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 346700 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
Thread pointer: 0x0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 0 thread_stack 0x30000
/usr/sbin/mysqld(my_print_stacktrace+0x20)[0x7f08d3614c70]
170708 6:05:03 [Note] Event Scheduler: Loaded 0 events
170708 6:05:03 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.5.37-0ubuntu0.14.04.1' socket: '/var/run/mysqld/mysqld.sock' port: 3306 (Ubuntu)
/usr/sbin/mysqld(handle_fatal_signal+0x3d5)[0x7f08d34ff6d5]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x10340)[0x7f08d2291340]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0x39)[0x7f08d18e7f79]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x148)[0x7f08d18eb388]
/usr/sbin/mysqld(+0x588b65)[0x7f08d36aeb65]
/usr/sbin/mysqld(+0x5896b9)[0x7f08d36af6b9]
/usr/sbin/mysqld(+0x64acdf)[0x7f08d3770cdf]
/usr/sbin/mysqld(+0x641595)[0x7f08d3767595]
/usr/sbin/mysqld(+0x58b525)[0x7f08d36b1525]
/usr/sbin/mysqld(+0x57d13c)[0x7f08d36a313c]
/usr/sbin/mysqld(+0x581213)[0x7f08d36a7213]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8182)[0x7f08d2289182]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x6d)[0x7f08d19ac30d]
The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.
170708 6:05:04 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full n$
170708 6:05:04 [Note] Plugin 'FEDERATED' is disabled.
170708 6:05:04 InnoDB: The InnoDB memory heap is disabled
170708 6:05:04 InnoDB: Mutexes and rw_locks use GCC atomic builtins
170708 6:05:04 InnoDB: Compressed tables use zlib 1.2.8
170708 6:05:04 InnoDB: Using Linux native AIO
170708 6:05:04 InnoDB: Initializing buffer pool, size = 128.0M
170708 6:05:04 InnoDB: Completed initialization of buffer pool
170708 6:05:04 InnoDB: highest supported file format is Barracuda.
InnoDB: Log scan progressed past the checkpoint lsn 1332284392
170708 6:05:04 InnoDB: Database was not shut down normally!
Then I tried to start my MySQL:
sudo /etc/init.d/mysql start
And I got this in the error.log:
170708 06:06:23 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
170708 6:06:23 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
170708 6:06:23 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full n$
170708 6:06:23 [Note] Plugin 'FEDERATED' is disabled.
170708 6:06:23 InnoDB: The InnoDB memory heap is disabled
170708 6:06:23 InnoDB: Mutexes and rw_locks use GCC atomic builtins
170708 6:06:23 InnoDB: Compressed tables use zlib 1.2.8
170708 6:06:23 InnoDB: Using Linux native AIO
170708 6:06:23 InnoDB: Initializing buffer pool, size = 128.0M
170708 6:06:23 InnoDB: Completed initialization of buffer pool
170708 6:06:23 InnoDB: highest supported file format is Barracuda.
InnoDB: Log scan progressed past the checkpoint lsn 1332284392
170708 6:06:23 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...
InnoDB: Doing recovery: scanned up to log sequence number 1332887786
InnoDB: 1 transaction(s) which must be rolled back or cleaned up
InnoDB: in total 1 row operations to undo
InnoDB: Trx id counter is 13E200
170708 6:06:23 InnoDB: Starting an apply batch of log records to the database...
InnoDB: Progress in percents: 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 6$
InnoDB: Apply batch completed
InnoDB: Cleaning up trx with id 13DA6A
170708 6:06:23 InnoDB: Waiting for the background threads to start
170708 6:06:24 InnoDB: 5.5.37 started; log sequence number 1332887786
170708 6:06:24 [Note] Server hostname (bind-address): '127.0.0.1'; port: 3306
170708 6:06:24 [Note] - '127.0.0.1' resolves to '127.0.0.1';
170708 6:06:24 [Note] Server socket created on IP: '127.0.0.1'.
170708 6:06:24 InnoDB: Assertion failure in thread 140384662005504 in file trx0purge.c line 840
InnoDB: Failing assertion: purge_sys->purge_trx_no <= purge_sys->rseg->last_trx_no
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
10:06:24 UTC - mysqld got signal 6 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.
key_buffer_size=16777216
read_buffer_size=131072
max_used_connections=0
max_threads=151
thread_count=0
connection_count=0
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 346700 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
Thread pointer: 0x0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 0 thread_stack 0x30000
/usr/sbin/mysqld(my_print_stacktrace+0x20)[0x7fadf2b5bc70]
/usr/sbin/mysqld(handle_fatal_signal+0x3d5)[0x7fadf2a466d5]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x10340)[0x7fadf17d8340]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0x39)[0x7fadf0e2ef79]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x148)[0x7fadf0e32388]
/usr/sbin/mysqld(+0x588b65)[0x7fadf2bf5b65]
/usr/sbin/mysqld(+0x5896b9)[0x7fadf2bf66b9]
/usr/sbin/mysqld(+0x64acdf)[0x7fadf2cb7cdf]
/usr/sbin/mysqld(+0x641595)[0x7fadf2cae595]
/usr/sbin/mysqld(+0x58b525)[0x7fadf2bf8525]
/usr/sbin/mysqld(+0x57d13c)[0x7fadf2bea13c]
/usr/sbin/mysqld(+0x581213)[0x7fadf2bee213]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8182)[0x7fadf17d0182]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x6d)[0x7fadf0ef330d]
The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.
170708 06:06:24 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
These errors don't mean anything to me, please point me in the right direction to troubleshoot this problem.
Cheers

Xampp mysql Error: MySQL shutdown unexpectedly

when I starting mysql, giving the following error:
17:43:13 [mysql] Error: MySQL shutdown unexpectedly.
17:43:13 [mysql] This may be due to a blocked port, missing dependencies,
17:43:13 [mysql] improper privileges, a crash, or a shutdown by another method.
17:43:13 [mysql] Press the Logs button to view error logs and check
17:43:13 [mysql] the Windows Event Viewer for more clues
17:43:13 [mysql] If you need more help, copy and post this
17:43:13 [mysql] entire log window on the forums
then, I check the mysql_error.log:
2017-05-03 17:39:39 202c InnoDB: Warning: Using innodb_additional_mem_pool_size is DEPRECATED. This option may be removed in future releases, together with the option innodb_use_sys_malloc and with the InnoDB's internal memory allocator.
170503 17:39:39 [Note] InnoDB: Using mutexes to ref count buffer pool pages
170503 17:39:39 [Note] InnoDB: The InnoDB memory heap is disabled
170503 17:39:39 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
170503 17:39:39 [Note] InnoDB: Memory barrier is not used
170503 17:39:39 [Note] InnoDB: Compressed tables use zlib 1.2.3
170503 17:39:39 [Note] InnoDB: Not using CPU crc32 instructions
170503 17:39:39 [Note] InnoDB: Initializing buffer pool, size = 16.0M
170503 17:39:39 [Note] InnoDB: Completed initialization of buffer pool
170503 17:39:39 [Note] InnoDB: Highest supported file format is Barracuda.
170503 17:39:39 [Note] InnoDB: The log sequence numbers 0 and 0 in ibdata files do not match the log sequence number 1600674 in the ib_logfiles!
170503 17:39:39 [Note] InnoDB: Database was not shutdown normally!
170503 17:39:39 [Note] InnoDB: Starting crash recovery.
170503 17:39:39 [Note] InnoDB: Reading tablespace information from the .ibd files...
170503 17:39:39 [Note] InnoDB: Restoring possible half-written data pages
170503 17:39:39 [Note] InnoDB: from the doublewrite buffer...
170503 17:39:39 [Note] InnoDB: 128 rollback segment(s) are active.
170503 17:39:39 [Note] InnoDB: Waiting for purge to start
170503 17:39:40 [Note] InnoDB: Percona XtraDB (http://www.percona.com) 5.6.22-72.0 started; log sequence number 1600674
170503 17:39:40 [Note] Plugin 'FEEDBACK' is disabled.
170503 17:39:40 [Note] Server socket created on IP: '::'.
finally, I moved xampp/mysql/backup files into xampp/mysql/data and run mysql again.Then, it worked!But I don't know why.What led to this problem.
Hope someone doubts for me!
I searched on google and tried everything like port changing, delete files, reinstall xampp, copy and paste backup files to mysql/data folder but nothing worked.
I found the best solution to this problem.
Solution:
go to xampp/mysql/data and take a backup of this folder
delete all selected files in the below image
Copy selected files in below image from xampp/mysql/backup and paste it to xampp/mysql/data folder
Now restart your xampp server and it will run like before. no need to delete your database or reinstall your xampp server
If you're not running XAMPP as an administrator, shutting down MySQL can cause corruption which means you have to repair or delete your tables. This can easily be avoided by running XAMPP as administrator.
Open Services on XAMPP Control Panel
Look for the service MySQL80, right click on this service and click Stop
Get back to XAMPP Control Panel and start MySQL
this worked for me.
Open Services on XAMPP Control Panel
Look for the Services > MySQL80,
right click on this Services and click Stop
Get back to XAMPP Control Panel and start MySQL
thanks to #Shahjahan

Categories