Reading Magento Open Source logs to diagnose errors

Magento Open Source writes separate logs for exceptions, system events, cron, and support reports. This page explains which file answers which question and how to ship those logs to a central platform.

On this page

Reading Magento Open Source logs to diagnose errors starts with the right file

Each log file answers a different question, so the fastest diagnosis starts by matching the symptom to the file. A storefront error page points to the exception output, a stalled job points to the cron output, and a failed deployment points to the console output of the command that ran. Reading the wrong file wastes time because the most recent lines in a busy store are usually routine noise. Before you open anything, record when the symptom started, which store view, URL or job is affected, and which release is running. Those four facts narrow the file to open and the timestamp to search.

Ad hoc SSH sessions work for one person on one server. A structured log process becomes necessary once several people share responsibility for the store, or once several web and worker nodes serve traffic, because a log on one node says nothing about a request handled by another. Decide who may read production logs, where copies are kept, how long they are retained and who reviews them after an incident. Logs can contain customer data, so access and retention are compliance decisions as well as operations tasks, and they should be agreed before an incident forces the question.

The log locations documented by Adobe apply to self-managed installations, where your team controls the server and the Magento root directory. Cloud-hosted environments handle logs through their own tooling, so confirm log access with the provider before you design a process around it. Check the exact file names for your release in the Adobe documentation, because logging behavior changes between versions. For central collection, Graylog Open ingests syslog, GELF and Beats inputs and rotates indices by time, size or message count, but its SSPL-1.0 license is not OSI-approved, so have legal review it alongside your retention rules. The Graylog index model documentation explains how retention works.

Which Magento log file answers which question

This table compares the Magento logs, support reports and web server logs by the question each one answers, where to find it and when it misleads. Start with the question you need answered, then check the source that fits it. Confirm file paths and rotation settings against your installed version and your server configuration before you write any tooling around them.

Log or outputQuestion it answersWhere to lookWrong place to look when
Exception logWhich uncaught exception was thrown, with its message and stack tracevar/log/exception.log under the Magento rootThe request never reached PHP, such as a proxy 502 or a missing static asset
System logWhich warnings, errors or notices did core code or a module record without stopping the requestvar/log/system.logYou need the full stack trace of a crash, which usually sits in the exception log
Cron outputDid scheduled jobs run, and what did their console output reportThe file the crontab redirects to, plus the cron_schedule tableThe crontab entry never ran as the web user, so check the crontab owner first
Debug logWhat detailed messages were logged while debug logging was enabledvar/log/debug.log, only if debug logging is switched onProduction, where this logging is normally off and the file may be empty or stale
Support reportsWhich report ID a shopper or admin saw on an error page, and the request context captured with itThe report directory under var/report/The failure happened in CLI, cron or a queue consumer, which does not produce a browser report
Web server access and error logsWhich URL returned which status code, and whether the request reached PHP-FPMThe nginx log paths set in your server configurationYou need the Magento-level cause of a 500, which these logs cannot show
PHP-FPM or PHP error logWhether fatal errors or memory limit breaches stopped a PHP processThe error log path set in your PHP-FPM pool or php.iniThe question is about business logic, where the Magento logs hold the detail

How to set up a log reading routine on a self-hosted store

This sequence gives the operations team a repeatable way to go from a reported error to a recorded, verified cause using the Magento Open Source log files on their own servers.

  1. Confirm log paths and file permissions

    The Linux administrator on the store server locates the Magento var/log directory under the installation root and lists the files that matter for the incident: the exception log, the system log, the cron log and the support reports directory. Confirm that the web server and PHP-FPM users can write to these files, and that the operator account used for reading can read them without changing ownership. Owner or group mismatches are a common reason a log stops updating after a deployment or a user change, so check that the newest entries carry the current date before relying on the file. The step is complete when each file has a recorded path, owner, group and a last-modified time that matches recent activity.

  2. Check log rotation coverage before the incident

    Ask the platform team to confirm how logs are rotated on the host, which rotation tool or logrotate configuration applies, how many compressed generations are kept and whether the retention period covers the window in which the error was reported. Look at the oldest archived file in each directory and compare its date with the earliest timestamp the reporter can give. If rotation has already discarded the window, record that gap now, because the investigation will rely on the web server, cron and any centralized copies instead. The step closes with a note stating the earliest timestamp still available for each log source.

  3. Reproduce the error and capture the timestamp

    Ask the person who saw the error to repeat the action on a non-production copy or during a controlled window, noting the exact time, time zone, store view, customer or admin user and the request path. Record the reproduction in a shared ticket so the same steps can be repeated after a fix. Note whether the error is in the storefront, admin, API or a background job, because that choice decides which logs will carry the trace. The step is complete when the ticket holds a time range of at least a few minutes around the event, expressed in the server's time zone.

  4. Correlate the timestamp across application, web and cron logs

    Using the recorded time range, search the Magento exception log and system log first, then open the web server access and error logs for the same minutes to find the request, status code and client address. If the failure happened in a scheduled task, check the cron log and the cron_schedule records for matching job codes and run times. Match entries by time and by any shared identifier such as a request path, job code or order number. Compare what each source shows instead of relying on one file. The step closes when one event chain links at least two sources to the same moment.

  5. Confirm the cause against the code and configuration

    Read the exception stack trace from the matched entry and identify the module, class and method named at the top of the trace. Check whether a recent deployment, extension update, configuration change or upgrade lines up with the first occurrence in the logs, and whether the error repeats on a clean copy with the same configuration. Where the cause is unclear, consult the vendor's documentation or the extension's support channel rather than guessing. The step is complete when the team can state the failing component and the trigger, or lists the specific unknowns that remain.

  6. Record the finding and the evidence location

    Write a short incident record that states the symptom, the time range, the log files and line references used, the failing component, the trigger and the fix or next step. Store copies of the relevant excerpts in the ticket with personal data removed, and note where the full files were archived and for how long. Assign an owner for any follow-up such as a rotation change or a log shipment setup. The step is complete when another engineer can open the record and repeat the search without help from the original investigator.

  7. Decide whether logs need central shipping

    Review the incidents from the last few cycles and note where the team lost time because logs were rotated, spread across several servers or unavailable to the people who needed them. If several nodes write logs locally, or if retention must cover a longer period than the host keeps, plan a central platform that ingests the same files. Graylog Open is one option documented for ingesting logs over inputs such as syslog and Beats, and its retention deletes the oldest indices, so confirm that retention matches your policy before adopting it. The step closes with a documented decision and, if shipping is chosen, a list of log sources and owners.

How to correlate a storefront error across Magento and web server logs

A single failed storefront request usually leaves traces in three places, and the cause sits where they overlap. The nginx access log records the request path, the status code and the time the request arrived. The nginx error log records what the web server saw when PHP-FPM failed, timed out or returned an invalid response. The application writes exceptions to var/log/exception.log and general errors to var/log/system.log. Start from the status code in the access log, note the timestamp, and open the same minute in both Magento logs. Confirm the nginx log paths in your server configuration, and confirm the timezone each service writes in, because a one-hour offset sends you to the wrong lines. The most useful step is matching timestamps and request details together, not timestamps alone.

Matching by time alone is weak on a busy store, so add request details such as the URL, the query string and the customer action (add to cart, checkout or a GraphQL call) to find the matching exception entry. A 500 response with no matching exception usually points to the web server or PHP runtime, such as a timeout or a memory limit, so check those logs before reading Magento code. A 200 response that shows an error message on the page points the other way, toward application logic. If Varnish sits in front of the application, a cached page may never reach PHP, so the absence of an exception proves less than it appears to. Confirm whether your installation caches the failing route before you rule out the application code.

Protecting log data and access in a PCI-scoped store

Magento logs are useful for diagnosis precisely because they record what happened, and that includes customer details, payment-adjacent values and internal paths. The cards below cover what ends up in logs, who can read them, how they are shared with vendors or support teams, and how long they are kept. Each control should be agreed with your compliance and security owners before the store goes live.

Personal and payment-adjacent data in logs

Exception messages and debug output can include customer email addresses, names, addresses, order details and partial payment references, depending on the code path and the extensions installed. Before going live, trigger a few checkout, login and failed-payment scenarios on a staging store and read the resulting files in var/log. Note which fields appear and ask the developers who wrote each custom module or payment integration to confirm what they write. Anything card-related should never appear, so treat any occurrence as a defect to fix.

Stack traces that expose internals

Stack traces reveal file system paths, class names, and in some cases framework and extension versions. That information helps an attacker match a store to known weaknesses, so logs should be treated as internal only. Confirm with your security team whether developer mode or verbose error output is ever enabled on production, and whether any stack traces are copied into tickets, chat channels or vendor portals. Limit who sees the detailed trace and keep the public storefront on generic error pages.

Credentials pasted during troubleshooting

Under pressure, engineers paste database connection strings, API tokens, payment gateway keys or admin session details into tickets and logs while debugging. Ask your team to rotate any credential that has appeared in a log or a shared channel, and to keep secrets in app/etc/env.php or the secret store your organization uses rather than in code or debug statements. Review custom modules for any line that writes request headers or configuration arrays to a log.

Restricting read access to the log directory

The log directory var/log should be readable only by the account that runs PHP-FPM and by named administrators. Confirm the owner and permissions with your system administrator, and check that the web server does not serve var/log or any other directory under var to browsers. Access to the host should follow the same role model used for production servers, and every grant should be reviewed when staff change roles. Ask your hosting provider how host logins and sudo activity are themselves logged.

Redacting values before sharing

Support reports, partner tickets and screenshots often leave the organization, so redact before sending. Remove customer identifiers, payment-adjacent values, tokens, IP addresses where policy requires it, and internal paths that are not needed to reproduce the issue. Replace each value with a consistent placeholder so the sequence of events stays readable. Agree with your vendors which redaction standard they expect and whether they accept excerpts instead of full files.

Retention that matches your policy

Rotated logs and the central log platform each have their own retention, and both need a written setting. Local files grow until they are rotated or removed, so set a rotation and deletion schedule with your operations team. If you ship logs to a central platform such as Graylog, set retention on the index rotation and retention rules, and confirm who approves a change. The period should come from your data retention policy and legal obligations, not from the default configuration of a tool.

How Magento logs flow from the server to a central platform

The flow starts on the store servers, where the web server, the Magento application and cron jobs each write their own log files under the Magento var/log directory and the web server log directory. A log shipping agent reads those files and forwards them across the trust boundary to the central platform, which should accept only authenticated senders and limit who can search the stored logs. Before going live, confirm that the shipper runs as a user that can read the log files, that the transport is encrypted, and that the central platform's access roles match who should see customer and order data.

Store servers forward web, application and cron logs across a trust boundary to a central platform.

Which central log platform fits which team

A single-server store can usually answer most questions from files on the host. Magento writes its exception, system, cron and support reports under the var/log directory of the installation, so the operator reads them directly with standard tools. This option adds no moving parts, but it depends on someone logging in to the server and on the files surviving a rebuild or a disk failure. Log rotation and retention are whatever the host is configured to do, so they need an explicit setting rather than an assumption.

  • Lowest operating load: no extra service, database or license to run.
  • Fast answers for one node: tail and grep on the relevant file usually locate the failing request or cron run.
  • Weak for evidence: logs disappear with the host unless they are copied elsewhere on a schedule.
  • Access control is manual: anyone with shell access can read or edit files that may contain customer data.
  • Does not scale to several nodes: each web or cron server keeps its own files, so correlating a single request means collecting them by hand.

Before you rely on this model, confirm the log rotation settings, the retention period your policy requires and who holds shell access to the server.

What to confirm before you ship Magento logs centrally

Central logging only helps if the log platform, the Magento stack and your budget for storage fit together. The cards below list the checks to finish before you forward Magento exception, system and cron logs to a shared platform, so the first incident does not expose a gap.

Magento and PHP version pairing

Confirm the exact Magento Open Source release and patch level you run, then match the PHP, database, search, cache and nginx versions to Adobe's system requirements for that release. Adobe supports only the listed combinations, and a log shipper or parser that expects one format can break when the stack changes. Record the version in the log pipeline notes so parsing rules are tested against the right release. Your parsing rules for var/log files should be written against this baseline, not against memory of an older install.

System requirements

Search backend version support

If your log platform stores data in OpenSearch, check that the log platform's documented compatibility matrix includes the OpenSearch version you plan to run. Graylog lists supported OpenSearch ranges per Graylog release, and use of OpenSearch 1.x is deprecated there, so a version mismatch can block ingestion or search. Confirm whether you will run Graylog Data Node or self-managed OpenSearch before you size anything. Ask your platform owner who will apply upgrades to the search backend and when.

Compatibility matrix

Daily log volume and retention

Measure how many gigabytes of Magento logs each day reach the platform during normal trading and during peak promotions, then choose retention in days. The Graylog system architecture guidance advises sizing log storage as daily ingest times retention days times 120 percent, and giving the message journal 3 to 5 times daily ingest on SSDs. Exception logs can spike during a broken deployment, so size for that burst, not the average. Ask your security and compliance teams how long they need logs kept before you set the retention value.

System architecture

Alert routing in your edition

Confirm which alerting features your chosen log platform edition includes and whether it can send notifications to the on-call tools your team uses. For Graylog Open, the product page says notifications can go to PagerDuty, Slack and email, while correlation and other advanced features sit in paid tiers. Test an alert end to end, from a sample Magento exception to a page received by the on-call engineer. Check who owns event definitions after launch so alerts do not fall silent when staff change.

Graylog Open product page

Access control and log content

Confirm who may read Magento logs once they leave the server, because exception messages can include request data, customer identifiers or file paths. Check whether your platform supports role-based access, field masking and audit logs for the users who search logs, and whether it requires single sign-on. Decide which fields to drop or mask at ingest so personal data is not copied into a second system without a documented purpose. Record this decision with your data protection owner before the pipeline goes live.

User authentication

Network path and transport security

Map the path each Magento host uses to send logs, including firewall rules, the log shipper or agent, and whether traffic is encrypted between the host and the central platform. Confirm the platform's input types, such as syslog, GELF or Beats, match what your shipper sends. Check that log shipping keeps working after a server is rebuilt or an autoscaling group replaces a node. Assign one owner for the shipper configuration so changes are reviewed with the rest of your deployment code.

Questions teams ask before diagnosing Magento logs in-house

How long does a Magento log investigation take?

The duration depends on how many components are involved and how much history you need to search, so no single figure applies. A failure confined to one exception in the Magento exception log can often be traced in a session, while intermittent errors that span web requests, cron, queue consumers and the database usually take longer because each source must be lined up by timestamp. Ask any provider to split the estimate into log collection, correlation, root cause confirmation and fix verification, and to state what access to production they need to start.

Can our own team read Magento logs without outside help?

Yes, most operations engineers can read the core logs once they know which file answers which question. The skills that take longer to build are correlating events across web nodes, reading stack traces against the installed code version, and recognizing when a symptom comes from a stuck consumer or an indexer backlog rather than the code that logged it. Teams with a clear on-call runbook and access to the store's log directory usually handle routine errors in-house, and bring in outside help for recurring or cross-system failures.

What does a central log platform need from our team?

A central platform needs an owner who can decide retention, access and alerting, plus infrastructure that stays online longer than the store it observes. For Graylog, the vendor's multi-node guide recommends three Graylog and MongoDB nodes with MongoDB as a replica set, three Data Nodes on their own cluster and a load balancer for medium to large deployments. Your team also supplies the log shipping agent or input configuration for each Magento host, field naming rules, and the search backend version that the compatibility matrix lists for your Graylog release.

What drives the cost of a central log platform?

Cost has four parts: infrastructure, storage, licensing and staff time. Storage is the largest variable. The Graylog system architecture page advises sizing log storage as daily ingest times retention days times 120 percent, so doubling retention doubles the storage requirement, and the message journal should get 3 to 5 times daily ingest on SSDs. Licensing depends on the edition: Graylog's pricing page lists Graylog Open as free with no volume limits and community support, while Enterprise and Security editions start at published annual figures tied to processed data. Staff time for setup, parsing rules and alert tuning recurs for as long as the platform runs.

What does the storage sizing formula look like in practice?

Illustrative example: if a store produced 2 GB of logs per day and you kept 30 days of data, the Graylog formula gives 2 GB times 30 times 1.2, or 72 GB of log storage, before adding the message journal sizing. Replace the 2 GB figure with your own measured daily ingest, because Magento log volume depends on debug settings, traffic, extensions and how many hosts ship logs. Measure ingest for at least one normal week and one peak period before you commit to retention.

How should we handle logs that contain personal or payment data?

Treat logs as regulated data when they can hold customer names, email addresses, addresses, IP addresses or payment-related values. Keep card data out of logs entirely, review which extensions write debug output, and restrict who can search the central platform by role. The OpenSearch Security plugin, which Graylog can use for storage, offers role-based access control, field-level security and field masking, and audit logging, so confirm that your chosen backend and Graylog version support the controls you need. Set retention based on your policy, and confirm scope with your compliance team and assessor, since DeployOpen prepares evidence but does not issue audit reports.

Should we send Magento logs to Graylog Open or a paid edition?

Graylog Open suits teams that need inputs, streams, search, dashboards, index rotation and event alerts without a subscription. Its product page lists alert notifications to PagerDuty, Slack and email. The paid editions add capabilities such as archive restore, data tiering, a correlation engine, 24/7 support and SIEM features. Confirm the license terms with the vendor before deployment, because Graylog Open is licensed under the Server Side Public License version 1, which is not an OSI-approved open source license.

What changes in log practice after launch

Once the store is live, logs stop being something you read only when a customer complains and become a signal you watch on a schedule. The first change is alerting: a single exception in the Magento exception log is usually noise, but the same exception repeating across cron runs, checkout requests or consumer processes is a pattern worth an alert. Decide which repeated messages page someone, which go into a daily digest, and which are ignored, and write those rules down before launch rather than during the first incident. Confirm with your monitoring or log platform how it counts repeats and how long it keeps them, since those settings decide whether a slow-building fault is visible at all.

The second change is a log review after every deployment. Compare the exception log, the system log and the cron and support reports against the previous release, looking for new message types, deprecation notices and warnings that a code or configuration change introduced. Check the log locations and rotation settings as part of the same review, because a deployment that changes file ownership or paths can quietly stop writes to the file you rely on. Rotation and retention need their own periodic check: confirm that old files are compressed or removed on schedule, that disk space has headroom, and that shipped copies still arrive.

The third change is the runbook. Each Magento Open Source release line has a published support window, and Adobe's lifecycle policy and release schedule set when regular and security support end for each 2.4.x line. Adobe's released versions page and the 2.4.9 release notes give the current version context, while the system requirements list the PHP, database, search and cache versions Adobe supports for each release. When you move Magento, PHP or any of those components, update the log-reading guide with the new message formats and paths, and confirm the exact support dates for your release with Adobe before you plan the change.

How DeployOpen scopes log diagnosis and central logging

DeployOpen writes the scope before work starts, so the log review, symptom list, shipping setup and runbook are agreed in advance. Each card below is one part of that written scope, and together they set out what a client receives and what it must provide.

Review existing log locations and retention

The first step is an inventory of where the store writes logs today: the Magento var/log directory, the web server and PHP-FPM logs, cron output, and any Supervisor logs for queue consumers. For each source, the review records the owner, the rotation settings and how long the files are kept. Teams should confirm whether logs are kept on the same host as the store, because a host failure or a full disk can remove the evidence needed for an investigation.

Define the symptoms to cover

Diagnosis works best when the list of failures is written down before any shipping is configured. Typical entries include checkout errors, failed payment callbacks, stalled cron jobs, queue backlogs, and 500 responses on the storefront. For each symptom, the scope names the log source expected to show it, the fields needed to find it, and the person who acts on the alert. Clients should review this list against their own incident history.

Configure log shipping and parsing

Shipping moves log lines from the store hosts to a central platform. Graylog Open accepts input over syslog, GELF and Beats, and the scope defines which inputs, parsing rules and stream routing will be used for each Magento log file. The team should decide how request identifiers, store codes and server hostnames are extracted so that a single error can be traced across web nodes. Confirm that shipped logs do not carry card data, customer personal data or credentials.

Graylog Open product page

Build dashboards and alerts

Dashboards and event definitions turn the shipped logs into a working view for the operations team. The scope covers which searches become dashboard panels, which conditions trigger alerts, and which notification channels receive them. Graylog event definitions can run in real time or over historical data, so the scope should state which checks need each mode. Alert thresholds should be tuned during a trial period, and the written scope should say who reviews them.

Size storage and set index retention

Central logging needs a storage plan that matches ingest volume and retention. Graylog's system architecture guidance advises sizing log storage as daily ingest multiplied by retention days and multiplied by 120 percent, and allowing 3 to 5 times daily ingest for the message journal on SSDs. The scope records the daily volume measured on the store, the retention period set by the client's compliance and support needs, and the index rotation and deletion rules. Ask the team to confirm these figures against their own measured traffic.

Graylog architecture guidance

Document the runbook and retainers

The final deliverable is a runbook that maps each symptom to its log source, search query, dashboard and first response step, so that on-call staff can act without the implementation team. The runbook is handed over with the configuration and access notes. For clients that need help after handover, DeployOpen offers retainers for ongoing support, and the scope should state what the retainer covers, such as rule tuning, version updates and incident review. Clients should ask for the runbook format and the support terms in the written quote.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.