On Wed, Apr 9, 2014 at 2:30 AM, R.P. Ross <[email protected]> wrote:

> I've spent a couple of days trying to figure out how to make smartos zones
> behave with an external DHCP server (pfSense). I'm trying to keep the JSON
> manipulation to a minimum. It seems nothing in the DHCP config sticks
> except
> the IP address. The zone doesn't register a hostname; the gateway, dns
> search and resolvers don't populate; no NTP, etc. I've scoured the wiki,
> github and Google, even Solaris threads, and have come up with nothing
> sustainable on this topic. If the captive DHCP server is the only way, then
> shouldn't there be a config in the global zone that would accommodate
> something like dnsmasq or some local resolution scheme? Looking for
> help/ideas. Thanks. Robert
>


Finally got some time to learning how the smartos vmadm zone creation
mechanism works. Planning to setup a joyent dovecot archive imap vm as a
test.

Anyway, running into a similar issue.

Create a domain with:

[root@00-15-17-20-9d-de ~]# vmadm create -f test-20140423.json

Successfully created VM 7ae12a18-526c-4e48-ab65-c4cd3271f449

[root@00-15-17-20-9d-de ~]# cat test-20140423.json

{

"brand": "joyent",

"image_uuid": "ff86eb8a-a069-11e3-ae0e-4f3c8983a91c",

"alias": "test01",

"hostname": "test01",

"max_physical_memory": 512,

"nics": [

 {

   "nic_tag": "external",

   "ip": "dhcp",

   "vlan_id": "216"

 }

]

}


[root@00-15-17-20-9d-de ~]# vmadm get 7ae12a18-526c-4e48-ab65-c4cd3271f449
| grep resol "resolvers": [],



The DHCP server on "external" is a Windows 2003 Server box.


[root@00-15-17-20-9d-de ~]# zlogin 7ae12a18-526c-4e48-ab65-c4cd3271f449
...


root@test01 ~]# ipadm show-addr

ADDROBJ           TYPE     STATE        ADDR

lo0/v4            static   ok           127.0.0.1/8

net0/?            dhcp     ok           192.168.10.100/24

lo0/v6            static   ok           ::1/128



[root@test01 ~]# netstat -rn


Routing Table: IPv4

 Destination           Gateway           Flags  Ref     Use     Interface

-------------------- -------------------- ----- ----- ---------- ---------

default              192.168.10.1         UG        1          0 net0

127.0.0.1            127.0.0.1            UH        3         22 lo0

192.168.10.0         192.168.10.100       U         2          0 net0



[root@test01 ~]# cat /etc/resolv.conf

search local


So, everything except for the resolver seems to be set correctly from the
dhcp server.  Is this the default action?  Do I need to manually edit
/etc/resolv.conf?


I note that the vmadm man page talks about "maintain_resolvers" and
"resolvers". These seem to imply some manual process of /etc/resolv.conf is
required with ip: dhcp.


Is there a way to get the resolvers setup automatically from dhcp?



Nicholas



-------------------------------------------
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