Access denied when creating a New Site

Hello Team

I have successfully done a clean production setup hoping to setup another site, but below is the error i get after command “bench new-site demo1”

Please help with an urgent fix

ubuntu@ip-172-31-57-248:~# bench new-site demo1
MySQL root password:
Traceback (most recent call last):
File “/usr/lib/python2.7/runpy.py”, line 162, in _run_module_as_main
main”, fname, loader, pkg_name)
File “/usr/lib/python2.7/runpy.py”, line 72, in _run_code
exec code in run_globals
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/utils/bench_helper.py”, line 79, in
main()
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/utils/bench_helper.py”, line 16, in main
click.Group(commands=commands)(prog_name=‘bench’)
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py”, line 716, in call
return self.main(*args, **kwargs)
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py”, line 696, in main
rv = self.invoke(ctx)
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py”, line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py”, line 534, in invoke
return callback(*args, **kwargs)
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/commands/site.py”, line 26, in new_site
verbose=verbose, install_apps=install_app, source_sql=source_sql, force=force)
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/commands/site.py”, line 56, in _new_site
admin_password=admin_password, verbose=verbose, source_sql=source_sql,force=force, reinstall=reinstall)
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/installer.py”, line 34, in install_db
create_database_and_user(force, verbose)
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/installer.py”, line 52, in create_database_and_user
if force or (db_name not in dbman.get_database_list()):
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/model/db_schema.py”, line 540, in get_database_list
return [d[0] for d in self.db.sql(“SHOW DATABASES”)]
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/database.py”, line 106, in sql
self.connect()
File “/home/ubuntu/frappe-bench/apps/frappe/frappe/database.py”, line 52, in connect
use_unicode=True, charset=‘utf8’)
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/MySQLdb/init.py”, line 81, in Connect
return Connection(*args, **kwargs)
File “/home/ubuntu/frappe-bench/env/local/lib/python2.7/site-packages/MySQLdb/connections.py”, line 193, in init
super(Connection, self).init(*args, **kwargs2)
_mysql_exceptions.OperationalError: (1045, “Access denied for user ‘root’@‘localhost’ (using password: YES)”)

@EnSeal

seems like you entered the wrong mysql password.
you can check your mysql password in home directory in frappe_passwords.txt

try again