|
PostgreSQL Source Code git master
|
#include "postgres.h"#include <sys/param.h>#include <signal.h>#include <time.h>#include <sys/file.h>#include <sys/stat.h>#include <fcntl.h>#include <unistd.h>#include <grp.h>#include <pwd.h>#include <netinet/in.h>#include <arpa/inet.h>#include <utime.h>#include "access/htup_details.h"#include "access/parallel.h"#include "catalog/pg_authid.h"#include "common/file_perm.h"#include "libpq/libpq.h"#include "libpq/pqsignal.h"#include "mb/pg_wchar.h"#include "miscadmin.h"#include "pgstat.h"#include "postmaster/autovacuum.h"#include "postmaster/interrupt.h"#include "postmaster/postmaster.h"#include "replication/slotsync.h"#include "storage/fd.h"#include "storage/ipc.h"#include "storage/latch.h"#include "storage/pg_shmem.h"#include "storage/pmsignal.h"#include "storage/proc.h"#include "storage/procarray.h"#include "utils/builtins.h"#include "utils/guc.h"#include "utils/inval.h"#include "utils/memutils.h"#include "utils/pidfile.h"#include "utils/syscache.h"#include "utils/varlena.h"#include "utils/wait_event.h"#include "postmaster/proctypelist.h"
Go to the source code of this file.
Data Structures | |
| struct | SerializedClientConnectionInfo |
Macros | |
| #define | DIRECTORY_LOCK_FILE "postmaster.pid" |
| #define | PG_PROCTYPE(bktype, bkcategory, description, main_func, shmem_attach) case bktype: backendDesc = description; break; |
Typedefs | |
| typedef struct SerializedClientConnectionInfo | SerializedClientConnectionInfo |
| #define DIRECTORY_LOCK_FILE "postmaster.pid" |
Definition at line 61 of file miscinit.c.
| #define PG_PROCTYPE | ( | bktype, | |
| bkcategory, | |||
| description, | |||
| main_func, | |||
| shmem_attach | |||
| ) | case bktype: backendDesc = description; break; |
Definition at line 1520 of file miscinit.c.
References close, DIRECTORY_LOCK_FILE, ereport, errcode_for_file_access(), errmsg, fb(), fd(), len, LOG, PG_BINARY, pg_fsync(), pg_pwrite, pgstat_report_wait_end(), pgstat_report_wait_start(), read, snprintf, and str.
Referenced by InternalIpcMemoryCreate(), PostmasterMain(), process_pm_child_exit(), process_pm_pmsignal(), and process_pm_shutdown_request().
Definition at line 410 of file miscinit.c.
References Assert, DataDir, ereport, errcode_for_file_access(), errmsg, FATAL, and fb().
Referenced by BootstrapModeMain(), PostgresSingleUserMain(), and PostmasterMain().
Definition at line 297 of file miscinit.c.
References Assert, data_directory_mode, DataDir, ereport, errcode(), errcode_for_file_access(), errdetail(), errhint(), errmsg, FATAL, fb(), pg_dir_create_mode, pg_mode_mask, PG_MODE_MASK_GROUP, S_ISDIR, SetDataDirectoryCreatePerm(), stat, and ValidatePgVersion().
Referenced by BootstrapModeMain(), PostgresSingleUserMain(), and PostmasterMain().
Definition at line 1464 of file miscinit.c.
References CreateLockFile(), DataDir, DIRECTORY_LOCK_FILE, and fb().
Referenced by BootstrapModeMain(), PostgresSingleUserMain(), and PostmasterMain().
|
static |
Definition at line 1159 of file miscinit.c.
References close, DataDir, elog, ereport, errcode(), errcode_for_file_access(), errhint(), errmsg, FATAL, fb(), fd(), filename, INT64_FORMAT, kill, lcons(), len, LOCK_FILE_LINE_SHMEM_KEY, lock_files, MAXPGPATH, MyStartTime, NIL, on_proc_exit(), pg_file_create_mode, pg_fsync(), PGSharedMemoryIsInUse(), pgstat_report_wait_end(), pgstat_report_wait_start(), PostPortNumber, pstrdup(), read, snprintf, strlcat(), UnlinkLockFiles(), and write.
Referenced by CreateDataDirLockFile(), and CreateSocketLockFile().
Definition at line 1473 of file miscinit.c.
References CreateLockFile(), fb(), MAXPGPATH, and snprintf.
Referenced by Lock_AF_UNIX().
Definition at line 1036 of file miscinit.c.
References add_size(), ClientConnectionInfo::authn_id, fb(), and MyClientConnectionInfo.
Referenced by InitializeParallelDSM().
Definition at line 546 of file miscinit.c.
References Assert, AuthenticatedUserId, and OidIsValid.
Referenced by check_session_authorization(), and InitializeParallelDSM().
| const char * GetBackendTypeDesc | ( | BackendType | backendType | ) |
Definition at line 264 of file miscinit.c.
References fb(), and gettext_noop.
Referenced by BackendInitialize(), BackendStartup(), CleanupBackend(), CountChildren(), get_backend_type_for_log(), init_ps_display(), pg_stat_get_activity(), pg_stat_io_build_tuples(), and signal_child().
Definition at line 936 of file miscinit.c.
References InvalidOid, OuterUserId, and SetRoleIsActive.
Referenced by check_role(), InitializeParallelDSM(), and show_role().
Definition at line 481 of file miscinit.c.
References Assert, OidIsValid, and OuterUserId.
Referenced by DropRole(), and RenameRole().
Definition at line 509 of file miscinit.c.
References Assert, OidIsValid, and SessionUserId.
Referenced by check_role(), check_session_authorization(), DropRole(), get_rolespec_oid(), get_rolespec_tuple(), InitializeParallelDSM(), InitPostgres(), pgstat_bestart_final(), RenameRole(), and session_user().
Definition at line 516 of file miscinit.c.
References Assert, OidIsValid, SessionUserId, and SessionUserIsSuperuser.
Referenced by check_session_authorization(), and InitializeParallelDSM().
Definition at line 470 of file miscinit.c.
References Assert, CurrentUserId, and OidIsValid.
Referenced by AfterTriggerSaveEvent(), AggregateCreate(), all_rows_selectable(), AlterCollation(), AlterDatabase(), AlterDatabaseOwner(), AlterDatabaseRefreshColl(), AlterDatabaseSet(), AlterEventTrigger(), AlterEventTriggerOwner_internal(), AlterExtensionNamespace(), AlterForeignServer(), AlterForeignServerOwner_internal(), AlterFunction(), AlterObjectNamespace_internal(), AlterObjectOwner_internal(), AlterObjectRename_internal(), AlterOperator(), AlterOpFamilyAdd(), AlterPublication(), AlterPublicationOwner_internal(), AlterRole(), AlterRoleSet(), AlterSchemaOwner_internal(), AlterStatistics(), AlterSubscription(), AlterSubscriptionOwner_internal(), AlterSystemSetConfigFile(), AlterTableMoveAll(), AlterTableSpaceOptions(), AlterTSConfiguration(), AlterTSDictionary(), AlterType(), AlterTypeNamespace_oid(), AlterTypeOwner(), ATExecChangeOwner(), ATPrepAlterColumnType(), ATPrepSetTableSpace(), ATSimplePermissions(), bbsink_server_new(), be_lo_unlink(), binary_upgrade_check_logical_slot_pending_wal(), binary_upgrade_create_empty_extension(), brin_desummarize_range(), BuildCachedPlan(), BuildDescForRelation(), BuildIndexValueDescription(), calculate_database_size(), calculate_tablespace_size(), call_pltcl_start_proc(), check_enable_rls(), check_search_path(), check_temp_tablespaces(), CheckCachedPlan(), checkDomainOwner(), checkEnumOwner(), checkFkeyPermissions(), CheckFunctionValidatorAccess(), CheckMyDatabase(), CheckSlotPermissions(), CommentObject(), compile_plperl_function(), compile_pltcl_function(), CompleteCachedPlan(), compute_return_type(), ConfigOptionIsVisible(), convert_and_check_filename(), copy_sequence(), CreateCast(), CreateConversionCommand(), createdb(), CreateEventTrigger(), CreateExtensionInternal(), CreateForeignDataWrapper(), CreateForeignServer(), CreateForeignTable(), CreateFunction(), CreateOpFamily(), CreateProceduralLanguage(), CreatePublication(), CreateRole(), CreateStatistics(), CreateSubscription(), CreateTableSpace(), CreateTransform(), CreateTriggerFiringOn(), current_user(), currtid_internal(), currval_oid(), DefineAggregate(), DefineCollation(), DefineDomain(), DefineEnum(), DefineIndex(), DefineOpClass(), DefineOperator(), DefineOpFamily(), DefineQueryRewrite(), DefineRange(), DefineRelation(), DefineTSConfiguration(), DefineTSDictionary(), DefineType(), DoCopy(), dropdb(), DropOwnedObjects(), DropRole(), DropSubscription(), DropTableSpace(), emit_audit_message(), EnableDisableRule(), ExecAlterDefaultPrivilegesStmt(), ExecAlterExtensionContentsStmt(), ExecAlterExtensionStmt(), ExecAlterObjectDependsStmt(), ExecBuildGroupingEqual(), ExecBuildParamSetEqual(), ExecBuildSlotPartitionKeyDescription(), ExecBuildSlotValueDescription(), ExecCheckOneRelPerms(), ExecCheckpoint(), ExecGetResultRelCheckAsUser(), ExecInitAgg(), ExecInitExprRec(), ExecInitFunc(), ExecInitWindowAgg(), ExecReindex(), ExecSecLabelStmt(), execute_extension_script(), ExecuteCallStmt(), ExecuteDoStmt(), ExecuteTruncateGuts(), extension_is_trusted(), file_fdw_validator(), findRangeCanonicalFunction(), findRangeSubtypeDiffFunction(), FinishPreparedTransaction(), fmgr_security_definer(), get_connect_string(), get_other_operator(), get_rolespec_oid(), get_rolespec_tuple(), get_row_security_policies(), get_tables_to_repack(), get_tables_to_repack_partitioned(), GetConfigOptionValues(), gin_clean_pending_list(), GrantRole(), HandleFunctionRequest(), has_any_column_privilege_id(), has_any_column_privilege_name(), has_column_privilege_id_attnum(), has_column_privilege_id_name(), has_column_privilege_name_attnum(), has_column_privilege_name_name(), has_database_privilege_id(), has_database_privilege_name(), has_foreign_data_wrapper_privilege_id(), has_foreign_data_wrapper_privilege_name(), has_function_privilege_id(), has_function_privilege_name(), has_language_privilege_id(), has_language_privilege_name(), has_largeobject_privilege_id(), has_parameter_privilege_name(), has_schema_privilege_id(), has_schema_privilege_name(), has_sequence_privilege_id(), has_sequence_privilege_name(), has_server_privilege_id(), has_server_privilege_name(), has_table_privilege_id(), has_table_privilege_name(), has_tablespace_privilege_id(), has_tablespace_privilege_name(), has_type_privilege_id(), has_type_privilege_name(), have_createdb_privilege(), have_createrole_privilege(), heap_force_common(), ImportForeignSchema(), init_sexpr(), InitializeSearchPath(), InitPostgres(), InitTempTableNamespace(), inline_function(), inline_function_in_from(), insert_username(), interpret_function_parameter_list(), inv_create(), inv_open(), LargeObjectCreate(), lastval(), LockViewRecurse(), LogicalRepSyncTableStart(), lookup_agg_function(), LookupCreationNamespace(), LookupExplicitNamespace(), MergeAttributes(), movedb(), nextval_internal(), OperatorCreate(), OperatorShellMake(), pg_get_multixact_stats(), pg_get_sequence_data(), pg_has_role_id(), pg_has_role_name(), pg_import_system_collations(), pg_prewarm(), pg_sequence_last_value(), pg_sequence_parameters(), pg_signal_backend(), pg_stat_get_recovery(), pg_stat_get_wal_receiver(), pg_stat_get_wal_senders(), pg_stat_statements_internal(), pgrowlocks(), pgss_store(), pgstat_get_backend_current_activity(), pltcl_fetch_interp(), postgresBeginDirectModify(), postgresBeginForeignScan(), postgresExecForeignTruncate(), postgresGetForeignRelSize(), postgresImportForeignSchema(), PrepareTempTablespaces(), PrepareTransaction(), PublicationAddTables(), RangeVarCallbackForAlterRelation(), RangeVarCallbackForDblink(), RangeVarCallbackForDropRelation(), RangeVarCallbackForLockTable(), RangeVarCallbackForPolicy(), RangeVarCallbackForReindexIndex(), RangeVarCallbackForRenameRule(), RangeVarCallbackForRenameTrigger(), RangeVarCallbackForStats(), RangeVarCallbackMaintainsTable(), RangeVarCallbackOwnsRelation(), RangeVarGetAndCheckCreationNamespace(), ReassignOwnedObjects(), recomputeNamespacePath(), REGRESS_exec_check_perms(), REGRESS_object_access_hook(), REGRESS_object_access_hook_str(), REGRESS_utility_command(), ReindexMultipleInternal(), ReindexMultipleTables(), RemoveObjects(), renameatt_check(), RenameDatabase(), RenameRole(), RenameSchema(), RenameTableSpace(), RenameType(), RevalidateCachedQuery(), RI_Initial_Check(), ri_ReportViolation(), select_best_grantor(), select_perl_context(), set_config_option(), set_foreign_rel_properties(), SetSequence(), shell_check_detail(), superuser(), TargetPrivilegesCheck(), TerminateOtherDBBackends(), transformTableLikeClause(), truncate_check_perms(), user_mapping_ddl_aclcheck(), vacuum_is_permitted_for_relation(), validate_option_array_item(), ValidateJoinEstimator(), ValidateOperatorReference(), and ValidateRestrictionEstimator().
Definition at line 662 of file miscinit.c.
References CurrentUserId, fb(), and InLocalUserIdChange().
Definition at line 613 of file miscinit.c.
References CurrentUserId, and SecurityRestrictionContext.
Referenced by AfterTriggerExecute(), amcheck_lock_relation_and_check(), ATExecMergePartitions(), ATExecSplitPartition(), brin_summarize_range(), cluster_rel(), ComputeIndexAttrs(), CreateSchemaCommand(), DefineIndex(), do_analyze_rel(), execute_extension_script(), fmgr_security_definer(), index_build(), index_concurrently_build(), InitializeParallelDSM(), PushTransaction(), RefreshMatViewByOid(), reindex_index(), ReindexRelationConcurrently(), ri_PerformCheck(), ri_PlanCheck(), StartTransaction(), SwitchToUntrustedUser(), vacuum_rel(), and validate_index().
Definition at line 989 of file miscinit.c.
References ereport, errcode(), errmsg, ERROR, fb(), Form_pg_authid, GETSTRUCT(), HeapTupleIsValid, NameStr, ObjectIdGetDatum(), pstrdup(), ReleaseSysCache(), rolname, and SearchSysCache1().
Referenced by AddRoleMems(), AlterSubscription(), AlterSubscriptionOwner_internal(), check_can_set_role(), check_object_ownership(), check_role_grantor(), check_role_membership_authorization(), current_user(), DelRoleMems(), DropOwnedObjects(), DropSubscription(), execute_extension_script(), getObjectDescription(), getObjectIdentityParts(), GetSubscription(), insert_username(), LogicalRepSyncTableStart(), ReassignOwnedObjects(), regroleout(), select_best_grantor(), session_user(), SwitchToUntrustedUser(), and TargetPrivilegesCheck().
Definition at line 689 of file miscinit.c.
References fb(), Form_pg_authid, GETSTRUCT(), HeapTupleIsValid, ObjectIdGetDatum(), ReleaseSysCache(), rolreplication, SearchSysCache1(), and superuser_arg().
Referenced by AlterRole(), binary_upgrade_check_logical_slot_pending_wal(), CheckSlotPermissions(), CreateRole(), and InitPostgres().
Definition at line 711 of file miscinit.c.
References AcceptInvalidationMessages(), AmRegularBackendProcess, Assert, CountUserBackends(), ereport, errcode(), errmsg, FATAL, fb(), Form_pg_authid, GETSTRUCT(), HeapTupleIsValid, InitializingParallelWorker, is_superuser(), IsBootstrapProcessingMode, IsUnderPostmaster, NameStr, ObjectIdGetDatum(), PGC_BACKEND, PGC_S_OVERRIDE, PointerGetDatum(), ReleaseSysCache(), SearchSysCache1(), SetAuthenticatedUserId(), and SetConfigOption().
Referenced by InitPostgres().
Definition at line 841 of file miscinit.c.
References AmAutoVacuumWorkerProcess, AmBackgroundWorkerProcess, AmLogicalSlotSyncWorkerProcess, Assert, AuthenticatedUserId, fb(), InvalidOid, IsUnderPostmaster, OidIsValid, SetCurrentRoleId(), and SetSessionAuthorization().
Referenced by InitPostgres().
Definition at line 875 of file miscinit.c.
References Assert, authn_id, fb(), MemoryContextStrdup(), pfree(), psprintf(), system_user(), SystemUser, and TopMemoryContext.
Referenced by InitPostgres(), and ParallelWorkerMain().
Definition at line 97 of file miscinit.c.
References BlockSig, elog, ereport, errcode_for_socket_access(), errmsg_internal(), FATAL, fb(), InitializeLatchWaitSet(), InitializeWaitEventSupport(), InitProcessGlobals(), InitProcessLocalLatch(), IsUnderPostmaster, on_exit_reset(), pgwin32_signal_initialize(), postmaster_alive_fds, POSTMASTER_FD_WATCH, PostmasterDeathSignalInit(), pqinitmask(), pqsignal, SignalHandlerForCrashExit(), and SIGQUIT.
Referenced by postmaster_child_launch().
Definition at line 236 of file miscinit.c.
References InitLatch(), LocalLatchData, and MyLatch.
Referenced by InitPostmasterChild(), InitStandaloneProcess(), and PostmasterMain().
Definition at line 176 of file miscinit.c.
References argv0, Assert, B_STANDALONE_BACKEND, BlockSig, elog, FATAL, fb(), find_my_exec(), get_pkglib_path(), InitializeLatchWaitSet(), InitializeWaitEventSupport(), InitProcessGlobals(), InitProcessLocalLatch(), IsPostmasterEnvironment, my_exec_path, MyBackendType, pgwin32_signal_initialize(), pkglib_path, and pqinitmask().
Referenced by BootstrapModeMain(), and PostgresSingleUserMain().
Definition at line 631 of file miscinit.c.
References SECURITY_LOCAL_USERID_CHANGE, and SecurityRestrictionContext.
Referenced by GetUserIdAndContext(), and set_config_with_handle().
Definition at line 649 of file miscinit.c.
References SECURITY_NOFORCE_RLS, and SecurityRestrictionContext.
Referenced by check_enable_rls().
Definition at line 640 of file miscinit.c.
References SECURITY_RESTRICTED_OPERATION, and SecurityRestrictionContext.
Referenced by afterTriggerMarkEvents(), CheckRestrictedOperation(), DefineRelation(), PerformCursorOpen(), set_config_with_handle(), and SetUserIdAndContext().
Definition at line 1800 of file miscinit.c.
References DEBUG1, ereport, errcode(), errmsg, errmsg_internal(), fb(), filename, first_dir_separator(), lfirst, list_free_deep(), load_file(), LOG, pfree(), psprintf(), pstrdup(), restricted, and SplitDirectoriesString().
Referenced by process_session_preload_libraries(), and process_shared_preload_libraries().
Definition at line 1889 of file miscinit.c.
References fb(), get_locale_path(), MAXPGPATH, and my_exec_path.
Referenced by _PG_init(), and test_translation().
Definition at line 1866 of file miscinit.c.
References load_libraries(), local_preload_libraries_string, and session_preload_libraries_string.
Referenced by InitPostgres().
Definition at line 1852 of file miscinit.c.
References load_libraries(), process_shared_preload_libraries_done, process_shared_preload_libraries_in_progress, and shared_preload_libraries_string.
Referenced by PostgresSingleUserMain(), and PostmasterMain().
Definition at line 1880 of file miscinit.c.
References process_shmem_requests_in_progress, and shmem_request_hook.
Referenced by PostgresSingleUserMain(), and PostmasterMain().
Definition at line 1647 of file miscinit.c.
References close, DIRECTORY_LOCK_FILE, ereport, errcode_for_file_access(), errmsg, fb(), fd(), len, LOG, PG_BINARY, pgstat_report_wait_end(), pgstat_report_wait_start(), and read.
Referenced by ServerLoop().
Definition at line 1085 of file miscinit.c.
References ClientConnectionInfo::auth_method, ClientConnectionInfo::authn_id, authn_id, fb(), MemoryContextStrdup(), MyClientConnectionInfo, and TopMemoryContext.
Referenced by ParallelWorkerMain().
Definition at line 1052 of file miscinit.c.
References Assert, ClientConnectionInfo::auth_method, ClientConnectionInfo::authn_id, SerializedClientConnectionInfo::authn_id_len, fb(), and MyClientConnectionInfo.
Referenced by InitializeParallelDSM().
Definition at line 553 of file miscinit.c.
References Assert, AuthenticatedUserId, MyProc, OidIsValid, and PGPROC::roleId.
Referenced by InitializeSessionUserId(), and ParallelWorkerMain().
Definition at line 957 of file miscinit.c.
References is_superuser(), OidIsValid, SessionUserId, SessionUserIsSuperuser, SetOuterUserId(), and SetRoleIsActive.
Referenced by assign_role(), InitializeSessionUserIdStandalone(), and ParallelWorkerMain().
Definition at line 284 of file miscinit.c.
References Assert, DatabasePath, MemoryContextStrdup(), and TopMemoryContext.
Referenced by InitPostgres().
Definition at line 390 of file miscinit.c.
References Assert, DataDir, free, and make_absolute_path().
Referenced by SelectConfigFiles().
Definition at line 489 of file miscinit.c.
References Assert, CurrentUserId, is_superuser(), OidIsValid, OuterUserId, PGC_INTERNAL, PGC_S_DYNAMIC_DEFAULT, SecurityRestrictionContext, and SetConfigOption().
Referenced by SetCurrentRoleId(), and SetSessionAuthorization().
Definition at line 921 of file miscinit.c.
References is_superuser(), SetOuterUserId(), SetRoleIsActive, and SetSessionUserId().
Referenced by assign_session_authorization(), InitializeSessionUserIdStandalone(), and ParallelWorkerMain().
Definition at line 523 of file miscinit.c.
References Assert, is_superuser(), OidIsValid, SecurityRestrictionContext, SessionUserId, and SessionUserIsSuperuser.
Referenced by SetSessionAuthorization().
Definition at line 669 of file miscinit.c.
References CurrentUserId, ereport, errcode(), errmsg, ERROR, fb(), InSecurityRestrictedOperation(), SECURITY_LOCAL_USERID_CHANGE, and SecurityRestrictionContext.
Definition at line 620 of file miscinit.c.
References CurrentUserId, and SecurityRestrictionContext.
Referenced by AbortSubTransaction(), AbortTransaction(), AfterTriggerExecute(), amcheck_lock_relation_and_check(), ATExecMergePartitions(), ATExecSplitPartition(), brin_summarize_range(), cluster_rel(), ComputeIndexAttrs(), CreateSchemaCommand(), DefineIndex(), do_analyze_rel(), execute_extension_script(), fmgr_security_definer(), index_build(), index_concurrently_build(), ParallelWorkerMain(), refresh_by_match_merge(), RefreshMatViewByOid(), reindex_index(), ReindexRelationConcurrently(), RestoreUserContext(), ri_PerformCheck(), ri_PlanCheck(), SwitchToUntrustedUser(), vacuum_rel(), and validate_index().
Definition at line 243 of file miscinit.c.
References Assert, fb(), FeBeWaitSet, FeBeWaitSetLatchPos, LocalLatchData, ModifyWaitEvent(), MyLatch, MyProc, PGPROC::procLatch, SetLatch(), and WL_LATCH_SET.
Referenced by AuxiliaryProcKill(), and ProcKill().
Definition at line 216 of file miscinit.c.
References Assert, fb(), FeBeWaitSet, FeBeWaitSetLatchPos, LocalLatchData, ModifyWaitEvent(), MyLatch, MyProc, PGPROC::procLatch, SetLatch(), and WL_LATCH_SET.
Referenced by InitAuxiliaryProcess(), and InitProcess().
| Datum system_user | ( | PG_FUNCTION_ARGS | ) |
Definition at line 899 of file miscinit.c.
References CStringGetTextDatum, fb(), GetSystemUser(), PG_RETURN_DATUM, and PG_RETURN_NULL.
Referenced by check_ident_usermap(), check_usermap(), and InitializeSystemUser().
Definition at line 1491 of file miscinit.c.
References DIRECTORY_LOCK_FILE, fb(), lfirst, and lock_files.
Referenced by ServerLoop().
Definition at line 1125 of file miscinit.c.
References ereport, errmsg, fb(), IsPostmasterEnvironment, lfirst, lock_files, LOG, and NOTICE.
Referenced by CreateLockFile().
Definition at line 1719 of file miscinit.c.
References AllocateFile(), ereport, errcode(), errcode_for_file_access(), errdetail(), errhint(), errmsg, FATAL, fb(), FreeFile(), MAXPGPATH, and snprintf.
Referenced by checkDataDir(), and InitPostgres().
|
static |
Definition at line 450 of file miscinit.c.
Referenced by GetAuthenticatedUserId(), InitializeSessionUserIdStandalone(), and SetAuthenticatedUserId().
|
static |
Definition at line 453 of file miscinit.c.
Referenced by GetUserId(), GetUserIdAndContext(), GetUserIdAndSecContext(), SetOuterUserId(), SetUserIdAndContext(), and SetUserIdAndSecContext().
Definition at line 82 of file miscinit.c.
Referenced by AuxiliaryProcessMainCommon(), BootstrapModeMain(), get_relation_info(), systable_beginscan(), and systable_beginscan_ordered().
Definition at line 1784 of file miscinit.c.
Referenced by process_session_preload_libraries().
|
static |
Definition at line 70 of file miscinit.c.
Referenced by InitProcessLocalLatch(), SwitchBackToLocalLatch(), and SwitchToSharedLatch().
Definition at line 68 of file miscinit.c.
Referenced by CreateLockFile(), TouchSocketLockFiles(), and UnlinkLockFiles().
| ProcessingMode Mode = InitProcessing |
Definition at line 63 of file miscinit.c.
| BackendType MyBackendType |
Definition at line 65 of file miscinit.c.
Referenced by CreateRestartPoint(), execute_extension_script(), get_backend_type_for_log(), init_ps_display(), InitAuxiliaryProcess(), InitProcess(), InitStandaloneProcess(), InvalidatePossiblyObsoleteSlot(), pgaio_init_backend(), pgaio_worker_error_callback(), pgstat_bestart_final(), pgstat_bestart_initial(), pgstat_count_backend_io_op(), pgstat_count_backend_io_op_time(), pgstat_count_io_op(), pgstat_flush_backend(), pgstat_io_flush_cb(), pgstat_should_report_connstat(), pgstat_write_statsfile(), PostgresMain(), postmaster_child_launch(), ProcessStartupPacket(), send_message_to_server_log(), should_output_to_server(), standard_ProcessUtility(), write_csvlog(), and write_jsonlog().
| ClientConnectionInfo MyClientConnectionInfo |
Definition at line 1019 of file miscinit.c.
Referenced by auth_peer(), ClientAuthentication(), EstimateClientConnectionInfoSpace(), InitPostgres(), ParallelWorkerMain(), RestoreClientConnectionInfo(), SerializeClientConnectionInfo(), set_authn_id(), and validate().
|
static |
Definition at line 452 of file miscinit.c.
Referenced by GetCurrentRoleId(), GetOuterUserId(), and SetOuterUserId().
Definition at line 1788 of file miscinit.c.
Referenced by check_wal_consistency_checking(), InitializeWalConsistencyChecking(), and process_shared_preload_libraries().
Definition at line 1787 of file miscinit.c.
Referenced by _PG_init(), apw_start_leader_worker(), init_custom_variable(), pgstat_register_kind(), process_shared_preload_libraries(), RegisterBackgroundWorker(), and RegisterCustomRmgr().
Definition at line 1791 of file miscinit.c.
Referenced by process_shmem_requests(), RequestAddinShmemSpace(), and RequestNamedLWLockTranche().
|
static |
Definition at line 459 of file miscinit.c.
Referenced by GetUserIdAndSecContext(), InLocalUserIdChange(), InNoForceRLSOperation(), InSecurityRestrictedOperation(), SetOuterUserId(), SetSessionUserId(), SetUserIdAndContext(), and SetUserIdAndSecContext().
Definition at line 1782 of file miscinit.c.
Referenced by process_session_preload_libraries().
|
static |
Definition at line 451 of file miscinit.c.
Referenced by GetSessionUserId(), GetSessionUserIsSuperuser(), SetCurrentRoleId(), and SetSessionUserId().
Definition at line 457 of file miscinit.c.
Referenced by GetSessionUserIsSuperuser(), SetCurrentRoleId(), and SetSessionUserId().
Definition at line 462 of file miscinit.c.
Referenced by GetCurrentRoleId(), SetCurrentRoleId(), and SetSessionAuthorization().
Definition at line 1783 of file miscinit.c.
Referenced by process_shared_preload_libraries().
| shmem_request_hook_type shmem_request_hook = NULL |
Definition at line 1790 of file miscinit.c.
Referenced by _PG_init(), and process_shmem_requests().
Definition at line 454 of file miscinit.c.
Referenced by GetSystemUser(), and InitializeSystemUser().