Project

General

Profile

Bug #5654

network restart should die

Added by Josh Paetzel over 5 years ago. Updated almost 2 years ago.

Status:
Resolved
Priority:
Blocks Until Resolved
Assignee:
Vaibhav Chauhan
Category:
Middleware
Target version:
Severity:
New
Reason for Closing:
Reason for Blocked:
Needs QA:
Yes
Needs Doc:
Yes
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
ChangeLog Required:
No

Description

Currently when you change ANYTHING related to networking at all, FreeNAS reacts by restarting the network, and by that I mean it destroys all virtual interfaces and recreates them.

Handwavy IRC conversation says we should "do something" and that something should be able to apply deltas between the current config and what you are saving...doing the needful as far as ifconfig, ifconfig create, ifconfig destroy

this is a large project. (which in william speak means it will take most of a day. ;)

Associated revisions

Revision beb9b211 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): add py-netif to the build Ticket: #5654

Revision bfcd78df (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): depend on py-ucl Ticket: #5654

Revision 7e354498 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): network plugin for interfaces sync This is a work in progress, only regular physical ifaces are working. Code inspired in networkd using py-netif. Ticket: #5654

Revision 428af7ec (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): sync lagg interface Ticket: #5654

Revision b36506ed (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): sync vlan interfaces Ticket: #5654

Revision abb07826 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): first pass at syncing carp interfaces Ticket: #5654

Revision 1f84e95b (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): typo Ticket: #5654

Revision 3f3112a4 (diff)
Added by William Grzybowski about 3 years ago

Revert "feat(middlewared): depend on py-ucl" UCL will no longer be used for parsing. This reverts commit bfcd78df12a08a496d2bdff6a23447a3c85d78ab. Ticket: #5654

Revision 53975b4f (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): run dhclient if dhcp is enabled and not running Ticket: #5654

Revision c80e1860 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): always check if dhclient is running Ticket: #5654

Revision 56c9cb36 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): partially revert last commit File was committed by accident, this is not yet ready for overall usage. Ticket: #5654

Revision 862aa16b (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): destroy interfaces which are not in database Ticket: #5654

Revision 3bd621b3 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): start network when lagg members change Ticket: #5654

Revision 0cec8967 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): set ipv6 interface flags Grabbed from networkd. Ticket: #5654

Revision fd780053 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): ipv6 auto configure also enable flags Make sure rtsold is started for ipv6auto. Ticket: #5654

Revision 954a31f3 (diff)
Added by William Grzybowski about 3 years ago

feat(gui): make start network call middleware interfaces.sync Ticket: #5654

Revision 4123040d (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): split dhcplient check for code reuse Ticket: #5654

Revision bdcccf17 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): kill dhclient of unconfigured interface Ticket: #5654

Revision 79a1add1 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): actually check for returncode before logging error Ticket: #5654

Revision 0777b543 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): close fds Ticket: #5654

Revision 1236d1fe (diff)
Added by William Grzybowski about 3 years ago

feat(gui): adding interface should not interrupt connectivity now Ticket: #5654

Revision 9d4212cc (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): add system plugin Ticket: #5654

Revision 1a4b80fb (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): typo Ticket: #5654

Revision 1a39c358 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): carp_config takes a list Ticket: #5654

Revision 8107f859 (diff)
Added by William Grzybowski about 3 years ago

feat(build): update py-netif fixing carp key Ticket: #5654

Revision b285a6ad (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): configure carp after removing addresses Ticket: #5654

Revision 5da442a5 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): UP parent interfaces from lagg/vlan Ticket: #5654

Revision d204f12b (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): simplify destroy logic Ticket: #5654

Revision 6d4e5076 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): add some logging to interfaces sync Ticket: #5654

Revision 95cb6e38 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): debug about addresses added/removed Ticket: #5654

Revision 1a73f6c3 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): only set lagg protocol if it has changed Ticket: #5654

Revision 4543b230 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): get right ip field depending on node Ticket: #5654

Revision ffcfa6d5 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): add routes service Ticket: #5654

Revision 080c856c (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): python 2 Ticket: #5654

Revision 706b3c42 (diff)
Added by William Grzybowski about 3 years ago

feat(build): update py-netif Ticket: #5654

Revision f2af4de3 (diff)
Added by William Grzybowski about 3 years ago

rem(gui): ifconfig_alias has been superseded by interfaces.sync Ticket: #5654

Revision 70e09398 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): do not stop netif when alias is deleted Ticket: #5654

Revision 203a35c7 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): sync routes on network "start" Ticket: #5654

Revision 1ff5419a (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): set a reasonable default advskew Ticket: #5654

Revision 22e57b29 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): reconfigure_logging has to happen later While I'm here, space -> tab. Ticket: #5654

Revision c8e05b86 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): do not reload "networkgeneral" when editing interfaces Ticket: #5654

Revision f3c28ca5 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): we do not offer ipv6 node B field Ticket: #5654

Revision 698f6f47 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): sync_carp_ips has been superseded by interfaces.sync Ticket: #5654

Revision 51d6833a (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): handle ipv6 default route Ticket: #5654

Revision c8612936 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): sync interface options Ticket: #5654

Revision 94394617 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): check for error when applying iface options Ticket: #5654

Revision 894750bf (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): update py-netif Ticket: #5654

Revision 09d34f51 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): add lagg and vlan to interfaces in database list Ticket: #5654

Revision 3861334f (diff)
Added by William Grzybowski about 3 years ago

feat(gui): allow sql insert/updates to happen synchronously Ticket: #5654

Revision 284806c7 (diff)
Added by William Grzybowski about 3 years ago

feat(gui): make network sql operations happen synchronously Ticket: #5654

Revision 3cf016c8 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): sync interfaces when vlan is deleted Ticket: #5654

Revision b6916fcd (diff)
Added by William Grzybowski about 3 years ago

fix(gui): iface_destroy is no longer used Ticket: #5654

Revision d484ce93 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): run network notifier when lagg is deleted Ticket: #5654

Revision a3112569 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): error caught by flake8 Ticket: #5654

Revision c3f4c885 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): unreachable code Ticket: #5654

Revision 1fda8f57 (diff)
Added by William Grzybowski about 3 years ago

rem(gui): lagg_remove_port is no longer used Ticket: #5654

Revision dc782048 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): network start should happen in done() This is to make sure all formsets are saved before it happens. Ticket: #5654

Revision 744de106 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): save alias synchronously as well Ticket: #5654

Revision bd78f2e2 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): interface_mtu is no longer used Ticket: #5654

Revision 0c074404 (diff)
Added by William Grzybowski about 3 years ago

feat(middlewared): revert mtu to 1500 Ticket: #5654

Revision dd86e7c9 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): remove unused import Ticket: #5654

Revision 27e523be (diff)
Added by William Grzybowski about 3 years ago

fix(gui): interface delete should "start" network Ticket: #5654

Revision a52e1317 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): better handling of vlan/lagg not in Interfaces If lagg/vlan is in database but not in interfaces we should remove its addresses and bring it down. We also turn down every physical interface not in database. Ticket: #5654

Revision 93abcf58 (diff)
Added by William Grzybowski about 3 years ago

feat(gui): deleting vlan Interface will delete underlying vlan config Ticket: #5654

Revision c5d9815b (diff)
Added by William Grzybowski about 3 years ago

feat(gui): creating VLAN config will create VLAN Interface Ticket: #5654

Revision da8f01f4 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): be more graceful when interface in db does not exist Ticket: #5654

Revision 913d129c (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): typo Ticket: #5654

Revision 413c614a (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): lagg name Ticket: #5654

Revision 6eda2065 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): save advskew of carp, if existent Ticket: #5654

Revision 8c950f45 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): only start network for freenas Ticket: #5654

Revision 1bea8758 (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): do not down interfaces part of lagg/vlan Ticket: #5654

Revision f86202dd (diff)
Added by William Grzybowski about 3 years ago

feat(gui): remove the requirement to manually disable failover Ticket: #5654

Revision ddcb28b1 (diff)
Added by William Grzybowski about 3 years ago

fix(gui): simplify HA check Ticket: #5654

Revision 753c7408 (diff)
Added by William Grzybowski about 3 years ago

feat(gui): be less restrictive about disabling failover Ticket: #5654

Revision eaa9499a (diff)
Added by William Grzybowski about 3 years ago

fix(middlewared): update py-netif for interfaces.sync Ticket: #5654

History

#1 Updated by William Grzybowski over 5 years ago

  • Status changed from Unscreened to Screened

#2 Updated by William Grzybowski about 4 years ago

  • Status changed from Screened to Closed: Not To Be Fixed
  • Seen in changed from to 9.3.1-STABLE-201511040813

This is not going to happen in 9.3, although this is already fixed in 10.

#3 Updated by William Grzybowski about 3 years ago

  • Status changed from Closed: Not To Be Fixed to Screened
  • Target version changed from 49 to 9.10.2

This should happen in 9.10.2 or so.

#4 Updated by Josh Paetzel about 3 years ago

  • Priority changed from Nice to have to Blocks Until Resolved

#5 Updated by William Grzybowski about 3 years ago

  • Status changed from Screened to 19

#7 Updated by William Grzybowski about 3 years ago

  • Status changed from 19 to Needs Developer Review

#8 Updated by William Grzybowski about 3 years ago

  • Assignee changed from William Grzybowski to Josh Paetzel

#9 Updated by Josh Paetzel about 3 years ago

re:
https://bugs.freenas.org/projects/freenas/repository/revisions/1ff5419a36e10a8fa44cb26459105f3ac7f31b39/diff

jpaetzel [5:09 PM]
I'm confused perhaps

[5:09]
if self.middleware.call('notifier.failover_status') == 'MASTER':
advskew = 20

[5:10]
could that demote an HA unit's advskew from 1 -> 20 ?

william [5:11 PM]
idk, lets think about it

[5:12]
say you are passive and becomes master, it will set advskew to 1, right? and when the other needs comes back up, it will be 20?

jpaetzel [5:13 PM]
when the HA node boots it will select it's advskew from the database as either 20 or 80

william [5:13 PM]
its not in the database

jpaetzel [5:13 PM]
when carp goes master, carp_hook runs, and if it "wins" the advskew gets set to 1

[5:14]
oh right, it's all in rc.conf.local now

william [5:15 PM]
but yeah, that doesn't look right

jpaetzel [5:15 PM]
and if carp goes BACKUP, carp_hook runs it's backup routines and sets advskew to 100

[5:17]
the comment on line 250

[5:18]
it sounds like what needs to happen is before the delete, see what the advskew is, then use that when reconfiguring carp

william [5:18 PM]
yes

jpaetzel [5:18 PM]
I'll update the ticket

william [5:19 PM]
and additionally, use the node A or B to set 20 or 80

[5:19]
if there was no carp configured previously (edited)

[5:19]
instead of MASTER/BACKUP

jpaetzel [5:19 PM]
right

#10 Updated by Josh Paetzel about 3 years ago

  • Status changed from Needs Developer Review to Fix In Progress
  • Assignee changed from Josh Paetzel to William Grzybowski

#11 Avatar?id=14398&size=24x24 Updated by Kris Moore about 3 years ago

  • Status changed from Fix In Progress to Reviewed
  • Assignee changed from William Grzybowski to Vaibhav Chauhan

#12 Updated by Vaibhav Chauhan about 3 years ago

  • Status changed from Reviewed to Ready For Release

#13 Updated by Dru Lavigne almost 2 years ago

  • Status changed from Ready For Release to Resolved

Also available in: Atom PDF