Release test plan: live checks before tagging the next release #21
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
eric/10-wancarp#21
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Purpose
Live tests to run on the HA pair before tagging the next release. The off-box harness (
php tests/run.php) covers the logic; these cover what only a real box can confirm. Add a section here for each issue fixed before the release that needs a live check.Install the
mainbuild on both nodes first and confirm the START banner reportsversion=<last release>+dev.Watch the logs on both nodes throughout:
Pre-checks
/usr/local/etc/rc.syshook.d/carp/10-wancarp --dryrun --reconcileshows the expectedrole=line and no errors.boot check product::booting() present; booting=no.That is the check the INIT rule relies on during boot (#15). If it reportsclass product MISSINGinstead, an INIT event during boot would take WAN down; reopen #15.#15: all-INIT node takes its WAN down
A. Lost LAN link on the MASTER
role=BACKUP counted=[1@<lan>=INIT] (MASTER for nothing, INIT), and WAN goes down (ifconfig <wan>has noUPflag).B. Temporarily Disable CARP
INITinifconfig(the issue flagged this as unconfirmed). If they show something else, note what and check the role line still takes WAN down.C. Boot
(INIT while booting: left to the next event)and doesn't touch WAN (nodisabling interface 'wan'line during boot). Before the #15 follow-up fix (222180a) the boot check always read "not booting" on a real box, so this is the check that matters. Once it rejoins, WAN ends up live on exactly one node.role=BACKUP,had drifted).D. Dry-run
./10-wancarp --dryrun 1@<lan> INITon the MASTER prints theWOULD disablelines and changes nothing.#17: BACKUP no longer calls interface_configure()
The removed call did nothing, so BACKUP should behave exactly as before. These checks confirm that on a real box.
disabling interface 'wan'and endsresult=ok changed=yes, with noUNCAUGHT,partialor other error lines.ifconfig <wan>has noUPflag and noinetaddress, andpgrep -fl 'dhclient.*<wan>'finds nothing.$remove_backup_routeis set:netstat -rnshowsdefaultvia$lan_vip, and the node can still reach the Internet through the peer (for example,pkg updateworks)../10-wancarp --dryrun 1@<lan> BACKUPon the MASTER printswould interface_reset('wan'), unset enable (in-memory), ifconfig <wan> down.with nointerface_configure(), and changes nothing.#18: lock in /var/run with a bounded wait
Run on the BACKUP, firing an event that matches its current role, so nothing changes even if the run went ahead. In one shell, hold the lock; in a second, fire the event:
exit=1. The log showstimed out after 120s waiting for lock /var/run/wancarp.lockandEND ... aborted=lock changed=no, and WAN is untouched./usr/local/etc/rc.syshook.d/carp/10-wancarp --reconcile; echo "exit=$?"returnsexit=0at once and logs nothing.sleepends, fire the same event again: it runs normally and endsresult=ok changed=no.ls -l /var/run/wancarp.lockshows-rw-------owned by root (not readable by other users, sinceflock()works on a read-only descriptor), and nothing new appears at/tmp/wancarp.lock(an old one left by 1.1.1 is harmless and can be deleted).su -m nobody -c 'lockf -k -t 0 /var/run/wancarp.lock true'; echo "exit=$?"fails withPermission deniedand a non-zero exit.Regression: normal failover
configctl interface reconfigure wan. Within a minute the reconcile takes WAN back down and logshad drifted.Release
[Unreleased]inCHANGELOG.md, setVERSION, commit, and push the tag.Updated after the follow-up audit of #15, #18 and #20 (
222180a): replaced themethod_exists()boot pre-check, which would have readbool(false)on a healthy box, with the new dry-runboot checkline; flagged the boot tests in #15 C as the ones that confirm that fix; the #18 lock now expects-rw-------, plus a check thatnobodycan't take it.