summaryrefslogtreecommitdiff
path: root/server/failover.c
Commit message (Collapse)AuthorAgeFilesLines
* [45364] Replaced --enable-secs-byteorder with runtime check-secs-byte-orderThomas Markwalder2017-11-291-3/+3
| | | | | | | | | | | | | | | | | | | | | configure.ac removed --enable-secs-byteorder support includes/dhcpd.h added SV_CHECK_SECS_BYTE_ORDER includes/failover.h added extern int check_secs_byte_order server/dhcpd.c postconf_initialization() - added logic to set check_secs_byte_order server/failover.c load_balance_mine() - replaced conditional comp directives with runtime test of check_secs_byte_order Added release note and updated man page.
* [master] Disable load balancing when load balance max secs is 0Thomas Markwalder2017-11-271-1/+10
| | | | Merges in rt39669.
* [master] Replaced licensing text with MPL licensing text throughoutThomas Markwalder2017-07-121-3/+3
|
* [master] Check failover pools per peer in test modeThomas Markwalder2017-06-271-92/+114
| | | | Merges in rt29892
* [master] Scrub leases when they are re-balancedThomas Markwalder2016-06-131-0/+47
| | | | Merges in 42008.
* [master] Fixed several minor Coverity issuesThomas Markwalder2016-02-181-5/+1
| | | | Merges in rt35144.
* [master] Failover primary now accepts secondary updates from active to abandonedThomas Markwalder2016-01-181-4/+7
| | | | Merges in rt25189.
* [master] Add support for manipulating lease queues via a binary search.Shawn Routhier2015-05-271-22/+43
| | | | | | Add support for manipluating the queues holding leaes for time based events (free, backup, active, expired, abandoned and reserved) via a binary search instead of walking through the linked list.
* [master] Don't call pool_timer recusivelyShawn Routhier2014-12-101-7/+6
| | | | | | Add a flag to avoid supersede_lease calling pool_timer recursively when pool_timer can't handle that. rt38002
* [master] Patch the failover code to avoid deadlocksShawn Routhier2014-11-101-73/+133
| | | | | | | | | | | | | | | | | | | | | | Patch for 36810 & 20352 This coves several related problems 1) When the primary is in conflict done it allows the secondary to transition around resolution interrupted and potentical conflict previously the primary would die on an illegal state. 2) It allows the servers to restart a bind update request. Previously if one of the servers sent an udpate request and there died (or had the communications interrupted) in some states the first server wouldn't retransmit a new update request and the other server wouldn't send any bind updates. This was noticed in potential conflict. 3) Updated the state transitions to move the leases on the ack queue back to the update queue in case of conflict-done as we might need to retransmit them all. 4) Updated a transition from startup to potentical conflict instead of resolution interrupted when the servers reconnect during the startup phase in order to avoid a diffferent dead lock.
* [master] Added check for invalid failover message type.Thomas Markwalder2014-09-081-0/+6
| | | | Merges in rt36653
* [master] Corrects medium impact issues reported by Coverity.Thomas Markwalder2014-08-281-1/+6
| | | | Merges in rt36933
* [master] Update partner's stos field when processing an updateShawn Routhier2014-04-281-0/+1
|
* [master] Add #ifdefs to allow code to compile if NSUPDATE isn't definedShawn Routhier2014-04-281-0/+2
|
* [master] Remove vix.com and nominum.comShawn Routhier2014-01-261-7/+1
| | | | | Remove old information from copyrights and man pages.
* [master] Emit log messages when the server is stableShawn Routhier2013-11-081-0/+8
| | | | | | Emit a log message when the server had completed initialization and is about to start dispatching. And emit log messages when both peers in a failover pair have reached the normal state.
* - Silence benign static analysis warnings.Mark Andrews2013-05-151-5/+3
| | | | [ISC-Bugs #33428]
* [master]Shawn Routhier2012-10-161-3/+1
| | | | | | [rt23833] Clean up a number of items identified by the Coverity static analysis tool. Runs courtesy of Red Hat.
* [master]Shawn Routhier2012-10-111-17/+31
| | | | | | | | | | | [ISC-Bugs #26108] Add a compile time option, enable-secs-byteorder, to deal with clients that do the byte ordering on the secs field incorrectly. This field should be in network byte order but some clients get it wrong. When this option is enabled the server will examine the secs field and if it looks wrong (high byte non zero and low byte zero) swap the bytes. The default is disabled. This option is only useful when doing load balancing within failover.
* [master]Shawn Routhier2012-10-091-1/+5
| | | | | | | | | | | [rt30320] When processing a failover request with an unexpected name create an option block the relationship_name instead of using the one from the incoming message. This avoids problems when the option is freed. Also add code to free the relationship_name from the incoming mesasage when we free the message.
* Modify the code that determines if an outstanding DDNS requestShawn Routhier2012-03-191-1/+1
| | | | | | | | should be cancelled. This patch results in cancelling the outstanding request less often. It fixes the problem caused by a client doing a release where the txt and ptr records weren't removed from the DNS. [ISC-BUGS #27858]
* Fixed many compilation problems ("set, but not used" warnings) forTomek Mrugalski2012-03-091-8/+12
| | | | gcc 4.6 that may affect Ubuntu 11.10 users. [ISC-Bugs #27588]
* Modify the DDNS handling code. In a previous patch we added loggingShawn Routhier2011-12-301-1/+1
| | | | | | | | | | | | | | code to the DDNS handling. This code included a bug that caused it to attempt to dereference a NULL pointer and eventually segfault. While reviewing the code as we addressed this problem, we determined that some of the updates to the lease structures would not work as planned since the structures being updated were in the process of being freed: these updates were removed. In addition we removed an incorrect call to the DDNS removal function that could cause a failure during the removal of DDNS information from the DNS server. Thanks to Jasper Jongmans for reporting this issue. [ISC-Bugs #27078] CVE: CVE-2011-4868
* - Code cleanup: remove obsolete PROTO, KandR, INLINE and ANSI_DECL macrosTomek Mrugalski2011-05-111-3/+3
| | | | [ISC-Bugs #13151]
* Fix the handling of connection requests on the failover port.Shawn Routhier2010-12-131-2/+3
| | | | | | | Previously a connection request from a source that wasn't listed as a failover peer would cause the server to become non-responsive. [ISC-Bugs #22679] CERT: VU#159528 CVE: CVE-2010-3616
* - An optimization described in the failover protocol draft is now included,David Hankins2010-02-031-11/+81
| | | | | | | | which permits a DHCP server operating in communications-interrupted state to 'rewind' a lease to the state most recently transmitted to its peer, greatly increasing a server's endurance in communications-interrupted. This is supported using a new 'rewind state' record on the dhcpd.leases entry for each lease. [ISC-Bugs #19601]
* Support for asynchronous ddns per ticket 19216 - convert to using isclib andShawn Routhier2009-10-281-64/+64
| | | | dnslib.
* - s/%ul/%lu/ in failover timing debug logs. This bug was introduced inDavid Hankins2009-09-081-1/+1
| | | | | 4.2 feature development, so no RELNOTES entry has been made. [ISC-Bugs #20161]
* Switch isc urls from http to https and correct sw to services or softwareShawn Routhier2009-07-231-2/+2
| | | | for new web site as appropirate.
* - Secondary servers in a failover pair will now perform ddns removals ifDavid Hankins2009-07-221-3/+48
| | | | | | | | | they had performed ddns updates on a lease that is expiring, or was released through the primary. As part of the same fix, stale binding scopes will now be removed if a change in identity of a lease's active client is detected, rather than simply if a lease is noticed to have expired (which it may have expired without a failover server noticing in some situations). [ISC-Bugs #19826b]
* update copyrightPaul Selkirk2009-07-161-1/+1
|
* add a null check to avoid primary crash on contact with secondary [rt19705]Paul Selkirk2009-07-161-1/+2
|
* - A new failover configuration parameter has been introduced for thoseDavid Hankins2009-06-171-2/+43
| | | | | | | | | environments where DHCP servers can be reasonably guaranteed to be "down" when the failover TCP socket is severed, "auto-partner-down". This parameter is not generally safe, and by default is disabled, so please carefully review the documentation of this parameter in the dhcpd.conf(5) manpage before determining to use it yourself. [ISC-Bugs #19600]
* - Fixed a bug where an OMAPI socket disconnection message would not resultDavid Hankins2009-05-201-13/+10
| | | | | | in scheduling a failover reconnection, if the link had not negotiated a failover connect yet (e.g.: connection refused, asynch socket connect() timeouts). [ISC-Bugs #19684]
* - Fixed failover reconnection retry code to continue to retry to reconnectDavid Hankins2009-04-221-6/+4
| | | | rather than restarting the listener. [ISC-Bugs #19618]
* - Memory leak in the load_balance_mine() function is fixed. This wouldDavid Hankins2009-04-071-0/+2
| | | | | | | | leak ~20-30 octets per DHCPDISCOVER packet while failover was in use and in normal state. [ISC-Bugs #19548] - Various compilation fixes have been included for the memory related DEBUG #defines in includes/site.h. [ISC-Bugs #19548]
* - Some failover debugging #defines have been better defined and someDavid Hankins2008-09-241-79/+192
| | | | | | | | | | | | high frequency messages moved to a deeper debugging symbol. - The CLTT parameter in failover is now only updated by client activity, and not by failover binding updates (taking on the peer's CLTT). - Failover BNDUPD messages are now discarded if they conflict with an update that has been trasnmitted, but not acknowledged. [ISC-Bugs #17577c]
* Updated copyright strings for 4.1.0a1 releaseEvan Hunt2008-01-241-1/+1
|
* - When a failover server suspects it has encountered a peer running aDavid Hankins2008-01-211-1/+31
| | | | | | | version 3.0.x failover server, a warning that the failover wire protocol is incompatible is printed. [ISC-Bugs #17129] - The failover server no longer issues a floating point error if it encounters a previously undefined option code. [ISC-Bugs #17129]
* - A log message was introduced to clarify the situation where a failoverDavid Hankins2008-01-081-0/+3
| | | | | 'address' parameter (the server's local address) did not resolve to an IPv4 address. [ISC-Bugs #15826]
* finer granularity timersFrancis Dupont2008-01-031-25/+75
|
* - A bug in failover pool rebalancing that caused POOLREQ message ping-pongsDavid Hankins2007-12-181-23/+62
| | | | | | | | was repaired. [ISC-Bugs #17228] - A flaw in failover pool rebalancing that could cause POOLREQ messages to be sent outside of the min-balance/max-balance scheduled intervals has been repaired. [ISC-Bugs #17228]
* - A cosmetic bug during potential-conflict recovery that caused the peer'sDavid Hankins2007-12-131-0/+3
| | | | | 'conflict-done' state message to be logged as 'unknown-state' has been repaired. It is now logged correctly. [ISC-Bugs #17204]
* almost editorial stuffFrancis Dupont2007-11-301-4/+4
|
* - The peer_wants_leases() changes pulled up from 3.1.0 were corrected,David Hankins2007-10-091-8/+31
| | | | | 'never used' leases will no longer consistently shift between servers on every pool rebalance run. [ISC-Bugs #17211]
* - A bug was repaired where MAC Address Affinity for virgin leases alwaysDavid Hankins2007-09-271-4/+12
| | | | | | | | | mapped to the primary. Virgin leases now have an interleaved preference between primary and secondary. [ISC-Bugs #17174] - A bug was repaired where MAC Address Affinity for clients with no client identifier was sometimes mishashed to the peer. Load balancing during runtime and pool rebalancing were opposing. [ISC-Bugs #17174]
* Couple of casts to fix build errors reported by robie.Shane Kerr2007-09-181-2/+3
|
* - Log messages when failover peer names mismatch have been improved toDavid Hankins2007-09-171-9/+30
| | | | point out the problem.
* Code cleanup to remove warnings from "gcc -Wall".Shane Kerr2007-07-131-26/+1
| | | | See RT ticket #16988 for more.
* - Failover rebalance events no longer play ping pong with round errorsDavid Hankins2007-06-011-13/+38
| | | | | | | | | | | | | | | (moving leases between free and back to backup where there are an odd number of leases). [ISC-Bugs #16910] - The 'pool' log line has been split into two messages, one before the rebalance run, and one after. [ISC-Bugs #16910] - Any queued BNDACKs are transmitted before transmitting new BNDUPDs. This enforces the correct sequence of events for the remote server processing these messages. [ISC-Bugs #16910]