lazydubuntu icon indicating copy to clipboard operation
lazydubuntu copied to clipboard

Remove Database on delsite

Open itsdarrylnorris opened this issue 10 years ago • 1 comments

Problem:

Went we remove a virtual host by typing sudo delete-website this only remove the files and not the database.

Solution:

We need to find away to remove the database that is connected with this virtual host if is necessary.

itsdarrylnorris avatar Dec 16 '14 06:12 itsdarrylnorris

Here is a great resource that provide you information about removing database http://stackoverflow.com/questions/1082130/how-to-remove-mysql-database

So this patch is going to looks something similar too:

# Login to the MySQL
mysql -u root -p
# This is going to ask for a MySQL credentials

# Removing the database
 drop schema <database_name>; 
 FLUSH PRIVILEGES; 

itsdarrylnorris avatar Jan 16 '15 22:01 itsdarrylnorris