LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-29-2015, 09:09 AM   #1
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Rep: Reputation: Disabled
I am not able to go over mysql_secure_installation


I have the latest stable release of CentOS7, and I installed the latest release of MySQL server from here:

Code:
http://dev.mysql.com/get/ mysql57-community-release-el7-7.noarch.rpm
Everything went as expected, and according to online tutorial, I have to run this:

Code:
# /usr/bin/mysql_secure_installation
Then I get this:

Code:
Securing the MySQL server deployment. 
Enter password for user root: 
Error: Access denied for user 'root@localhost' *(using password: YES)
I tried three options here:

a) Press Enter instead of entering any password
b) Enter the actual password for user root
c) Enter new password

None of these work. I checked /var/log/mysqld.log, and there is no more info about it there. It tells me what i already told me on the screen with no further reasons.

Would you have an idea what can I do about this?

Thanks.
 
Old 10-29-2015, 11:15 AM   #2
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Original Poster
Rep: Reputation: Disabled
CentOS7 comes with MariaDB as default, and I went for installing the MySQL:

Code:
rpm -Uvh http://dev.mysql.com/get/ mysql57-community-release-el7-7.noarch.rpm
Retrieving httpd://dev.mysql.com/get/ mysql57-community-release-el7-7.noarch.rpm
warning: /var/tmp/rpm-tmp.eke8Kn: Header V3 DSA/SHA1 Signature, key ID 0000a0b0: NOKEY
yum install mysql-server
systemctl start mysqld
Since this is the case, maybe I would need to take some additional steps. Or just delete this and go for MariaDB?
 
Old 10-29-2015, 01:07 PM   #3
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Original Poster
Rep: Reputation: Disabled
Would anybody have an idea what I could do here? I've been stuck on this for most of the day now.

I guess I would just reverse what I've done here and simply go for the MariaDB. Would it make sense?

Edit: I've been trying to remove mysql-server and install MariaDB-server and MariaDB-client but I am getting some erros. It is a fresh / clean CentOS 7 installation (latest). I would need to clean up that database mess, and just install the MariaDB, I guess. This is not going through...

Last edited by AdultFoundry; 10-29-2015 at 01:59 PM.
 
Old 10-29-2015, 02:23 PM   #4
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Original Poster
Rep: Reputation: Disabled
Looks like I am getting deeper into s*** here, and could be about to mess something up:

http://stackoverflow.com/questions/3...esh-mariadb-on

Last edited by AdultFoundry; 10-29-2015 at 02:36 PM.
 
Old 10-29-2015, 03:12 PM   #5
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Original Poster
Rep: Reputation: Disabled
/etc/yum.repos.d screenshot

Would you say it is the default, or do I have something added there?

rpm -qa | grep mysql

rpm -qa | grep mariadb - this returns nothing

Last edited by AdultFoundry; 10-29-2015 at 03:13 PM.
 
Old 10-29-2015, 08:10 PM   #6
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.9, Centos 7.3
Posts: 17,347

Rep: Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365Reputation: 2365
MariaDB is the fork of MySQL that RedHat etc have decided to go with as of v7. Its created by the originator of MySQL.
I would stick with that as its in the std repos and will be fully supported/compatible with std RHEL/Centos SW.

I would try:
1. yum remove mysql (might be yum remove mysql-community)
2. Go into the mysql-... repos and set enable=0 or (better) just remove them altogether.
3. yum install mariadb

Worst case scenarion if that doesn't work, given that this is a fresh install, would be to re-install from scratch.

In any case I heavily(!) recommend installing https://wiki.centos.org/PackageManag...Yum/Priorities if you intend to add any other repos on top of the initial install set.
Set the priority values as described BEFORE using extra repos - this even applies to EPEL.
 
Old 10-30-2015, 06:31 AM   #7
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Original Poster
Rep: Reputation: Disabled
I deleted the last two entries from the /etc/yum.repos.d. When I run rpm -qa | grep mysql, I get something like this:

Code:
rpm -qa | grep mysql
mysql-community-libs-5.7.9-1.e17.x86_64
php-mysql-5.4.16-36.e17_1.x86_64
mysql57-community-release-e17-7.noarch
mysql-community-common-5.7.9-1.e17.x86_64
mysql-community-libs-compat-5.7.9-1.e17.x86_64
When I run something like this:

Code:
rpm -e mysql-community-libs-5.7.9-1.e17.x86_64
I get:

Code:
error: package mysql-community-libs-5.7.9-1.e17.x86_64 not installed
So it gets found, but I cant delete it too. I will be trying to find it with something like find -name, or something that would show me the location of the files. I will try to delete it then, I guess. There may be some interdependencies, I am not sure. In general, I kind of bother here, but I am not sure how to get this done. centos.org support forum is good too.

Things like this are not written in the books, and not really on the Internet, and it could be easy to mess something up. I have a fresh / clean install of the latest CentOS on Virtual Box so I can compare anything to that. I dont find any of these packages there, so I guess it needs to be deleted, but nothing works.

Edit:

Something like:

Code:
 
find / -name mysql-community-libs-5.7.9-1.e17.x86_64
returns nothing too.

Last edited by AdultFoundry; 10-30-2015 at 06:39 AM.
 
Old 10-30-2015, 07:10 AM   #8
AdultFoundry
Member
 
Registered: Jun 2015
Posts: 272

Original Poster
Rep: Reputation: Disabled
This seems to be solved now. I've been using e17 instead of el7 ( so it is L7 instead of 17 there, if capital letter would be used).
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
automate mysql_secure_installation pinoyskull Linux - Server 0 08-29-2009 11:50 AM


All times are GMT -5. The time now is 05:04 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration