Multiple MiSTers on The Same Network
-
- Posts: 10
- Joined: Mon May 25, 2020 6:46 pm
- Has thanked: 1 time
Multiple MiSTers on The Same Network
Thanks
Re: Multiple MiSTers on The Same Network
Press F9 and log in
Login: root
Password: 1
Edit etc/hostname
open vim (Text editor)
vim /etc/hostname
press i to enter insert mode
press esc to exit insert mode
press :wq to save and quit
Re: Multiple MiSTers on The Same Network
you can also place a text file in the Linux folder on your SD card called u-boot.txt
Place the following line in the u-boot.txt (Use whatever Mac Address you like).
ethaddr=02:03:04:05:06:01
@Locutus73, does the script create a u-boot.txt file?
-
- Posts: 10
- Joined: Mon May 25, 2020 6:46 pm
- Has thanked: 1 time
Re: Multiple MiSTers on The Same Network
Thanks for the reply Locutus73, I'm not sure where the script you are referring to is located. Is it in the main MiSTer repo? Do you have a link?
NML32, thank you for your suggestion. I'm guessing a script is not necessary if I follow your steps. So if I create a txt file named 'u-boot.txt' with the new mac address (ethaddr=myNewMacAddress) and edit the hosts file as mentioned in the reply above, that should be everything I need to have two MiSTer's happily coexisting on the same network?
Re: Multiple MiSTers on The Same Network
You will have to update the hostname anytime there is a Linux update.
-
- Core Developer
- Posts: 51
- Joined: Mon May 25, 2020 9:55 am
- Has thanked: 1 time
- Been thanked: 8 times
Re: Multiple MiSTers on The Same Network
Exactly
https://github.com/MiSTer-devel/Scripts ... _change.sh
will do that generating a random valid local/private MAC address (not using something universal corresponding to a public brand).
Pay attention: the script is quite old and will overwrite u-boot.txt... you will have to apply again USB polling options.
Regards.
Locutus73
- Sorgelig
- Site Admin
- Posts: 890
- Joined: Thu May 21, 2020 9:49 pm
- Has thanked: 2 times
- Been thanked: 214 times
Re: Multiple MiSTers on The Same Network
-
- Core Developer
- Posts: 51
- Joined: Mon May 25, 2020 9:55 am
- Has thanked: 1 time
- Been thanked: 8 times
Re: Multiple MiSTers on The Same Network
The script will assure all the flags are set correctly.
Alternatively you can launch
Code: Select all
echo "$(printf "%012X" $(( 0x$(hexdump -n6 -e '/1 "%02X"' /dev/random) & 0xFEFFFFFFFFFF | 0x020000000000 )) | sed 's/.\{2\}/&:/g' | sed s/:$//g)"
Regards.
Locutus73
Re: Multiple MiSTers on The Same Network
I'm a little confused though... it looks like the default MiSTer MAC address is: 02-03-04-05-06-07 (obviously this appears fake and to confirm, 02-03-04 isn't a registered OUI either).
Should we change the MAC even on a single-device setup to ensure the flags are set?
EDIT: Also, we can set a different host-name with u-boot.txt?
Re: Multiple MiSTers on The Same Network
Is it possible to set the hostname using the u-boot.txt? I know the hostname isn't nearly as important as the MAC address but it would still be nice to set it (and persist over Linux system upgrades).
Re: Multiple MiSTers on The Same Network
Re: Multiple MiSTers on The Same Network
I don't think there is a problem having two MiSTer's with the same hostname, right? As long as they both have different MAC addresses (and IP addresses of course), right?
Re: Multiple MiSTers on The Same Network
-
- Posts: 9
- Joined: Thu Nov 19, 2020 1:04 am
- Has thanked: 21 times
- Been thanked: 2 times
Re: Multiple MiSTers on The Same Network
Re: Multiple MiSTers on The Same Network
Re: Multiple MiSTers on The Same Network
gordonfish wrote: ↑Wed Dec 16, 2020 5:49 amA router, and rest of the network, will see MAC addresses over WiFi just as they would via wired connectivity. Wired or wifi, you don't want duplicate MAC addresses, as that upsets switches and arp tables.
While true, an off the shelf wifi adapter will have its own unique MAC burned, so you wouldn't need to set the MAC in this case.
-
- Posts: 9
- Joined: Thu Nov 19, 2020 1:04 am
- Has thanked: 21 times
- Been thanked: 2 times
Re: Multiple MiSTers on The Same Network
Missus wrote: ↑Wed Dec 20, 2023 9:56 pmgordonfish wrote: ↑Wed Dec 16, 2020 5:49 amA router, and rest of the network, will see MAC addresses over WiFi just as they would via wired connectivity. Wired or wifi, you don't want duplicate MAC addresses, as that upsets switches and arp tables.
While true, an off the shelf wifi adapter will have its own unique MAC burned, so you wouldn't need to set the MAC in this case.
True, since that would be a separate network interface. You could also use a USB wired network adapter too for the same effect.