Gracias Lazaro, el español es mi idioma, solo que como el foro de pgpool es ingles, era para que se pueda entender.. gracias por la aclaracion, ahora entiendo el por que de esta situacion(pensaba que igual debia de tomar el now() del master, q al comitear se guardaba lo que el master generaba), la verdad que por las funcionalidades y ventajas del pgpool-II , decidi usarlo, estamos en etapa de pruebas de funcionamiento justamente, para poder meterlo a produccion. estuve viendo la funcionalidad del postgresql con replicacion sincronica, pero no se que tan eficaz sea, tal vez sea por desconocimiento mio.. A mi entender, el pgpool-II, es mejor, tu utilizas la replicacion sincronica del Postgres ? que tal es, asi, tambien lo estaria probando para ver que tal funciona. <br>
<br>una vez mas, gracias por la aclaracion y ayuda.<br><br><div class="gmail_quote">2012/9/13 Lazáro Rubén García Martínez <span dir="ltr"><<a href="mailto:lgarciam@vnz.uci.cu" target="_blank">lgarciam@vnz.uci.cu</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hola Diego, te escribo en español, porque vi que los campos de tu tabla están escritos es español y supongo que ese sea tu idioma. Si no es el caso me respondes.<br>

<br>
Según estuve viendo en tu fichero de configuración, estas utilizando la replicación síncrona de pgpool-II mediante el modo replication_mode=on.<br>
<br>
Lo que sucede es que los parámetros de fecha tienen un default con la funcion now() y cuando a pgpool le llega esta consulta, al esta ser enviada a cada nodo, el resultado de now() en cada uno puede ser diferente como es el caso, pues cada una se ejecuta en cada servidor de manera independiente. Cuando yo estuve utilizando este método de replicación, me sucedía lo mismo y el convenio que se utilizó en el desarrollo, era calcular las fechas desde la app y pasarlas a la función como parámetro.<br>

<br>
Otra alternativa es utilizar streaming replication, de esa forma garantizas que todo lo que sea guardado en el master exista identicamente en los standby, y como pude apreciar al estar en 9.1 puedes también utilizar replicación sincrona nativa de postgres que ya está incluida en esa versión.<br>

<br>
Saludos.<br>
________________________________________<br>
From: Diego Ayala [<a href="mailto:netdiego81@gmail.com">netdiego81@gmail.com</a>]<br>
Sent: Thursday, September 13, 2012 8:52 AM<br>
To: Tatsuo Ishii<br>
Cc: <a href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a>; Lazáro Rubén García Martínez<br>
Subject: Re: [pgpool-general: 989] Re: Fwd: Timestamp and pgpool-II 3.2<br>
<div><div class="h5"><br>
thanks for replying,<br>
<br>
I have my development database that contains the table test. well, to insert records, comparing both tables and I see the difference in milliseconds that were generated in each server. I need that times are exact, since we have a procurement system for auction, which requires the milliseconds, and that can make a difference to any bidder wins the bid.<br>

the truth is that it's random, I went back to try and generate some logs me equal, and others have differences in milliseconds<br>
<br>
CREATE TABLE test<br>
(<br>
  id bigserial NOT NULL,<br>
  namecharacter varying(200),<br>
  alta timestamp without time zone DEFAULT now(),<br>
  mod timestamp with time zone DEFAULT now()<br>
)<br>
WITH (<br>
  OIDS=FALSE<br>
);<br>
<br>
 insert into test(name) values('first test');<br>
<br>
<br>
server 1 : select * from prueba;<br>
 id |            nombre            |       tiempo        |            alta            |              mod<br>
----+------------------------------+---------------------+----------------------------+-------------------------------<br>
  1 | diego                        | 2012-09-04 14:23:45 |  2012-09-04 14:25:33.040833 |   2012-09-04 14:56:57.631909-04<br>
  2 | ayala                        | 2012-09-04 14:24:22 |  2012-09-04 14:25:33.040833 |   2012-09-04 14:56:57.631909-04<br>
  3 | pepe                         | 2012-09-04 14:24:28 |  2012-09-04 14:25:33.040833 |   2012-09-04 14:56:57.631909-04<br>
  4 | mujica                       | 2012-09-04 14:24:35 |  2012-09-04 14:25:33.040833 |   2012-09-04 14:56:57.631909-04<br>
  5 | rolo                         | 2012-09-04 14:25:45 |     2012-09-04 14:25:45.143966   |    2012-09-04 14:56:57.631909-04<br>
  6 | chespi                       | 2012-09-04 14:26:00 |   2012-09-04 14:25:59.735838 |    2012-09-04 14:56:57.631909-04<br>
  7 | trifulcio rapado             | 2012-09-04 14:26:26 |  2012-09-04 14:26:26.056678 |    2012-09-04 14:56:57.631909-04<br>
  8 | eraldo                       | 2012-09-04 14:27:45 |     2012-09-04 14:27:45.082837 |    2012-09-04 14:56:57.631909-04<br>
  9 | CORTINAS                     | 2012-09-04 14:53:07 |  2012-09-04 14:53:07.086145 |   2012-09-04 14:56:57.631909-04<br>
 10 | PUERTAS                      | 2012-09-04 14:57:30 |  2012-09-04 14:57:30.109121 |   2012-09-04 14:57:30.109121-04<br>
<br>
 11 | prueba de desarrollo         | 2012-09-13 09:05:25 |  2012-09-13 09:05:25.393988 |   2012-09-13 09:05:25.393988-04<br>
 12 | segunda prueba de desarrollo | 2012-09-13 09:06:24 |  2012-09-13 09:06:24.083936 |   2012-09-13 09:06:24.083936-04<br>
(12 rows)<br>
<br>
<br>
<br>
server 2: select * from prueba;<br>
 id |            nombre            |       tiempo        |            alta            |              mod<br>
----+------------------------------+---------------------+----------------------------+-------------------------------<br>
  1 | diego                        | 2012-09-04 14:23:45 |   2012-09-04 14:25:33.042316 |    2012-09-04 14:56:57.633128-04<br>
  2 | ayala                        | 2012-09-04 14:24:22 |   2012-09-04 14:25:33.042316 |   2012-09-04 14:56:57.633128-04<br>
  3 | pepe                         | 2012-09-04 14:24:28 |   2012-09-04 14:25:33.042316 |   2012-09-04 14:56:57.633128-04<br>
  4 | mujica                       | 2012-09-04 14:24:35 |   2012-09-04 14:25:33.042316 |   2012-09-04 14:56:57.633128-04<br>
  5 | rolo                         | 2012-09-04 14:25:45 |   2012-09-04 14:25:45.144954 |   2012-09-04 14:56:57.633128-04<br>
  6 | chespi                       | 2012-09-04 14:26:00 |   2012-09-04 14:25:59.736717 |   2012-09-04 14:56:57.633128-04<br>
  7 | trifulcio rapado             | 2012-09-04 14:26:26 |   2012-09-04 14:26:26.057284 |   2012-09-04 14:56:57.633128-04<br>
  8 | eraldo                       | 2012-09-04 14:27:45 |   2012-09-04 14:27:45.083635 |    2012-09-04 14:56:57.633128-04<br>
  9 | CORTINAS                     | 2012-09-04 14:53:07 |   2012-09-04 14:53:07.087332 |   2012-09-04 14:56:57.633128-04<br>
 10 | PUERTAS                      | 2012-09-04 14:57:30 |   2012-09-04 14:57:30.110247 |   2012-09-04 14:57:30.110247-04<br>
<br>
 11 | prueba de desarrollo         | 2012-09-13 09:05:25 |   2012-09-13 09:05:25.393988 |   2012-09-13 09:05:25.393988-04<br>
 12 | segunda prueba de desarrollo | 2012-09-13 09:06:24 |   2012-09-13 09:06:24.083936 |   2012-09-13 09:06:24.083936-04<br>
(12 rows)<br>
<br>
<br>
<br>
<br>
lazaro therefore seen, the watchdog does almost the same as the hearbeat, just as enbebido say already in the nucleus of pgPool-II, also, it proves<br>
<br>
thanks for the help<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</div></div>2012/9/12 Lazáro Rubén García Martínez <<a href="mailto:lgarciam@vnz.uci.cu">lgarciam@vnz.uci.cu</a><mailto:<a href="mailto:lgarciam@vnz.uci.cu">lgarciam@vnz.uci.cu</a>>><br>
<div class="im">The core of pgpool-II 3.2 has a new functionality developed for the high availability of pgpool, it is called watchdog. Maybe you could use it instead of heartbeat. This is not the case of the problem, this is only one recomendation.<br>

<br>
Regards.<br>
________________________________________<br>
</div>From: <a href="mailto:pgpool-general-bounces@pgpool.net">pgpool-general-bounces@pgpool.net</a><mailto:<a href="mailto:pgpool-general-bounces@pgpool.net">pgpool-general-bounces@pgpool.net</a>> [<a href="mailto:pgpool-general-bounces@pgpool.net">pgpool-general-bounces@pgpool.net</a><mailto:<a href="mailto:pgpool-general-bounces@pgpool.net">pgpool-general-bounces@pgpool.net</a>>] On Behalf Of Diego Ayala [<a href="mailto:netdiego81@gmail.com">netdiego81@gmail.com</a><mailto:<a href="mailto:netdiego81@gmail.com">netdiego81@gmail.com</a>>]<br>

<div class="im">Sent: Wednesday, September 12, 2012 5:18 PM<br>
To: Tatsuo Ishii<br>
</div>Cc: <a href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a><mailto:<a href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a>><br>
<div class="im">Subject: [pgpool-general: 989] Re: Fwd: Timestamp and pgpool-II 3.2<br>
<br>
this is my config file. forget to mention, I'm also using heartbeat, high availability for pgPool-II<br>
<br>
</div>2012/9/12 Tatsuo Ishii <<a href="mailto:ishii@postgresql.org">ishii@postgresql.org</a><mailto:<a href="mailto:ishii@postgresql.org">ishii@postgresql.org</a>><mailto:<a href="mailto:ishii@postgresql.org">ishii@postgresql.org</a><mailto:<a href="mailto:ishii@postgresql.org">ishii@postgresql.org</a>>>><br>

<div class="HOEnZb"><div class="h5">> good afternoon, I have a question, if you could get me out of doubt, to have<br>
> a timestamp() without time zone NOT NULL DEFAULT now (), to replicate,<br>
> there differences<br>
> in thousandths between each server. That is a problem or pgPool-II, there<br>
> is a solution to not happen? I'm using version 3.2 on pgPool REL6-II and<br>
> PostgreSQL 9.1<br>
><br>
> thanks for the help<br>
><br>
> eg<br>
> Server 1 =  2012-09-04 14:57:30.109121-04<br>
> Server 2 =  2012-09-04 14:57:30.110247-04<br>
<br>
Please show us pgpool.conf.<br>
--<br>
Tatsuo Ishii<br>
SRA OSS, Inc. Japan<br>
English: <a href="http://www.sraoss.co.jp/index_en.php" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
Japanese: <a href="http://www.sraoss.co.jp" target="_blank">http://www.sraoss.co.jp</a><br>
<br>
<br>
________________________________<br>
Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!<br>
<a href="http://www.antiterroristas.cu" target="_blank">http://www.antiterroristas.cu</a><br>
<a href="http://justiciaparaloscinco.wordpress.com" target="_blank">http://justiciaparaloscinco.wordpress.com</a><br>
<br>
Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!<br>
<a href="http://www.antiterroristas.cu" target="_blank">http://www.antiterroristas.cu</a><br>
<a href="http://justiciaparaloscinco.wordpress.com" target="_blank">http://justiciaparaloscinco.wordpress.com</a><br>
<br>
<br>
________________________________<br>
Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!<br>
<a href="http://www.antiterroristas.cu" target="_blank">http://www.antiterroristas.cu</a><br>
<a href="http://justiciaparaloscinco.wordpress.com" target="_blank">http://justiciaparaloscinco.wordpress.com</a><br>
<br>
Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!<br>
<a href="http://www.antiterroristas.cu" target="_blank">http://www.antiterroristas.cu</a><br>
<a href="http://justiciaparaloscinco.wordpress.com" target="_blank">http://justiciaparaloscinco.wordpress.com</a><br>
</div></div></blockquote></div><br>