louislam/uptime-kuma · error · Error

No record matched.

Error message

No record matched. 

What it means

Thrown by the Globalping DNS monitor path when a keyword filter (monitor.keyword) is set and checkDNSRecordValueMatch found no record matching the keyword regex (case-insensitive). The DNS message (pipe-joined answer values, or 'No records found') is appended so you can see what was actually returned.

Source

Thrown at server/monitor-types/globalping.js:342

        let recordMatched = true;

        // keyword
        if (monitor.keyword) {
            recordMatched = this.checkDNSRecordValueMatch(monitor, values, monitor.keyword);
        }

        if (monitor.dns_last_result !== dnsMessage && dnsMessage !== undefined) {
            await redbean.exec("UPDATE `monitor` SET dns_last_result = ? WHERE id = ? ", [dnsMessage, monitor.id]);
        }

        heartbeat.ping = result.timings.total || 0;

        if (!dnsMessage) {
            dnsMessage = `No records found. ${result.statusCodeName}`;
        }

        if (!recordMatched) {
            throw new Error(this.formatResponse(probe, "No record matched. " + dnsMessage));
        }

        heartbeat.msg = this.formatResponse(probe, dnsMessage);
        heartbeat.status = UP;
    }

    /**
     * Handles keyword for HTTP monitors.
     * @param {Monitor} monitor - The monitor object.
     * @param {Array<string>} values - The values to search for.
     * @param {string} keyword - The keyword to search for.
     * @returns {boolean} True if the regex matches, false otherwise.
     */
    checkDNSRecordValueMatch(monitor, values, keyword) {
        const regex = new RegExp(keyword, "i");

        switch (monitor.dns_resolve_type) {
            case "A":

View on GitHub (pinned to 6b5ea01557)

Solutions

  1. Compare the returned dnsMessage against the keyword regex
  2. Confirm dns_resolve_type matches the record family you expect (A vs TXT vs MX)
  3. Loosen or correct the keyword regex; remember it is case-insensitive
  4. If records are genuinely absent, remove the keyword filter or fix the zone

Example fix

// before: keyword expects old IP
monitor.keyword = "203.0.113.5"; // record rotated to 198.51.100.2
// after: match the current value or use a broader regex
monitor.keyword = "198\\.51\\.100\\.";
Defensive patterns

Strategy: validation

Validate before calling

// Validate keyword regex compiles before the monitor runs
if (monitor.keyword) {
    try { new RegExp(monitor.keyword, "i"); } catch {
        throw new Error("DNS keyword is not a valid regex: " + monitor.keyword);
    }
}

Try / catch

if (!recordMatched) {
    throw new Error(this.formatResponse(probe, "No record matched. " + dnsMessage));
}

Prevention

When it happens

Trigger: monitor.keyword is set, result.answers were returned (or empty), and none of the answer values match new RegExp(keyword, 'i'). Also fires when answers is empty because recordMatched stays false and dnsMessage becomes 'No records found'.

Common situations: Keyword regex does not match the actual record values (e.g. expecting an IP that changed), wrong dns_resolve_type so the expected record family is never returned, or the DNS keyword was configured before records existed.

Related errors


AI-assisted analysis of louislam/uptime-kuma@6b5ea01557 (2026-08-12). Data as JSON: /api/errors/fdee910c0ab858c6. Report an issue: GitHub.