mysql_db: Fix for #6860, adds error message if socket does not exist

or file is not a socket.