1st command
RELAY_MASTER_LOG_FILE=$(mysql -uroot -p1234 -e 'show slave status \G'| grep 'Relay_Master_Log_File' |cut -d: -f2|tr -d " ")
echo $RELAY_MASTER_LOG_FILE
result
node-bin.000002
(no space before the variable value)
but when I try to execute this command
SET_REPLICATION_PARAMS="MASTER_LOG_FILE='$RELAY_MASTER_LOG_FILE'"
I get this result
MASTER_LOG_FILE=' node-bin.000002'
there is a space before the variable value