skytools.git
15 years agoInstall queue_splitter
Marko Kreen [Thu, 3 Jun 2010 14:01:17 +0000 (17:01 +0300)]
Install queue_splitter

15 years agolondiste.local_add_table: use pg_trigger instead of information_schema
Marko Kreen [Tue, 1 Jun 2010 14:25:28 +0000 (17:25 +0300)]
londiste.local_add_table: use pg_trigger instead of information_schema

information_schema uses ordinary strings as trigger names, so the
sorting order is random due to locale rules.

15 years agopgq,londite: support install over skytools 2
Marko Kreen [Tue, 1 Jun 2010 14:20:49 +0000 (17:20 +0300)]
pgq,londite: support install over skytools 2

15 years agoskytools.DBObject: remove duplicated file find logic
Marko Kreen [Tue, 1 Jun 2010 13:55:29 +0000 (16:55 +0300)]
skytools.DBObject: remove duplicated file find logic

15 years agodoc: move dox generation from apiupload to apidoc
Marko Kreen [Thu, 13 May 2010 09:14:23 +0000 (12:14 +0300)]
doc: move dox generation from apiupload to apidoc

15 years agopkgloader: avoid supressing any import errors
Marko Kreen [Tue, 11 May 2010 12:31:21 +0000 (15:31 +0300)]
pkgloader: avoid supressing any import errors

15 years agosql/pgq: compat with 9.0 bytea format
Marko Kreen [Tue, 11 May 2010 12:28:06 +0000 (15:28 +0300)]
sql/pgq: compat with 9.0 bytea format

15 years agopgq_quote_ident: compat with newer ScanKeywordLookup
Marko Kreen [Tue, 11 May 2010 12:27:22 +0000 (15:27 +0300)]
pgq_quote_ident: compat with newer ScanKeywordLookup

Also avoid quoting unreserved names

15 years agosql/londiste: 9.0 compat
Marko Kreen [Tue, 11 May 2010 12:25:31 +0000 (15:25 +0300)]
sql/londiste: 9.0 compat

- londiste.get_table_list(): qualify argument refs with function name
- regtest: load plpgsql ourself
- regtest: avoid contrib_regression on older postgres

15 years agolondiste.local_remove_table: dynamically detect triggers to be dropped.
Marko Kreen [Mon, 10 May 2010 12:25:56 +0000 (15:25 +0300)]
londiste.local_remove_table: dynamically detect triggers to be dropped.

15 years agopgq/triggers: Survive setup errors better
Marko Kreen [Mon, 10 May 2010 08:42:34 +0000 (11:42 +0300)]
pgq/triggers: Survive setup errors better

15 years agolondiste add-table: pass --skip-truncate to copy process
Marko Kreen [Mon, 10 May 2010 08:38:56 +0000 (11:38 +0300)]
londiste add-table: pass --skip-truncate to copy process

15 years agolondiste add-table: --trigger-arg switch to set custom params
Marko Kreen [Fri, 7 May 2010 11:30:32 +0000 (14:30 +0300)]
londiste add-table: --trigger-arg switch to set custom params

15 years agorefresh libusual
Marko Kreen [Fri, 7 May 2010 11:13:14 +0000 (14:13 +0300)]
refresh libusual

15 years agolondiste: test custom args
Marko Kreen [Fri, 7 May 2010 11:12:51 +0000 (14:12 +0300)]
londiste: test custom args

15 years agolondiste: regtest: avoid 'data', seems its dirty word now
Marko Kreen [Fri, 7 May 2010 11:05:53 +0000 (14:05 +0300)]
londiste: regtest: avoid 'data', seems its dirty word now

15 years agopgq_node: update regtest with new fields
Marko Kreen [Fri, 7 May 2010 10:50:09 +0000 (13:50 +0300)]
pgq_node: update regtest with new fields

15 years agopgq: random naturaldocs 1.4 changes
Marko Kreen [Fri, 7 May 2010 10:41:50 +0000 (13:41 +0300)]
pgq: random naturaldocs 1.4 changes

15 years agolondiste.local_add_table: allow custom args to triggers
Marko Kreen [Fri, 7 May 2010 10:24:00 +0000 (13:24 +0300)]
londiste.local_add_table: allow custom args to triggers

15 years agopgq_node.register_consumer: update existing reg info, instead erroring out
Marko Kreen [Fri, 7 May 2010 10:23:26 +0000 (13:23 +0300)]
pgq_node.register_consumer: update existing reg info, instead erroring out

15 years agopgq: tune regtest to autovacuum=on, which is more common
Marko Kreen [Fri, 7 May 2010 10:01:00 +0000 (13:01 +0300)]
pgq: tune regtest to autovacuum=on, which is more common

15 years agopgq/triggers: Custom SQL expressions for field values
Marko Kreen [Thu, 6 May 2010 09:37:25 +0000 (12:37 +0300)]
pgq/triggers: Custom SQL expressions for field values

Move fields around for caching the trigger arguments
and cached plans for override queries.

15 years agopgq.Consumer: remove hardwired cursor name
Marko Kreen [Wed, 28 Apr 2010 10:05:46 +0000 (13:05 +0300)]
pgq.Consumer: remove hardwired cursor name

15 years agopgq.get_batch_cursor: no need to calculate row count
Marko Kreen [Wed, 28 Apr 2010 09:49:56 +0000 (12:49 +0300)]
pgq.get_batch_cursor: no need to calculate row count

15 years agopgqd: fix maint function names.
Marko Kreen [Tue, 27 Apr 2010 12:53:20 +0000 (15:53 +0300)]
pgqd: fix maint function names.

15 years agorefresh libusual, add WFLAGS to CFLAGS
Marko Kreen [Tue, 27 Apr 2010 12:43:16 +0000 (15:43 +0300)]
refresh libusual, add WFLAGS to CFLAGS

15 years agopgqd: fix help string, detect --help
Marko Kreen [Tue, 27 Apr 2010 12:42:17 +0000 (15:42 +0300)]
pgqd: fix help string, detect --help

15 years agoRequire [londiste3] in londiste config.
Marko Kreen [Tue, 27 Apr 2010 10:41:49 +0000 (13:41 +0300)]
Require [londiste3] in londiste config.

15 years agoinstall: add suffix '3' to scripts that conflict with skytools 2
Marko Kreen [Tue, 27 Apr 2010 10:39:09 +0000 (13:39 +0300)]
install: add suffix '3' to scripts that conflict with skytools 2

15 years agorefresh libusual
Marko Kreen [Mon, 12 Apr 2010 11:35:04 +0000 (14:35 +0300)]
refresh libusual

15 years agorefresh libusual, sync pgqd with changes in pgsocket
Marko Kreen [Fri, 12 Mar 2010 13:33:01 +0000 (15:33 +0200)]
refresh libusual, sync pgqd with changes in pgsocket

15 years agopgq upgrade: missed few obsoleted functions
Marko Kreen [Fri, 12 Mar 2010 13:14:16 +0000 (15:14 +0200)]
pgq upgrade: missed few obsoleted functions

15 years agoMakefile: add configure.ac -> lib/m4/usual.m4 dependency
Marko Kreen [Fri, 12 Mar 2010 13:03:31 +0000 (15:03 +0200)]
Makefile: add configure.ac -> lib/m4/usual.m4 dependency

15 years agopgq: 2.1.x to 3.0 upgrade script
Marko Kreen [Fri, 12 Mar 2010 13:02:46 +0000 (15:02 +0200)]
pgq: 2.1.x to 3.0 upgrade script

15 years agoskytools.parse_pgarray(): ignore dimension prefix
Marko Kreen [Fri, 12 Mar 2010 12:17:31 +0000 (14:17 +0200)]
skytools.parse_pgarray(): ignore dimension prefix

15 years agopgqd: Add switch to show template config.
Marko Kreen [Fri, 12 Mar 2010 12:16:07 +0000 (14:16 +0200)]
pgqd: Add switch to show template config.

15 years agopgq/triggers: sprintf->snprintf
Marko Kreen [Tue, 19 Jan 2010 13:28:03 +0000 (15:28 +0200)]
pgq/triggers: sprintf->snprintf

15 years agopgq/triggers: Fix crash in case invalidate happens from signal handler.
Marko Kreen [Fri, 15 Jan 2010 15:39:57 +0000 (17:39 +0200)]
pgq/triggers: Fix crash in case invalidate happens from signal handler.

Currently code assumed the invalidate happens only from per-query checks,
but this seems not to be the case.

Fix it by moving reset code out from invalidate callback.

Also old code seemed to leak htab per full reset, because it assumed
to be located under cache context, but init code did not assign it there.

Thanks to Andrew Dunstan for the report.

15 years agoRedundant pg_auth file synch removed. By Mark Kirkwood.
Martin Pihlak [Tue, 29 Dec 2009 11:32:15 +0000 (13:32 +0200)]
Redundant pg_auth file synch removed. By Mark Kirkwood.

15 years agoNew python module: skytools.timeutil
Marko Kreen [Fri, 11 Dec 2009 14:57:17 +0000 (16:57 +0200)]
New python module: skytools.timeutil

ATM contains FixedOffsetTimezone class and parse_iso_timestamp()
function, which are sadly missing from core Python.

15 years agorefresh libusual
Marko Kreen [Fri, 11 Dec 2009 14:21:29 +0000 (16:21 +0200)]
refresh libusual

15 years agosql/ticker: use usual/pgsocket for connection handling
Marko Kreen [Sat, 5 Dec 2009 16:20:06 +0000 (18:20 +0200)]
sql/ticker: use usual/pgsocket for connection handling

the connection.c was already generalized and moved to libusual.
make the ticker use it now.

15 years agofix londiste import
Marko Kreen [Fri, 4 Dec 2009 16:19:00 +0000 (18:19 +0200)]
fix londiste import

15 years agotemporarily install only minimal number of scripts
Marko Kreen [Fri, 4 Dec 2009 15:50:36 +0000 (17:50 +0200)]
temporarily install only minimal number of scripts

15 years agopgq/ticker: fix leaks
Marko Kreen [Fri, 4 Dec 2009 15:28:50 +0000 (17:28 +0200)]
pgq/ticker: fix leaks

- make connection.c responsible for freeing PGresult
- free strlist
- make SIGINT free allocated resources

15 years agopgq/triggers: tag pgq.logtriga() as obsolete.
Marko Kreen [Fri, 4 Dec 2009 11:46:58 +0000 (13:46 +0200)]
pgq/triggers: tag pgq.logtriga() as obsolete.

Plus few other docstring cleanups.

15 years agopgq_coop: test if main consumer has batch open
Marko Kreen [Fri, 4 Dec 2009 11:26:03 +0000 (13:26 +0200)]
pgq_coop: test if main consumer has batch open

15 years agofix qadmin todo items
Marko Kreen [Fri, 4 Dec 2009 11:25:12 +0000 (13:25 +0200)]
fix qadmin todo items

15 years agoDBScript: move self.args check for config to load_config()
Marko Kreen [Thu, 3 Dec 2009 15:48:10 +0000 (17:48 +0200)]
DBScript: move self.args check for config to load_config()

This allows config-less scripts to override it.

15 years agoDBScript.run_func_safely: stop playing with prefer_looping
Marko Kreen [Thu, 3 Dec 2009 15:27:53 +0000 (17:27 +0200)]
DBScript.run_func_safely: stop playing with prefer_looping

Precalculating 'prefer_looping' does not work as the parameters
may be changed inside called function.

15 years agoDBscript.sleep(): wrapper around time.sleep()
Marko Kreen [Thu, 3 Dec 2009 15:13:52 +0000 (17:13 +0200)]
DBscript.sleep(): wrapper around time.sleep()

This will allow smarter handling of sleep time in the future.
Eg. wake up on notice from db.

15 years agoDBScript: quick exit on MemoryError
Marko Kreen [Thu, 3 Dec 2009 14:45:26 +0000 (16:45 +0200)]
DBScript: quick exit on MemoryError

15 years agoskytools.connect_database: avoid tuning keepalive on unix socket
Marko Kreen [Thu, 3 Dec 2009 14:44:37 +0000 (16:44 +0200)]
skytools.connect_database: avoid tuning keepalive on unix socket

15 years agoskytools.Config: allow missing filename
Marko Kreen [Thu, 3 Dec 2009 14:44:02 +0000 (16:44 +0200)]
skytools.Config: allow missing filename

15 years agoMerge remote branch 'martin/master'
Marko Kreen [Fri, 27 Nov 2009 09:59:04 +0000 (11:59 +0200)]
Merge remote branch 'martin/master'

15 years agopgq.sqltriga/pgq.logutriga now fire in origin and replica roles.
Martin Pihlak [Fri, 27 Nov 2009 09:34:23 +0000 (11:34 +0200)]
pgq.sqltriga/pgq.logutriga now fire in origin and replica roles.
This allows 'ENABLE ALWAYS' and 'ENABLE REPLICA' triggers to
fire on the target side. Previous behaviour was to only fire in
origin role.

15 years agoMerge branch 'master' of git://github.com/markokr/skytools-dev
Martin Pihlak [Fri, 27 Nov 2009 09:09:04 +0000 (11:09 +0200)]
Merge branch 'master' of git://github.com/markokr/skytools-dev

15 years agoqadmin: parser cleanup, make * optional.
Marko Kreen [Tue, 24 Nov 2009 15:43:33 +0000 (17:43 +0200)]
qadmin: parser cleanup, make * optional.

15 years agosql/pgq: make pgq.logutriga() ignore UPDATE when only ignored fields change
Marko Kreen [Tue, 24 Nov 2009 15:16:41 +0000 (17:16 +0200)]
sql/pgq: make pgq.logutriga() ignore UPDATE when only ignored fields change

previously it behaved differently from sqltriga, as it did not need
to analyze which field change.  but it's better if it acts like
sqltriga when field ignoring is used.

15 years agosql/pgq: update regtest for get_batch_cursor() change
Marko Kreen [Tue, 24 Nov 2009 14:54:40 +0000 (16:54 +0200)]
sql/pgq: update regtest for get_batch_cursor() change

15 years agopsycopgwrapper: Activate TCP keepalive on database connections
Marko Kreen [Tue, 24 Nov 2009 13:55:09 +0000 (15:55 +0200)]
psycopgwrapper: Activate TCP keepalive on database connections

Turn on keepalive by default, to avoid hanged scripts in case of
network problems.

Also tune the keepalive timeouts smaller, on Linux at least,
so that the error happens after 5 min blackout.
(4 min idle + 4x15sec keepalive pings)

15 years agoMerge branch 'master' of git://github.com/markokr/skytools-dev
Martin Pihlak [Fri, 6 Nov 2009 08:57:06 +0000 (10:57 +0200)]
Merge branch 'master' of git://github.com/markokr/skytools-dev

15 years agoqadmin: extend REGISTER CONSUMER
Marko Kreen [Thu, 5 Nov 2009 12:57:24 +0000 (14:57 +0200)]
qadmin: extend REGISTER CONSUMER

Custom tick pos: at <tick_id>
Copy other registration: copy <consumer>

15 years agotodo update
Marko Kreen [Wed, 4 Nov 2009 13:30:48 +0000 (15:30 +0200)]
todo update

15 years agoDBScript: restore .looping variable
Marko Kreen [Wed, 4 Nov 2009 13:28:49 +0000 (15:28 +0200)]
DBScript: restore .looping variable

loop_delay is loaded from conf, so it conflicts with .set_single_loop()
in scripts which have both looping mode and non-looping mode.
Eg: londiste, walmgr

15 years agopgq.Consumer: report new class vars in top-level
Marko Kreen [Wed, 4 Nov 2009 13:28:27 +0000 (15:28 +0200)]
pgq.Consumer: report new class vars in top-level

15 years agoqadmin: fix style problems
Marko Kreen [Wed, 4 Nov 2009 13:27:45 +0000 (15:27 +0200)]
qadmin: fix style problems

15 years agoskytools_upgrade: add missing import
Marko Kreen [Wed, 4 Nov 2009 13:27:16 +0000 (15:27 +0200)]
skytools_upgrade: add missing import

15 years agowalmgr: remove double import
Marko Kreen [Wed, 4 Nov 2009 13:26:51 +0000 (15:26 +0200)]
walmgr: remove double import

15 years agopychecker: dont warn for class docstrs, too much noise
Marko Kreen [Wed, 4 Nov 2009 13:25:47 +0000 (15:25 +0200)]
pychecker: dont warn for class docstrs, too much noise

15 years agosql/londiste: restore fkeys to local tables only
Marko Kreen [Wed, 4 Nov 2009 12:24:54 +0000 (14:24 +0200)]
sql/londiste: restore fkeys to local tables only

Fwd-port from 2.1-stable

15 years agoDBScript: avoid second reload on startup
Marko Kreen [Wed, 4 Nov 2009 12:24:28 +0000 (14:24 +0200)]
DBScript: avoid second reload on startup

15 years agotodo update
Marko Kreen [Tue, 3 Nov 2009 12:43:41 +0000 (14:43 +0200)]
todo update

15 years agopgqadm status: show quick stats
Marko Kreen [Tue, 3 Nov 2009 12:37:37 +0000 (14:37 +0200)]
pgqadm status: show quick stats

15 years agosql/pgq: add quick stats to get_{queue|consumer}_info
Marko Kreen [Tue, 3 Nov 2009 12:30:27 +0000 (14:30 +0200)]
sql/pgq: add quick stats to get_{queue|consumer}_info

get_consumer_info().pending_events

  How batched events are availble for read.

get_queue_info().ev_per_sec

  Average event creation speed, based on recent 20 batches.

get_queue_info().ev_new

  How many events have appreased in queue since recent tick.
  Those are not yet in any batch so consumers cannot read them yet.

15 years agoDBScript: use log.exception also for psycopg errors
Marko Kreen [Tue, 3 Nov 2009 12:28:27 +0000 (14:28 +0200)]
DBScript: use log.exception also for psycopg errors

15 years agopsycopgwrapper: make server_version int
Marko Kreen [Tue, 3 Nov 2009 12:27:40 +0000 (14:27 +0200)]
psycopgwrapper: make server_version int

15 years agofix pgq brokenness related to recent commits
Marko Kreen [Tue, 3 Nov 2009 12:26:19 +0000 (14:26 +0200)]
fix pgq brokenness related to recent commits

- get_batch_cursor()
- loop_delay

15 years agotestlib: set pipefail to catch errors in middle of pipe
Marko Kreen [Tue, 3 Nov 2009 12:24:26 +0000 (14:24 +0200)]
testlib: set pipefail to catch errors in middle of pipe

15 years agolondiste: copy expression support
Marko Kreen [Tue, 3 Nov 2009 12:21:28 +0000 (14:21 +0200)]
londiste: copy expression support

15 years agopkgloader: allow non-numerics after '-'
Marko Kreen [Tue, 3 Nov 2009 12:19:22 +0000 (14:19 +0200)]
pkgloader: allow non-numerics after '-'

Clean up few veriable names also

15 years agolondiste copy: use TRUNCATE ONLY on 8.4+
Marko Kreen [Wed, 28 Oct 2009 14:03:28 +0000 (16:03 +0200)]
londiste copy: use TRUNCATE ONLY on 8.4+

15 years agopsycopgwrapper: Fill .server_version on older psycopg
Marko Kreen [Wed, 28 Oct 2009 14:00:51 +0000 (16:00 +0200)]
psycopgwrapper: Fill .server_version on older psycopg

This make the parameter always available.

15 years agodbstruct: Remove ONLY from ADD CONSTRAINT.
Marko Kreen [Wed, 28 Oct 2009 13:34:27 +0000 (15:34 +0200)]
dbstruct: Remove ONLY from ADD CONSTRAINT.

Parent table cannot have contraints that the childs do not have.

15 years agoMakefile: pass sub-* target exit status back
Marko Kreen [Mon, 2 Nov 2009 13:45:47 +0000 (15:45 +0200)]
Makefile: pass sub-* target exit status back

16 years agopython/: Add --version switch to all scripts.
Marko Kreen [Wed, 14 Oct 2009 15:03:54 +0000 (18:03 +0300)]
python/: Add --version switch to all scripts.

Based on patch by Hannu Krosing

16 years agolondiste: make copy unlink inherited table from it's parents
Marko Kreen [Wed, 14 Oct 2009 14:34:40 +0000 (17:34 +0300)]
londiste: make copy unlink inherited table from it's parents

Otherwise we cannot drop constraints.

Unlink from childs is not needed, so they are left as-is.

Patch by Hannu Krosing

16 years agoskytools.DBScript: safer pidfile writing
Marko Kreen [Wed, 14 Oct 2009 13:47:31 +0000 (16:47 +0300)]
skytools.DBScript: safer pidfile writing

- signal_pidfile: Clarify ValueError error message. Thrown usually
  on empty pidfiles, the error messega will now mention the pidfile name.

- run_single_process: restructure pidfile writing, so that
  the pidfile is removed if .write() failed, but not when open() failed.
  This should avoid the chance that empty pidfiles are hanging around.

16 years agopython/skytools: add doctest-based regtests to few non-sql functions
Marko Kreen [Wed, 14 Oct 2009 13:37:17 +0000 (16:37 +0300)]
python/skytools: add doctest-based regtests to few non-sql functions

Seems to be better testing method than ad-hoc scripts.  They will
serve as examples too.

Also fix few minor problems found in the process:
- parse_pgarray:  check if str ends with }
- parse_pgarray: support NULL
- quote_fqident: add 'public.' schema to idents without schema
- fq_name_parts: return always list

16 years agosql/pgq/triggers: magic fields to set event fields directly.
Marko Kreen [Wed, 14 Oct 2009 13:30:18 +0000 (16:30 +0300)]
sql/pgq/triggers: magic fields to set event fields directly.

pgq.sqltriga() / pgq.logutriga() now consider following fields magic:

  _pgq_ev_type
  _pgq_ev_data
  _pgq_ev_extra1
  _pgq_ev_extra2
  _pgq_ev_extra3
  _pgq_ev_extra4

If any of them is present in table, corresponding event field is set directly
to it's value, overriding value generated by trigger.

16 years agoMerge remote branch 'martin/master'
Marko Kreen [Tue, 6 Oct 2009 15:01:23 +0000 (18:01 +0300)]
Merge remote branch 'martin/master'

16 years agoMerge branch 'master' of git://github.com/markokr/skytools-dev
Martin Pihlak [Tue, 6 Oct 2009 14:16:55 +0000 (17:16 +0300)]
Merge branch 'master' of git://github.com/markokr/skytools-dev

16 years agoFix the pg_[x]log rsyncing code to leave out directory contents.
Martin Pihlak [Tue, 6 Oct 2009 14:12:19 +0000 (17:12 +0300)]
Fix the pg_[x]log rsyncing code to leave out directory contents.

16 years agodbscript: rename connection_setup to connection_hook
Marko Kreen [Mon, 21 Sep 2009 13:25:00 +0000 (16:25 +0300)]
dbscript: rename connection_setup to connection_hook

16 years agoDBScript: Simplify looping and docstring handling
Marko Kreen [Mon, 21 Sep 2009 13:13:27 +0000 (16:13 +0300)]
DBScript: Simplify looping and docstring handling

- looping: remove .do_single_loop and .looping variables, let only .loop_delay
  control looping.  If loop_delay is missing from confing or 0, then
  instead sleep, the script will exit.

- docstr: print docstring fragments recursively, so each class
  needs to only document its own parameters.

- londiste.py: use Replicator class to print default config as it has
  proper class inheritance.

16 years agoAdd various junk to .gitignore
Marko Kreen [Mon, 21 Sep 2009 13:12:56 +0000 (16:12 +0300)]
Add various junk to .gitignore

16 years agosqltools: make mk_update_sql()/mk_delete_sql() use ONLY
Marko Kreen [Mon, 21 Sep 2009 11:37:28 +0000 (14:37 +0300)]
sqltools: make mk_update_sql()/mk_delete_sql() use ONLY

This will make urlencoded events behave same as sql events.

16 years agosql/pgq: trigger fixes
Marko Kreen [Mon, 21 Sep 2009 11:29:51 +0000 (14:29 +0300)]
sql/pgq: trigger fixes

- pgq.logutriga() did not put custom pkey= value into events.

- pgq.logutriga() and pgq.sqltriga() did allow UPDATE and DELETE
  on tables without pkey, running into SQL errors downstream.
  They should throw error in such case.

16 years agopgq.maint_retry_events(): lock table to allow only single mover
Marko Kreen [Thu, 17 Sep 2009 08:46:10 +0000 (11:46 +0300)]
pgq.maint_retry_events(): lock table to allow only single mover

Use SHARE UPDATE EXCLUSIVE lock, which will not conflict with inserts.

16 years agoDisable archive_command in restored postgresql.conf
Martin Pihlak [Tue, 15 Sep 2009 12:24:01 +0000 (15:24 +0300)]
Disable archive_command in restored postgresql.conf
archive_command is set to /bin/true instead of disabling archive_mode
This avoids the extra reconfiguration restart when the slave is actually
booted and promoted to master. Based on patch by Mark Kirkwoord.