Restore old DB with old file

I restore erpnext DB v8.x.x and its files then

bench --site mysite migrate

ERROR
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 11, in
load_entry_point(‘bench’, ‘console_scripts’, ‘bench’)()
File “/home/accounting/bench-repo/bench/cli.py”, line 26, in cli
return frappe_cmd()
File “/home/accounting/bench-repo/bench/cli.py”, line 90, in frappe_cmd
os.execv(f, [f] + [‘-m’, ‘frappe.utils.bench_helper’, ‘frappe’] + sys.argv[1:])
OSError: [Errno 13] Permission denied

It seems bench version is newer than frappe version. any help?

Seems issue with file ownership. Please share the steps that you have performed and also share output of ls -l from frappe-bench

I have backup DB v.8.x.x and a whole folder frappe-bench.

Then I upgraded to V9 successfully.
I want to downgrade to my backup.

First:
I successfully restore DB v.8.x.x (bench --site mysite --force restore backup.sql)
then I replaced my backup folder “frappe-bench” with the current one (V9)

bench --site mysite migrate, and Error happened

erpnextpermission