Can't register Gateway - EUI is still in use

Sorry, no.

Thank you for your help borroz.
I can’t keep going on my work, just because of my problem with the gateway eui id and new account… :frowning_face: and now it’s weekend and i would have a lot of time for it, but without gateway i can’t keep working on my project.
Is there someone who can delete my gateway out of the old account?

Thank you so much for your help borroz :muscle:t3:

I think you can change your MAC address
https://en.wikibooks.org/wiki/Changing_Your_MAC_Address/Linux

1 Like

Though quite commonly used indeed, there is no longer an officially supported way to convert an 48 bits MAC-address into an official EUI64. Also, the new MAC-address could already be in use, or belong to a future gateway, especially when based on the same hardware and when only making minor changes to the unique factory MAC-address.

While the chances for collisions within TTN might be very low, it might also be easier to use an officially supported random EUI64 instead, and change the gateway’s code (or configuration?) to use that value.

So the lesson we can learn is : before you delete your TTN account and start a new one , first delete all devices and gateways, because afterwards it’s, without TTN editing in a database, impossible to use these again ??

I don’t think that helps:

1 Like

Thank you for the lesson, borroz.
But that was my problem and why i deleted my account.
I had a few applications, which i could not delete and i deleted my gateway before i delete my account. :sweat:

uhhhhhhhhhhhhh … :sunglasses:

so how do you change (spoof) your mac adress in a RPI ?
https://www.raspberrypi.org/forums/viewtopic.php?t=171534

yes I understand your problem… very normal, really hope they can help you soon.

1 Like

thank you for your help arjanvanb.

Sounds good, but where can i change the configuration of my gateway/the gateway’s code?

I installed the gateway with this tutorial -> http://www.technoblogy.com/show?1XKI
Last time i registered my gateway in the console on ttn it works with this tutorial, but now the problem with the already existing eui-id.

So how can i change now the gateway’s code?

Sorry, i’m a completely newbie and that’s why so much questions…

best regards

So you’re using https://github.com/ttn-zh/ic880a-gateway for which install.sh generates the gateway’s EUI only once, using:

GATEWAY_EUI=$(ip link show $GATEWAY_EUI_NIC | awk '/ether/ {print $2}' | awk -F\: '{print $1$2$3"FFFE"$4$5$6}')
GATEWAY_EUI=${GATEWAY_EUI^^} # toupper

echo "Detected EUI $GATEWAY_EUI from $GATEWAY_EUI_NIC"

…and then when selecting “N” for Do you want to use remote settings file? will write it to the local configuration file, defined in $LOCAL_CONFIG_FILE, using:

echo -e "{\n\t\"gateway_conf\": {\n\t\t\"gateway_ID\": \"$GATEWAY_EUI\",\n\t\t\"servers\": [ { \"server_address\": \"router.eu.thethings.network\", \"serv_port_up\": 1700, \"serv_port_down\": 1700, \"serv_enabled\": true } ],\n\t\t\"ref_latitude\": $GATEWAY_LAT,\n\t\t\"ref_longitude\": $GATEWAY_LON,\n\t\t\"ref_altitude\": $GATEWAY_ALT,\n\t\t\"contact_email\": \"$GATEWAY_EMAIL\",\n\t\t\"description\": \"$GATEWAY_NAME\" \n\t}\n}" >$LOCAL_CONFIG_FILE

The config file is defined as:

# Install LoRaWAN packet forwarder repositories
INSTALL_DIR="/opt/ttn-gateway"
...
LOCAL_CONFIG_FILE=$INSTALL_DIR/bin/local_conf.json

So, I’d say you can edit /opt/ttn-gateway/bin/local_conf.json to change gateway_ID:

sudo nano /opt/ttn-gateway/bin/local_conf.json
1 Like

thank you so much, but now i have the problem:

“…no such file or directory”

-> So, I’d say you can edit /opt/ttn-gateway/bin/local_conf.json to change gateway_ID.

Do i have to do it on the gateway/pi per ssh? or put the stick in my notebook and search the file with explorer?

You see, i’m really new in this…

Yes, it’s a file on your gateway’s Pi, so using SSH, and then use an command line editor such as nano /opt/ttn-gateway/bin/local_conf.json, might be easiest. What command do you use to start the gateway? That should be in /opt/ttn-gateway too.

You might need to be root to edit the file: sudo nano /opt/ttn-gateway/bin/local_conf.json.

By the way, to create a random EUI using @terrillmoore’s little tool:

git clone https://github.com/things-nyc/random-eui64.git
cd random-eui64/
make random-eui64

I ignored a warning on a Mac, warning: format specifies type 'size_t' (aka 'unsigned long') but the argument has type 'unsigned int'. Next, run:

./random-eui64
2 Likes

Great! I’m getting closer, thank you so much! :slight_smile:

“make random-eui64” - this command before i install the complete gateway with the tutorial from gonzalo/ttn-zh or after everything is ready?

The tool to generate random EUIs is only needed before you edit the config file. Running it will give you a new EUI every time you need one, from which you remove the dashes and then copy it into the configuration file.

./random-eui64
D6-B6-80-D1-D5-1B-E3-1D

…or to remove the dashes on the fly, use ./random-eui64 | tr -d '-':

./random-eui64 | tr -d '-'
36D06C66546116EE
./random-eui64 | tr -d '-'
56C14B98C630E178
./random-eui64 | tr -d '-'
123E454624E1B7C1
./random-eui64 | tr -d '-'
3A04F9A32A0B532F

I am not using the above EUIs myself :wink:

1 Like

arjanvanb - thank you so much!
i’ve found the problem.

now its working!

thank you so much!

the problem was, when i tried to change the local_conf.json file, i was still as ttn registered, then i disconnect the connection to the raspberry and logged in as lgw.

then it works with ./random-eui64 and changing the eui in the local_conf.json file.

you made my day! thank you so much!

2 Likes

Thanks @arjanvanb for pointing out the compile warning. I don’t happen to use a Mac very often and I had not tested. It turned out to be a common problem on systems with 64-bit size_t; Ubuntu 64-bit and macOS in particular. It’s a path that is never taken unless read() from /dev/random fails, which isn’t supposed to happen. But it needed fixing, and it’s now fixed. (https://github.com/things-nyc/random-eui64/issues/1).

1 Like

@arjanvanb @BoRRoZ @gonzalo
Please can someone help me with deleting my gateway out from TTN?
I’m going crazy with it.

It worked with the ./random-eui64 - the help from arjanvanb, but i have a new gateway and the old gave someone. He can’t register the gateway, because the EUI B827EBFFFE870380 is still registered from TTN side.

I had so much issues and problems with my account and deleting of applications, devices and gateway.
When i deleted a device, application or gateway it wasn’t possible and if it was possible, there was still a a counted device.

Sometime i lost my patience and deleted my account.

So that is the problem now, beause somewhere in the TTN or backend of TTN my device with the EUI B827EBFFFE870380 is still registered.

Is there a contact from TTN or support, which can help me with my problem?

Thank you and greets
Albert

1 Like

I notified the Community Manager about your problem

2 Likes

just to check… how’s the current situation ?

@rish1

1 Like