Skip to content

Database User Management & Password Configuration in FlyEnv

Managing database users and passwords is a critical part of local development. FlyEnv simplifies this with built-in management tools for all supported databases—no command line required.

Initial Account Passwords

When you first install a database through FlyEnv, default credentials are set for security and convenience:

DatabaseUsernameInitial Password
MySQLrootroot
MariaDBrootroot
PostgreSQLpostgrespostgres
MongoDB-None (no auth by default)

Important: Change default passwords before exposing databases to the network.

Built-in Database Management Interface (MySQL & MariaDB)

FlyEnv now includes a powerful built-in management interface for MySQL and MariaDB—no external tools needed for common operations.

Accessing the Management Interface

  1. Open FlyEnv → MySQL or MariaDB module
  2. Click the "Manage" popover menu
  3. The management interface loads automatically

Database Management Interface

One-Click Database Operations

Create New Database

Quickly create databases without writing SQL:

  1. Click "Create Database" button
  2. Enter database name
  3. Enter database username
  4. Select character set (utf8mb4 recommended)
  5. Click "Save"

Database created instantly—ready for your application.

Create Database Dialog

Reset Root Password

Forgot the root password? Reset it with one click:

  1. Click "Reset Root Password"
  2. Enter new password
  3. Confirm password
  4. Click "Update"

No need to stop the service or edit configuration files manually.

Reset Root Password

Why Use the Built-in Interface?

TaskCommand LineFlyEnv Interface
Create databaseWrite SQL + execute2 clicks
Reset root passwordStop service, edit files, restart1 click
List usersSQL queryAutomatic display
Change user passwordSQL query1 click

Save time: Common operations that used to require multiple commands now take seconds.

External Database Clients

While FlyEnv's built-in interface handles most needs, you may prefer dedicated database clients for complex operations:

ClientPlatformBest For
phpMyAdminWebFamiliar web interface
NavicatWin/MacProfessional features
MySQL WorkbenchAllOfficial MySQL tool
DataGripAllIDE integration
DbGateWebModern web UI
DBeaverAllFree, multi-database

Connecting to FlyEnv Databases

Use these connection settings with external clients:

Host: 127.0.0.1 (or localhost)
Port: 3306 (MySQL/MariaDB)
      5432 (PostgreSQL)
      27017 (MongoDB)
Username: root (MySQL/MariaDB)
          postgres (PostgreSQL)
Password: [Your configured password]

Security Best Practices

Local Development

  1. Change default passwords - Don't use "root" or default credentials
  2. Restrict host access - Use 'localhost' instead of '%' (any host)
  3. Create app-specific users - Don't use root for applications
  4. Regular backups - Export databases before major changes

Before Exposing to Network

If you must expose your database to the network:

  1. Strong passwords - Minimum 16 characters, mixed case, numbers, symbols
  2. Firewall rules - Restrict to specific IP addresses
  3. SSL connections - Enable encrypted connections
  4. Disable root remote access - Create limited-privilege users for remote access

Troubleshooting

"Access denied for user 'root'@'localhost'"

Solution: Use FlyEnv's "Reset Root Password" feature in the Database tab.

"Can't connect to MySQL server"

Check:

  1. MySQL/MariaDB service is running in FlyEnv
  2. Correct port (default 3306)
  3. Firewall not blocking localhost connections

"Unknown database" error

Solution: Create the database first using FlyEnv's built-in interface or your application's migration tool.

Password not working after reset

Solution:

  1. Ensure MySQL/MariaDB service was running during password reset
  2. Try restarting the database service
  3. Check for multiple MySQL installations conflicting

Frequently Asked Questions (FAQ)

Q: Can I use the built-in interface for PostgreSQL or MongoDB? A: Currently, the visual management interface is available for MySQL and MariaDB only. PostgreSQL and MongoDB require external clients or command-line management.

Q: Will resetting the root password affect my existing databases? A: No. Password reset only changes authentication credentials—all your data remains intact.

Q: Can I import existing databases into FlyEnv? A: Yes. Use the external client of your choice to connect to FlyEnv's database and import SQL dumps.

Q: How do I backup my databases? A: Use external clients like DBeaver or command-line tools: mysqldump -u root -p database_name > backup.sql

Q: Can I run multiple database versions simultaneously? A: Yes. FlyEnv supports running different MySQL/MariaDB versions on different ports.

Q: Is the built-in interface secure? A: Yes. It connects through localhost only and respects all MySQL permission systems.

Summary

FlyEnv's built-in database management brings convenience to local development:

  • ✅ One-click database creation
  • ✅ Visual user management
  • ✅ Instant password resets
  • ✅ Privilege management without SQL

For most development tasks, you may never need an external database client again.