I had it working also. Here is my config:

/usb/config

admin_nic=00:e8:4c:68:48:57

admin_ip=10.10.0.2

admin_netmask=255.255.255.240

admin_network=

admin_gateway=10.10.0.2

homeVlan_nic=00:e8:4c:68:48:57

homeVlan0_ip=192.168.1.29

homeVlan0_netmask=255.255.255.0

homeVlan0_gateway=192.168.1.254

homeVlan0_vlan_id=100

headnode_default_gateway=none

dns_resolvers=8.8.8.8,8.8.4.4,192.168.1.254

dns_domain=p.net

ntp_hosts=0.smartos.pool.ntp.org

compute_node_ntp_hosts=192.168.1.29

hostname=smartRouter

external_nic=0:e8:4c:68:48:56


opensense json

{

       "brand": "kvm",

       "vcpus": 2,

       "alias": "opnsense router",

       "autoboot": true,

       "vnc_port": 12345,

       "ram": 2048,

       "disks": [{

               "boot": true,

               "model": "virtio",

               "size": 24000

       }],

       "nics": [{

               "nic_tag": "external",

               "model": "virtio",

               "ip": "dhcp",

               "mac": "d4:a9:28:14:e8:98",

               "allow_restricted_traffic": true,

               "allow_ip_spoofing": true,

               "allow_mac_spoofing": true,

               "allow_dhcp_spoofing": true,

               "allow_unfiltered_promisc": true,

               "primary": true

       }, {

               "nic_tag": "admin",

               "model": "virtio",

               "vlan_id": 100,

               "ip": "192.168.1.254",

               "netmask": "255.255.255.0",

               "allow_restricted_traffic": true,

               "allow_ip_spoofing": true,

               "allow_mac_spoofing": true,

               "allow_dhcp_spoofing": true,

               "allow_unfiltered_promisc": true

           }]

}


On Wed, Mar 29, 2017 at 6:17 PM, Nicholas Lee <[email protected]> wrote:

> Odd I thought "allow_dhcp_spoofing" would be enough. Otherwise I think the
> host will filter out the DHCP packets.
>
> This guy seems to have it working that way - http://www.daveeddy.com/2015
> /05/31/smartos-as-a-home-router/.
>
> Nicholas
>
>
>
>
>
> On 30 March 2017 at 08:59, Kevr <[email protected]> wrote:
>
>> Thank you for your reply Nicholas. I had in fact read that article but
>> read that as for running a DHCP server in a zone. What I'm trying to
>> achieve is to get a zone(with only a single vnic at the moment) to obtain a
>> public IP address from my ISP via a dedicated NIC with the nic_tag
>> "external".
>>
>> From the GZ after I update the zone vnic with the "allow_dhcp_spoofing"
>> property:
>> [root@smartos-1 ~]# dladm show-linkprop -z 
>> 5c809072-6baf-6d3c-f5a1-c6b8e4f0ce68
>> -p protection
>> LINK         PROPERTY        PERM VALUE          DEFAULT        POSSIBLE
>> net0         protection           rw        --
>> --                    mac-nospoof,
>>
>>                                       restricted,
>>
>>                                       ip-nospoof,
>>
>>                                       dhcp-nospoof
>>
>> Sorry if the crappy web mail client messes up the formatting.
>>
>> Kevin Ratcliffe
>>
>> Sent from ProtonMail <https://protonmail.ch>
>>
>>
>> -------- Original Message --------
>> Subject: Re: [smartos-discuss] One Public IP Address and DHCP in a Zone
>> Local Time: 29 March 2017 8:00 PM
>> UTC Time: 29 March 2017 19:00
>> From: [email protected]
>> To: SmartOs Discuss <[email protected]>
>>
>> Check out https://wiki.smartos.org/display/DOC/Managing+NICs#Manag
>> ingNICs-DHCPSupport.
>>
>> On 29/03/2017 8:58 AM, "Kevr" <[email protected]> wrote:
>>
>>> Hi
>>>
>>> I am trying to get a public IP via DHCP on a vnic but failing miserably.
>>> My ISP(VirginMedia) supply me with a single IP address. When I remove the
>>> cable from my external interface on my SmartOS host and plug it into my PC
>>> I get a public address. Have I missed something? Should the following just
>>> work?
>>>
>>> [root@smartos-1 ~]# dladm show-phys -m
>>> LINK         SLOT     ADDRESS            INUSE CLIENT
>>> e1000g0      primary  70:71:bc:8f:3c:6c  yes  e1000g0
>>> e1000g3      primary  0:15:17:f0:26:34   yes  e1000g3
>>> [root@smartos-1 ~]# nictagadm list
>>> NAME           MACADDRESS         LINK           TYPE
>>> external       00:15:17:f0:26:34  e1000g3        normal
>>> admin          70:71:bc:8f:3c:6c  e1000g0        normal
>>> [root@smartos-1 ~]# dladm show-vnic
>>> LINK         OVER       SPEED MACADDRESS        MACADDRTYPE VID  ZONE
>>> net0         e1000g3    0     e2:5d:a5:cd:7f:d7 fixed       0
>>> 5c809072-6baf-6d3c-f5a1-c6b8e4f0ce68
>>> [root@smartos-1 ~]# vmadm get 5c809072-6baf-6d3c-f5a1-c6b8e4f0ce68 |
>>> json nics
>>> [
>>>   {
>>>     "interface": "net0",
>>>     "mac": "e2:5d:a5:cd:7f:d7",
>>>     "nic_tag": "external",
>>>     "ip": "dhcp",
>>>     "ips": [
>>>       "dhcp"
>>>     ],
>>>     "primary": true
>>>   }
>>> ]
>>>
>>> Thank you in advance for any help
>>>
>>> Kevin Ratcliffe
>>>
>>> Sent from ProtonMail <https://protonmail.ch>
>>>
>>>
>>>
>>
> *smartos-discuss* | Archives
> <https://www.listbox.com/member/archive/184463/=now>
> <https://www.listbox.com/member/archive/rss/184463/26772761-5af1dc68> |
> Modify
> <https://www.listbox.com/member/?&;>
> Your Subscription <http://www.listbox.com>
>



-- 
Greg

http://www.linkedin.com/in/gregtreantos



-------------------------------------------
smartos-discuss
Archives: https://www.listbox.com/member/archive/184463/=now
RSS Feed: https://www.listbox.com/member/archive/rss/184463/25769125-55cfbc00
Modify Your Subscription: 
https://www.listbox.com/member/?member_id=25769125&id_secret=25769125-7688e9fb
Powered by Listbox: http://www.listbox.com

Reply via email to