Your ZendDBi instance comes with a local mysql pre-installed client which can be run from PASE. You can either use it to manage your server or any other mysql or mariadb client(either remote or local).
The mysql client can either be started from QSH or from an ssh session (recommended). If you connect from ssh you’ll gain access to the full formatting options available in your terminal:
- ssh to your server (as QSECOFR) or start QSH or QP2TERM from your “5250 session”.
- Optionally add the directory /usr/local/mariadb/bin to your path.
- If running from QSH then : export TERM=xterm
- /usr/local/mariadb/bin/mysql (by default 'root' has no password from localhost) .
If you wish to manage mariadb using a remote mysql client or if you configured ZendDBi to use a non-default port/socket then you can use one of the following options:
- /usr/local/mariadb/bin/mysql --socket /usr/local/mariadbdata/mariadb.sock (local)
- /usr/local/mariadb/bin/mysql --host <server_ip> --port <server_port>
Note: ZENDDBI listens on port 3306 and socket /tmp/mysql.sock by default and is open to outside computers. Access from outside is only allowed for users with passwords (GRANT will fail to create users with no password).
If you installed ZendDBi 10 (Mariadb) side by side with a previous mysql then it will listen on a different port (default: 3307) and socket (default: /usr/local/mariadbdata/mariadb.sock) ( according to the installation summary screen). After installation it can also be retrieved from the MY.CNF file (option 20 in the menu).
F.e : /usr/local/mariadb/bin/mysql --socket /usr/local/mariadbdata/mariadb.sock