Community discussions

MikroTik App
 
juhos
just joined
Topic Author
Posts: 6
Joined: Thu May 28, 2015 3:21 pm

DHCP Server network boot file name vs option 67

Wed Jun 03, 2020 12:36 am

Hi!

I want implement docsis provisioning with mikrotik dhcp server, authenticated with radius.
The radius authentication is ok, i get the file-name in radius reply to "RADIUS_MT_STR1" variable. But.
Noticed that, some modems don't request the option 67, but it needed to start up.
Trided to write static string to the network "Boot File Name" option and it sended, but if configured in options as option 67 it not sended.
This is not sended:
/ip dhcp-server option add code=67 name=bootfile_name value="\$(RADIUS_MT_STR1)"
This sends "$(RADIUS_MT_STR1)" as string to the client, what is wrong too.
/ip dhcp-server network add address=10.10.10.0/24 boot-file-name="\$(RADIUS_MT_STR1)" dhcp-option-set=modem dns-server=1.1.1.1,8.8.8.8 gateway=10.10.10.1 next-server=10.10.10.254
I really need to force send that option, or use the variable in network.

Anyone has any ideas how to get this work?
Thanks.
 
juhos
just joined
Topic Author
Posts: 6
Joined: Thu May 28, 2015 3:21 pm

Re: DHCP Server network boot file name vs option 67

Mon Jun 08, 2020 2:06 am

Nobody? :(
 
User avatar
braveheartleo
newbie
Posts: 45
Joined: Thu Apr 16, 2020 8:10 pm
Location: /dev/console

Re: DHCP Server network boot file name vs option 67

Mon Jun 08, 2020 12:16 pm

Have you tried adding
dhcp-option=bootfile_name
to the relevant /ip dhcp-server network entry? What options consist the modem dhcp-option-set?
 
juhos
just joined
Topic Author
Posts: 6
Joined: Thu May 28, 2015 3:21 pm

Re: DHCP Server network boot file name vs option 67

Mon Jun 08, 2020 5:30 pm

Have you tried adding
dhcp-option=bootfile_name
to the relevant /ip dhcp-server network entry? What options consist the modem dhcp-option-set?
Yes, i added, and when it's requested (typical older modems), it's sended.
 
User avatar
braveheartleo
newbie
Posts: 45
Joined: Thu Apr 16, 2020 8:10 pm
Location: /dev/console

Re: DHCP Server network boot file name vs option 67

Tue Jun 09, 2020 4:17 am

There's no use force sending a dhcp option that the client didn't specifically request. It will be ignored even if it were sent along with the dhcp offer. The best you can do is to modify the client, the modem in this case, so that it specifically requests that option, if that's even possible.

I'm not sure how the boot-file-name option in /ip dhcp-server network can work but not the one in the /ip dhcp-server option when provided via the dhcp-option option, if the boot-file-name dhcp option (code 67) is NOT specifically requested by the client. The two should function just the same, i.e. provide option code 67 to clients that request it. The variable RADIUS_MT_STR1 is only valid under the /ip dhcp-server option scope, so you can't use that inside the network submenu.

If it is the case that the boot-file-name option works, then my suggestion would be to define a fixed boot-file-name that you can supply to that option, and not rely on the variable provided from the radius authentication reply.