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

    Service vHosts-http won't start.

    pfSense Packages
    6
    18
    4.2k
    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.
    • A
      aaronouthier
      last edited by

      I installed the vHosts package, and defined an http host on port 80 with an otherwise unused ip address. Yes, outside the dhcp range. I am trying to create a wpad host. I've created a wpad.dat file, and placed it in the correct location. The darn ghost service won't start when I click the start/play button on the services status page, despite the message at the top saying it has started. There are no new log messages created. I have not yet created the dns entry. I am just trying to open the ip address in a web browser. Cannot connect to server.

      Relevant details:
      LAN segment: 192.168.0.0/24; Router address: 192.168.0.1; DHCP pool: 192.168.0.100 - .0.199
      vHost address: 192.168.0.2; Default LAN any to any rule is in place.

      Please help me figure out what I'm doing wrong here, before I create a head-shaped hole in the nearest wall!!

      If you need any more details as to my setup, let me know.

      –Aaron

      1 Reply Last reply Reply Quote 0
      • A
        aaronouthier
        last edited by

        Just logged into ssh server on router. Found the startup command /usr/local/etc/rc.d/vhosts-httpd.sh . running that with a 'start' parameter yields: "Cannot bind to port: 80 Address already in use".

        In use by what??

        1 Reply Last reply Reply Quote 0
        • C
          Cino
          last edited by

          You probably have the pfSense Web GUI blind to port 80 instead of HTTPS. Check System: Advanced: Admin Access

          1 Reply Last reply Reply Quote 0
          • A
            aaronouthier
            last edited by

            Set to https and on port 4438. Has been from the get go. Not finding an lsof command either.

            1 Reply Last reply Reply Quote 0
            • A
              aaronouthier
              last edited by

              /usr/local/etc/rc.d/vhosts.sh start

              (network.c.415) can't bind to port: 192.168.0.2 80 Can't assign requested address
              

              What does this mean?

              1 Reply Last reply Reply Quote 0
              • C
                Cino
                last edited by

                make sure you have 'WebGUI redirect' checked 'Disable webConfigurator redirect rule'

                1 Reply Last reply Reply Quote 0
                • A
                  aaronouthier
                  last edited by

                  It is.

                  Or at least, it was.

                  I ended-up putting back the login page to http, default port, and then moving my wpad file to the main web server folder. I have removed the vHosts package, as it seems to be broken.

                  1 Reply Last reply Reply Quote 0
                  • D
                    doktornotor Banned
                    last edited by

                    @aaronouthier:

                    I have removed the vHosts package, as it seems to be broken.

                    I have a sanitized (and completely untested) vHosts package here: https://github.com/pfsense/pfsense-packages/pull/998

                    Messing with the current one is indeed a complete waste of time. Once the above PR gets merged, perhaps people will be able to test and eventually get it working.  ::)

                    1 Reply Last reply Reply Quote 0
                    • D
                      doktornotor Banned
                      last edited by

                      OK, the PR has been merged. So, if you have a use for this, you can give it another try and report back.

                      1 Reply Last reply Reply Quote 0
                      • T
                        tomekk
                        last edited by

                        It's working fine , please start service under  Status services

                        1 Reply Last reply Reply Quote 0
                        • P
                          Pelle900
                          last edited by

                          For a complete newbie in pfsense, what do I have to do to make vHost work?
                          Is the package I download the usual way in the menu updated and should work or do I have to install something manually?

                          BR

                          Pelle

                          1 Reply Last reply Reply Quote 0
                          • D
                            doktornotor Banned
                            last edited by

                            @Pelle900:

                            For a complete newbie in pfsense, what do I have to do to make vHost work?

                            Install the package and go to Services - vHosts

                            1 Reply Last reply Reply Quote 0
                            • P
                              Pelle900
                              last edited by

                              That gives the same fault as the thread starter reported.

                              I will uninstall vHost and install again and see what happens else I wipe it all clean and begin from the beginning.

                              I'll be back….

                              1 Reply Last reply Reply Quote 0
                              • D
                                doktornotor Banned
                                last edited by

                                Sadly, with any package using its include file referenced in the XML for install routines, you MUST reinstall it twice, or uninstall and reinstall it, otherwise the install code gets cached and the new fixes never applied. Considering the shitty state of original package, indeed wipe it all clean might be a good option if everything else fails.

                                1 Reply Last reply Reply Quote 0
                                • P
                                  Pelle900
                                  last edited by

                                  It works now after reinstalling vHost again. Thanks for the fix of the plugin!

                                  However, I think the text for the IP address in the vHost settings is open for misinterpretation:

                                  "Required. Make sure the IP and Port combination does not conflict with the local system. example: 192.168.0.1"

                                  If you see in the first post the user tried to use a new "virtual" host IP 192.168.0.2 (that is not in use in the PFSense setup) and i believe the user thought that he can create virtual IP-addresses for the web-server with the vHost plugin (the name of the plugin even can lead to an misinterpretation). I was also confused about the text and had to trial and error to understand that the IP address, in fact, should conflict with an already active IP-address as it binds to it.

                                  If I now understand how this plugin works (pfsense-newbie as I am) it binds to an already existing interface and therefore a more proper text for the IP setting box could be:

                                  "The IP address should correspond to any of the active IP addresses that is configured on WAN/LAN/OPT interfaces and will bind to it."

                                  Maybe also the Port text should be altered to leave the IP address statement out of it for the same reason.

                                  1 Reply Last reply Reply Quote 0
                                  • D
                                    doktornotor Banned
                                    last edited by

                                    I don't think the original problem is related to virtual IP in any way. The package was completely broken.

                                    1 Reply Last reply Reply Quote 0
                                    • P
                                      professornayr
                                      last edited by

                                      I installed the vhosts package a couple of years ago and gave up trying to get it to work, so I uninstalled it. However, I still have a service listed under 'Status' -> 'Services' for vhosts-ssl-1. When I reinstall vhosts via the package section, a new service pops up, but I cannot get either to start. Anyone have any idea how I can remove this apparently orphaned service manually?

                                      1 Reply Last reply Reply Quote 0
                                      • D
                                        doktornotor Banned
                                        last edited by

                                        Perhaps install and uninstall the updated rewritten package and see if it helps? Other than that, editing config.xml manually.

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