Using Wild Cards

Hello. I’m relatively new to RouterOs. Getting a deep dive quickly. Is there a guide or general information on using wildcards in router OS?

For example, I would like to search for MAC address in DHCP Server using omitting the last octet. Can wildcards be used in this following MAC Address in place of the last octet?

/ip dhcp-server lease print where mac-address =48:A9:8A:42:5F:CE

/ip dhcp-server lease print where mac-address =48:A9:8A:42:5F:**

Thanks in advance

In WINBOX go to IP…DHCP Server…Leases and you will see your list of MAC addresses for the DHCP along with the clients attaached to that DHCP Server

In Terminal type “/ip dhcp-server lease print” that will display what you are looking to accomplish, as I understand what you are wanting to see.

Thanks!
Yes, that is what I want to see, however I have hundreds of MACs per DHCP server and want to see if I can use Wildcards in place of the last octet for the MAC address in that terminal command.

Have you tried it yet? If so what command did you use?

use the ~ operator

example

ip dhcp-server lease print where mac-address ~“:11”

will show any mac’s that have “:11” in it, in any position

Try this to see if it does what you want.

In WINBOX go to IP…DHCP Server…Leases
There is a “FIND” window in the top right.

Enter your wildcard string in that line and see if that will work for you.
dhcp.JPG

Thank you @blingblouw2. That is what I am looking for.

Did it solve your problem completly? If so please mark “Solved”