⚙️ 4. General Settings

This section covers the main configuration settings, automation via cron jobs, and debugging tools for the JaJuMa Ultimate Image Optimizer for Magento 2. These settings form the foundation for all the performance, UX, and SEO features discussed throughout this documentation.

To begin, navigate to JaJuMa > Ultimate Image Optimizer > General.

Ultimate Image Optimizer - General Configuration

  • Enable Image Optimization

    • Explanation: This is the global master switch for the extension. Setting it to "No" will disable all features.
    • Options: Yes/No.
    • Recommended: Yes.
  • Blacklist

    • Explanation: A powerful tool to exclude specific images or elements from all optimization features. This is useful for problematic images or third-party scripts that should not be modified. You can add a comma-separated list of strings or regular expression (RegEx) patterns to match filenames, paths, or CSS classes.
    • Examples:
      • By filename: logo\.png
      • By path: wysiwyg (excludes all images added via the WYSIWYG editor)
      • By CSS class: product-image-photo
  • Remote Storage Support

    • Explanation: Enable this if your Magento installation uses an external storage solution like Amazon S3. For more details on this Magento feature, refer to the official Adobe Commerce documentation.
    • Options: Yes/No.

4.1 🔍 Media Scan Cron Job Settings

The media scan is the foundation of the optimization process. It crawls your media directories and builds a database of all images eligible for optimization. The conversion cron job then uses this database to know which files to process.
This scan must run regularly to detect new images.

Ultimate Image Optimizer - Scan Media Configuration

  • Enable Image Scan

    • Explanation: Enables the automatic media scan to run via a cron job.
    • Options: Yes/No.
  • Scan Schedule

    • Explanation: Define the frequency of the scan using a cron expression. Running it once a day is typically sufficient.
    • Example: 0 0 * * * (runs daily at midnight). Use this online cron editor for help creating schedules.
  • Included Directories

    • Explanation: Specify which directories the extension should scan. If left empty, the extension will scan all Magento directories.
    • Default: pub/media/
  • Excluded Directories

    • Explanation: Specify directories to skip during the scan using RegEx. It is crucial to exclude the extension's own cache (pub/media/opti_image) to prevent re-optimizing already optimized images.

      💡 Pro Tip: To save server resources, we highly recommend excluding all directories that do not contain front-facing images, such as Magento's original-size product image backups
      (pub\/media\/catalog\/product\/(?=.\/).*).

  • Reset Errors on Scan

    • Explanation: If set to "Yes", any image that previously failed to convert (status "Error") will be reset to "Pending" during the next scan. This gives the conversion cron another chance to process it.
    • Options: Yes/No.

Note: The media scan can also be run manually from the command line or from the
JaJuMa > Image Optimization Status screen.

4.2 ⚙️ Media Optimization Cron Job Settings

This cron job is the engine that performs the actual image conversions. It checks the database for "Pending" images and processes them in batches. This is especially important for the resource-intensive AVIF format.

Ultimate Image Optimizer - Optimization Cron Configuration

  • Enable Conversion Cron Job

    • Explanation: Enables the automatic conversion of images via a cron job.
    • Options: Yes/No.
  • Optimization Schedule

    • Explanation: Define how often the conversion job runs.
    • Example: * * * * * (runs every minute to process pending images quickly).
  • Limit Number of Images

    • Explanation: Controls how many images are processed in a single cron run.
  • Number of Threads

    • Explanation: Controls how many CPU cores are used for conversion. Start with 1 or 2 on a production server to avoid performance issues.
  • Server Load Limit

    • Explanation: A crucial safeguard that prevents the cron from running if the server load is too high.
      The load is calculated as (1 Minute Load Average / Number of CPU Cores).
      A value of 0.7 or 0.8 is a safe choice, ensuring the process only runs when the server has at least 20-30% free resources.

      ⚠️ Warning: It is highly recommended to use the server load limit on production sites to prevent the conversion process from slowing down your store during peak traffic. This option only works if supported by your hosting environment.

4.3 🛠 Debugging and Verification

These tools are invaluable for troubleshooting and confirming your setup is correct.

Ultimate Image Optimizer - Debug Options & Configuration

  • Enable Scan/Convert Images Logger

    • Explanation: When enabled, the extension logs detailed progress and errors to files in the
      var/log/image-optimizer/
      directory. This is the first place to look when troubleshooting.
    • Options: Yes/No.
  • Download Log Files

    • Explanation: Provides direct links to download the scan-images.log and convert-images.log files from the admin panel.
  • Check Configuration

    • Explanation: This is your primary diagnostic tool. Clicking this button opens a popup that validates your extension settings and verifies that the necessary server tools for WebP and AVIF conversion are installed and accessible. Always use this first if you suspect a problem. Check Configuration Popup

📞 Need Help?

Having trouble with the setup? Check our Troubleshooting, FAQ & Best Practices for common solutions.

Still have questions or need help with configuration? Our expert team is here to assist. Please don't hesitate to contact our support team for personalized assistance.


Ready to unlock these features for your store?

The JaJuMa Ultimate Image Optimizer is the all-in-one solution for a faster, higher-ranking Magento store.


Find all you need to know and more valuable insights about Hyvä and Magento.
Expertly curated by JaJuMa:

🚀 Launch the JaJuMa Hyväverse

Your central resource for everything Hyvä.

Explore the Magento Metropolis!

Your central resource for everything Magento.



Do you find all information about us and our services?

thumb-up
thumb-down