LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-22-2003, 01:48 PM   #1
markopolox
LQ Newbie
 
Registered: Sep 2003
Posts: 12

Rep: Reputation: 0
I you totally screw up Mysql


I have debian running with mysql php mode_perl apache.
If I want to reset just mysql (getting rid of whatever tables users etc I have created what would I do.

apt-get -remove <package mysql>

Is that enough or should I worry about other config files on the system.

Then all I would have to apt-get install (mysql-server) again correct???

Last edited by markopolox; 09-22-2003 at 02:05 PM.
 
Old 09-22-2003, 02:03 PM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
A bit overkill if you only want to get rid of usersettings/excisting tables etc).

Find the directory that holds these files (among others in that dir):

user.frm
user.MYD
user.MYI

This can be found inside the mysql_install_db file and starts with this:

test -z "$ldata" && ldata=
It's the path behind ldata=

Delete all files in this dir and run the following script (mysql should provide this one):

/opt/mysql/bin/mysql_install_db (path could be different).

This will create a 'fresh mysql'.
 
  


Reply



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
mysql error Can't connect to local MySQL server through socket '/var/lib/mysql/mysql. Dannux Linux - Software 3 03-24-2006 08:44 AM
Looking for help on my screw up. Tink Linux - General 2 03-19-2004 05:55 AM
you know what screw it? unimaginative General 7 01-06-2004 02:28 PM
Did I screw up? Aktionman Slackware 7 11-18-2003 04:33 PM
What to do if I screw up Linux ??? glenn69 Linux - Newbie 1 09-27-2003 06:12 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:44 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
Open Source Consulting | Domain Registration