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"
|
Attachments
Activity
Field | Original Value | New Value |
---|---|---|
Description |
When running the `mysqld_safe start` command, if the `grep` command which is installed on the operating system is not fully functional, for example the `busybox` version, then the mysql command will fail with the following error:
``` grep: mysqld_safe: No such file or directory ``` 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") ``` |
When running the {{mysqld_safe start}} command, if the `grep` command which is installed on the operating system is not fully functional, for example the `busybox` version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} 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") ``` |
Description |
When running the {{mysqld_safe start}} command, if the `grep` command which is installed on the operating system is not fully functional, for example the `busybox` version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} 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") ``` |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} |
Summary | mysqld_safe script breaks if grep is not fully functional | mysqld_safe script breaks if grep is not fully featured |
Description |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
Description |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This is a problem, as the script should not assume that the {{grep}} command that is installed should have all the features. --- This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
Description |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This is a problem, as the script should not assume that the {{grep}} command that is installed should have all the features. --- This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This is a problem, as the script should not assume that the {{grep}} command that is installed should have all the features. ---- This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
Summary | mysqld_safe script breaks if grep is not fully featured | mysqld_safe script breaks with many versions of grep |
Description |
When running the {{mysqld_safe start}} command, if the {{grep}} command which is installed on the operating system is not fully functional, for example the {{busybox}} version, then the mysql command will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} This is a problem, as the script should not assume that the {{grep}} command that is installed should have all the features. ---- This was broken in commit {{193bfdd831bbbf65e74acd12baf691d4305e3c11}}. The offending line of code is in {{server/scripts/CMakeLists.txt}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
When running the {{mysqld_safe start}} command, if the {{grep}} command isn't the exact correct version, it will fail with the following error:
{code:shell} grep: mysqld_safe: No such file or directory {code} 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}}: {code:shell} # 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") {code} This could be fixed by changing the middle grep command from {code:shell} grep -vE mariadbd-safe -vE mysqld_safe {code} To the new command: {code:shell} grep -vE "mariadbd-safe|mysqld_safe" {code} |
Component/s | Scripts & Clients [ 11002 ] | |
Component/s | Server [ 13907 ] |
Labels | beginner-friendly |
Assignee | Rucha Deodhar [ rucha174 ] |
Fix Version/s | 10.6 [ 24028 ] | |
Fix Version/s | 10.7 [ 24805 ] | |
Fix Version/s | 10.8 [ 26121 ] | |
Fix Version/s | 10.9 [ 26905 ] |
Assignee | Rucha Deodhar [ rucha174 ] | Vicențiu Ciorbaru [ cvicentiu ] |
Fix Version/s | 10.6.9 [ 27507 ] | |
Fix Version/s | 10.7.5 [ 27505 ] | |
Fix Version/s | 10.8.4 [ 27503 ] | |
Fix Version/s | 10.9.2 [ 27115 ] | |
Fix Version/s | 10.6 [ 24028 ] | |
Fix Version/s | 10.7 [ 24805 ] | |
Fix Version/s | 10.8 [ 26121 ] | |
Fix Version/s | 10.9 [ 26905 ] | |
Resolution | Fixed [ 1 ] | |
Status | Open [ 1 ] | Closed [ 6 ] |