Community discussions

MikroTik App
 
igorfranco
just joined
Topic Author
Posts: 2
Joined: Tue Mar 15, 2016 6:06 pm

Assigning a identity/hostname to a MAC address

Tue Mar 15, 2016 6:24 pm

Dear Srs.,
how can I assign a hostname/identity/name to a MAC address device that connects through any way (wireless/cable/hotspot and etc) to the routerboard?

I'd like to see easily some known hostnames that are connected to the mikrotik, instead of MAC address

I have a 951Ui-2hnd

Thanks in advance
Igor
 
User avatar
pukkita
Trainer
Trainer
Posts: 3051
Joined: Wed Dec 04, 2013 11:09 am
Location: Spain

Re: Assigning a identity/hostname to a MAC address

Tue Mar 15, 2016 6:27 pm

Are you using DHCP? Making static entries on DHCP and DNS would help for that.
 
igorfranco
just joined
Topic Author
Posts: 2
Joined: Tue Mar 15, 2016 6:06 pm

Re: Assigning a identity/hostname to a MAC address

Wed Mar 16, 2016 2:44 am

Are you using DHCP? Making static entries on DHCP and DNS would help for that.
Yes I am. I've tried to include some leases, but did not work. I've included "samsung host" and its MAC address, but when I connected, it uses another IP ...
leases.jpg
Am I doing something wrong?
You do not have the required permissions to view the files attached to this post.
 
User avatar
pukkita
Trainer
Trainer
Posts: 3051
Joined: Wed Dec 04, 2013 11:09 am
Location: Spain

Re: Assigning a identity/hostname to a MAC address

Wed Mar 16, 2016 11:45 am

I'm afraid so, mac should be the real host mac...

To make static entries, right click one of those entries (use winbox) and select "Make static". Note the ip address (or set it to whichever you want). Add a comment to the entry, e.g. Samsung S6 Igor.

If you now sort by Status in the DHCP Server > Leases tab, you'll see devices connected, their IPs and the comment so you could instantly identify them.

This is a practical way to have your network setup centralized, while having known, fixed IPs for the devices, and at the same time having the setup minimally "documented".
 
hennotaht
just joined
Posts: 17
Joined: Thu Jan 18, 2018 10:40 pm

Re: Assigning a identity/hostname to a MAC address

Thu Jun 06, 2019 12:06 pm

So far I've been keeping
/ip dhcp-server lease print
 #   ADDRESS                 MAC-ADDRESS        HOST-NAME   SERVER  RATE-LIMIT  STATUS 
 0   ;;; Room 18 wifi router
     192.168.88.20           70:4F:57:A4:B1:AA  TL-WR840N   DHCP1               bound
 1 D 192.168.88.251          30:9C:23:2C:75:B8  POS         DHCP1               bound
output in one window while looking at
/log print
or
/interface wireless registration-table print
output.

But it is super annoying to try to look up hostnames by MAC address just by using eyes and fingers to find the same MAC in the other window. And the more MAC addresses you have in your logs the harder it gets. It has been bugging me from day 1 since I started using Mikrotik products.

But I guess so far it's the best method, right?

Would you like to see the first or the second row in your logs:
11:43:06 wireless,info CC:25:EF:01:36:A7@wlan1: disconnected, group key exchange timeout
11:43:06 wireless,info CC:25:EF:01:36:A7(Johns-iPhone)@wlan1: disconnected, group key exchange timeout
:)
 
McSee
Frequent Visitor
Frequent Visitor
Posts: 84
Joined: Tue Feb 26, 2019 12:49 pm

Re: Assigning a identity/hostname to a MAC address

Thu Jun 06, 2019 4:31 pm

Would you like to see the first or the second row in your logs:
11:43:06 wireless,info CC:25:EF:01:36:A7@wlan1: disconnected, group key exchange timeout
11:43:06 wireless,info CC:25:EF:01:36:A7(Johns-iPhone)@wlan1: disconnected, group key exchange timeout
:)
Maybe something like this would do ?
.
 # INTERFACE    RADIO-NAME       MAC-ADDRESS       AP  SIGNAL-STRENGTH TX-RATE UPTIME              
 0 ;;; iPhone B
   wlan1                       00:6D:52:XX:XX:XX  no  -64dBm@18Mbps   72.2... 3d5h44m34s          
 1 ;;; Asus Y
   wlan1                       38:B1:DB:XX:XX:XX no  -47dBm@1Mbps    14.4... 2d3h26m16s          
 2 ;;; TPAD2 N
   wlan2                       D4:6D:6D:XX:XX:XX no  -53dBm@6Mbps    433.... 6h9m21s             
 3 ;;; Redmi Y
   wlan1                       38:A4:ED:XX:XX:XX no  -42dBm@6Mbps    72.2... 1h41m32s            
 4 ;;; iPhone N
   wlan1                       54:72:4F:XX:XX:XX  no  -66dBm@1Mbps    72.2... 1h3m29s             
 
charliecrash
just joined
Posts: 22
Joined: Tue Nov 13, 2018 4:04 pm
Location: Sweden

Re: Assigning a identity/hostname to a MAC address

Sun Oct 20, 2019 2:05 pm

Hi, and sorry for waking an old thread, but I stumbled on a way to identify every MACaddress, the easy way for dummies.,,

If you use Kid Control , and make one kid named for example: "#Admin/System", you can copy all MACaddresses not belong to any kid in there and give them a comprehensible name.

That way you'll also minimize any "unknown" devices floating around not supposed to be there. Kids are very clever and can lend somebodys spare phone or use vpn on a pc (that creates a new MACaddress) - and you'll have pretty good control over what is what.

At the moment I have 17 devices in admin/system and no unknown devices, oh and 8 kids with more than one device each...besides devices that are for all kids, like xboxes/wiuu/chromecasts and so on...made a special "kid" for those too.

EDIT: And I forgot to say that I don't use the downtime timer on those other "kids" because that would interrupt the whole network, so every weekday hours must be set at "00:00:00-1d 00:00:00"
 
hennotaht
just joined
Posts: 17
Joined: Thu Jan 18, 2018 10:40 pm

Re: Assigning a identity/hostname to a MAC address

Wed Jun 15, 2022 11:57 pm

Would you like to see the first or the second row in your logs:
11:43:06 wireless,info CC:25:EF:01:36:A7@wlan1: disconnected, group key exchange timeout
11:43:06 wireless,info CC:25:EF:01:36:A7(Johns-iPhone)@wlan1: disconnected, group key exchange timeout
:)
Maybe something like this would do ?
.
 # INTERFACE    RADIO-NAME       MAC-ADDRESS       AP  SIGNAL-STRENGTH TX-RATE UPTIME              
 0 ;;; iPhone B
   wlan1                       00:6D:52:XX:XX:XX  no  -64dBm@18Mbps   72.2... 3d5h44m34s          
 1 ;;; Asus Y
   wlan1                       38:B1:DB:XX:XX:XX no  -47dBm@1Mbps    14.4... 2d3h26m16s          
 2 ;;; TPAD2 N
   wlan2                       D4:6D:6D:XX:XX:XX no  -53dBm@6Mbps    433.... 6h9m21s             
 3 ;;; Redmi Y
   wlan1                       38:A4:ED:XX:XX:XX no  -42dBm@6Mbps    72.2... 1h41m32s            
 4 ;;; iPhone N
   wlan1                       54:72:4F:XX:XX:XX  no  -66dBm@1Mbps    72.2... 1h3m29s             
Yes it would, as long as it can be used on public wifi where new devices come and old ones go forever by the hour.

Who is online

Users browsing this forum: No registered users and 116 guests