Mysql (MariaDB) connect with https://www.phpmyadmin.co - mysql

I would like to manage my database with https://www.phpmyadmin.co. But it doesn't want to bind. After like 20 Seconds there comes an errror.
error picture
I can use it for my minecraft plugins with localhost. Here are my setup commands:
CREATE DATABASE data;
CREATE USER 'myuser'#localhost IDENTIFIED BY 'userpsw432';
GRANT ALL PRIVILEGES ON data.* TO 'myuser'#localhost;
I think it has something to do with #localhost but I'm not that familiar with linux yet.
Thanks for helping!

That phpmyadmin.co thing is a web service, running on some server on the net someplace, that connects to its users' databases and serves as a phpmyadmin database client.
To use it your database must be on the network and not firewalled, and you must give it your machine's public internet address.
localhost isn't a public address, though. I suspect your localhost database server is not accessible that way.
You probably need some substitute for phpmyadmin that you can run locally. HeidiSql? MySql Workbench? SquirrelSQL?

Related

Connecting to a remote mySql server from my local machine

My main problem right now is that I can't connect to the remote mysql server while developing on my machine. I'm trying to update a website that was previously developed by someone I do not know. I've been editing the site on my local machine but I need to access data from the mysql database that it has been using. I have the username and password that the site uses to connect to the mysql server. I can connect to it through phpmyadmin but I would like to work locally without publishing my edits to the server.
I found this here in SO and I tried running the scripts in phpmyadmin using my pc's IPaddress but I keep getting
Access denied for user 'username'#'localhost' (using password: YES)
even though I'm 100% sure I'm using the password that I used to login to phpmyadmin. I tried creating a new user but the login I'm using doesn't seem to have a Create User privilege either.
I understand that the previous developer might have a different "admin" account that has all the privileges but I have no way of knowing either.
I am a C# developer but I'm really new to MySql. Any help is greatly appreciated.
This may be a firewall issue. phpmyadmin listens on port 80 by default, but mySQL listens on port 3306. Please check the firewalls on your local PC (to make sure you can get out on 3306) and the server (to make sure you can get in on 3306).

How to connect Power BI Desktop to remote MySql server that requires authentication

I have a MySql database running on a remote server which requires ssh authentication that I need to connect to with Microsoft Power BI. I can easily connect to MySQL on my localhost machine, but cannot find a way to manage both the server ssh authentication and the database user log on information.
The server requires authentication on port 22 with a username and password and the MySQL database requires a different username and password.
Can anyone offer assistance?
It seems possible to connect remotely, though I'm not sure you can do it through an 'SSH tunnel' on port 22.
There's a discussion here about connecting remotely which sounds to me like a connection to the usual port 3306, though I'm not certain:
https://community.powerbi.com/t5/Integrations-with-Files-and/Cannot-Connect-to-MySQL-on-Linux-VM/td-p/94914
Some common pitfalls:
1) Make sure you download the correct version of MySQL/Net connector. As of now, version 6.6.5 seems to be working. I wasted a lot of time trying to figure out what was wrong with earlier versions.
2) Server & database settings: closed ports / user permissions / bind-address
Before connecting PowerBI, try to connect another utility like MySQL Workbench. This will force you to troubleshoot the above settings.
This is not currently possible with PowerBI. The feature is currently under review, and you can help get it prioritized by upvoting here:
https://ideas.powerbi.com/forums/265200-power-bi-ideas/suggestions/7020353-mysql-over-ssh-connection
I don't think it is supported (yet) but it looks like a lot of people want a solution including me. See this Power BI Ideas Request
1) create gateway to connect server then
2) then it will ask connection string their you can give server port and database username and password
The problem turned out to be an error in the remote servers firewall configuration.
After further research I have confirmed that Power BI would not support dual authentication steps like logging onto a remote server with ssh and then connecting to the database. Thanks Robin for your suggestion. That was a key point.
Please remember that for remote connections you need to authorise the mysql users to connect from specific hosts (adding the IP) or % to allow to get connected from any host remotely
the SQL is something similar to:
GRANT ALL PRIVILEGES ON *.* TO 'root'#'%' IDENTIFIED BY 'password' WITH GRANT OPTION;
FLUSH PRIVILEGES;
How to allow remote connection to mysql

Connect to database using Workbench

I have a database on my server and I want to connect to it through MySql Workbench, I entered my HostName, Username, Password, When I click Test Connection I get this Error Message:
Failed to Connect to MYSQL at **.**.***.**:3306 with user root.
Host '**.171.199.66' is not allowed to connect to this MySQL server
I am 100% sure my Hostname, username and Password are correct, I did some research and from what I managed to find out that I have to actually permit an access from my IP address to the database before I can connect.....if this is correct could someone explain to me how to give myself e permission to connect to my database on server.
It is likely that your MySql root account is configured to not accept remote root logins (its a default). If you are trying to connect from anywhere but localhost its not going to allow it. Your're right you need to permit access for your IP. You need to do it from within the server your MySql is installed on. In case of if you have managed hosting, your hosting company should provide you with a tool like phpMyAdmin or such, to manage your MySql. If it is your own installation, you can connect to mysql server instance from the console and go from there.
Check out another stackoverflow post:
Here is what you should be looking for in phpMyAdmin:
Keep in mind it might look a bit different depending on the phpMyAdmin Version.

Can't connect to MySQL database hosted in CloudBees

I have a free CloudBees account and created a free ClearDB database using their wizards. My trouble is when I use their connection information (whether I try to connect from my Java app, or an outside tool - SQLyog to be exact) I take the error: Access denied for user 'b51dbc5757d79f'#'%' to database 'mywiki.
The username provided by CloudBees does not contain those extra characters that the error message is displaying which seems like it would be a problem, but I'm not sure there is anything I can do about that since everything is configured for me. The username I am given is: b51dbc5757d79f - which I can delete and rebuild after sharing here :)
To diagnosis this best way is to be sure you use the right username and password when you connect through a MySQL client like MySQLWorkbench. For that you can use the CloudBees SDK and to use the db:info command.
bees db:info -p DATABASE_NAME
Be sure you don't have any firewall or proxy in the middle of the connection.

Can't Connect to MySQL instance Remotely that is running on EC2 Instance (Not RDS)

I have seen a lot of posts that claim they are running an RDS instance of MySql in which they cannot connect to, but I am not running RDS.
I used my EC2 insance to host my wordpress blog which was installed using the Web Platform Installer.
This setup the wordpress schema and data that I needed and I have been running it for a couple years.
I want to be able to access this database remotely instead of only logging into my server.
I have checked and have the following users
root
wpadmin
I have also verified that the port specified in the mysql config is the standard 3306 and I have setup an Inbound Firewall rule to allow 3306 through.
When I try to connect from MySql Workbench, I get the following error message:
Number 3 Is particularly one that I do not know how to check, but I do know that MySql is running and that it is running on 3306. Additionally, I know I am using the correct password.
When I try to connect, the prompt looks like this. Do I need to do something to grant Mysql user permissions or anything?
Based on your GRANT information, you have at least the problem of root user only having access privileges from localhost. You would need to create a root#% user (or a more specific host/IP instead of % if you have a reliable address). That would allow external access so long as your EC2 security group also allow access on port 3306 (either globally or to a more restrictive IP address or IP range).
Of course the security implication here is that you are opening up access to MySQL that you might not want to make more accessbile to potential attackers. For this reason, I would recommend you access your DB via SSH tunnel, which is supported by MySQL workbench. This will in essence allow you to shell into the host your your access key and then access as root#localhost.