Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    check_upgrade: "Updating repositories metadata" returned error code 1

    Scheduled Pinned Locked Moved Problems Installing or Upgrading pfSense Software
    68 Posts 16 Posters 7.8k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • stephenw10S
      stephenw10 Netgate Administrator
      last edited by

      Hmm, OK. If you check the available packages now though it shows them?

      Alternatively run at the command line: pkg -d update

      That will show if you have access to the pkg repos and should should you why it's failing if it does.

      P 1 Reply Last reply Reply Quote 1
      • P
        pfpv @stephenw10
        last edited by

        @stephenw10
        I logged in to the GUI again and there was no delay this time. The dashboard update check was relatively fast. I went to System, Package Manager. And it got stuck there without loading anything for longer than I could have expected, for about a minute. Thinking it will not load anything, I opened the Diagnostics, Command Prompt page in a new tab and executed the command you suggested (pkg -d update). The lengthy output is below. It looks like something was not right ("Couldn't find host pkg01-atx.netgate.com in the .netrc file; using defaults" and it tried twice, and "The requested document is not new enough") but in the end it concluded "All repositories are up to date."

        After that I switched to the Package Manager tab and found that the list of the installed packages that wasn't loading before now loaded. I clicked on the "Available Packages" and the list loaded reasonably fast.

        The output of 'pkg -d update':

        DBG(1)[64250]> pkg initialized
        Updating pfSense-core repository catalogue...
        DBG(1)[64250]> PkgRepo: verifying update for pfSense-core
        DBG(1)[64250]> Pkgrepo, begin update of '/var/db/pkg/repos/pfSense-core/db'
        DBG(1)[64250]> Request to fetch pkg+https://pkg.pfsense.org/pfSense_v2_8_0_amd64-core/meta.conf
        DBG(1)[64250]> curl_open
        DBG(1)[64250]> Fetch: fetcher used: pkg+https
        DBG(1)[64250]> curl> fetching https://pkg.pfsense.org/pfSense_v2_8_0_amd64-core/meta.conf
        
        DBG(1)[64250]> CURL> attempting to fetch from , left retry 3
        
        * Couldn't find host pkg01-atx.netgate.com in the .netrc file; using defaults
        * Host pkg01-atx.netgate.com:443 was resolved.
        * IPv6: 2610:160:11:18::209
        * IPv4: 208.123.73.209
        *   Trying 208.123.73.209:443...
        * Connected to pkg01-atx.netgate.com (208.123.73.209) port 443
        * ALPN: curl offers http/1.1
        *  CAfile: none
        *  CApath: /etc/ssl/certs/
        * SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384 / X25519 / RSASSA-PSS
        * ALPN: server accepted http/1.1
        * Server certificate:
        *  subject: CN=*.netgate.com
        *  start date: Apr 10 00:00:00 2025 GMT
        *  expire date: May 11 23:59:59 2026 GMT
        *  subjectAltName: host "pkg01-atx.netgate.com" matched cert's "*.netgate.com"
        *  issuer: C=GB; ST=Greater Manchester; L=Salford; O=Sectigo Limited; CN=Sectigo RSA Domain Validation Secure Server CA
        *  SSL certificate verify ok.
        *   Certificate level 0: Public key type RSA (2048/112 Bits/secBits), signed using sha256WithRSAEncryption
        *   Certificate level 1: Public key type RSA (2048/112 Bits/secBits), signed using sha384WithRSAEncryption
        *   Certificate level 2: Public key type RSA (4096/152 Bits/secBits), signed using sha384WithRSAEncryption
        * using HTTP/1.x
        > GET /pfSense_v2_8_0_amd64-core/meta.conf HTTP/1.1
        Host: pkg01-atx.netgate.com
        User-Agent: pkg/1.21.3
        Accept: */*
        If-Modified-Since: Thu, 22 May 2025 01:27:36 GMT
        
        * Request completely sent off
        < HTTP/1.1 200 OK
        Fetching meta.conf: < Server: nginx
        < Date: Mon, 16 Jun 2025 15:59:53 GMT
        < Content-Type: application/octet-stream
        < Content-Length: 179
        < Last-Modified: Thu, 22 May 2025 01:27:36 GMT
        < Connection: keep-alive
        < ETag: "682e7d88-b3"
        < Strict-Transport-Security: max-age=31536000; preload
        < X-Content-Type-Options: nosniff
        < X-XSS-Protection: 1; mode=block
        < X-Robots-Tag: all
        < X-Download-Options: noopen
        < X-Permitted-Cross-Domain-Policies: none
        < Accept-Ranges: bytes
        <
        * The requested document is not new enough
        * Simulate an HTTP 304 response
        * Closing connection
        
        DBG(1)[64250]> Request to fetch pkg+https://pkg.pfsense.org/pfSense_v2_8_0_amd64-core/data.pkg
        DBG(1)[64250]> curl_open
        DBG(1)[64250]> Fetch: fetcher used: pkg+https
        DBG(1)[64250]> curl> fetching https://pkg.pfsense.org/pfSense_v2_8_0_amd64-core/data.pkg
        
        DBG(1)[64250]> CURL> attempting to fetch from , left retry 3
        
        * Couldn't find host pkg01-atx.netgate.com in the .netrc file; using defaults
        * Hostname pkg01-atx.netgate.com was found in DNS cache
        *   Trying 208.123.73.209:443...
        * Connected to pkg01-atx.netgate.com (208.123.73.209) port 443
        * ALPN: curl offers http/1.1
        *  CAfile: none
        *  CApath: /etc/ssl/certs/
        * SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384 / X25519 / RSASSA-PSS
        * ALPN: server accepted http/1.1
        * Server certificate:
        *  subject: CN=*.netgate.com
        *  start date: Apr 10 00:00:00 2025 GMT
        *  expire date: May 11 23:59:59 2026 GMT
        *  subjectAltName: host "pkg01-atx.netgate.com" matched cert's "*.netgate.com"
        *  issuer: C=GB; ST=Greater Manchester; L=Salford; O=Sectigo Limited; CN=Sectigo RSA Domain Validation Secure Server CA
        *  SSL certificate verify ok.
        *   Certificate level 0: Public key type RSA (2048/112 Bits/secBits), signed using sha256WithRSAEncryption
        *   Certificate level 1: Public key type RSA (2048/112 Bits/secBits), signed using sha384WithRSAEncryption
        *   Certificate level 2: Public key type RSA (4096/152 Bits/secBits), signed using sha384WithRSAEncryption
        * using HTTP/1.x
        > GET /pfSense_v2_8_0_amd64-core/data.pkg HTTP/1.1
        Host: pkg01-atx.netgate.com
        User-Agent: pkg/1.21.3
        Accept: */*
        If-Modified-Since: Thu, 22 May 2025 01:27:36 GMT
        
        * Request completely sent off
        < HTTP/1.1 200 OK
        Fetching data.pkg: < Server: nginx
        < Date: Mon, 16 Jun 2025 15:59:53 GMT
        < Content-Type: application/octet-stream
        < Content-Length: 1623
        < Last-Modified: Thu, 22 May 2025 01:27:36 GMT
        < Connection: keep-alive
        < ETag: "682e7d88-657"
        < Strict-Transport-Security: max-age=31536000; preload
        < X-Content-Type-Options: nosniff
        < X-XSS-Protection: 1; mode=block
        < X-Robots-Tag: all
        < X-Download-Options: noopen
        < X-Permitted-Cross-Domain-Policies: none
        < Accept-Ranges: bytes
        <
        * The requested document is not new enough
        * Simulate an HTTP 304 response
        * Closing connection
        
        pfSense-core repository is up to date.
        Updating pfSense repository catalogue...
        DBG(1)[64250]> PkgRepo: verifying update for pfSense
        Waiting for another process to update repository pfSense
        All repositories are up to date.
        
        1 Reply Last reply Reply Quote 0
        • stephenw10S
          stephenw10 Netgate Administrator
          last edited by

          Hmm, well that's the expected behaviour so perhaps you just hit some temporary connectivity issue somewhere.

          If it fails again re-run that command to see where it's failing.

          P 1 Reply Last reply Reply Quote 1
          • P
            pfpv @stephenw10
            last edited by

            @stephenw10
            This just happened again. I logged in to the GUI (haven't rebooted pfSense for 8 days). The dashboard check took forever. I left it alone for a few minutes. When I returned to the tab the check was finished normally with "no new version". I went to another page in the GUI and noticed that dreaded error at the top of the page. Then I ran 'pkg -d update' and it returned the output similar to what I posted earlier. I went to the package manager and it loaded the list of installed packages fairly quickly. I went to the dashboard and it loaded quickly with "no new version" check.

            It looks like the issue happens after a prolonged time of not checking for updates and on login. Is somebody else having the same issue?

            1 Reply Last reply Reply Quote 0
            • stephenw10S
              stephenw10 Netgate Administrator
              last edited by

              Hmm, so just the alert shown after that? No errors in the system log? Gateway went down?

              1 Reply Last reply Reply Quote 0
              • M
                Marlepou
                last edited by

                Same problem here with a PC Engines APU4.
                No package installed.

                After upgrading from 2.7.2 to 2.8.0, the bell with check_upgrade: "Updating repositories metadata" returned an error code 1

                Doesn't come back after marking as read until next reboot AND click on a menu item.

                And yes,

                • Available Packages can be seen,
                • System update status is "Up to date".
                1 Reply Last reply Reply Quote 0
                • stephenw10S
                  stephenw10 Netgate Administrator
                  last edited by

                  Hmm, and that's repeatable after every reboot?

                  And does it initially show an error in the dashboard widget for updates?

                  DonnyD 1 Reply Last reply Reply Quote 0
                  • DonnyD
                    Donny @stephenw10
                    last edited by stephenw10

                    @stephenw10
                    Hello stephenw10,
                    I’ve been trying to find a way to resolve the issue: check_upgrade: "Updating repositories metadata" returned error code 1
                    an issue that many users seem to be facing, just like me. Unfortunately, I couldn’t solve it through the WebGUI or by accessing the console via option 8 and using commands like pkg -d update, pkg upgrade, or anything similar.

                    So I ended up leaving the notification bell (next to the top menu bar on the dashboard) as it was—showing that error—for about one or two weeks, if I remember correctly. After that, I tried disabling and re-enabling pfBlockerNG-Devel to refresh its database.
                    Then I configured and saved new Traffic Shaper settings. At that point, I manually clicked "X – Close and Mark All as Read" on the bell icon to dismiss all notifications.

                    Later, I rebooted the pfSense system. After logging back in to the dashboard, I noticed that the notification bell no longer showed the message (check_upgrade: "Updating repositories metadata" returned error code 1). not on the Dashboard, nor when navigating through other menu sections like System, Interfaces, Firewall, etc.

                    To be sure, I rebooted the system two or three more times. Normally, I don’t reboot my firewall unless necessary, but this time I wanted to confirm whether the error would return. Surprisingly, the bell notification never came back, and everything has been running smoothly since then.

                    I still don’t know whether this resolution is directly related to pfBlockerNG-Devel, Traffic Shaper, or a combination of both—but somehow, after these actions, the error never appeared again.

                    1 Reply Last reply Reply Quote 0
                    • stephenw10S
                      stephenw10 Netgate Administrator
                      last edited by

                      Hmm, and prior to that the alert was shown after every reboot?

                      DonnyD 1 Reply Last reply Reply Quote 0
                      • DonnyD
                        Donny @stephenw10
                        last edited by

                        @stephenw10 Yes, prior to that, after every reboot, a notification bell would appear showing the alert: check_upgrade: "Updating repositories metadata" returned error code 1. This happened every time.

                        Later, when I clicked “X – Close and Mark All as Read” (without rebooting), the system continued to work normally. However, after rebooting again and logging in to the pfSense Dashboard, the bell notification wouldn't appear initially. It only popped up once I clicked on a menu item—such as System, Interfaces, Firewall, or any other menu—and then the notification would show up immediately. After clicking the bell and selecting “X – Close and Mark All as Read” again, everything continued to work normally. This behavior repeated itself after every reboot.

                        But now, that no longer happens. After every reboot, the bell alert no longer appears, and I can navigate through all menu items without any issues. This change occurred after I disabled and re-enabled pfBlockerNG-Devel and configured the Traffic Shaper.

                        So, I'm not sure whether this behavior is somehow related to setting the maximum bandwidth values on the WAN, LAN, and OPT interfaces that are used in conjunction with the Traffic Shaper.

                        1 Reply Last reply Reply Quote 0
                        • B
                          bigdaddy286
                          last edited by

                          Same problem with APU2C4.
                          Fresh installed 2.8 no packages installed.
                          Also tested 2.7.2 with update to 2.8, always the same message after rebooting.
                          Setting and deleting traffic shaping doesn‘t help.

                          1 Reply Last reply Reply Quote 0
                          • First post
                            Last post
                          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.