MAC address keep changing every re-connection to the internet

Hi,

I noticed that every time the client re-connects to the mender server, the mac address which is the one used for identification is changed. I would like to ask which mac address does mender grab? Is it the mac address of the ethernet, or the 4G dongle or the wifi? Which in the code can I change it to always grab the mac address of the 4G dongle?

Thank you!

Kind regards,
Marizonne

Check out the mender-identity file. This contains the code for the MAC Address grabbing.

1 Like

HI,

Thank you for your response. I found the script in the target at /usr/share/mender/identity. I want to edit the mender-device-identity script and commit it but I couldn’t find it in the meta-mender package. I only found something like this in the mender-client.inc:

FILES_${PN} += "\
    ${datadir}/dbus-1/system.d/io.mender.AuthenticationManager.conf \
    ${datadir}/mender/identity \
    ${datadir}/mender/identity/mender-device-identity \
do_install() {
    oe_runmake \
        -C ${B}/src/${GO_IMPORT} \
        V=1 \
        prefix=${D} \
        bindir=${bindir} \
        datadir=${datadir} \
        sysconfdir=${sysconfdir} \
        systemd_unitdir=${systemd_unitdir} \
        install-bin \
        install-identity-scripts \

I tried to search for install-identity-scripts but couldn’t find it.

Please advise. Thank you!

Kind regards,
Marizonne