Troubleshooting Common Issues

Troubleshooting Common Issues

MySQL is not recognised after successfull installation.

It appears that the MySQL command is not being recognized in your terminal. Let’s troubleshoot this issue:

  1. Check MySQL Installation Path:
    • First, verify the installation path of MySQL. By default, it should be in /usr/local/mysql/bin.
    • Open a terminal and run the following command to navigate to the MySQL bin directory:cd /usr/local/mysql/bin
    • If you see the MySQL binaries (including mysql), you’re in the right place.
  2. Add MySQL to PATH:
    • To make the mysql command accessible globally, add the MySQL bin directory to your system’s PATH.
    • Open your shell profile file (usually .bashrc or .zshrc) using a text editor:nano ~/.bashrc
    • Add the following line at the end of the file:export PATH=$PATH:/usr/local/mysql/bin
    • Save the file and exit the text editor.
    • Restart your terminal or run source ~/.bashrc to apply the changes.
  3. Test MySQL Access:
    • Now try running the mysql command again:mysql -u root -p
    • It will prompt you for the MySQL root password. Enter the password you set during installation.

If you encounter any issues or need further assistance, feel free to ask! 🚀🔧.

1 thought on “Troubleshooting Common Issues

Leave a Reply

Your email address will not be published. Required fields are marked *


Translate »