Details
-
Bug
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Fixed
-
10.7.4
-
Linux
Description
When running the mysqld_safe start command, if the grep command isn't the exact correct version, it will fail with the following error:
grep: mysqld_safe: No such file or directory
|
This is a problem, as the script should not assume that the grep command that is installed should have all the features.
It is failing with very common versions of grep, like GNU grep v3.7
This was broken in commit 193bfdd831bbbf65e74acd12baf691d4305e3c11.
The offending line of code is in server/scripts/CMakeLists.txt:
# FIND_PROC and CHECK_PID are used by mysqld_safe
|
IF(CMAKE_SYSTEM_NAME MATCHES "Linux")
|
SET (FIND_PROC
|
"ps wwwp $PID | grep -vE mariadbd-safe -vE mysqld_safe | grep -- $MYSQLD > /dev/null")
|
This could be fixed by changing the middle grep command from
grep -vE mariadbd-safe -vE mysqld_safe
|
To the new command:
grep -vE "mariadbd-safe|mysqld_safe"
|