A question about mysql database sharing

I install the mysql database on the ubuntu virtual machine of my computer, and then store the data, and then my classmate can access my database and retrieve the data directly on his computer. Please tell me what to do and how to set it up. I haven"t contacted mysql? before.

Mar.03,2021

1. First of all, you two need to be in the same local area network.
2. If your classmate wants to log in with a root account, you need to set up root to allow remote login.
3. Whether ubuntu has enabled the firewall of port 3306.


depends on whether you two are on the same LAN

Menu