MariaDB server with 80K-100K DataBases
As already stated, the filesystem is the problem.  However, there may be some tuning that would help.
If innodb_file_per_table has been ON, then there are 2*12 files in each database directory.  Turning that OFF would lead to fewer files (but not fewer directories).  This might help some.
SHOW VARIABLES LIKE 'table%';
SHOW VARIABLES LIKE 'innodb%files';
SHOW VARIABLES LIKE 'open%';
SHOW GLOBAL STATUS LIKE 'Opened%';
SHOW GLOBAL STATUS LIKE 'Uptime%';
SHOW GLOBAL STATUS LIKE 'Table%';

There is some info that can be gathered from those outputs.
Or, give me (1) amount of RAM, (2) SHOW VARIABLES;, and (3) SHOW GLOBAL STATUS;.  I will run a number of checks to see if the table_open_cache is too small, and other things.