Navigation

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

    Option 82 to DHCP logs? add config to dhcpd.conf via shell without reset?

    DHCP and DNS
    4
    4
    3448
    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.
    • 2
      21hertz last edited by

      Hello!

      I manage a network with Cisco-switches where each the Cisco-switch inserts a DHCP Option 82 with the switch name + port number + VLAN to every DHCP Request made a client.
      The purpose is to keep track where users connect. I have, with success, used this solution together with a standalone ISC DHCP server.
      I'd like to do the same thing in pfSense.

      In the standalone ISC DHCP-server I have this configured:

      if exists agent.circuit-id
      {
      log ( info, concat( "Lease for ", binary-to-ascii (10, 8, ".", leased-address), " is connected to switch ",
      substring( option agent.remote-id, 2, 9999), " port ",
      binary-to-ascii (10, 8, "/", suffix ( option agent.circuit-id, 2)), " via VLAN ",
      binary-to-ascii (10, 16, "", substring( option agent.circuit-id, 2, 2))));
      }
      
      

      Which results in these logs:

      Apr 16 20:01:41 dhcp-1 dhcpd: Lease for 10.1.109.85 is connected to switch CISCO-SWITCH-1 port 1/38 via VLAN 7
      Apr 16 20:01:41 dhcp-1 dhcpd: DHCPREQUEST for 10.1.109.85 from 00:6c:8f:00:6b:31 via 10.1.109.2
      Apr 16 20:01:41 dhcp-1 dhcpd: DHCPACK on 10.1.109.85 to 00:6c:8f:00:6b:31 via 10.1.109.2
      
      

      My questions:

      1. Is it possible to do the same in pfSense DHCP-server via GUI (in the DHCP Option menu)?
      2. If not - can I add configuration via shell, to /var/dhcpd/etc/dhcpd.conf, without it being flushed/reset by pfSense once DHCPD is started again?

      Regards,
      J.

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

        Nice feature ! Have you managed to test on pfSense ?

        Regards,
        Adrian

        1 Reply Last reply Reply Quote 0
        • johnpoz
          johnpoz LAYER 8 Global Moderator last edited by

          That is pretty slick.. Have to look to see if that can be implemented.. But there is currently no place you could put that in the gui in pfsense, it would have to be done on the .conf file which I would think would just get over written if not on restart at min on update to pfsense.

          1 Reply Last reply Reply Quote 0
          • G
            GoldServe last edited by

            I'd like to see this too!

            1 Reply Last reply Reply Quote 0
            • First post
              Last post

            Products

            • Platform Overview
            • TNSR
            • pfSense Plus
            • Appliances

            Services

            • Training
            • Professional Services

            Support

            • Subscription Plans
            • Contact Support
            • Product Lifecycle
            • Documentation

            News

            • Media Coverage
            • Press
            • Events

            Resources

            • Blog
            • FAQ
            • Find a Partner
            • Resource Library
            • Security Information

            Company

            • About Us
            • Careers
            • Partners
            • Contact Us
            • Legal
            Our Mission

            We provide leading-edge network security at a fair price - regardless of organizational size or network sophistication. We believe that an open-source security model offers disruptive pricing along with the agility required to quickly address emerging threats.

            Subscribe to our Newsletter

            Product information, software announcements, and special offers. See our newsletter archive to sign up for future newsletters and to read past announcements.

            © 2021 Rubicon Communications, LLC | Privacy Policy