Error when starting mariadb - no such process
Asked Answered
B

4

15

I installed mariadb via homebrew to set up a wordpress enviroment. It is meant to work with laravel valet. I am currently using using the zsh shell.

I installed it without a problem (10.3.12), but when I run mysql.server start I get the following error:

mysql.server start
Starting MariaDB
.190206 11:26:18 mysqld_safe Logging to '/usr/local/var/mysql/chriss-mbp.lan.err'.
190206 11:26:18 mysqld_safe Starting mysqld daemon with databases from /usr/local/var/mysql
/usr/local/bin/mysql.server: line 260: kill: (55179) - No such process
 ERROR!

Can anybody help me narrow down why I'm getting this error? I'm new to terminal and mariadb, so I'm hoping it's just a silly error that I wasn't aware of.

Barter answered 6/2, 2019 at 18:31 Comment(1)
How is this related to Laravel, Wordpress or Valet? Please do not use irrelevant tagsLarson
S
8

Brew has its own service manager included. Via brew services list you get all installed services listed. MariaDB should be there.

To start it call brew services start mariadb.

Sempstress answered 6/2, 2019 at 18:37 Comment(1)
brew info mariadb lists both options: both mysql.server start and brew services start mariadb. To start as a service is not related to an error when manually starting, in fact: most likely starting the service will have the same effect... mariadb not starting.Presbytery
B
4

Looking at the offending line in the startup script, this error indicates:

  1. the startup script timed out waiting for the server to come up, and
  2. the server process isn't running.

The command name kill is a little misleading; it's most commonly used to kill a process, but it can also be used to send an arbitrary signal, or even (with -0) just to check whether it would be possible to send a signal, which is what's happening here.

To find out why the server didn't come up, you need to check the error log, which on a macOS / Homebrew installation of MySQL or MariaDB is going to be in:

/usr/local/var/mysql/<hostname>.err

If you tail that file, you should see the reason for the failure, e.g.

2019-11-01 11:29:14 0 [ERROR] Can't start server: Bind on TCP/IP port.
  Got error: 48: Address already in use
2019-11-01 11:29:14 0 [ERROR] Do you already have another mysqld server
  running on port: 3306 ?
2019-11-01 11:29:14 0 [ERROR] Aborting

(In my case I had another instance of MariaDB running in a Docker container and squatting on port 3306.)

Bridgeboard answered 1/11, 2019 at 18:38 Comment(0)
V
1

sudo tail -f /usr/local/var/mysql/[your computer host name].err

2021-01-22 13:16:17 4581617088 [Note] InnoDB:  Percona XtraDB (http://www.percona.com) 5.6.42-84.2 started; log sequence number 149299467171
2021-01-22 13:16:17 123145364480000 [Note] InnoDB: Dumping buffer pool(s) not yet started
2021-01-22 13:16:17 4581617088 [Note] Plugin 'FEEDBACK' is disabled.
2021-01-22 13:16:17 4581617088 [Note] Recovering after a crash using tc.log
2021-01-22 13:16:17 4581617088 [ERROR] Bad magic header in tc log
2021-01-22 13:16:17 4581617088 [ERROR] Crash recovery failed. Either correct the problem (if it's, for example, out of memory error) and restart, or delete tc log and start mysqld with --tc-heuristic-recover={commit|rollback}
2021-01-22 13:16:17 4581617088 [ERROR] Can't init tc log
2021-01-22 13:16:17 4581617088 [ERROR] Aborting

I was running MariaDB 10.1 locally and boot up a MariaDB 10.5, somehow my /usr/local/var/mysql/tc.log was affected and I have to rename it to boot my local 10.1 again.

sudo mv /usr/local/var/mysql/tc.log  /usr/local/var/mysql/tc.log_ 
sudo mysql.server start

Starting MariaDB
.210122 14:30:56 mysqld_safe Logging to '/usr/local/var/mysql/[your computer host name].err'.
210122 14:30:56 mysqld_safe Starting mysqld daemon with databases from /usr/local/var/mysql
 SUCCESS! 
Vancevancleave answered 22/1, 2021 at 6:33 Comment(0)
U
0

Try to seek the error inside the log file /var/log/mariadb/mariadb.log. My was configured non-existing , better said not yet imported/configured time-zone.

Unit answered 9/10, 2020 at 12:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.