Your message dated Sun, 21 Jun 2015 16:19:35 +0000
with message-id <[email protected]>
and subject line Bug#7: Removed package(s) from unstable
has caused the Debian Bug report #736532,
regarding [postgres-xc] gtm proxy support in init script
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
736532: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=736532
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: postgres-xc
Version: 1.1-2
Severity: normal
Tags: patch

--- Please enter the report below this line. ---

Hello,

Original init script included into the package does not support gtm proxy.

Please find below my suggested patch for init script to handle that
additional component of postgres-xc:


--- /etc/init.d/postgres-xc     2013-08-20 07:29:54.000000000 -0400
+++ ./postgres-xc       2014-01-24 11:37:20.185485456 -0500
@@ -33,6 +33,10 @@
 {
     status=0
     case "$1" in
+        gtm_proxy)
+            pidfile=gtm_proxy.pid
+            sleep 2
+            ;;
         gtm)
             pidfile=gtm.pid
             sleep 2
@@ -40,7 +44,7 @@
         postgres)
             pidfile=postmaster.pid
             confport=$(grep -si '^port *=' $PGXC_DATA/$2/postgresql.conf |
-               cut -f2 -d= | sed -e 's/#.*$//' -e 's/ //g')
+                cut -f2 -d= | sed -e 's/#.*$//' -e 's/ //g')
             port=${confport:=5432}

             # wait for server to come up, but no more than 10 seconds
@@ -63,6 +67,7 @@
             [ "`ps h -o comm -p $PID`" != $1 ] && status=1
         fi
     else
+#       echo $PGXC_DATA/$2/$pidfile is not readable
         status=1
     fi
     return 0
@@ -77,15 +82,24 @@
         $FAST_STOP &&
             STOP_MODE="-mf"
     }
-    for TYPE in datanode coordinator gtm; do
+    SEQUENCE="gtm gtm_proxy coordinator datanode"
+    [ "$ACTION" = "stop" ] && SEQUENCE="datanode coordinator gtm_proxy gtm"
+    for TYPE in $SEQUENCE; do
         case $TYPE in
             gtm)
             PG_CTL=gtm_ctl
             PG_START=gtm
+            EXTRA_OPTS=''
+            ;;
+            gtm_proxy)
+            PG_CTL=gtm_ctl
+            PG_START=gtm_proxy
+            EXTRA_OPTS=''
             ;;
             coordinator|datanode)
             PG_CTL=pg_ctl
             PG_START=postgres
+            EXTRA_OPTS=''
             ;;
         esac
         log_daemon_msg "$2 Postgres-XC ${TYPE}"
@@ -94,24 +108,37 @@
                 if [ "$ACTION" = "reload" ] && [ "$TYPE" = "gtm" ]; then
                     ACTION="restart"
                 fi
+                if [ "$ACTION" = "reload" ] && [ "$TYPE" = "gtm_proxy" ];
then
+                    ACTION="restart"
+                fi
                 [ "$ACTION" = "stop" ] &&
                 check_if_running $PG_START $NODE stop
                 if [ $status -eq 1 ]; then
                     log_progress_msg "$NODE is not running"
                 else
-                    ERRMSG=$(start-stop-daemon -c postgres-xc \
-                               -Sx /usr/bin/$PG_CTL  -- $ACTION $STOP_MODE
\
-                               -D $PGXC_DATA/$NODE -Z $TYPE \
-                               -l $PGXC_LOG/datanode.log
-                       STATUS=$?
-                       if $FAST_STOP && [ $STATUS -gt 0 ] &&
-                               [ "$ACTION" = "stop" ]; then
-                                       STATUS=0
-                                       start-stop-daemon -c postgres-xc \
-                                       -Sx /usr/bin/$PG_CTL  -- stop -mi \
-                                       -D $PGXC_DATA/$NODE -Z $TYPE \
-                                       -l $PGXC_LOG/datanode.log ||
STATUS=$?
-                       fi)
+                if [ "$TYPE" = "gtm_proxy" ] ; then EXTRA_OPTS="-o -D
$PGXC_DATA/$NODE"; fi
+                    ERRMSG=$(if [ "$TYPE" = "gtm_proxy" ] ; then {
+                                start-stop-daemon -c postgres-xc \
+                                -Sx /usr/bin/$PG_CTL  -- $ACTION
$STOP_MODE \
+                                -D $PGXC_DATA/$NODE -Z $TYPE \
+                                -l $PGXC_LOG/datanode.log -o "-D
$PGXC_DATA/$NODE"
+                                }
+                                else {
+                                start-stop-daemon -c postgres-xc \
+                                -Sx /usr/bin/$PG_CTL  -- $ACTION
$STOP_MODE \
+                                -D $PGXC_DATA/$NODE -Z $TYPE \
+                                -l $PGXC_LOG/datanode.log
+                                }
+                                fi
+                STATUS=$?
+                        if $FAST_STOP && [ $STATUS -gt 0 ] &&
+                                [ "$ACTION" = "stop" ]; then
+                                        STATUS=0
+                                        start-stop-daemon -c postgres-xc \
+                                        -Sx /usr/bin/$PG_CTL  -- stop -mi \
+                                        -D $PGXC_DATA/$NODE -Z $TYPE \
+                                        -l $PGXC_LOG/datanode.log ||
STATUS=$?
+                        fi)
                     REPORT=$NODE
                     [ "$ACTION" = "status" ] && REPORT=$ERRMSG
                     log_progress_msg "$REPORT"
@@ -153,4 +180,3 @@
 esac

 exit 0
-


Thanks
Tim

--- System information. ---
Architecture: amd64
Kernel:       Linux 3.11-2-amd64

Debian Release: jessie%2Fsid
  800 unstable        http.us.debian.org
  800 unstable        deb-multimedia.org
  500 stable          dl.google.com
    1 experimental    http.us.debian.org

--- Package information. ---
Depends                      (Version) | Installed
======================================- -================
libc6                        (>= 2.16) |
libcomerr2                   (>= 1.01) |
libgssapi-krb5-2       (>= 1.10 dfsg~) |
libkrb5-3              (>= 1.6.dfsg.2) |
libldap-2.4-2               (>= 2.4.7) |
libpam0g                 (>= 0.99.7.1) |
libpq5                       (>= 9.1~) |
libssl1.0.0                 (>= 1.0.0) |
libxml2                     (>= 2.7.4) |
zlib1g                    (>= 1:1.1.4) |
postgres-xc-client                     |
adduser                                |
ssl-cert                   (>= 1.0.11) |
logrotate                              |


Package's Recommends field is empty.

Package's Suggests field is empty.

--- End Message ---
--- Begin Message ---
Version: 1.1-2+rm

Dear submitter,

as the package postgres-xc has just been removed from the Debian archive
unstable we hereby close the associated bug reports.  We are sorry
that we couldn't deal with your issue properly.

For details on the removal, please see https://bugs.debian.org/7

The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.

This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing
[email protected].

Debian distribution maintenance software
pp.
Luca Falavigna (the ftpmaster behind the curtain)

--- End Message ---
_______________________________________________
Pkg-postgresql-public mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-postgresql-public

Reply via email to