aboutsummaryrefslogtreecommitdiff
path: root/src/backend
Commit message (Collapse)AuthorAge
* Further message changes when recovery.conf parameters missing.Simon Riggs2010-04-06
|
* Rename "Log-streaming replication parameters" header to "Standby serverHeikki Linnakangas2010-04-06
| | | | | | parameters" in recovery.conf, to match the grouping in the documentation. Fujii Masao
* Change some debug ereports to elogs, as requested by translation team.Simon Riggs2010-04-06
|
* Arrange to remove pg_default_acl entries completely if their ACL settingTom Lane2010-04-05
| | | | | | | | is changed to match the hard-wired default. This avoids accumulating useless catalog entries, and also provides a path for dropping the owning role without using DROP OWNED BY. Per yesterday's complaint from Jaime Casanova, the need to use DROP OWNED BY for that is less than obvious, so providing this alternative method might save some user frustration.
* Fix updateAclDependencies() to not assume that ACL role dependencies can onlyTom Lane2010-04-05
| | | | | | | | | | be added during GRANT and can only be removed during REVOKE; and fix its callers to not lie to it about the existing set of dependencies when instantiating a formerly-default ACL. The previous coding accidentally failed to malfunction so long as default ACLs contain only references to the object's owning role, because that role is ignored by updateAclDependencies. However this is obviously pretty fragile, as well as being an undocumented assumption. The new coding is a few lines longer but IMO much clearer.
* Improve phrasing of warning message for NOTIFY queue getting too full.Tom Lane2010-04-05
| | | | Per gripe from Peter.
* Check compulsory parameters in recovery.conf in standby_mode, per docs.Simon Riggs2010-04-02
|
* Move system startup message prior to any calls out of data directory.Simon Riggs2010-04-02
| | | | | | | This allows us to see what mode the server is in before it starts to perform actions that can block or hang. Otherwise server messages may not appear until after messages that say FATAL the database server is starting up.
* Don't pass an invalid file handle to dup2(). That causes a crash onHeikki Linnakangas2010-04-01
| | | | | | | | | | | Windows, thanks to a feature in CRT called Parameter Validation. Backpatch to 8.2, which is the oldest version supported on Windows. In 8.2 and 8.3 also backpatch the earlier change to use DEVNULL instead of NULL_DEV #define for a /dev/null-like device. NULL_DEV was hard-coded to "/dev/null" regardless of platform, which didn't work on Windows, while DEVNULL works on all platforms. Restarting syslogger didn't work on Windows on versions 8.3 and below because of that.
* Refer to max_wal_senders in a more consistent fashion.Robert Haas2010-04-01
| | | | | | | The error message now makes explicit reference to the GUC that must be changed to fix the problem, using wording suggested by Tom Lane. Along the way, rename the GUC from MaxWalSenders to max_wal_senders for consistency and grep-ability.
* Change recovery.conf.sample to match postgresql.conf by showing onlyBruce Momjian2010-03-31
| | | | default values, with example comments.
* Fix "constraint_exclusion = partition" logic so that it will also attemptTom Lane2010-03-30
| | | | | | constraint exclusion on an inheritance set that is the target of an UPDATE or DELETE query. Per gripe from Marc Cousin. Back-patch to 8.4 where the feature was introduced.
* Change the retry-loop in standby mode to also try restoring files fromHeikki Linnakangas2010-03-30
| | | | | | | | | | | | | | | | pg_xlog directory. This is essential for replaying WAL records that were streamed from the master, after a standby server restart. If a corrupt record is seen in a file restored from the archive or streamed from the master, log it as a WARNING and keep retrying. If the corruption is permanent, and not just a glitch in the whatever copies the files to the archive or a network error not caught by CRC checks in TCP for example, we will keep retrying and logging the WARNING indefinitely. But that's better than shutting down completely, the standby is still useful for running read-only queries. In PITR the recovery ends at such a corrupt record, which is a bit questionable, but that's the behavior we had in previous releases and we don't feel like chaning it now. It does make sense for tools like pg_standby.
* Message tuningPeter Eisentraut2010-03-30
|
* Properly initialize local varaible inBruce Momjian2010-03-30
| | | | | btree_xlog_delete_get_latestRemovedXid(). This variable was only tested in assert builds.
* Add comma missing from postgresql.conf comment.Bruce Momjian2010-03-30
|
* Edit recovery.conf.sample so it matches docs. Change standby_modeSimon Riggs2010-03-29
| | | | | | example to 'on or 'off' rather than 'true' or 'false', as shown in docs. Add restartpoint_command. Add section header for recovery target parameters, matching docs.
* Rework join-removal logic as per recent discussion. In particular thisTom Lane2010-03-28
| | | | | fixes things so that it works for cases where nested removals are possible. The overhead of the optimization should be significantly less, as well.
* Derive latestRemovedXid for btree deletes by reading heap pages. TheSimon Riggs2010-03-28
| | | | | | | | | | | WAL record for btree delete contains a list of tids, even when backup blocks are present. We follow the tids to their heap tuples, taking care to follow LP_REDIRECT tuples. We ignore LP_DEAD tuples on the understanding that they will always have xmin/xmax earlier than any LP_NORMAL tuples referred to by killed index tuples. Iff all tuples are LP_DEAD we return InvalidTransactionId. The heap relfilenode is added to the WAL record, requiring API changes to pass down the heap Relation. XLOG_PAGE_MAGIC updated.
* Flush CopyOutResponse when starting streaming in walsender, so that it'sHeikki Linnakangas2010-03-26
| | | | | | not delayed until the first WAL record is sent. Fujii Masao
* Modify some new and pre-existing messages for translatability.Simon Riggs2010-03-25
|
* Prevent ALTER USER f RESET ALL from removing the settings that were put thereAlvaro Herrera2010-03-25
| | | | | | | | by a superuser -- "ALTER USER f RESET setting" already disallows removing such a setting. Apply the same treatment to ALTER DATABASE d RESET ALL when run by a database owner that's not superuser.
* Additional thoughts on WALSender cpu reduction. Use long typeSimon Riggs2010-03-24
| | | | and alter a comment to reduce confusion.
* Change replication connection log format to allow for a databaseSimon Riggs2010-03-24
| | | | | called replication. Add host and port details, following format of messages in BackendInitialize().
* Reduce CPU utilisation of WALSender process. Process was using 10% CPUSimon Riggs2010-03-24
| | | | | | doing nothing, caused by naptime specified in milliseconds yet units of pg_usleep() parameter is microseconds. Correctly specifying units reduces call frequency by 1000. Reduction in CPU consumption verified.
* Fix thinko in log message for "sameuser" ident map mismatch: the providedTom Lane2010-03-24
| | | | | | | and authenticated usernames were swapped. Reported by Bryan Henderson in bug #5386. Also clean up poorly-maintained header comment for this function.
* Now that we know last_statrequest > last_statwrite can be observed in theTom Lane2010-03-24
| | | | buildfarm, expend a little more effort on the log message for it.
* Update description of walrcv_receive() function to match reality.Heikki Linnakangas2010-03-24
|
* Document in postgresql.conf that the max_standby_delay default is 30Bruce Momjian2010-03-24
| | | | 'seconds'.
* Shorten suffix of automatically created indexes to "_excl" when usingSimon Riggs2010-03-22
| | | | exclusion constraints, in line with string length of other pre-9.0 suffixes.
* Fix an oversight in join-removal optimization: we have to check not only forTom Lane2010-03-22
| | | | | plain Vars that are generated in the inner rel and used above the join, but also for PlaceHolderVars. Per report from Oleg K.
* Message tuningPeter Eisentraut2010-03-21
|
* Clear error_context_stack and debug_query_string at the beginning of proc_exit,Tom Lane2010-03-20
| | | | | | | | | | | | | so that we won't try to attach any context printouts to messages that get emitted while exiting. Per report from Dennis Koegel, the context functions won't necessarily work after we've started shutting down the backend, and it seems possible that debug_query_string could be pointing at freed storage as well. The context information doesn't seem particularly relevant to such messages anyway, so there's little lost by suppressing it. Back-patch to all supported branches. I can only demonstrate a crash with log_disconnections messages back to 8.1, but the risk seems real in 8.0 and before anyway.
* Forbid renaming columns of objects whose column names are system-generated.Robert Haas2010-03-20
| | | | KaiGai Kohei, with adjustments to the comments.
* Modify error context callback functions to not assume that they can fetchTom Lane2010-03-19
| | | | | | | | | | | | | | | | | | catalog entries via SearchSysCache and related operations. Although, at the time that these callbacks are called by elog.c, we have not officially aborted the current transaction, it still seems rather risky to initiate any new catalog fetches. In all these cases the needed information is readily available in the caller and so it's just a matter of a bit of extra notation to pass it to the callback. Per crash report from Dennis Koegel. I've concluded that the real fix for his problem is to clear the error context stack at entry to proc_exit, but it still seems like a good idea to make the callbacks a bit less fragile for other cases. Backpatch to 8.4. We could go further back, but the patch doesn't apply cleanly. In the absence of proof that this fixes something and isn't just paranoia, I'm not going to expend the effort.
* Add connection messages for streaming replication. log_connectionsSimon Riggs2010-03-19
| | | | | | | was broken for a replication connection and no messages were displayed on either standby or primary, at any debug level. Connection messages needed to diagnose session drop/reconnect events. Use LOG mode for now, discuss lowering in later releases.
* Minor tweaks on libpqrcv_connect(): ensure conninfo_repl[] isSimon Riggs2010-03-19
| | | | | correctly sized and expand comment to explain otherwise undocumented use of replication connection parameter.
* Adjust comment in .history file to match recovery target specified. CommentSimon Riggs2010-03-19
| | | | | | | | present since 8.0 was never fully meaningful, since two recovery targets cannot be specified. Refactor recovery target type to make this change and associated code easier to understand. No change in function. Bug report arising from internal support question.
* Reset btpo.xact following recovery of btree delete page. Add btpo_xactSimon Riggs2010-03-19
| | | | | | | field into WAL record and reset it from there, rather than using FrozenTransactionId which can lead to some corner case bugs. Problem report and suggested route to a fix from Heikki, details by me.
* Add restartpoint_command option to recovery.conf. Fix bug in %r handlingHeikki Linnakangas2010-03-18
| | | | | | | | | in recovery_end_command, it always came out as 0 because InRedo was cleared before recovery_end_command was executed. Also, always take ControlFileLock when reading checkpoint location for %r. The recovery_end_command bug and the missing locking was present in 8.4 as well, that part of this patch will be backported separately.
* Add vacuum_defer_cleanup_age to postgresql.conf.sample.Simon Riggs2010-03-18
|
* Pass incompletely-transformed aggregate argument lists as separate parametersTom Lane2010-03-17
| | | | | | to transformAggregateCall, instead of abusing fields in Aggref to carry them temporarily. No change in functionality but hopefully the code is a bit clearer now. Per gripe from Gokulakannan Somasundaram.
* Throw a nicer error message if a standby server attempts to connect whileHeikki Linnakangas2010-03-16
| | | | | | the master is still in recovery. We don't support cascading slaves yet. Patch by Fujii Masao, with slightly changed wording.
* Remove incorrect comment from GetWriteRecPtr(): the return value is alwaysSimon Riggs2010-03-15
| | | | correct, as described in comments at start of xlog.c
* Revert all keepalive moves, reevaluate.Bruce Momjian2010-03-13
|
* Move more tcp keepalive macros to be consistent.Bruce Momjian2010-03-13
|
* Move TCP keepalive macro definitionBruce Momjian2010-03-13
| | | | Jaime Casanova
* Add libpq warning message if the .pgpass-retrieved password fails.Bruce Momjian2010-03-13
| | | | Add ERRCODE_INVALID_PASSWORD sqlstate error code.
* Allow underscores in tsearch email addressses, per RFC 5322 and reportBruce Momjian2010-03-13
| | | | | | by Dan O'Hara. Patch by Teodor Sigaev
* Add some logging code for unexpected cases in pgstat.c, particularly beingTom Lane2010-03-12
| | | | | | | | | | unable to read a stats file for reasons other than ENOENT, and having to reset last_statrequest because it's later than current time in the collector. Not clear if this will shed any light on the "pgstat wait timeout" business, but it seems like a good idea in general. In passing, do some message-style-police work on recently-added pgstat_reset_shared_counters code.