/etc/rc.d/init.d/mysqld hardcodes datadir - mysql won't load

Mark Mielke mark at mark.mielke.cc
Wed Oct 29 03:21:37 UTC 2003


I have my datadir on a dedicated mysql partition. Every time I update mysql,
I have to change /etc/rc.d/init.d/mysqld to point to my datadir.

Shouldn't it grab datadir from /etc/my.cnf? Why does it hardcode it? Was it
just easier that way?

The symptom is that it tries to 'Initializing MySQL database: ', and then
fails, because /usr/bin/mysql_install_db honours /etc/my.cnf and is able
to determine (I guess?) that there is nothing to do. When init.d/mysqld
continues, $datadir still doesn't exist...

Cheers,
mark

-- 
mark at mielke.cc/markm at ncf.ca/markm at nortelnetworks.com __________________________
.  .  _  ._  . .   .__    .  . ._. .__ .   . . .__  | Neighbourhood Coder
|\/| |_| |_| |/    |_     |\/|  |  |_  |   |/  |_   | 
|  | | | | \ | \   |__ .  |  | .|. |__ |__ | \ |__  | Ottawa, Ontario, Canada

  One ring to rule them all, one ring to find them, one ring to bring them all
                       and in the darkness bind them...

                           http://mark.mielke.cc/





More information about the test mailing list