MySQL Workbench Manual  /  Installation  /  Command-Line Options

2.2 Command-Line Options

In addition to platform-specific command-line options, MySQL Workbench has the following command-line options:

  • --log-level level: Controls the verbosity level for logging output from Workbench.

    With increasingly levels of verbosity, the valid values for level are: error, warning, info, debug1, debug2, and debug3.

    The location of the generated log files, such as wb.log, are as follows:

    Table 2.1 Default location of generated MySQL Workbench log files

    Platform Default location
    Linux ~/.mysql/workbench/log/
    macOS ~/Library/Application Support/Workbench/log/
    Microsoft Windows C:\Users\user_name\AppData\Roaming\MySQL\Workbench\log\

  • --admin instance: Opens an administration tab to the named connection.

  • --upgrade-mysql-dbs: Opens the Schema Transfer Wizard.

  • --migration: Opens the MySQL Workbench Migration Wizard.

  • --log-to-stderr: Also sends the log to stderr.

  • --version: Shows the MySQL Workbench version number and exits.

  • --verbose, -v: Enables diagnostics output.

  • --query [connection]: Opens a named connection.

  • --model modelfile: Opens the given EER model file.

  • --script script: Opens the given SQL file in a connection, typically used with the --query parameter.

  • --run code: Executes the given code using the default language for GRT shell.

  • --run-python script: Executes the given code in Python.

  • --run-script file: Executes Python code from a file.

  • --open file: Opens the given file at startup. Deprecated, so instead use specific types such as --script or --model.

  • --quit-when-done: Quits MySQL Workbench after --script or --run finishes.