[clarkconnect]Mysql settings resetten

Pagina: 1
Acties:

  • burlapp
  • Registratie: Februari 2004
  • Laatst online: 09-02 21:52
Onder clarkconnect 3.0 (redhat 9) heb ik MySql geinstalleerd. Nu wordt alleen mijn root wachtwoord niet meer herkend. (ik nam aan dat je in moet loggen met root) eerst deed hij het wel, en nu niet meer. Nu had ik nog niet erg veel in de database staan, dus dacht alles opnieuw te gaan installeren.

Maar nu blijkt dat alle instellingen behouden blijven. Hoe wis ik deze, zodat ik met een schone installatie verder kan. Met apt-get remove etc. ben ik al bezig geweest, maar dit mocht niet baten.
Of is er een bestand wat je kan edditen ofzo, zodat je er wel weer in kan?

  • radial
  • Registratie: Augustus 2000
  • Laatst online: 14-02 11:51

radial

Watch out

Deze heb ik eens gevonden om het password te resetten tot nu toe heeft het geholpen.

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
Changing the root password on MySQL
Topic: Database
Posted:2002-01-31 19:30:33
Printer Friendly: 
 
 

Many distributions of Linux have an option to install MySQL. 
In this case, or even if you compile MySQL, the default password is blank. 
MySQL can also run on Windows boxen. When you install MySQL, make sure that
you set the root password. You can do this: 

root@u-1:/home/u-1# mysql -u root mysql
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 1 to server version: 3.23.47

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

mysql> SET PASSWORD FOR root@localhost=PASSWORD('rubberchicken');
Query OK, 0 rows affected (0.06 sec)

mysql> 

 

In this example, we set the root password to rubberchicken. 
Note from the above that the password wasn't set. If we try this again, 
we need to use the -p option to enter the password: 

root@u-1:/home/u-1# mysql -u root mysql
ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)
root@u-1:/home/u-1# mysql -u root -p mysql
Enter password: 
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 3 to server version: 3.23.47

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

mysql> 

 

To reset a root password that you forgot (using paths on our system): 

[root@host root]#killall mysqld
[root@host root]#/usr/libexec/mysqld -Sg --user=root &
[root@host root]# mysql
Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 1 to server version: 3.23.41

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

mysql> USE mysql
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> UPDATE user
    -> SET password=password("newpassword")
    -> WHERE user="root";
Query OK, 2 rows affected (0.04 sec)
Rows matched: 2  Changed: 2  Warnings: 0

mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)

mysql> exit;
[root@host root]#killall mysqld

 

Start MySQL the normal way for your system, and all is good. For Red Hat this is: 

/etc/init.d/mysqld start

20xSF170s - ozo


  • burlapp
  • Registratie: Februari 2004
  • Laatst online: 09-02 21:52
Bij de tweede regel: (nr 52)
[root@host root]#/usr/libexec/mysqld -Sg --user=root &
Gaat het eigenlijk al fout.

De server zegt dat de map onbekend is. Na checken blijkt er idd. ook niet zo'n map te bestaan. Wel /usr/libexec/, maar niks met mysqld daarin. Wel een map webmin, met daarin weer een mysql mapje. Maar ook daar weer geen mysqld....

Weet iemand waar ik voor clarkconnect 3.0 moet zoeken??? Welke map iig.

Of is er een mogelijkheid om de password file, of conig file te wissen? Zodat je opnieuw moet beginnen, en zo ja, waar bevind die zich?

[ Voor 16% gewijzigd door burlapp op 29-01-2005 11:56 ]


  • radial
  • Registratie: Augustus 2000
  • Laatst online: 14-02 11:51

radial

Watch out

het lijkt erop dat mysql niet geinstalleerd is op een of andere wijze. Wat gebeurd er als je doet:
- apt-get clean
- apt-get update
- apt-get install mysql

20xSF170s - ozo