The MDVA-29389 Magento patch fixes the issue where with Advanced Reporting where the
analytics_collect_data cronjob says: " Port must be configured within host parameter (like localhost:3306) ". This patch is available when theQuality Patches Tool (QPT) 1.0.7is installed. The issue is scheduled to be fixed in Magento Commerce 2.4.2.
Affected products and versions
- The patch was designed for Magento Commerce 2.3.4.
- The patch is also compatible with Magento Commerce and Magento Commerce Cloud 2.3.0 - 2.4.1.
Note: the patch might become applicable to other versions with new QPT tool releases. To check if the patch is compatible with your Magento version, run
./vendor/bin/magento-patches status .
Steps to reproduce
- In your Magento instance, enable Advanced Reporting.
- Run the following query to insert analytics/general/token value in the DB:
sql INSERT INTO core_config_data VALUES(NULL,'default',0,'analytics/general/token','ABCDE',now());
- Open your env.php and add port to the host parameter in DB configuration in the following format:
'host' => 'hostname:port',
- Clear cache.
- Execute the
analytics_collect_data job throws an error " Port must be configured within host parameter (like localhost:3306) " when using non-default port to connect to MySQL in env.php.
analytics_collect_data job runs successfully when using default or non-default port to connect to MySQL in env.php.
Apply the patch
For instructions on how to apply an QPT patch, use the following links depending on your Magento product:
- Magento Commerce: DevDocs Apply patches using Quality Patches Tool .
- Magento Commerce Cloud: DevDocs Upgrades and Patches > Apply patches .
To learn more about Quality Patches Tool, refer to:
- Quality Patches Tool released: a new tool to self-serve quality patches .
- Check if patch is available for your Magento issue using Quality Patches Tool .
For info about other patches available in QPT tool, refer to the Patches available in QPT tool section.