when i try to run this command “bench set-mariadb-host mariadb” i face error like this:-
Usage: bench frappe [OPTIONS] COMMAND [ARGS]…
Try ‘bench frappe --help’ for help.
It looks like the bench version 5.7.5 does not have the set-mariadb-host option. In addition to trying the options that @revant_one suggests, you may pip3 install frappe-bench --upgrade to bring bench to version 5.7.6 and the set-mariadb-host will be available. pip3 show frappe-bench will show what version bench is intalled.
It depends a lot on where you have been installed bench.
If you are using the frappe_docker solution, it would be easy to answer because all users have bench installed in the same folder: ~/.bench, so the cli.py is at ~/.bench/bench/cli.py.
Anyway, I ordered the solutions from the best to the worst, so the 3rd one is the least recommended. I personally recommend to you the answer that @revant_one provides: bench set-config -g db_host mariadb.