I am trying to set up a LAMP stack to develop a website for a class. I have an PHP website hosted using Apache on localhost. When I try to run mysql, I get this error:
$ mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/run/mysqld/mysqld.sock' (2)
How would I fix this error so that I can create a local database?
inxi in case you need it:
CPU: 8-core AMD Ryzen 7 PRO 4750U with Radeon Graphics (-MT MCP-)
speed/min/max: 1435/1400/1700 MHz Kernel: 6.4.11-arch2-1 x86_64 Up: 1d 20h 12m
Mem: 6.54/14.86 GiB (44.0%) Storage: 476.94 GiB (26.5% used) Procs: 374
Shell: Bash inxi: 3.3.29