PostgreSQL Source Code
git master
|
#include "postgres_fe.h"
#include <sys/stat.h>
#include <limits.h>
#include <fcntl.h>
#include "access/visibilitymapdefs.h"
#include "common/file_perm.h"
#include "pg_upgrade.h"
#include "storage/bufpage.h"
#include "storage/checksum.h"
#include "storage/checksum_impl.h"
Go to the source code of this file.
Macros | |
#define | COPY_BUF_SIZE (50 * BLCKSZ) |
Functions | |
void | cloneFile (const char *src, const char *dst, const char *schemaName, const char *relName) |
void | copyFile (const char *src, const char *dst, const char *schemaName, const char *relName) |
void | copyFileByRange (const char *src, const char *dst, const char *schemaName, const char *relName) |
void | linkFile (const char *src, const char *dst, const char *schemaName, const char *relName) |
void | rewriteVisibilityMap (const char *fromfile, const char *tofile, const char *schemaName, const char *relName) |
void | check_file_clone (void) |
void | check_copy_file_range (void) |
void | check_hard_link (void) |
#define COPY_BUF_SIZE (50 * BLCKSZ) |
void check_copy_file_range | ( | void | ) |
Definition at line 400 of file file.c.
References close, MAXPGPATH, new_cluster, old_cluster, PG_BINARY, pg_fatal, pg_file_create_mode, ClusterInfo::pgdata, and snprintf.
Referenced by check_new_cluster().
void check_file_clone | ( | void | ) |
Definition at line 360 of file file.c.
References close, MAXPGPATH, new_cluster, old_cluster, PG_BINARY, pg_fatal, pg_file_create_mode, ClusterInfo::pgdata, and snprintf.
Referenced by check_new_cluster().
void check_hard_link | ( | void | ) |
Definition at line 437 of file file.c.
References link(), MAXPGPATH, new_cluster, old_cluster, pg_fatal, ClusterInfo::pgdata, and snprintf.
Referenced by check_new_cluster().
void cloneFile | ( | const char * | src, |
const char * | dst, | ||
const char * | schemaName, | ||
const char * | relName | ||
) |
Definition at line 39 of file file.c.
References close, PG_BINARY, pg_fatal, pg_file_create_mode, and strerror.
Referenced by transfer_relfile().
void copyFile | ( | const char * | src, |
const char * | dst, | ||
const char * | schemaName, | ||
const char * | relName | ||
) |
Definition at line 82 of file file.c.
References _dosmaperr(), close, COPY_BUF_SIZE, PG_BINARY, pg_fatal, pg_file_create_mode, pg_free(), pg_malloc(), read, and write.
Referenced by transfer_relfile().
void copyFileByRange | ( | const char * | src, |
const char * | dst, | ||
const char * | schemaName, | ||
const char * | relName | ||
) |
Definition at line 151 of file file.c.
References close, PG_BINARY, pg_fatal, and pg_file_create_mode.
Referenced by transfer_relfile().
void linkFile | ( | const char * | src, |
const char * | dst, | ||
const char * | schemaName, | ||
const char * | relName | ||
) |
void rewriteVisibilityMap | ( | const char * | fromfile, |
const char * | tofile, | ||
const char * | schemaName, | ||
const char * | relName | ||
) |
Definition at line 216 of file file.c.
References BITS_PER_BYTE, BITS_PER_HEAPBLOCK, close, ClusterInfo::controldata, PGIOAlignedBlock::data, ControlData::data_checksum_version, fstat, i, new_cluster, PG_BINARY, pg_checksum_page(), pg_fatal, pg_file_create_mode, read, SizeOfPageHeaderData, stat::st_size, VISIBILITYMAP_ALL_VISIBLE, and write.
Referenced by transfer_relfile().