After running the command for creating new site
bench new-site test-site
I get below error. I am not sure why it can’t create database. I configured the mariaDB directory as well. Please help. I am desperately stuck for a few days now.
Traceback (most recent call last):
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/commands/site.py”, line 112, in new_site
_new_site(
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/installer.py”, line 83, in _new_site
install_db(
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/installer.py”, line 164, in install_db
setup_database(force, verbose, mariadb_user_host_login_scope)
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/database/init.py”, line 21, in setup_database
return frappe.database.mariadb.setup_db.setup_database(force, verbose, mariadb_user_host_login_scope)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/database/mariadb/setup_db.py”, line 44, in setup_database
dbman.create_database(db_name)
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/database/db_manager.py”, line 28, in create_database
self.db.sql(f"CREATE DATABASE {target}
CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci")
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/apps/frappe/frappe/database/database.py”, line 238, in sql
self._cursor.execute(query, values)
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/cursors.py”, line 153, in execute
result = self._query(query)
^^^^^^^^^^^^^^^^^^
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/cursors.py”, line 322, in _query
conn.query(q)
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/connections.py”, line 563, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/connections.py”, line 825, in _read_query_result
result.read()
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/connections.py”, line 1199, in read
first_packet = self.connection._read_packet()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/connections.py”, line 775, in _read_packet
packet.raise_for_error()
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/protocol.py”, line 219, in raise_for_error
err.raise_mysql_exception(self._data)
File “/Users/girishbudhwani/workspace/girman/experiments/frappe-basics/test/env/lib/python3.11/site-packages/pymysql/err.py”, line 150, in raise_mysql_exception
raise errorclass(errno, errval)
pymysql.err.OperationalError: (1006, ‘Can't create database '_219b32c5b14be7a3' (errno: 2 “No such file or directory”)’)