Results 1 to 3 of 3

Thread: mariadb/mysql -- more informations at first launch

  1. #1
    Join Date
    May 2009
    Location
    Liège Walifornia
    Posts
    393

    Default mariadb/mysql -- more informations at first launch

    Greetings in this 2017 year !!

    I experienced strange things I already had in the past: when mariadb/mysql hasn't been used yet on a system, for example, when you decided to create your first database, as it was the case with my student's computers last friday...

    The mysql.service won't start until you set the correct proprietary user for the folder /usr/lib/mysql.
    You have to chown -R mysql:root /usr/lib/mysql to make it work.

    If this thread could be useful for those still in 13.2.
    I did not yet checked if the settings were correct on my unique 42.1 computer. On my three 13.2 versions, here at home, this folder is set to mysql:root but on all the 13.2 computers in my lab, none of them were correctly set.

    We first did mysql_install_db and tried to set the root password using the advices given by the mysql_install_db output... but never succeeded until I asked the students to READ the output of the systemctl status mysql.service command.
    There the students saw that there was a permission issue.

  2. #2
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    11,446
    Blog Entries
    2

    Default Re: mariadb/mysql -- more informations at first launch

    Nowadays,
    MySQL/Mariadb installs with a script you can run that sets up your initial security called
    Code:
    mysql_secure_installation
    Just run that script, you'll be prompted for all the settings that should be set on first install.

    If you need to set up a large number of instances, or if you want to standardize setups, I describe how you can automatically run and answer the script in a Here Document

    https://en.opensuse.org/User:Tsu2/MySQL_and_Mariadb

    Your steps for changing ownership should not be necessary, and may even be inadvisable.
    To start, just run the following
    Code:
    systemctl start mysql.service
    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

  3. #3
    Join Date
    May 2009
    Location
    Liège Walifornia
    Posts
    393

    Default Re: mariadb/mysql -- more informations at first launch

    thanks... I will try your solution next time.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •