Page 1 of 1
Wo is die Configfile?
Posted: 2006-05-31 09:09
by basetiger
Moin,
ich arbeite gerade an einem mir fremden System. Es ist Cobalt Linux release 6.5.1 (Monterey) installiert. Kann mir jemand sagen wo ich die my.cnf oder wie auch immer sie auf diesem System heißen mag, finden kann?
Oder wie ich herausfinden kann wo die config-file der mysql liegt?
Ich hoffe ihr könnt mir helfen.
Gruss Basetiger
Re: Wo is die Configfile?
Posted: 2006-05-31 09:25
by captaincrunch
alternaiv:
Code: Select all
rpm -ql `rpm -qa|grep mysql` | grep my.cnf
(ungetestet)
Re: Wo is die Configfile?
Posted: 2006-05-31 09:35
by basetiger
Code: Select all
[root admin]# find /etc -name my.cnf
[root admin]# rpm -ql `rpm -qa|grep mysql` | grep my.cnf
rpm: no arguments given for query
wie man sieht sieht man nichts :(
Ich hab ja schon gesucht, aber leider bin ich bis jetzt nirgends fündig geworden.
Re: Wo is die Configfile?
Posted: 2006-05-31 09:51
by captaincrunch
Dann such dir mal per "rpm -qa|grep mysql" das Paket händisch raus, und schau dir dann per "rpm -ql" an, wo das File steckt. Noch genauer geht's dann aber wirklich nicht...
Re: Wo is die Configfile?
Posted: 2006-05-31 10:23
by basetiger
ich glaub ich bin zu blöde
kein Ausgabe
package mysql is not installed
Re: Wo is die Configfile?
Posted: 2006-05-31 10:41
by mattiass
basetiger wrote:ich glaub ich bin zu blöde
kein Ausgabe
Eher:
Re: Wo is die Configfile?
Posted: 2006-05-31 10:45
by Joe User
Code: Select all
find /{etc,home,lib,opt,root,usr,var}/ -name my.cnf
Re: Wo is die Configfile?
Posted: 2006-05-31 11:24
by basetiger
@joe user: das hab ich natürlich schon ausprobiert. ohne erfolg. die file muss einen anderen namen haben
sooo jetzt hab ich nich nur eine config gefunden sondern 4!!!
/usr/share/mysql/my-huge.cnf
/usr/share/mysql/my-large.cnf
/usr/share/mysql/my-medium.cnf
/usr/share/mysql/my-small.cnf
und welche is es nun? *verzweifel*
Re: Wo is die Configfile?
Posted: 2006-05-31 11:34
by mattiass
basetiger wrote:@joe user: das hab ich natürlich schon ausprobiert. ohne erfolg. die file muss einen anderen namen haben
sooo jetzt hab ich nich nur eine config gefunden sondern 4!!!
/usr/share/mysql/my-huge.cnf
/usr/share/mysql/my-large.cnf
/usr/share/mysql/my-medium.cnf
/usr/share/mysql/my-small.cnf
und welche is es nun? *verzweifel*
Schau halt mal rein. :-) Das sollte die Lösung bringen.
Re: Wo is die Configfile?
Posted: 2006-05-31 16:49
by snowball
Es kann ohne weiteres sein, das es diese Datei nicht gibt. Dann werden eben die Standardeinstellungen genommen. Es ist nicht zwingend notwendig eine my.cnf zu haben (auch wenn es sich anbietet).
Re: Wo is die Configfile?
Posted: 2006-06-01 08:13
by basetiger
Wenn ich eine my.cnf erstelle, nimmt er die dann von selbst an oder muss ich ihm das noch irgendwie klar machen?
Gruß BaseTiger
Re: Wo is die Configfile?
Posted: 2006-06-01 08:22
by snowball
basetiger wrote:Wenn ich eine my.cnf erstelle, nimmt er die dann von selbst an oder muss ich ihm das noch irgendwie klar machen?
Das kommt darauf an, wie du die Datenbank installiert hast. Unter normalen Umständen findet er diese automatisch im Verzeichnis /etc oder im Datenverzeichnis deiner Datenbank (z.B. /usr/local/mysql/data). Du kannst den Pfad zu der my.cnf aber auch beim Starten der DB mit übergeben. Dein Startskript sollte dafür einen extra Parameter kennen.
Cheers,
Jochen
Re: Wo is die Configfile?
Posted: 2006-06-01 11:59
by isotopp
basetiger wrote:ich arbeite gerade an einem mir fremden System. Es ist Cobalt Linux release 6.5.1 (Monterey) installiert. Kann mir jemand sagen wo ich die my.cnf oder wie auch immer sie auf diesem System heißen mag, finden kann?
mysqld --help --verbose | less
sagt es Dir:
Code: Select all
Default options are read from the following files in the given order:
/etc/my.cnf /var/lib/mysql/my.cnf ~/.my.cnf
The following groups are read: mysqld server mysqld-4.1
in meinem Suse Linux. Dein Cobalt wird es Dir auch zeigen.
Oder wie ich herausfinden kann wo die config-file der mysql liegt?
Wenn nicht die o.a. Standard-Locations verwendet werden, steht es in der Prozeßliste: "ps axuwww| grep mysql[d]" und dann nach --defaults-file= oder nach --extra- suchen.
Re: Wo is die Configfile?
Posted: 2006-06-12 15:52
by basetiger
Code: Select all
[root /etc]# ps axuwww| grep mysql[d]
root 28277 0.0 0.0 1692 840 pts/1 S 15:22 0:00 sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid
mysql 28314 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28316 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28317 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28318 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28319 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28320 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28321 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28322 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28323 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28324 0.0 0.9 39932 12344 pts/1 S 15:22 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28344 0.0 0.9 39932 12344 pts/1 S 15:23 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28345 0.0 0.9 39932 12344 pts/1 S 15:23 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28366 0.2 0.9 39932 12344 pts/1 S 15:23 0:03 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28407 0.0 0.9 39932 12344 pts/1 S 15:24 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 28758 0.0 0.9 39932 12344 pts/1 S 15:32 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
mysql 29152 0.0 0.9 39932 12344 pts/1 S 15:42 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid --skip-locking
Re: Wo is die Configfile?
Posted: 2006-06-16 16:53
by isotopp
basetiger wrote:Code: Select all
[root /etc]# ps axuwww| grep mysql[d]
root 28277 0.0 0.0 1692 840 pts/1 S 15:22 0:00 sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/lib/mysql/cobalt.cds-ds.com.pid
Es werden also keine Nonstandard-Locations verwendet. Es gelten also die von Deinem mysqld genannten Standard-Locations.