In order to create a new database i use Plesk Panel.
I am also using mysql workbench to administer my database instances.
The problem is that when i connect to a database in my server (via workbench) using its unique credentials (database user and passwd) i’m able to see another database instace as well that i have created for another domain in my server via plesk panel.
This second database instance has different credentials from the ones i used to login to the initial database and therefore shouldn’t be visible at all.
Does anyone has a clue of how this can happen?
3
Answers
First of all thanks a lot for your time and answers. The reason behind my problem was the actual name of the database instance I had created, which contained the word "test_".
Every database instance created with this text inside its name was visible to every database user when using mysql workbench.
I know it seems a bit strange but I resolved the issue by just changing the name of the db instance.
Both are likely linked to your account. I’ve used a shared hosting environment (Plesk) before where I could see all the database names on the entire server but without the correct credentials I wasn’t able to access any of them or view their table structure (I found out because I didn’t want others accessing my database).
I would check with your web host for more information.
You don’t connect to a database, but you connect to a server. The user you are connecting with has been given privileges to access db objects according to the domain it belongs to. However, if the user you connected with is allowed to enumerate schemas then you will be able to see all defined schemas (= databases) on this server. That doesn’t mean you can access it. No reason to worry unless you don’t want users to see schemas they have no rights for.
Use the Server Administration section where you can list all users and see what privileges they have for which db object.