1. 10 6月, 2020 1 次提交
  2. 08 6月, 2020 1 次提交
  3. 04 6月, 2020 1 次提交
  4. 21 5月, 2020 1 次提交
  5. 13 5月, 2020 2 次提交
    • N
      gpexpand: behave: allow pkill to fail · c40b1bff
      Ning Yu 提交于
      We use "pkill postgres" to cleanup leaked segments in the behave tests,
      if the postgress processes already exited the pkill command would fail
      with code 1, "No processes matched or none of them could be signalled".
      
      Fixed by ignoring the return code of pkill.
      
      (cherry picked from commit a92e0a33)
      c40b1bff
    • N
      gpexpand: behave: cleanup leaked segs after rollback · 0c62d320
      Ning Yu 提交于
      In the scenario "inject a fail and test if rollback is ok" the expansion
      is canceled after the new segment is launched, it must be shutdown in
      time to prevent port conflicts in followings scenarios.
      
      (cherry picked from commit a5e32530)
      0c62d320
  6. 12 5月, 2020 1 次提交
  7. 07 5月, 2020 2 次提交
    • B
      Improve handling of -I input file · e055c67d
      Bhuvnesh Chaudhary 提交于
      Previously, gpinitsystem did not allow the user to specify a hostname
      and address for each segment in the input file used with -I; it only
      accepted one value per segment and used it for both hostname and
      address.
      
      This commit changes the behavior so that the user can specify both
      hostname and address. If the user specifies only the address (such as by
      using an old config file), it will preserve the old behavior and set
      both hostname and address to that value. It also adds a few tests around
      input file parsing so SET_VAR is more resilient to further refactors.
      
      The specific changes involved are the following:
      
      1) Change SET_VAR to be able to parse either the old format (address
      only) or new format (host and address) of the segment array
      representation.
      2) Move SET_VAR from gpinitsystem to gp_bash_functions.sh and remove the
      redundant copy in gpcreateseg.sh.
      3) Remove a hardcoded "~0" in QD_PRIMARY_ARRAY in gpinitsystem,
      representing a replication port value, that was left over from 5X.
      4) Improve the check for the number of fields in the segment array
      representation.
      
      Also, Remove use of ignore warning flag and use [[ ]] the check for IGNORE_WARNING
      e055c67d
    • B
      gpinitsystem: update catalog with correct hostname · 91771f4f
      Bhuvnesh Chaudhary 提交于
      Previously, gpintsystem was incorrectly filling the hostname field of each
      segment in gp_segment_configuration with the segment's address. This commit
      changes it to correctly resolve hostnames and update the catalog accordingly.
      
      This reverts commit 12ef7352, Revert "gpinitsystem: update catalog with
      correct hostname".
         Commit message from 12ef7352:
         The commit requires some additional tweaks to the input file logic for
         backwards compatibility purposes, so we're reverting this until the full
         fix is ready.
      91771f4f
  8. 29 4月, 2020 1 次提交
  9. 31 3月, 2020 1 次提交
  10. 18 3月, 2020 1 次提交
  11. 14 3月, 2020 2 次提交
  12. 13 3月, 2020 1 次提交
    • C
      Fix analyzedb with config file to work with partitioned tables · 37c18c3e
      Chris Hajas 提交于
      Previously, running analyzedb with an input file (`analyzedb -f
      <config_file`) containing a root partition would fail as we did not
      properly populate the list of leaf partitions. The logic in analyzedb
      assumes that we enumerate leaf partitions from the root partition that
      the user had input (either from the command line or from an input file).
      While we did this properly when the table was passed in from the command
      line, we looked for the table name rather than the schema-qualifed table
      for input files.
      
      This would cause partitioned heap tables to fail when writing the
      report/status files at the end, and would cause analyzedb to not track
      DML changes in partitioned AO tables. Now, we properly check for the
      schema-qualified table name.
      
      (cherry picked from commit d1611944)
      37c18c3e
  13. 09 3月, 2020 1 次提交
  14. 02 3月, 2020 1 次提交
    • H
      Add max_retries flag for gpload (#9606) · 1bb52ea8
      Huiliang.liu 提交于
      Add max_retries flag for gpload. It indicates the max times on connecting to GPDB timed out.
      max_retries default value is 0 which means no retry.
      If max_retries is -1 or other negative value, it means retry forever.
      
      Test has been done manually.
      
      ( cherry pick from master commit: b891b85b)
      1bb52ea8
  15. 27 2月, 2020 1 次提交
  16. 19 2月, 2020 2 次提交
    • H
      Fix dependencies issue in GPPKG utility (6X_STABLE) (#9494) · bf7bc9e9
      Haozhou Wang 提交于
      1. When two gppkg packages have the same dependencies, gppkg utility
         will refuse to install the second gppkg package and throw an error.
         This patch fixes this issue and the second gppkg package can install
         successfully.
      
      2. Fix install/uninstall issue if the master and standby master use the
         same node address.
      
      PS: This patch is backported from the master branch
      bf7bc9e9
    • A
      Avoid ifaddrs utility crash · 78d4e6bb
      Ashwin Agrawal 提交于
      `ifa_addr` may be null for interface returned by getifaddrs(). Hence,
      checking for the same should be perfomed, else ifaddrs crashes. As
      side effect to this crashing, on my ubuntu laptop gpinitstandby always
      fails.
      
      Interface for which `getifaddrs()` returned null for me is:
      gpd0: flags=4240<POINTOPOINT,NOARP,MULTICAST>  mtu 1500
              unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  txqueuelen 500  (UNSPEC)
              RX packets 0  bytes 0 (0.0 B)
              RX errors 0  dropped 0  overruns 0  frame 0
              TX packets 0  bytes 0 (0.0 B)
              TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
      
      (gdb) p *list
      $5 = {ifa_next = 0x5555555586a8, ifa_name = 0x555555558694 "gpd0",
      ifa_flags = 4240, ifa_addr = 0x0, ifa_netmask = 0x0, ifa_ifu =
      {ifu_broadaddr = 0x0, ifu_dstaddr = 0x0}, ifa_data = 0x555555558bb8}
      Reviewed-by: NJacob Champion <pchampion@pivotal.io>
      Reviewed-by: NMark Sliva <msliva@pivotal.io>
      78d4e6bb
  17. 13 2月, 2020 1 次提交
    • A
      Incremental recovery and rebalance should run pg_rewind in parallel · 3ddbed8e
      Asim R P 提交于
      Incremental recovery and rebalance operations involve running
      pg_rewind against failed primaries.  This patch changes gprecoverseg
      such that pg_rewind is invoked in parallel, using the WorkerPool
      interface, for each affected segment in the cluster.  There is no
      reason to rewind segments one after the other.
      
      Fixes Github issue #9466
      
      Reviewed by: Mark Sliva and Paul Guo
      
      (cherry picked from commit 43ad9d05)
      3ddbed8e
  18. 12 2月, 2020 2 次提交
  19. 08 2月, 2020 1 次提交
    • A
      Make gpcheckcat independent of master dbid · 6d5195e7
      Ashwin Agrawal 提交于
      gpcheckcat hard-coded master dbid to 1 for various queries. This
      assumption is flawed. There is no restriction master can only have dbid
      1, it can be any value. For example, failover to standby and gpcheckat
      is not usable with that assumption.
      
      Hence, run-time find the value of master's dbid using the info that
      it's content-id is always -1 and use the same.
      Co-authored-by: NAlexandra Wang <lewang@pivotal.io>
      (cherry picked from commit d1f19ca9)
      6d5195e7
  20. 24 1月, 2020 3 次提交
  21. 03 1月, 2020 3 次提交
  22. 31 12月, 2019 1 次提交
  23. 12 12月, 2019 9 次提交
    • N
      packcore: ignore warnings of the lsb_release command · 607ab4d1
      Ning Yu 提交于
      The lsb_release output is included in the packcore tarball, but
      sometimes the command may show an warning like below:
      
          No LSB modules are available.
      
      This warning message can be safely ignored, so do not show it to the
      user.
      
      (cherry picked from commit d1d7310b)
      607ab4d1
    • N
      packcore: allow spaces in the core name · 9243abcf
      Ning Yu 提交于
      By setting shell=True to python's subprocess.Popen() it composes a
      command string and launches a shell to parse and execute the command,
      this may not handle the spaces and other special characters correctly,
      and may cause security issues.
      
      We should execute the commands with shell=False, the default value, and
      pass the command as an args list, so spaces and other special characters
      can be correctly parsed.
      
      (cherry picked from commit 4f07bf1b)
      9243abcf
    • N
      packcore: remove incomplete tarball on failures · af8b81c0
      Ning Yu 提交于
      Packcore uses the tar command to create a tarball for the coredump, the
      tar command can fail due to kinds of reasons, such as "permission
      denied", "no space left on device", or can not find the gzip command.
      The tar command will not remove the incomplete tarball or failures, we
      should remove it explicitly.
      
      (cherry picked from commit 3c6b0bf1)
      af8b81c0
    • N
      packcore: do not remove existing pack dir · 337b087a
      Ning Yu 提交于
      Pack dir is a temporary directory used by packcore to store the
      coredump, the postgres binary and the shared libraries, then once
      tarball is created the pack dir will be removed.
      
      Packcore will error out if the pack dir already exists, the purpose is
      to prevent removing the user data unexpectedly.  However even it errors
      out it will still remove the pack dir during its cleanup.
      
      Fixed the logic so an pre-existing pack dir is not changed or removed by
      packcore.
      
      (cherry picked from commit a700419d)
      337b087a
    • N
      packcore: let runGDB.sh accepts extra gdb arguments · 401f09eb
      Ning Yu 提交于
      runGDB.sh is a convenient helper script to load the coredump, now we
      allow passing extra gdb arguments to it via cmdline like below:
      
          ./runGDB.sh --batch -ex 'bt'
      
      This makes it more friendly in automated scripts.
      
      Also refactored the code to use python multiline string instead of
      multiple prints.
      
      (cherry picked from commit 0ab035be)
      401f09eb
    • N
      packcore: list libraries with gdb explicitly · 0d85e83e
      Ning Yu 提交于
      Gdb used to show verbose information on every loaded shared libraries
      when loading a coredump, packcore used to rely on them to list the
      libraries.  However with higher version of gdb, such as the one shipped
      on ubuntu 18.04, the information is not printed anymore.
      
      So we should use the gdb `info sharedlibrary` command to list the
      libraries explicitly.
      
      Also set some proper gdb cmdline options for better handling:
      - `--batch`: exit after processing, so we do not need to execute the
        `quit` command explicitly;
      - `--nx`: do not read any `.gdbinit` files;
      
      (cherry picked from commit 9e6a3d52)
      0d85e83e
    • N
      packcore: list libraries with ld-linux.so when ldd is unavailable · 6e25035a
      Ning Yu 提交于
      When the gdb command is not found on the system, packcore could use the
      ldd command to list the shared libraries.  When ldd is neither found now
      we will try to list the libraries with the `ld-linux.so` directly.
      
      (cherry picked from commit ab56489f)
      6e25035a
    • N
      packcore: add missing libraries for ubuntu · 75f88da4
      Ning Yu 提交于
      When listing shared libraries with the ldd command we have to add some
      missing libraries like `libgcc_s.so.1` and `libnss_files.so.2`, they
      have different paths on centos and ubuntu, we should search for them on
      all possible paths.
      
      (cherry picked from commit dbeba12e)
      75f88da4
    • N
      packcore: find correct binary path with file command · 67594f17
      Ning Yu 提交于
      packcore uses the file command to find the postgres binary path, it
      searches for the first single-quoted string and uses it as the path.
      However let's look at an output of the file command on centos 6,
      manually broken into multiple lines:
      
          core.45685:
            ELF 64-bit LSB core file x86-64,
            version 1 (SYSV),
            SVR4-style,
            from 'postgres:  7000, gpadmin isolation2test [local] con7 cmd5 CREATE TABLE',
            real uid: 500,
            effective uid: 500,
            real gid: 501,
            effective gid: 501,
            execfn: '/usr/local/greenplum-db-devel/bin/postgres',
            platform: 'x86_64'
      
      The first single-quoted string is actually the status line as shown in
      the ps command, we should use the `execfn` field as the path.
      
      (cherry picked from commit 8e249c41)
      67594f17