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

    [Solved] Ad-Blocking broken after VM Host reboot

    Scheduled Pinned Locked Moved pfBlockerNG
    6 Posts 2 Posters 675 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.
    • provelsP
      provels
      last edited by provels

      Being that I run pfSense in Hyper-V and am subject to required host reboots after various Windows Updates, it seems that ad blocking does not function right after the host and pf are back online. Are the host files waiting to be copied to RAM or waiting for a scheduled update to take effect? It does seem to clear up later but even closing the browser and clearing the DNS cache on a client or the host does not seem to have any effect. Not complaining, only curious. It's a very remarkable package.

      Peder

      MAIN - pfSense+ 24.11-RELEASE - Adlink MXE-5401, i7, 16 GB RAM, 64 GB SSD. 500 GB HDD for SyslogNG
      BACKUP - pfSense+ 23.01-RELEASE - Hyper-V Virtual Machine, Gen 1, 2 v-CPUs, 3 GB RAM, 8GB VHDX (Dynamic)

      BBcan177B 1 Reply Last reply Reply Quote 0
      • BBcan177B
        BBcan177 Moderator @provels
        last edited by

        @provels said in Ad-Blocking after VM Host reboot:

        Being that I run pfSense in Hyper-V and am subject to required host reboots after various Windows Updates, it seems that ad blocking does not function right after the host and pf are back online. Are the host files waiting to be copied to RAM or waiting for a scheduled update to take effect? It does seem to clear up later but even closing the browser and clearing the DNS cache on a client or the host does not seem to have any effect. Not complaining, only curious. It's a very remarkable package.

        Are you using RAMdisks for this VM? If so, then the /var/ folder is wiped on reboots and will require a "Force Reload" to get it all back.
        If not using Ramdisks, what errors do you get? system.log, resolver.log and pfblockerng.log?

        "Experience is something you don't get until just after you need it."

        Website: http://pfBlockerNG.com
        Twitter: @BBcan177  #pfBlockerNG
        Reddit: https://www.reddit.com/r/pfBlockerNG/new/

        provelsP 1 Reply Last reply Reply Quote 0
        • provelsP
          provels @BBcan177
          last edited by

          @BBcan177 Yes, that must be it. Using RAM for /var and /tmp.
          Thanks for a great package!

          Peder

          MAIN - pfSense+ 24.11-RELEASE - Adlink MXE-5401, i7, 16 GB RAM, 64 GB SSD. 500 GB HDD for SyslogNG
          BACKUP - pfSense+ 23.01-RELEASE - Hyper-V Virtual Machine, Gen 1, 2 v-CPUs, 3 GB RAM, 8GB VHDX (Dynamic)

          BBcan177B 1 Reply Last reply Reply Quote 0
          • BBcan177B
            BBcan177 Moderator @provels
            last edited by

            @provels said in Ad-Blocking after VM Host reboot:

            @BBcan177 Yes, that must be it. Using RAM for /var and /tmp.
            Thanks for a great package!

            Thanks for the feedback!
            Disabling Ramdisks will solve that issue. Or just run a "Force Reload - All" after each reboot to get it all back.

            "Experience is something you don't get until just after you need it."

            Website: http://pfBlockerNG.com
            Twitter: @BBcan177  #pfBlockerNG
            Reddit: https://www.reddit.com/r/pfBlockerNG/new/

            provelsP 2 Replies Last reply Reply Quote 0
            • provelsP
              provels @BBcan177
              last edited by

              @BBcan177 Fixed by checkbox, thanks. You have made the package so much more friendly by including default lists. And whitelisting the right ones... I used to use a Windows app called Hostsman which worked fine for the most part but broke many sites, too. And had to be maintained on each machine.
              There are very few times I need to whitelist sites myself with NG. Seeing ads these days makes me want to throw a hammer through my screen! Thanks again for your help.

              Peder

              MAIN - pfSense+ 24.11-RELEASE - Adlink MXE-5401, i7, 16 GB RAM, 64 GB SSD. 500 GB HDD for SyslogNG
              BACKUP - pfSense+ 23.01-RELEASE - Hyper-V Virtual Machine, Gen 1, 2 v-CPUs, 3 GB RAM, 8GB VHDX (Dynamic)

              1 Reply Last reply Reply Quote 0
              • provelsP
                provels @BBcan177
                last edited by provels

                @BBcan177 said in [Solved] Ad-Blocking broken after VM Host reboot:

                @provels said in Ad-Blocking after VM Host reboot:

                @BBcan177 Yes, that must be it. Using RAM for /var and /tmp.
                Thanks for a great package!

                Thanks for the feedback!
                Disabling Ramdisks will solve that issue. Or just run a "Force Reload - All" after each reboot to get it all back.

                Would there be a way to add a script to automate "reload all" post-reboot when using RAM disks? I also use XigmasNAS (was NAS4Free) and they have a GUI option for that (adding pre- and postinit scripts), but I would have no idea how to add that to pfSense. I'm pretty BSDumb. Maybe add

                /usr/local/bin/php /usr/local/www/pfblockerng/pfblockerng.php cron >> /var/log/pfblockerng/pfblockerng.log
                

                somewhere?
                EDIT - Found this. I'll try. https://docs.netgate.com/pfsense/en/latest/development/executing-commands-at-boot-time.html

                Peder

                MAIN - pfSense+ 24.11-RELEASE - Adlink MXE-5401, i7, 16 GB RAM, 64 GB SSD. 500 GB HDD for SyslogNG
                BACKUP - pfSense+ 23.01-RELEASE - Hyper-V Virtual Machine, Gen 1, 2 v-CPUs, 3 GB RAM, 8GB VHDX (Dynamic)

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