Re: [HACKERS] hot standby system
Ühel kenal päeval, R, 2006-07-21 kell 20:00, kirjutas Chris Campbell: The documentation [1] says this about On-line backup and point-in- time recovery: If we continuously feed the series of WAL files to another machine that has been loaded with the same base backup file, we have a hot standby system: at any point we can bring up the second machine and it will have a nearly-current copy of the database. Is this possible today in a stable and robust way? If so, can we document the procedure? If not, should we alter the documentation so it's not misleading? I've had several people ask me where to enable the hot standby feature, not realizing that PostgreSQL only has some of the raw materials that could be used to architect such a thing. We have written a management script that manages the setup und failover procedures. It is a part of the SkyTools package we announced at the postgresql conference in Toronto. We failed to put it up on PgFoundry during the code sprint (it took a whole day to enable the project there :( ) and have not had enough time to do it after coming back. But it will be on PgFoundry eventually. Marko has the details if you need it faster -- Hannu Krosing Database Architect Skype Technologies OÜ Akadeemia tee 21 F, Tallinn, 12618, Estonia Skype me: callto:hkrosing Get Skype for free: http://www.skype.com ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [HACKERS] [PATCHES] Generic Monitoring Framework with DTrace patch
Peter Eisentraut wrote: Here is a consolidated patch that contains all the files. I made some configure and makefile adjustments and put standard comment headers in all the files. You can use DTRACEFLAGS to pass options to configure, which should help sorting out the 32/64-bit issue. The problem of the *.d files is already gone in CVS. Since I don't have access to a Solaris system, this is untested for the DTrace-enabled case. The only thing left to do besides actually testing that case would be moving the probes.d file to a different location, since we probably don't want to have special-purpose files in src/backend. I can't seem to apply the patch on Solaris. I ran the patch command from the top of the src tree and got the following messages. When I tried to enter a file name, it goes into infinite loop. What did I do wrong? -bash-3.00$ patch -p0 -u /var/tmp/dtrace-patch.diff Looks like a unified context diff. The next patch looks like a unified context diff. The next patch looks like a unified context diff. The next patch looks like a unified context diff. The next patch looks like a unified context diff. File to patch: Regards, -Robert ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [HACKERS] [PATCHES] Generic Monitoring Framework with DTrace patch
Robert Lor wrote: I can't seem to apply the patch on Solaris. Perhaps the attached patch in -c format will work better. -- Peter Eisentraut http://developer.postgresql.org/~petere/ diff -cNr ../cvs-pgsql/configure ./configure *** ../cvs-pgsql/configure 2006-07-21 23:35:48.0 +0200 --- ./configure 2006-07-22 01:21:54.0 +0200 *** *** 314,320 # include unistd.h #endif ! ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_ldap with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. --- 314,320 # include unistd.h #endif ! ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug DTRACE DTRACEFLAGS enable_dtrace CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_ldap with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. *** *** 865,870 --- 865,871 --disable-rpath do not embed shared library search path in executables --disable-spinlocks do not use spinlocks --enable-debug build with debugging symbols (-g) + --enable-dtrace build with DTrace support --enable-depend turn on automatic dependency tracking --enable-cassertenable assertion checks (for debugging) --enable-thread-safety make client libraries thread-safe *** *** 1947,1952 --- 1948,2029 # + # DTrace + # + + + + # Check whether --enable-dtrace or --disable-dtrace was given. + if test ${enable_dtrace+set} = set; then + enableval=$enable_dtrace + + case $enableval in + yes) + + cat confdefs.h \_ACEOF + #define ENABLE_DTRACE 1 + _ACEOF + + for ac_prog in dtrace + do + # Extract the first word of $ac_prog, so it can be a program name with args. + set dummy $ac_prog; ac_word=$2 + echo $as_me:$LINENO: checking for $ac_word 5 + echo $ECHO_N checking for $ac_word... $ECHO_C 6 + if test ${ac_cv_prog_DTRACE+set} = set; then + echo $ECHO_N (cached) $ECHO_C 6 + else + if test -n $DTRACE; then + ac_cv_prog_DTRACE=$DTRACE # Let the user override the test. + else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR + for as_dir in $PATH + do + IFS=$as_save_IFS + test -z $as_dir as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p $as_dir/$ac_word$ac_exec_ext; then + ac_cv_prog_DTRACE=$ac_prog + echo $as_me:$LINENO: found
Re: [HACKERS] [PATCHES] Generic Monitoring Framework with DTrace patch
Peter Eisentraut wrote: Perhaps the attached patch in -c format will work better. Now I'm getting a different type of error. After running the patch command, the configure file is partially patched but not the others. Attached is configure.rej. I just checked out the source from CVS. -bash-3.00$ patch -p0 /var/tmp/dtrace-patch-c.diff Looks like a context diff to me... Hunk #1 failed at line 314. Hunk #13 failed at line 19. 2 out of 33 hunks failed: saving rejects to ./configure.rej done Regards, -Robert *** *** 314,320 # include unistd.h #endif ! ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_ldap with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. --- 314,320 # include unistd.h #endif ! ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug DTRACE DTRACEFLAGS enable_dtrace CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_ldap with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. *** *** 19,25 SUBSYSOBJS := $(DIRS:%=%/SUBSYS.o) ! OBJS := $(SUBSYSOBJS) $(top_builddir)/src/port/libpgport_srv.a # We put libpgport into OBJS, so remove it from LIBS LIBS := $(filter-out -lpgport, $(LIBS)) --- 19,29 SUBSYSOBJS := $(DIRS:%=%/SUBSYS.o) ! OBJS = $(SUBSYSOBJS) $(top_builddir)/src/port/libpgport_srv.a ! ! ifeq ($(enable_dtrace), yes) ! OBJS += probes.o ! endif # We put libpgport into OBJS, so remove it from LIBS LIBS := $(filter-out -lpgport, $(LIBS)) ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org
[HACKERS] Documenting Replication Solutions
Hi, at the code sprint, we agreed to put together some documentation about current and upcoming replication solutions for PostgreSQL. Is somebody already working on that? For Postgres-R, you can find some information on www.postgres-r.org. And I've just opened a project on pgFoundry. This gives Postgres-R it's own mailing list: http://lists.pgfoundry.org/mailman/listinfo/postgres-r-general I know there is already a Postgres-R project on Gborg. But since everybody is moving to pgFoundry, I'd like to move materials from there and join that with the new website or put it to the pgFoundry project. What about that mailing-list there. Could the archive be 'added' to the new list on pgFoundry? Any opinions or wishes from the Gborg project owners? Regards Markus ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [HACKERS] [PATCHES] Generic Monitoring Framework with DTrace patch
Robert Lor wrote: Now I'm getting a different type of error. After running the patch command, the configure file is partially patched but not the others. Attached is configure.rej. I just checked out the source from CVS. Sorry, there must be something wrong with your source code or patch tools, or the patch is mangled by email. I'm not sure. -- Peter Eisentraut http://developer.postgresql.org/~petere/ ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
Re: [HACKERS] [PATCHES] Generic Monitoring Framework with DTrace patch
Peter Eisentraut wrote: Robert Lor wrote: Now I'm getting a different type of error. After running the patch command, the configure file is partially patched but not the others. Attached is configure.rej. I just checked out the source from CVS. Sorry, there must be something wrong with your source code or patch tools, or the patch is mangled by email. I'm not sure. I was able to apply the patch after splitting it into individual files, ran dos2unix on each, and removed the diff line. I believe the problem is with the patch tool. Anyways, I tested the patch with --enable-dtrace and/or DTRACEFLAGS, and it works like a charm! If DTRACEFLAGS is not use, dtrace will default to 32 bit which is what we want. When building a 64 bit binary with --enable-dtrace, DTRACEFLAGS needs to be set to '-64'. I will submit a doc patch to explain all of the above. There is one minor issue - gmake clean doesn't remove probe.o. Regarding where to put probe.d, will src/probe.d work since probes for all subsystems will go into this one file. Thanks a bunch Peter! Regards, -Robert ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq
Re: [HACKERS] Documenting Replication Solutions
Quoth Markus Schiltknecht [EMAIL PROTECTED]: at the code sprint, we agreed to put together some documentation about current and upcoming replication solutions for PostgreSQL. Is somebody already working on that? I don't recall that anyone expressly agreed to do so; I'll see if I can, this week... -- cbbrowne,@,linuxfinances.info http://linuxdatabases.info/info/x.html Would I be an optimist or a pessimist if I said my bladder was half full? ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [HACKERS] [PATCHES] Generic Monitoring Framework with DTrace patch
Here is a consolidated patch that contains all the files. I made some configure and makefile adjustments and put standard comment headers in all the files. You can use DTRACEFLAGS to pass options to configure, which should help sorting out the 32/64-bit issue. The problem of the *.d files is already gone in CVS. Since I don't have access to a Solaris system, this is untested for the DTrace-enabled case. The only thing left to do besides actually testing that case would be moving the probes.d file to a different location, since we probably don't want to have special-purpose files in src/backend. -- Peter Eisentraut http://developer.postgresql.org/~petere/ diff -uNr ../cvs-pgsql/configure ./configure --- ../cvs-pgsql/configure 2006-07-21 23:35:48.0 +0200 +++ ./configure 2006-07-22 01:21:54.0 +0200 @@ -314,7 +314,7 @@ # include unistd.h #endif -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_ldap with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug DTRACE DTRACEFLAGS enable_dtrace CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_ldap with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -865,6 +865,7 @@ --disable-rpath do not embed shared library search path in executables --disable-spinlocks do not use spinlocks --enable-debug build with debugging symbols (-g) + --enable-dtrace build with DTrace support --enable-depend turn on automatic dependency tracking --enable-cassertenable assertion checks (for debugging) --enable-thread-safety make client libraries thread-safe @@ -1947,6 +1948,82 @@ # +# DTrace +# + + + +# Check whether --enable-dtrace or --disable-dtrace was given. +if test ${enable_dtrace+set} = set; then + enableval=$enable_dtrace + + case $enableval in +yes) + +cat confdefs.h \_ACEOF +#define ENABLE_DTRACE 1 +_ACEOF + +for ac_prog in dtrace +do + # Extract the first word of $ac_prog, so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo $as_me:$LINENO: checking for $ac_word 5 +echo $ECHO_N checking for $ac_word... $ECHO_C 6 +if test ${ac_cv_prog_DTRACE+set} = set; then + echo $ECHO_N (cached) $ECHO_C 6 +else + if test -n $DTRACE; then + ac_cv_prog_DTRACE=$DTRACE # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir