?
Solved

My SQL wont start (path /etc/rc.d/init.d/mysqld not found)

Posted on 2008-06-25
16
Medium Priority
?
1,531 Views
Last Modified: 2008-09-17
Hello, I have a fresh install of Red Hat 5.2 which I think comes with MySql installed (rpm -qa | grep -i mysql yields ' mysql-5.0.45-7.el5'). mysqladmin -V yields 'mysqladmin  Ver 8.41 Distrib 5.0.45, for redhat-linux-gnu on i686'

Now, I don't seem to have some of the paths I would be expecting.

I have the /usr/bin/my(mysqlshow | mysqladmin | mysql | mysqldump | mysqlimport)
I have /etc/my.cnf

I don't have /etc/rc.d/init.d/mysqld
I don't have the database directory of /var/lib/mysql, actually nothing is here, no socket file, anything...
0
Comment
Question by:AbeSpain
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 7
  • 7
16 Comments
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21864410
   Hi!

Have you looked into the my.cnf file.
The basedir should tell you where the mysqld file is.
mysql.sock is usually in the /tmp folder if not look for the folder
/var/lib/mysql for both mysqld and mysql.sock.

Regards,
   Tomas Helgi
0
 

Author Comment

by:AbeSpain
ID: 21864444
Contents of my.conf

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

I cant find the file mysql.sock if I search for it.
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21864590
Is the mysql.sock in the /var/lib/mysql/ directory ?
go into that directory (using cd :) and execute there
ls -l mysql*

Is the mysql.sock in that list ? Or mysqld ?
If so then most likely the rpm database or locate/find database are not up to date
and that may lead not finding the files you are searching for.

Regards,
   Tomas Helgi
0
Percona Live Europe 2017 | Sep 25 - 27, 2017

The Percona Live Open Source Database Conference Europe 2017 is the premier event for the diverse and active European open source database community, as well as businesses that develop and use open source database software.

 

Author Comment

by:AbeSpain
ID: 21864953
There is no such folder under /var/lib/, so like I originally said, some of the files are on the server but not all of them. Why would this be? Also, how can I fix this install?
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21865282
Then I believe you have to reinstall the mysql server.D
Download the newest rpm's for your Redhat linux and do a rpm -Uhv *.rpm on these files.
That will install/update all the required/missing files.

Regards,
   Tomas Helgi
0
 

Author Comment

by:AbeSpain
ID: 21865814
Cheers Tomas, where do I get the latest rpm's from?
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21866146
Go to
http://rpm.pbone.net/
and choose search and then advanced search
type mysqld (mysql server) in the search box and check Redhat EL5 (in the RHEL row ).
and hit search.

You should get a list of sites that has the package you nead.
For the GUI tools simply type mysqladminstrator (if that is not already included in the mysqld rpm).

Regards,
   Tomas Helgi
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21866193
sorry mysqladmin not mysqladministrator

Regards,
   Tomas Helgi
0
 

Author Comment

by:AbeSpain
ID: 21866949
[root@thedesignfly02 ~]# rpm - i mysql-5.0.45-7.el5.i386.rpm
warning: mysql-5.0.45-7.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 82fd17b2
        package mysql-5.0.45-7.el5 is already installed
        file /usr/bin/my_print_defaults from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysql from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysql_config from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysql_waitpid from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysqladmin from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysqlbinlog from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysqlcheck from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysqldump from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysqlimport from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/bin/mysqlshow from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/lib/mysql/libmysqlclient.so.15.0.0 from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/lib/mysql/libmysqlclient_r.so.15.0.0 from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
        file /usr/lib/mysql/mysqlbug from install of mysql-5.0.45-7.el5 conflicts with file from package mysql-5.0.45-7.el5
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21868204
   Hi!

Use either the command
rpm -Uhv mysql-5.0.45-7.el5.i386.rpm (Updates the previous installed package to newer version and sometimes fixes lost files)
or if that doesn't work use
rpm -i --replacefiles --replacepkgs mysql-5.0.45-7.el5.i386.rpm (which will force reinstallation of the same version of the package)

Regards,
   Tomas Helgi
0
 

Author Comment

by:AbeSpain
ID: 21869087
Tried the first command, says it is already installed.

Second command gave me a key warning but that doesnt stop the process right. Didnt say anything else after that but I can still not see mysqld or the socket.
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21869842
Did you download all the packages I mentioned in the earlier post ?
mysql-5.0.45-7.el5.i386.rpm seems to have only the GUI (admin tools)

Try these links
1) MySQL Server Community version 5.0.51a for Redhat EL 5
http://rpm.pbone.net/index.php3/stat/4/idpl/5796596/com/MySQL-server-community-5.0.51a-0.rhel5.i386.rpm.html
2) MySQL admin and other Client GUI's (same version)
http://rpm.pbone.net/index.php3/stat/4/idpl/5796510/com/MySQL-client-community-5.0.51a-0.rhel5.i386.rpm.html

Try and see if this won't work.

Regards,
   Tomas Helgi
0
 

Author Comment

by:AbeSpain
ID: 21870139
Buh still nothing.
rpm -Uhv MySQL-client-community-5.0.51a-0.rhel5.i386.rpm
        package MySQL-client-community-5.0.51a-0.rhel5 is already installed
        file /usr/bin/mysql from install of MySQL-client-community-5.0.51a-0.rhel5 conflicts with file from package mysql-5.0.45-7.el5

///
rpm -Uhv MySQL-server-community-5.0.51a-0.rhel5.i386.rpm
error: Failed dependencies:
        libmysqlclient.so.15 is needed by (installed) dovecot-1.0.7-2.el5.i386
        libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) dovecot-1.0.7-2.el5.i386

The other method doesnt work either (rpm -i --replacefiles --replacepkgs)
0
 

Author Comment

by:AbeSpain
ID: 21998806
I compile from source in the end after reinstalling. In this case, what does one do about point assigning? I haven't used the solution although the help has been appreciated and probably helped.
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 22507453
PAQed with points refunded (500)

Computer101
EE Admin
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Containers like Docker and Rocket are getting more popular every day. In my conversations with customers, they consistently ask what containers are and how they can use them in their environment. If you’re as curious as most people, read on. . .
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question