Is there an equivalence of ($)PGDATA (Postgres) for MySQL?
Not sure if this is what you need, but datadir
points to physical database files:
mysql> show variables like 'datadir';
+---------------+-----------------+
| Variable_name | Value |
+---------------+-----------------+
| datadir | /var/lib/mysql/ |
+---------------+-----------------+
PGDATA contains : Item Description PG_VERSION A file containing the major version number of PostgreSQL base Subdirectory containing per-database subdirectories global Subdirectory containing cluster-wide tables, such as pg_database pg_clog Subdirectory containing transaction commit status data pg_multixact Subdirectory containing multitransaction status data (used for shared row locks) pg_subtrans Subdirectory containing subtransaction status data pg_tblspc Subdirectory containing symbolic links to tablespaces pg_twophase Subdirectory containing state files for prepared transactions pg_xlog Subdirectory containing WAL (Write Ahead Log) files postmaster.opts A file recording the command-line options the postmaster was last started with postmaster.pid A lock file recording the current postmaster PID and shared memory segment ID (not present after postmaster shutdown)