Welcome, Guest. Please login or register.

Author Topic: Update MAC Vendor OUI Database?  (Read 6108 times)

SchmuFoo

  • Jr. Member
  • **
  • Posts: 72
    • View Profile
Update MAC Vendor OUI Database?
« on: November 18, 2019, 11:59:08 am »
Hello,

don't remember anymore how the procedure was to update the MAC Vendor Database?

Update /var/nedi/inc/oui.csv and run /var/nedi/nedi.pl -N oui ?

If yes, some good source avaible for wget an oui.csv?

Thanks,
Jan

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2893
    • View Profile
    • NeDi
Re: Update MAC Vendor OUI Database?
« Reply #1 on: December 03, 2019, 10:01:17 am »
I use this to update the distribution:

wget -O /var/nedi/inc/oui.csv https://standards.ieee.org/develop/regauth/oui/oui.csv
wget -O /var/nedi/inc/mam.csv https://standards.ieee.org/develop/regauth/oui28/mam.csv
wget -O /var/nedi/inc/oui36.csv https://standards.ieee.org/develop/regauth/oui36/oui36.csv
wget -O /var/nedi/inc/iab.csv https://standards.ieee.org/develop/regauth/iab/iab.csv
wget -O /var/nedi/inc/cid.csv https://standards.ieee.org/develop/regauth/cid/cid.csv
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

ascii

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Update MAC Vendor OUI Database?
« Reply #2 on: December 12, 2019, 11:46:14 am »
i tried it but the sql update failed for me
Code: [Select]
$ perl /var/nedi/nedi.pl -v -N oui
DNS :Net::Nslookup not available
CLI :IO-Pty loaded
WEB :LWP-UserAgent loaded
OUI :38299 NIC vendor entries read
DBD::mysql::db do failed: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'L CO.' WHERE mac='448a5b7b506e'' at line 1 at /var/nedi/inc/libdb.pm line 2166.

I'm using NeDi 1.8.100p3

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2893
    • View Profile
    • NeDi
Re: Update MAC Vendor OUI Database?
« Reply #3 on: December 16, 2019, 11:03:03 am »
Umpf, vendors use single quotes and I never encountered it...

Search the function ReadOUIs in libmisc.pm and change:

            $m[2] =~ s/"//g;
to:
            $m[2] =~ s/["']//g;
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

ascii

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Update MAC Vendor OUI Database?
« Reply #4 on: December 17, 2019, 08:24:43 am »
worked like a charm

Code: [Select]
root at krenoc in ~
$ perl /var/nedi/nedi.pl -v -N oui
DNS :Net::Nslookup not available
CLI :IO-Pty loaded
WEB :LWP-UserAgent loaded
OUI :38299 NIC vendor entries read
......
NOUI:Updated 8773 node vendors
END :Took 0 minutes

ghermant

  • Newbie
  • *
  • Posts: 20
    • View Profile
Re: Update MAC Vendor OUI Database?
« Reply #5 on: January 03, 2020, 12:53:56 pm »
Hello,
How to make this OUI update to work with NeDi 1.7?
It seems that the -N option refers to IP or names in 1.7.

[nedi]$ perl /var/nedi/nedi.pl -v -N oui
CLI :IO-Pty loaded
Invalid IP: oui.1.1.1 at /var/nedi/nedi.pl line 192.


Brgds,
Gaël

gpinero

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Update MAC Vendor OUI Database?
« Reply #6 on: January 13, 2020, 08:41:41 am »
Hello,
How to make this OUI update to work with NeDi 1.7?
It seems that the -N option refers to IP or names in 1.7.

[nedi]$ perl /var/nedi/nedi.pl -v -N oui
CLI :IO-Pty loaded
Invalid IP: oui.1.1.1 at /var/nedi/nedi.pl line 192.


Brgds,
Gaël

Same problem with 1.6
/var/nedi# /var/nedi/nedi.pl -N oui
Invalid IP: oui.1.1.1 at /var/nedi/nedi.pl line 193




rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2893
    • View Profile
    • NeDi
Re: Update MAC Vendor OUI Database?
« Reply #7 on: February 05, 2020, 09:00:02 am »
Please update to 1.8 :-)
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

tristanbob

  • Full Member
  • ***
  • Posts: 165
    • View Profile
Re: Update MAC Vendor OUI Database?
« Reply #8 on: June 02, 2020, 06:05:25 pm »
I can confirm this fix also worked for me.  Thanks again, Remo!

Umpf, vendors use single quotes and I never encountered it...

Search the function ReadOUIs in libmisc.pm and change:

            $m[2] =~ s/"//g;
to:
            $m[2] =~ s/["']//g;
Please visit "Other"->"Invoices" on your NeDi installation to make an annual contribution and support Nedi!

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2893
    • View Profile
    • NeDi
Re: Update MAC Vendor OUI Database?
« Reply #9 on: June 18, 2020, 02:01:36 pm »
Just found out that some chinese characters can occur as well. Will be caught in the future...
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

networkbo

  • Newbie
  • *
  • Posts: 29
    • View Profile
Re: Update MAC Vendor OUI Database?
« Reply #10 on: December 01, 2020, 05:22:14 pm »
So there is no way to update list in Nedi 1.7,am I right?

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2893
    • View Profile
    • NeDi
Re: Update MAC Vendor OUI Database?
« Reply #11 on: December 17, 2020, 03:19:10 pm »
Sure is, but make sure your DB version is 1.7p1 (in System-Database click on the eye of the system table). If it's only 1.7 you'll have to download 1.7C and perform the DB update. Then update to 1.8 and 1.9. I'd then recommend you adapt the nedi.conf from 1.9 (you can easily extract it, if you change the pkg to tgz and open the archive with 7zip).
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo