-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
piscsi_bridge should not be created by default when WiFi is used for network access for daynaport #64
Comments
The issue_64 branch does not create the bridge anymore for any wlan interface. What about other interfaces like eth1, wlan1? Where excatly do we need the bridge, and where not? (I'm not a networking expert.) When using wlan0 and launching s2p, this is the initial setup I get with the issue_64 branch:
Now I run:
And see this:
I assigned IP 10.10.20.2 to the TT, but STiNG cannot connect to ftp.uni-erlangen.de, for instance. Any idea what might be wrong? |
@fdanapfel Without programmatically exeucting
this setup is rather inconvenient, isn't it? The setting gets lost after shutting s2p down, because the bridge interface it refers to is gone. |
The bridge is only needed if a physical Ethernet interface (eth0, eth1, ...) is used for the connection of the piscsi0 interface to the real network. As documented at https://wiki.debian.org/BridgeNetworkConnections#Bridging_with_a_wireless_NIC using a bridge to connect a wlan interface and an Ethernet interface (real or virtual like the piscsi0) doesn't work. And as mentioned in PiSCSI/piscsi#1387 with the setup using
This looks good.
Did you also set up the ROUTE.TAB file for STING to send the Network traffic over the 10.10.20.0 Network? See https://www.atari-forum.com/viewtopic.php?p=438157#p438157
Sorry, I don't understand what you mean here. There is no reference to a brige in that |
@fdanapfel Indeed, I forgot that I also had to edit ROUTE.TAB. Now it's working! (With bookworm.) Regarding the ip command, what I mean is that if s2p removes the piscsi0 interface when you stop s2p, any setting (ip addr add) for this interface is lost. Even when s2p re-creates piscsi0 when you re-start s2p the setting is lost. |
Regarding creating the bridge: My current approach is to not create it whenever the network interface name starts with "wlan", i.e. also wlan1 is covered. Correct me if I am wrong, but this approach should be fine, shouldn't it? |
Great!
OK, but this is the standard way how a network interface works even for Ethernet or WLAN interfaces. When a network interface is created (for Ethernet or WLAN interfaces this normally is done by the Linux kernel during boot based on the hardware it finds) it initially doesn't have an IP address assigned to it. This normally happens later via tools like NetworkManager or dhcpcd, or by configuring the IP address manually using the ip command. If s2p is not removing the piscsi0 interface when the daynaport is detached or when s2p itself is stopped then the piscsi interface should still keep the same ip address it was configured with before. Please also keep in mind that the IP address that needs to be assigned to the piscsi0 interface will not necessarily be the same all the time. As you can see in PiSCSI/piscsi#1387 when using parprouted the IP adress of the piscsi interface is actually set to the same IP address as the real network interface
Yes, this should be fine, unless the approach to use parprouted is accepted as the new standard for connecting the piscsi0 interface to the real network for both Ethernet and WLAN. Then the brige is also not needed when Ethernet is used. |
@fdanapfel Thank you for providing more details. Regarding manual configuration, this is IMO a blocker. One cannot expect the user to manually add the IP address after launching s2p (or piscsi). |
@fdanapfel I experimented a bit and think that s2p (issue_64 branch) now does everything required automatically. Before lauching s2p there is no piscsi0 interface. After lauching s2p ifconfig says:
After stopping s2p piscsi0 is gone, but it's there again when you re-start s2p. My TT was also happy with this, and on bullseye I get the same result. |
@fdanapfel https://www.scsi2pi.net/packages/develop/scsi2pi_2.1_devel_7c3df1b_bookworm_arm64-1.deb is a binary package of the current issue_62 branch. If possible, can you please verify whether it works as expected, i.e. as I have claimed it works? |
After some more testing I have just merged the current changes into the develop branch. Any potential change related to eth0 should be a separate ticket.
This solution is still not the best, because the interfaces are created even though they might never be needed. A user might always attach a DaynaPort but might not always not use it. |
@uweseimet Thanks, I've now tested this with scsi2pi_2.1_devel_7c3df1b_bookworm_arm64-1.deb and it works as expected when attaching the daynaport:
But when detaching the daynaport the piscsi0 interface isn't removed and also the IP address stays configured:
I would have expected that this works like with a real network interface or the piscsi_bridge ( #45), meaning that the piscsi0 interface is removed when the daynaport is detached. |
Sorry I'm not sure what the best way would be to automatically set the IP address, since right now there are three different possibilities how the connection between the emulated daynaport and the real network could be set up:
|
@fdanapfel I cannot reproduce this, but this might be because in the meantime I have cleaned up the legacy networking code quite a bit, and this is the code I have just tested with. Regarding 1. just a note: 10.10.20.1 is the default, but you can configure any IP, just like you can configure any interface. This way you can also use wlan0 even when eth0 (the default) is available, e.g.
Regarding 3. I will wait until PiSCSI/piscsi#1387 is done. |
@uweseimet I've now tested again with the latest development build from this morning, and now everything works as expected (the bridge is not created and the piscsi0 device is created/removed when the daynaport is attached/detached):
Thanks for implementing those changes. And for the information about configuring the IP and interface when attaching the daynaport, wasn't aware of that. So from my point of view this issue can be closed. |
@fdanapfel Thank you for your feedback! |
When creating a new ticket please provide information on your environment.
The Pi type:
Zero 2 W
The Pi OS version (output of 'lsb_release -a' and 'uname -a'):
The SCSI2Pi release or git revision:
scsi2pi_2.1_devel_0b10191_bookworm_arm64-1.deb
The computer/sampler connected to the RaSCSI/PiSCSI board:
Atari TT030
Mac SE/30
Describe the issue
As mentioned at PiSCSI/piscsi#1331 (comment) the NAT setup for the daynaport interface works if the piscsi_bridge is removed and the IP address is configured directly on the piscsi0 interface.
Also others have now been able to verify that the setup I proposed in PiSCSI/piscsi#1387 which uses parprouted instead of the bridge or the NAT setups that were originally used by PiSCSI works for both WLAN and Ethernet to allow systems using the emulated daynaport adapter to communicate over the network.
Therefore the piscsi_bridge should not be created by default when the daynaport is attached.
The text was updated successfully, but these errors were encountered: