Shell xfce4-terminal "cannot execute child process - no such file or directory"

I'm making a syntactic mistake, but I can't figure out what it is. I've tried every combination of delimiter I can think of.
xfce4-terminal -T MARIADB -x '/usr/local/bin/mysql --defaults-file="/usr/local/etc/my.cnf"'

It momentarily opens a terminal, but then closes it complaining that it can't find /usr/local/etc/my.cnf even though it's there and owned by mysql:mysql.
 
The mysql(1) client is started on your account, it doesn't run on the mysql account (only the service does). So I suspect your account can't read /usr/local/etc/my.cnf (640 permissions?).
 
I've tried -e with no change --they seem to be identical in effect, at least for this purpose.

-x /usr/local/bin/mysql --defaults-file="/usr/local/etc/my.cnf" apparently causes the same behavior but without the popup complaint afterwards. I suspect -just a guess- that it's executing the call to mysql and throwing away the --defaults.... as being nonsense as far as the terminal is concerned.

Calling xfce4-terminal -e 'mysql --defaults-file="/usr/local/etc/my.cnf"' appears to work. But in fact it's not reading that config file: it shows me the databases in /var/db, not in /Work/tables which is where dbdir in rc.conf and datadir in the config file point.

I can call /usr/local/libexec/mysqld --defaults.... by hand and THAT will work correctly, but that's the only way I can get the cursëd thing to point to the correct subtree.

Another strange fly in the ointment is that, after calling service start to bring up mysqld, ps | grep mysqld appears to indicate that it has read the correct defaults file. But it hasn't, or has ignored datadir because show databases shows the wrong ones.
 
Back
Top