Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Don't miss a thing. Post your questions and discussion about other uncategorized NAS features here.
Post Reply
b3chang3d
New here
Posts: 4
Joined: Wed Aug 08, 2018 8:20 am

Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by b3chang3d »

ie- NAS 1 (all NICs bonded to 1 via TLB) set bond0 -> 0.0.0.0 or flush bond 0 vlan 50 140.100.100.1 subnet 255.255.0.0

NAS 2 (all NICs bonded to 1 via TLB) set bond0 -> 0.0.0.0 or flush bond 0 vlan 50 140.100.100.2 subnet 255.255.0.0

My switch config looks something like ports 1 and 2 untagged for vlan 50 ports 5 and 6 tagged (NAS 1 connected to port 5, NAS 2 connected to port 6, computer connected to port 1 with proper network adapter configuration)

I have scripts that run on bootup on two NAS's (let's say they're QNAPs) to create bonds and have different ips for different vlans. My problem is that when both NAS's are plugged in and I ping both at the same time from the computer, I get huge latency (>=32ms) on the pings and pretty much any traffic going to either unit. The second I unplug one of the NAS, the other NAS ping drops to <1ms and I no longer have bad latency. Initially I thought that it may be a IP collision issue so I look at ifconfig of the NAS's on startup - turns out it is running something after my autorun script to set the bond0s to a factory ip (150.140.100.100). So I manually set the bond ip to something arbitrary and different for both NAS's, turn off the /etc/init.d/dhcpd.sh script and try to ping 140.100.100.1 and 140.100.100.2 - it works for a few minutes then it goes back to timing out and having bad latency. This time however, bond0 of both NAS's have different ips - and that's where I am really confused. Thanks for any help! Also, MAC addresses on all the NICS are all different.

Summary - How do I fix latency issue between two NAS units connected to the same switch despite having different bond ips?
User avatar
Trexx
Ask me anything
Posts: 5388
Joined: Sat Oct 01, 2011 7:50 am
Location: Minnesota

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by Trexx »

Buy a REAL switch so you can do thinks like LAG/LACP/VLAN/etc. in the switch.
Paul

Model: TS-877-1600 FW: 4.5.3.x
QTS (SSD): [RAID-1] 2 x 1TB WD Blue m.2's
Data (HDD): [RAID-5] 6 x 3TB HGST DeskStar
VMs (SSD): [RAID-1] 2 x1TB SK Hynix Gold
Ext. (HDD): TR-004 [Raid-5] 4 x 4TB HGST Ultastor
RAM: Kingston HyperX Fury 64GB DDR4-2666
UPS: CP AVR1350

Model:TVS-673 32GB & TS-228a Offline[/color]
-----------------------------------------------------------------------------------------------------------------------------------------
2018 Plex NAS Compatibility Guide | QNAP Plex FAQ | Moogle's QNAP Faq
b3chang3d
New here
Posts: 4
Joined: Wed Aug 08, 2018 8:20 am

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by b3chang3d »

Trexx wrote:Buy a REAL switch so you can do thinks like LAG/LACP/VLAN/etc. in the switch.
my switch is configured to tag vlan traffic - it is server grade. trunking the tagged ports via LACP does not work, already tried.

I even thought it might be the way i am bonding the nics on the NAS side - like if I have one nic out of the 4 plugged in, then TLB or ALB might be trying all the bonded ports and creating latency itself. However, the latency only happens when I plug in both NAS's which leads me to believe that it has to do with the network NAS configuration - I'm confident I can set up VLANs in a switch without screwing up :P
User avatar
Don
Guru
Posts: 12289
Joined: Thu Jan 03, 2008 4:56 am
Location: Long Island, New York

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by Don »

Please stop multiposting.
Use the forum search feature before posting.

Use RAID and external backups. RAID will protect you from disk failure, keep your system running, and data accessible while the disk is replaced, and the RAID rebuilt. Backups will allow you to recover data that is lost or corrupted, or from system failure. One does not replace the other.

NAS: TVS-882BR | F/W: 5.0.1.2346 | 40GB | 2 x 1TB M.2 SATA RAID 1 (System/VMs) | 3 x 1TB M.2 NMVe QM2-4P-384A RAID 5 (cache) | 5 x 14TB Exos HDD RAID 6 (Data) | 1 x Blu-ray
NAS: TVS-h674 | F/W: 5.0.1.2376 | 16GB | 3 x 18TB RAID 5
Apps: DNSMasq, PLEX, iDrive, QVPN, QLMS, MP3fs, HBS3, Entware, DLstation, VS, +
P3R
Guru
Posts: 13192
Joined: Sat Dec 29, 2007 1:39 am
Location: Stockholm, Sweden (UTC+01:00)

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by P3R »

b3chang3d wrote:I have scripts that run on bootup...
Why are you scripting? Why not use the gui?
...on two NAS's (let's say they're QNAPs)...
Let's say? Aren't they Qnaps? :shock:

What model of Qnaps running what QTS firmware version and build do you have there?
...to create bonds and have different ips for different vlans.
You have all LAN ports in a bond but different ips for different vlans? :-0
Initially I thought that it may be a IP collision issue so I look at ifconfig of the NAS's on startup - turns out it is running something after my autorun script to set the bond0s to a factory ip (150.140.100.100).
I would be very surprised if Qnap had that as a "factory ip". Do you really think that it's a coincidence that the last 3 bytes are your ip address, shifted one step right? :'
Summary - How do I fix latency issue between two NAS units connected to the same switch despite having different bond ips?
I think that the latency is only one symptom of the networking being very misconfigured. Sort out your networking properly and I bet the latency will disappear.
trunking the tagged ports via LACP does not work, already tried.
Find out what's wrong and fix it. As far as I know LACP properly setup should work.
RAID have never ever been a replacement for backups. Without backups on a different system (preferably placed at another site), you will eventually lose data!

A non-RAID configuration (including RAID 0, which isn't really RAID) with a backup on a separate media protects your data far better than any RAID-volume without backup.

All data storage consists of both the primary storage and the backups. It's your money and your data, spend the storage budget wisely or pay with your data!
b3chang3d
New here
Posts: 4
Joined: Wed Aug 08, 2018 8:20 am

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by b3chang3d »

first, thank you for trying to help I really appreciate it!
P3R wrote:Why are you scripting? Why not use the gui?
GUI does not let you assign VLANs to bonds, AFAIK. it also doesnt let you choose anything outside of active bond, balance-ALB, balance-TLB. GUI also does not allow you to stop the DHCPD/netmgr/etc service from running. if I set a static IP in the gui, non of my vlan ip work from the script, so I am avoiding UI at all costs for networking.
P3R wrote:Let's say? Aren't they Qnaps? :shock:
they are QNAPs, i wanted the question to be more general because I am also asking on stackexchange :lol: im running one of the 4.3.4 released in July 2018 on two TS-853U 8 bays
P3R wrote:You have all LAN ports in a bond but different ips for different vlans? :-0
yes, all bonded ports provides link aggregation and failover for the NAS, and I have different ips for vlans to have separate access. i am connected to a AD to give permission to domain groups that can only access through certain VLAN.
P3R wrote:I would be very surprised if Qnap had that as a "factory ip". Do you really think that it's a coincidence that the last 3 bytes are your ip address, shifted one step right? :'
QNAP has a factory ip that it defaults to, if you are not connected to the internet. 150.140.100.100 is just an example ip, the real IP is 169.254.100.100 which is found on uLinux.conf in the QNAP os
P3R wrote:I think that the latency is only one symptom of the networking being very misconfigured. Sort out your networking properly and I bet the latency will disappear.
Can you please elaborate? I have my ports correctly tagged and untagged. I am not messing with switch side trunking yet because ive tried LACP trunked ports on switch and I couldnt even ping QNAP after that.
P3R wrote:Find out what's wrong and fix it. As far as I know LACP properly setup should work.
well afaik, 802.3AD bond mode needs to be enabled on NAS side, and ports need to be trunked on switch side. however, I cannot find the script to run/edit in the QNAP to change the mode - all i have is from the UI which is ALB, TLB, and active bond.
P3R
Guru
Posts: 13192
Joined: Sat Dec 29, 2007 1:39 am
Location: Stockholm, Sweden (UTC+01:00)

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by P3R »

b3chang3d wrote:it also doesnt let you choose anything outside of active bond, balance-ALB, balance-TLB.
I'm sorry I don't know what active bond is. I do know that LACP and several other link aggregation modes are simple to setup through the gui and they work. I'm running LACP on proper switches and I run Balance-rr or Balance XOR if the switch only support static link aggregation.
if I set a static IP in the gui, non of my vlan ip work from the script...
Yes that's the problem with scripting. Qnaps don't run vanilla Linux so you don't know how your changes work and interact with the way Qnap intended the use and that will give you many problems now and in the future. Messing with scripting for unsupported system configurations on a Qnap is exactly that, messy.

Since you've already entered unsupported territory, I would take the complete step and switch to a more standard Linux if I intended to go that way. Debian, Ubuntu server or whatever you and your organization is familiar with and where a much larger community have knowledge and can assist.
yes, all bonded ports provides link aggregation and failover for the NAS, and I have different ips for vlans to have separate access. i am connected to a AD to give permission to domain groups that can only access through certain VLAN.
The way I would do it is to configure from the gui and have one NAS interface connected to the AD vlan (untagged on switch) and the rest in a LACP link aggregation (again untagged on switch). Different from your configuration, that would work and it would be a configuration on which you could get support from Qnap and a much larger part of this community could assist with any problems.

No you wouldn't have failover for the AD vlan but seriously, network interfaces don't fail that often especially not in a more stable professional environment surrounding it as I imagine you have. I've never in +10 years of Qnap usage experienced a network failure where link aggregation failover could save me.
QNAP has a factory ip that it defaults to, if you are not connected to the internet. 150.140.100.100 is just an example ip, the real IP is 169.254.100.100 which is found on uLinux.conf in the QNAP os
It's much easier to understand things if you don't selectively obfuscate things. Yes a link local address is the normal result when a DHCP-client fail to find a DHCP-server so that's another symptom of non-working network connectivity.
Can you please elaborate?
No I can't elaborate because:
  1. I don't know how the networking scripts work in a Qnap.
  2. You only tell us bits and pieces about your configuration and without the whole picture, it's near impossible to understand what you have or what is wrong with it.
well afaik, 802.3AD bond mode needs to be enabled on NAS side, and ports need to be trunked on switch side.
Yes of course. But using toy link aggregation as you do may also introduce other issues complicating the picture even more.

There are a few souls here that may be able to assist you but I'm not one of them.

Good luck!
RAID have never ever been a replacement for backups. Without backups on a different system (preferably placed at another site), you will eventually lose data!

A non-RAID configuration (including RAID 0, which isn't really RAID) with a backup on a separate media protects your data far better than any RAID-volume without backup.

All data storage consists of both the primary storage and the backups. It's your money and your data, spend the storage budget wisely or pay with your data!
b3chang3d
New here
Posts: 4
Joined: Wed Aug 08, 2018 8:20 am

Re: Question Regarding Network Latency accessing Two Devices via IP Collision/DHCPD.sh/Netmgr

Post by b3chang3d »

P3R wrote:
b3chang3d wrote:it also doesnt let you choose anything outside of active bond, balance-ALB, balance-TLB.
I'm sorry I don't know what active bond is. I do know that LACP and several other link aggregation modes are simple to setup through the gui and they work. I'm running LACP on proper switches and I run Balance-rr or Balance XOR if the switch only support static link aggregation.
if I set a static IP in the gui, non of my vlan ip work from the script...
Yes that's the problem with scripting. Qnaps don't run vanilla Linux so you don't know how your changes work and interact with the way Qnap intended the use and that will give you many problems now and in the future. Messing with scripting for unsupported system configurations on a Qnap is exactly that, messy.

Since you've already entered unsupported territory, I would take the complete step and switch to a more standard Linux if I intended to go that way. Debian, Ubuntu server or whatever you and your organization is familiar with and where a much larger community have knowledge and can assist.
yes, all bonded ports provides link aggregation and failover for the NAS, and I have different ips for vlans to have separate access. i am connected to a AD to give permission to domain groups that can only access through certain VLAN.
The way I would do it is to configure from the gui and have one NAS interface connected to the AD vlan (untagged on switch) and the rest in a LACP link aggregation (again untagged on switch). Different from your configuration, that would work and it would be a configuration on which you could get support from Qnap and a much larger part of this community could assist with any problems.

No you wouldn't have failover for the AD vlan but seriously, network interfaces don't fail that often especially not in a more stable professional environment surrounding it as I imagine you have. I've never in +10 years of Qnap usage experienced a network failure where link aggregation failover could save me.
QNAP has a factory ip that it defaults to, if you are not connected to the internet. 150.140.100.100 is just an example ip, the real IP is 169.254.100.100 which is found on uLinux.conf in the QNAP os
It's much easier to understand things if you don't selectively obfuscate things. Yes a link local address is the normal result when a DHCP-client fail to find a DHCP-server so that's another symptom of non-working network connectivity.
Can you please elaborate?
No I can't elaborate because:
  1. I don't know how the networking scripts work in a Qnap.
  2. You only tell us bits and pieces about your configuration and without the whole picture, it's near impossible to understand what you have or what is wrong with it.
well afaik, 802.3AD bond mode needs to be enabled on NAS side, and ports need to be trunked on switch side.
Yes of course. But using toy link aggregation as you do may also introduce other issues complicating the picture even more.

There are a few souls here that may be able to assist you but I'm not one of them.

Good luck!
thanks for trying anyway.

I fixed the latency issue by trunking two switches together and splitting up the connections. going to try untagged LACP as you suggested now, thanks for the tip.
Post Reply

Return to “Miscellaneous”