summaryrefslogtreecommitdiff
path: root/src/backend/utils/init/globals.c
Commit message (Collapse)AuthorAgeFilesLines
* pgindent run on all C files. Java run to follow. initdb/regressionBruce Momjian2001-10-251-2/+3
| | | | tests pass.
* Fix getopt-vs-init_ps_display problem by copying original argv[] info,Tom Lane2001-10-211-2/+4
| | | | | | per suggestion from Peter. Simplify several APIs by transmitting the original argv location directly from main.c to ps_status.c, instead of passing it down through several levels of subroutines.
* Give VACUUM its own GUC parameter for memory usage, rather thanTom Lane2001-09-211-1/+2
| | | | | piggybacking on SortMem. Add documentation for some recently-added GUC parameters that had so far escaped it.
* Replace implementation of pg_log as a relation accessed through theTom Lane2001-08-251-2/+1
| | | | | | | | | | | buffer manager with 'pg_clog', a specialized access method modeled on pg_xlog. This simplifies startup (don't need to play games to open pg_log; among other things, OverrideTransactionSystem goes away), should improve performance a little, and opens the door to recycling commit log space by removing no-longer-needed segments of the commit log. Actual recycling is not there yet, but I felt I should commit this part separately since it'd still be useful if we chose not to do transaction ID wraparound.
* Clean up various to-do items associated with system indexes:Tom Lane2001-06-121-20/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | pg_database now has unique indexes on oid and on datname. pg_shadow now has unique indexes on usename and on usesysid. pg_am now has unique index on oid. pg_opclass now has unique index on oid. pg_amproc now has unique index on amid+amopclaid+amprocnum. Remove pg_rewrite's unnecessary index on oid, delete unused RULEOID syscache. Remove index on pg_listener and associated syscache for performance reasons (caching rows that are certain to change before you need 'em again is rather pointless). Change pg_attrdef's nonunique index on adrelid into a unique index on adrelid+adnum. Fix various incorrect settings of pg_class.relisshared, make that the primary reference point for whether a relation is shared or not. IsSharedSystemRelationName() is now only consulted to initialize relisshared during initial creation of tables and indexes. In theory we might now support shared user relations, though it's not clear how one would get entries for them into pg_class &etc of multiple databases. Fix recently reported bug that pg_attribute rows created for an index all have the same OID. (Proof that non-unique OID doesn't matter unless it's actually used to do lookups ;-)) There's no need to treat pg_trigger, pg_attrdef, pg_relcheck as bootstrap relations. Convert them into plain system catalogs without hardwired entries in pg_class and friends. Unify global.bki and template1.bki into a single init script postgres.bki, since the alleged distinction between them was misleading and pointless. Not to mention that it didn't work for setting up indexes on shared system relations. Rationalize locking of pg_shadow, pg_group, pg_attrdef (no need to use AccessExclusiveLock where ExclusiveLock or even RowExclusiveLock will do). Also, hold locks until transaction commit where necessary.
* Remove unused tables pg_variable, pg_inheritproc, pg_ipl tables. InitdbBruce Momjian2001-05-141-2/+1
| | | | forced.
* Make bootstrap debug messages more readable. Clean up some clutter.Peter Eisentraut2001-05-121-2/+1
|
* pgindent run. Make it all clean.Bruce Momjian2001-03-221-2/+2
|
* XLOG (and related) changes:Tom Lane2001-03-131-49/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Store two past checkpoint locations, not just one, in pg_control. On startup, we fall back to the older checkpoint if the newer one is unreadable. Also, a physical copy of the newest checkpoint record is kept in pg_control for possible use in disaster recovery (ie, complete loss of pg_xlog). Also add a version number for pg_control itself. Remove archdir from pg_control; it ought to be a GUC parameter, not a special case (not that it's implemented yet anyway). * Suppress successive checkpoint records when nothing has been entered in the WAL log since the last one. This is not so much to avoid I/O as to make it actually useful to keep track of the last two checkpoints. If the things are right next to each other then there's not a lot of redundancy gained... * Change CRC scheme to a true 64-bit CRC, not a pair of 32-bit CRCs on alternate bytes. Polynomial borrowed from ECMA DLT1 standard. * Fix XLOG record length handling so that it will work at BLCKSZ = 32k. * Change XID allocation to work more like OID allocation. (This is of dubious necessity, but I think it's a good idea anyway.) * Fix a number of minor bugs, such as off-by-one logic for XLOG file wraparound at the 4 gig mark. * Add documentation and clean up some coding infelicities; move file format declarations out to include files where planned contrib utilities can get at them. * Checkpoint will now occur every CHECKPOINT_SEGMENTS log segments or every CHECKPOINT_TIMEOUT seconds, whichever comes first. It is also possible to force a checkpoint by sending SIGUSR1 to the postmaster (undocumented feature...) * Defend against kill -9 postmaster by storing shmem block's key and ID in postmaster.pid lockfile, and checking at startup to ensure that no processes are still connected to old shmem block (if it still exists). * Switch backends to accept SIGQUIT rather than SIGUSR1 for emergency stop, for symmetry with postmaster and xlog utilities. Clean up signal handling in bootstrap.c so that xlog utilities launched by postmaster will react to signals better. * Standalone bootstrap now grabs lockfile in target directory, as added insurance against running it in parallel with live postmaster.
* Change Copyright from PostgreSQL, Inc to PostgreSQL Global Development Group.Bruce Momjian2001-01-241-2/+2
|
* Remove useless leftover global variable Ps_status_buffer.Peter Eisentraut2001-01-231-9/+1
|
* Make critical sections (elog->crash) and interrupt holdoff sectionsTom Lane2001-01-191-1/+2
| | | | into distinct concepts, per recent discussion on pghackers.
* Restructure backend SIGINT/SIGTERM handling so that 'die' interruptsTom Lane2001-01-141-4/+7
| | | | | | | are treated more like 'cancel' interrupts: the signal handler sets a flag that is examined at well-defined spots, rather than trying to cope with an interrupt that might happen anywhere. See pghackers discussion of 1/12/01.
* Fix recent breakage of query-cancel logic, see my pghackers messageTom Lane2001-01-071-2/+2
| | | | of 6 Jan 2001 21:55.
* New WAL version - CRC and data blocks backup.Vadim B. Mikheev2000-12-281-1/+47
|
* Keep track of the last active slot in the shared ProcState array, soTom Lane2000-11-121-2/+1
| | | | | | | | | that search loops only have to scan that far and not through all maxBackends entries. This eliminates a performance penalty for setting maxBackends much higher than the average number of active backends. Also, eliminate no-longer-used 'backend tag' concept. Remove setting of environment variables at backend start (except for CYR_RECODE), since none of them are being examined by the backend any longer.
* Code cleanup of user name and user id handling in the backend. The currentPeter Eisentraut2000-09-061-2/+1
| | | | | | | | | | | user is now defined in terms of the user id, the user name is only computed upon request (for display purposes). This is kind of the opposite of the previous state, which would maintain the user name and compute the user id for permission checks. Besides perhaps saving a few cycles (integer vs string), this now creates a single point of attack for changing the user id during a connection, for purposes of "setuid" functions, etc.
* The heralded `Grand Unified Configuration scheme' (GUC)Peter Eisentraut2000-05-311-1/+4
| | | | | | | | | | | | | That means you can now set your options in either or all of $PGDATA/configuration, some postmaster option (--enable-fsync=off), or set a SET command. The list of options is in backend/utils/misc/guc.c, documentation will be written post haste. pg_options is gone, so is that pq_geqo config file. Also removed were backend -K, -Q, and -T options (no longer applicable, although -d0 does the same as -Q). Added to configure an --enable-syslog option. changed all callers from TPRINTF to elog(DEBUG)
* Remove unused include files. Do not touch /port or includes used by defines.Bruce Momjian2000-05-301-2/+1
|
* Make the indexes on pg_group be shared system relations.Tom Lane2000-05-051-1/+4
|
* Ye-old pgindent run. Same 4-space tabs.Bruce Momjian2000-04-121-2/+3
|
* Make ISO date style (e.g. "2000-02-16 09:33") the default.Thomas G. Lockhart2000-02-161-2/+2
| | | | | | | | | | | | | | Implement "date/time grand unification". Transform datetime and timespan into timestamp and interval. Deprecate datetime and timespan, though translate to new types in gram.y. Transform all datetime and timespan catalog entries into new types. Make "INTERVAL" reserved word allowed as a column identifier in gram.y. Remove dt.h, dt.c files, and retarget datetime.h, datetime.c as utility routines for all date/time types. date.{h,c} now deals with date, time types. timestamp.{h,c} now deals with timestamp, interval types. nabstime.{h,c} now deals with abstime, reltime, tinterval types. Make NUMERIC a known native type for purposes of type coersion. Not tested.
* Add:Bruce Momjian2000-01-261-2/+3
| | | | | | * Portions Copyright (c) 1996-2000, PostgreSQL, Inc to all files copyright Regents of Berkeley. Man, that's a lot of files.
* Fix memory overrun while setting ps statusTatsuo Ishii1999-12-101-1/+8
|
* Cleanup -is flag to -l for SSL. Another PERL variable name fix. CleanBruce Momjian1999-10-081-2/+2
| | | | | up debugging options for postmaster and postgres programs. postmaster -d is no longer optional. Documentation updates.
* Massimo's SET FSYNC and SHOW PG_OPTIONS changes, without SET QUERY_LIMIT.Bruce Momjian1999-09-271-2/+1
|
* Move some system includes into c.h, and remove duplicates.Bruce Momjian1999-07-171-3/+1
|
* Final cleanupBruce Momjian1999-07-161-4/+4
|
* Update #include cleanupsBruce Momjian1999-07-161-2/+2
|
* Change #include's to use <> and "" as appropriate.Bruce Momjian1999-07-151-2/+2
|
* Remove unused #includes in *.c files.Bruce Momjian1999-07-151-4/+1
|
* Clean up #include in /include directory. Add scripts for checking includes.Bruce Momjian1999-07-151-2/+1
|
* pgindent run over code.Bruce Momjian1999-05-251-1/+2
|
* Modify backend switch parsing to prevent 'insecure' switchesTom Lane1999-05-221-3/+2
| | | | | from being accepted when they are passed from client connection request. Get rid of a couple that no longer do anything (like -P).
* Add new postgres -O option to allow system table structure changes.Bruce Momjian1999-03-171-2/+3
|
* Change my-function-name-- to my_function_name, and optimizer renames.Bruce Momjian1999-02-131-2/+2
|
* The problem is that read_pg_options needs DataDir to read its file butBruce Momjian1998-10-161-2/+2
| | | | | | | | | | DataDir is set after read_pg_options if postgres is called interactively. If postgres is forked by postgres DataDir is read from the PGDATA enviromnent variable set by the postmaster and this explains while the bug disappears. I have written this patch but I don't like it. Any better idea? Massimo Dal Zotto
* From: Massimo Dal Zotto <dz@cs.unitn.it>Marc G. Fournier1998-08-251-2/+2
| | | | | | | | | | > ps-status.patch > > macros for ps status, used by postgres.c and utility.c. > Unfortunately ps status is system dependent and the current > code doesn't work on linux. The use of macros confines system > dependency to into one file (ps-status.h). Users of other > operating systems should check this code and submit new macros.
* From: Tom Lane <tgl@sss.pgh.pa.us>Marc G. Fournier1998-07-091-1/+3
| | | | | | | | | | | | | | | | | | Making PQrequestCancel safe to call in a signal handler turned out to be much easier than I feared. So here are the diffs. Some notes: * I modified the postmaster's packet "iodone" callback interface to allow the callback routine to return a continue-or-drop-connection return code; this was necessary to allow the connection to be closed after receiving a Cancel, rather than proceeding to launch a new backend... Being a neatnik, I also made the iodone proc have a typechecked parameter list. * I deleted all code I could find that had to do with OOB. * I made some edits to ensure that all signals mentioned in the code are referred to symbolically not by numbers ("SIGUSR2" not "2"). I think Bruce may have already done at least some of the same edits; I hope that merging these patches is not too painful.
* Remove fork()/exec() and only do fork(). Small cleanups.Bruce Momjian1998-05-291-2/+1
|
* Allow cancel from client of backend query. Change some int variablesBruce Momjian1998-05-191-3/+5
| | | | to bool's.
* pgindent run before 6.3 release, with Thomas' requested changes.Bruce Momjian1998-02-261-2/+2
|
* From: Jan Wieck <jwieck@debis.com>Marc G. Fournier1998-02-251-2/+2
| | | | | | | | | | seems that my last post didn't make it through. That's good since the diff itself didn't covered the renaming of pg_user.h to pg_shadow.h and it's new content. Here it's again. The complete regression test passwd with only some float diffs. createuser and destroyuser work. pg_shadow cannot be read by ordinary user.
* From: Phil Thompson <phil@river-bank.demon.co.uk>Marc G. Fournier1998-01-261-2/+3
| | | | | | | | | | | | | | | | | | | I've completed the patch to fix the protocol and authentication issues I was discussing a couple of weeks ago. The particular changes are: - the protocol has a version number - network byte order is used throughout - the pg_hba.conf file is used to specify what method is used to authenticate a frontend (either password, ident, trust, reject, krb4 or krb5) - support for multiplexed backends is removed - appropriate changes to man pages - the -a switch to many programs to specify an authentication service no longer has any effect - the libpq.so version number has changed to 1.1 The new backend still supports the old protocol so old interfaces won't break.
* getpid/pid cleanupBruce Momjian1998-01-251-2/+3
|
* Remove tqual.h includes not needed.Bruce Momjian1997-11-241-2/+1
|
* Remove pg_magic, defaults, server, hosts, and demon tables. unused.Bruce Momjian1997-11-151-6/+1
|
* Good Bye, Time Travel!Vadim B. Mikheev1997-11-021-2/+1
|
* No more SortTuplesInTree...Vadim B. Mikheev1997-09-181-2/+1
|
* + int SortTuplesInTree = 2560;Vadim B. Mikheev1997-09-181-1/+2
| | | | (default value for max number of tuples in leftist tree)