Hi,
I followed the following tutorial to install osticket: https://docs.osticket.com/en/latest/Getting%20Started/Installation.html

When I arrived to the last step I meet the follow error: Unable to connect to MySQL server: The server requested authentication method unknown to the client. I don't understand if the problem is the hostname (generic localhost) or another thing.

I'm using MySQL 8 and PHP 7.4

Thank you

You are running a newer version of MySQL and apparently they changed the default authentication method. You will have to change your MySQL configuration to support older authentication methods.

Edit your my.cnf and scroll down to the [mysql] section. If this does not exist add this:

[mysqld]
default_authentication_plugin= mysql_native_password

Then run the following command:
FLUSH PRIVILEGES;

Or simply restart your MySQL server service.

    4 months later

    ntozier
    Hi, after following your instructions, I now get the following message when setting up osTicket:

    <Database connection information Unable to connect to MySQL server: Access denied for user 'ostadmin'@'localhost' (using password: YES)>

    Do you have an idea regarding this? Thx Ron 😉

    I looks to me like the DB user that you are using does not have access to that database.

    10 months later

    For me changing the mysql config did not work. I had to create mysql user with a special parameter as so:

    CREATE USER username IDENTIFIED WITH mysql_native_password BY 'my_password';

    After installation I got 500 fatal error but everything seems to be working. mb_strpos was not enlisted in requirements but only in recommended environment, so the error should not be produced.

    [Tue Jan 26 20:20:26 2021] 127.0.0.1:53331 [500]: /setup/install.php - Uncaught Error: Call to undefined function mb_strpos() in /mnt/c/www/support eu v1.15.1/include/class.user.php:970
    Stack trace:
    #0 /mnt/c/www/support eu v1.15.1/include/class.user.php(829): PersonsName::splitName('osTicket Suppor...')
    #1 /mnt/c/www/support eu v1.15.1/include/class.user.php(1031): PersonsName->__construct('osTicket Suppor...', 'original')
    #2 /mnt/c/www/support eu v1.15.1/include/class.user.php(324): UsersName->__construct('osTicket Suppor...')
    #3 /mnt/c/www/support eu v1.15.1/include/class.user.php(450): User->getName()
    #4 /mnt/c/www/support eu v1.15.1/include/class.ticket.php(3979): User->getFilterData()
    #5 /mnt/c/www/support eu v1.15.1/include/class.ticket.php(4349): Ticket::filterTicketData('api', Array, Array, Object(User), true)
    #6 /mnt/c/www/support eu v1.15.1/setup/inc/class.installer.php(312): Ticket::create(Array, Array, 'api', false, false)
    #7 /mnt/c/www/support eu v1.15.1/setup/install.php(52): Installer->install(Array)
    #8 {main}
    thrown in /mnt/c/www/support eu v1.15.1/include/class.user.php on line 970

    Write a Reply...