Re: [GENERAL] Strange Issue between PSQL 9.3 and Label Zebra Printer?

2017-04-23 Thread Periko Support
Yes, with our datamax no issue.
Once u setup the label in LabelView u chose which printer to use.


On Sun, Apr 23, 2017 at 1:27 PM, Adrian Klaver
<adrian.kla...@aklaver.com> wrote:
> On 04/23/2017 01:12 PM, Periko Support wrote:
>>
>> We use a label program called LabelView to create our labels, we read
>> the record using ODBC.
>> The label has 8 fields which UPC is what it changes on each one.
>
>
> You use the same program and setup to print to the DataMax printer and you
> do not have the same issue, correct?
>
>
>> Thanks.
>>
>> On Sat, Apr 22, 2017 at 11:28 AM, Adrian Klaver
>> <adrian.kla...@aklaver.com> wrote:
>>>
>>> On 04/21/2017 05:14 PM, Periko Support wrote:
>>>>
>>>>
>>>> Hi guys.
>>>>
>>>> I would to explain my current strange issue with our label printer
>>>> -.
>>>>
>>>> Windows 8.1 x64, psqlodbc 9.5x86/x64 drivers tested.
>>>>
>>>> The issue is that every time we print labels that read data from the
>>>> DB, the print start printing
>>>> with pause on every label.
>>>
>>>
>>>
>>> What application are you doing this through?
>>>
>>>>
>>>> Is like, select data, send result to printer, print the label, stop,
>>>> request new record start over.
>>>
>>>
>>>
>>> Is each record different information?
>>>
>>> Or are you talking about multiple copies of a single record?
>>>
>>>>
>>>> PSQL is running under Linux Ubuntu 14.x PSQL 9.3.x
>>>>
>>>> We have other printer from DataMAX which we don't have any issue and
>>>> the connection is by LAN.
>>>
>>>
>>>
>>> So what does it do?
>>>
>>>
>>>>
>>>> Wondering is some one here have in the past issues like this one?
>>>>
>>>> Thanks for your time!!!
>>>>
>>>>
>>>
>>>
>>> --
>>> Adrian Klaver
>>> adrian.kla...@aklaver.com
>>
>>
>>
>
>
> --
> Adrian Klaver
> adrian.kla...@aklaver.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] Strange Issue between PSQL 9.3 and Label Zebra Printer?

2017-04-23 Thread Periko Support
We use a label program called LabelView to create our labels, we read
the record using ODBC.
The label has 8 fields which UPC is what it changes on each one.
Thanks.

On Sat, Apr 22, 2017 at 11:28 AM, Adrian Klaver
<adrian.kla...@aklaver.com> wrote:
> On 04/21/2017 05:14 PM, Periko Support wrote:
>>
>> Hi guys.
>>
>> I would to explain my current strange issue with our label printer
>> -.
>>
>> Windows 8.1 x64, psqlodbc 9.5x86/x64 drivers tested.
>>
>> The issue is that every time we print labels that read data from the
>> DB, the print start printing
>> with pause on every label.
>
>
> What application are you doing this through?
>
>>
>> Is like, select data, send result to printer, print the label, stop,
>> request new record start over.
>
>
> Is each record different information?
>
> Or are you talking about multiple copies of a single record?
>
>>
>> PSQL is running under Linux Ubuntu 14.x PSQL 9.3.x
>>
>> We have other printer from DataMAX which we don't have any issue and
>> the connection is by LAN.
>
>
> So what does it do?
>
>
>>
>> Wondering is some one here have in the past issues like this one?
>>
>> Thanks for your time!!!
>>
>>
>
>
> --
> Adrian Klaver
> adrian.kla...@aklaver.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Strange Issue between PSQL 9.3 and Label Zebra Printer?

2017-04-21 Thread Periko Support
Hi guys.

I would to explain my current strange issue with our label printer
Zebra ZT230 USB.

Windows 8.1 x64, psqlodbc 9.5x86/x64 drivers tested.

The issue is that every time we print labels that read data from the
DB, the print start printing
with pause on every label.

Is like, select data, send result to printer, print the label, stop,
request new record start over.

PSQL is running under Linux Ubuntu 14.x PSQL 9.3.x

We have other printer from DataMAX which we don't have any issue and
the connection is by LAN.

Wondering is some one here have in the past issues like this one?

Thanks for your time!!!


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] HotSync Replicate doubt?

2017-03-30 Thread Periko Support
Good, them I must tested, thanks guys!!!

On Thu, Mar 30, 2017 at 9:49 AM, Adrian Klaver
<adrian.kla...@aklaver.com> wrote:
> On 03/30/2017 09:39 AM, Periko Support wrote:
>>
>> Hi guys.
>>
>> I had some doubt about PSQL internal replication mechanics(Streaming).
>>
>> If I setup a Master-Slave Hot StandBy.
>>
>> The slave is on a Read-Only stage, but we can query the server.
>>
>> If a user create a table in the database:
>>
>> CREATE DATABASE mynewdb;
>> CREATE TABLE mytbale-name + fields.
>>
>> Or if changes a table with new fields or remove fields.
>>
>> Does the replication will send this commands to the SLAVE without user
>> intervention?
>>
>> I run bucardo for replication, but this feature doesn't work, we need
>> to manually do it on the
>> SLAVE and some other steps to have both DB sync.
>>
>> We already know how to do it, bucardo works.
>>
>> Just wondering if PSQL can handle this automatically?
>
>
> Yes, with an exception:
>
> https://www.postgresql.org/docs/9.6/static/warm-standby.html
>
> 26.2.1. Planning
>
> "Keep in mind that if CREATE TABLESPACE is executed on the primary, any new
> mount point needed for it must be created on the primary and all standby
> servers before the command is executed"
>
>>
>> Thanks.
>>
>>
>
>
> --
> Adrian Klaver
> adrian.kla...@aklaver.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] HotSync Replicate doubt?

2017-03-30 Thread Periko Support
Hi guys.

I had some doubt about PSQL internal replication mechanics(Streaming).

If I setup a Master-Slave Hot StandBy.

The slave is on a Read-Only stage, but we can query the server.

If a user create a table in the database:

CREATE DATABASE mynewdb;
CREATE TABLE mytbale-name + fields.

Or if changes a table with new fields or remove fields.

Does the replication will send this commands to the SLAVE without user
intervention?

I run bucardo for replication, but this feature doesn't work, we need
to manually do it on the
SLAVE and some other steps to have both DB sync.

We already know how to do it, bucardo works.

Just wondering if PSQL can handle this automatically?

Thanks.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] [Bucardo-general] Master-Slave setup.

2016-10-17 Thread Periko Support
Excellent, Yes I can make a copy before run bucardo the first time and
just add pushdelta to my sync and star working.
Thanks David.

On Mon, Oct 17, 2016 at 10:04 AM, David Christensen  wrote:
>> This week will continue testing but I have some doubts in a Master-Slave 
>> Setup.
>>
>> The slave db, if I will replicate the master, is prefer to start my
>> slave with empty data? or with a exact copy of my master db?
>
> Hi Periko,
>
> If you can start it with a copy of the master db you save yourself a step.  
> Otherwise you will need to initialize the target in Bucardo either using a 
> onetimesync=1 in the sync definition or copy over using pg_dump out-of-band.  
> Bucardo will not load the data in the target explicitly without being told 
> to, so if you just started with empty data it would only copy the rows over 
> as changes were made to them, probably not the effect you were looking for.
>
> David
> --
> David Christensen
> End Point Corporation
> da...@endpoint.com
> 785-727-1171
>
>
>


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] [Bucardo-general] doubts about target db?

2016-10-14 Thread Periko Support
Thanks Rakesh.

Let me explain my reason to have a replica server.

We run odoo server 7.x with ubuntu 14.

But we are working on a BI system right now(Pentaho), them we want to
run those heavy reports on the replica and let the current production
system on the master.

This is why I was thinking on a M-S setup.

Why don't u use PSQL built in replica tools? We try but exist  a lets
behavior of odoo that if u run a report he try to update some internal
tables and won't allow us to run our reports in the slave(streaming
replica).
Because the slave is in a ReadOnly mode.

Them we start searching for a solution and we came to bucardo.

Now, the BI server will just for that.

What setup guys recommend, M-M or M-S for my solution?

Now let me think in the future, I can think on a M-M-S, If the
master-1 fails we have the 2nd and nothing happen right and our
current S will continue running, bucardo let me do this?

Now let me back in the setup of bucardo, we u are in the setup, how
can I told to bucardo is a M-M or M-S?

Sorry for to much question, I want to understand all this and make my
own manual, I see a lot of settings of bucardo in the man page but not
to much examples.

youtube and google are giving me a lot info.

Thanks for your time and help!!!

On Fri, Oct 14, 2016 at 8:54 AM, Rakesh Kumar
 wrote:
>>Other thing, with bucardo what is the difference between in a
>>master-master replica vs master-slave, at the end in both ways the
>>user has a 2nd DB with R/W permission?
>
> I think in a M-M mode, updates from both dbs will be replicated to the other 
> db.
> In other words they will be eventually consistent.
> In a M-S mode, even though Slaves can be updated by the app, its updates will
> not be replicated back to the master. While updates from M->S will happen all
> the time, updates from S will not go to M.
>


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] [Bucardo-general] doubts about target db?

2016-10-14 Thread Periko Support
Thanks Rosser for your answer.

Other thing, with bucardo what is the difference between in a
master-master replica vs master-slave, at the end in both ways the
user has a 2nd DB with R/W permission?

Thanks.

On Thu, Oct 13, 2016 at 9:40 PM, Rosser Schwarz
<rosser.schw...@gmail.com> wrote:
> On Thursday, October 13, 2016, Periko Support <pheriko.supp...@gmail.com>
> wrote:
>>
>> 1) My target db must have all the tables created without data on it before
>> sync?
>
>
> Yes, tables must exist on the target. Generally, it's easiest to have them
> empty, but the bigger concern is conflicts with data from the master.
>
>>
>> 2) In a master-master or master slave, bucardo is best to be reside in the
>> main master side?
>
>
>  It doesn't really matter, as long as it can reach all the dbs it's
> managing. I've run it on the master, on the slave, and on another host
> entirely.
>
> rls
>
>
>
> --
> :wq


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-12 Thread Periko Support
Just to inform u that my log Yesterday didn't show any 'recovery' which is
the main goal of this post.

Looks like the script was causing the issue, I test and change it to the
one from Scott I'.

On odoo I switch user sessions from default value 1 week(:-/) to 1 hour.

I found that option in the file: /opt/openerp/web/addons/web/http.py
google help.

def session_gc(session_store):
if random.random() < 0.001:
# we keep session one week
#last_week = time.time() - 60*60*24*7 <= 1 week, don't know why
they chose this value.
last_week = time.time() - 3600   <change it to 1 hour.
for fname in os.listdir(session_store.path):
path = os.path.join(session_store.path, fname)
try:
if os.path.getmtime(path) < last_week:
os.unlink(path)
except OSError:
pass

Other thing, my server was using swap memory+5MB, checking logs and system,
the task that was causing my server to eat swap, not much but don't want to
use this, the backup process at night is the one that
force the system to use swap, I increase my memory 20GB+ and today I just
see swap =0 :-).

I will continue monitoring my system, I still have other goals to finish,
but this error was a big one.

Thanks all for your help and contribution.

On Mon, Oct 10, 2016 at 6:50 PM, Pavel Stehule <pavel.steh...@gmail.com>
wrote:

>
>
> 2016-10-10 21:43 GMT+02:00 Periko Support <pheriko.supp...@gmail.com>:
>
>> For the life time in odoo session, can u point me where I can manage that
>> setting?
>>
>> The configuration /etc/openerp-server.conf doesn't have any parameter for
>> that.
>>
>> That must be in a odoo file...?
>>
>
> https://www.odoo.com/forum/help-1/question/reduce-memory-usage-54636
> http://www.vionblog.com/openerp-server-conf-for-openerp-7-explained/
>
> Regards
>
> Pavel
>
>
>
>> Thanks.
>>
>> On Mon, Oct 10, 2016 at 12:25 PM, Pavel Stehule <pavel.steh...@gmail.com>
>> wrote:
>>
>>>
>>>
>>> 2016-10-10 21:12 GMT+02:00 Periko Support <pheriko.supp...@gmail.com>:
>>>
>>>> Andreo u got a good observation here.
>>>>
>>>> I got a script that run every hour why?
>>>>
>>>> Odoo got some issues with IDLE connections, if we don't check our
>>>> current psql connections after a while the system eat all connections and a
>>>> lot of them are IDLE and stop answering users, we create a script that runs
>>>> every hour, this is:
>>>>
>>>> """ Script is used to kill database connection which are idle from last
>>>> 15 minutes """
>>>> #!/usr/bin/env python
>>>> import psycopg2
>>>> import sys
>>>> import os
>>>> from os.path import join, expanduser
>>>> import subprocess, signal, psutil
>>>> import time
>>>>
>>>> def get_conn():
>>>>
>>>> conn_string = "host='localhost' dbname='template1' user='openerp'
>>>> password='s$p_p@r70'"
>>>>
>>>> try:
>>>> # get a connection, if a connect cannot be made an exception
>>>> will be raised here
>>>> conn = psycopg2.connect(conn_string)
>>>> cursor = conn.cursor()
>>>> #print "successful Connection"
>>>> return cursor
>>>> except:
>>>> exceptionType, exceptionValue, exceptionTraceback =
>>>> sys.exc_info()
>>>> sys.exit("Database connection failed!\n ->%s" %
>>>> (exceptionValue))
>>>>
>>>>
>>>> def get_pid():
>>>>
>>>> SQL="select pid, datname, usename from pg_stat_activity where
>>>> usename = 'openerp' AND query_start < current_timestamp - INTERVAL '15'
>>>> MINUTE;"
>>>> cursor = get_conn()
>>>> cursor.execute(SQL)
>>>> idle_record = cursor.fetchall()
>>>> print "---
>>>> "
>>>> print "Date:",time.strftime("%d/%m/%Y")
>>>> print "idle record list: ", idle_record
>>>> print "---
>>>> "
>>>> for pid in idle_record:
>>>> try:
>>>> #   

Re: [SPAM] [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
Scott your script is very clean, I'm testing, thanks.

On Mon, Oct 10, 2016 at 3:28 PM, Scott Mead <sco...@openscg.com> wrote:
>
>
> On Mon, Oct 10, 2016 at 6:15 PM, Tom Lane <t...@sss.pgh.pa.us> wrote:
>>
>> Adrian Klaver <adrian.kla...@aklaver.com> writes:
>> > On 10/10/2016 12:18 PM, Periko Support wrote:
>> >> I was on vacation, but the issue have the same behavior:
>>
>> > Actually no. Before you had:
>>
>> > 2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
>> > terminated by signal 9: Killed
>>
>> > Now you have:
>>
>> > 2016-10-10 07:50:09 PDT WARNING:  terminating connection because of
>> > crash of another server process
>>
>> Most likely it *is* the same thing but the OP trimmed the second log
>> excerpt too much.  The "crash of another server process" complaints
>> suggest strongly that there was already another problem and this
>> is just part of the postmaster's kill-all-children-and-restart
>> recovery procedure.
>>
>> Now, if there really is nothing before this in the log, another possible
>> theory is that something decided to send the child processes a SIGQUIT
>> signal, which would cause them to believe that the postmaster had told
>> them to commit hara-kiri.  I only bring this up because we were already
>> shown a script sending random SIGKILLs ... so random SIGQUITs wouldn't be
>> too hard to credit either.  But the subsequent log entries don't quite
>> square with that idea; if the postmaster weren't already expecting the
>> children to die, it would have reacted differently.
>
>
>
> The better solution is to do this in one query and more safely:
>
> select pid, usename, datname, pg_terminate_backend(pid)
>FROM pg_stat_activity
>   WHERE usename = 'openerp'
>AND  now() - query_start > '15 minutes'::interval;
>
>This will use the builtin 'pg_terminate_backend for you in one shot.
>
>  --Scott
>
>
>
>>
>>
>> regards, tom lane
>>
>>
>> --
>> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-general
>
>
>
>
> --
> --
> Scott Mead
> Sr. Architect
> OpenSCG
> http://openscg.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [SPAM] [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
Adrian

2016-10-10 12:00:01 PDT LOG:  connection authorized: user=openerp
database=template1
2016-10-10 12:00:01 PDT LOG:  server process (PID 30394) was
terminated by signal 9: Killed
2016-10-10 12:00:01 PDT DETAIL:  Failed process was running: SELECT
"name", "model", "description", "month" FROM "etiquetas_temp"
2016-10-10 12:00:01 PDT LOG:  terminating any other active server processes

I will  do some changes to my server and see if I can fix the issue.

Thanks for your comment and all of u for your great help.


On Mon, Oct 10, 2016 at 2:03 PM, Adrian Klaver
<adrian.kla...@aklaver.com> wrote:
> On 10/10/2016 12:18 PM, Periko Support wrote:
>>
>> I was on vacation, but the issue have the same behavior:
>
>
> Actually no. Before you had:
>
> 2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
> terminated by signal 9: Killed
>
> Now you have:
>
> 2016-10-10 07:50:09 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-10-10 07:50:09 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
>
> Which corresponds to this from your subsequent post:
>
> #os.system("kill -9 %s" % (int(pid[0]), ))
> os.kill(int(pid[0]), signal.SIGKILL)
>
>>
>> 2016-10-10 07:50:09 PDT WARNING:  terminating connection because of
>> crash of another server process
>> 2016-10-10 07:50:09 PDT DETAIL:  The postmaster has commanded this
>> server process to roll back the current transaction and exit, because
>> another server process exited abnormally and possibly corrupted shared
>> memory.
>> 2016-10-10 07:50:09 PDT HINT:  In a moment you should be able to
>> reconnect to the database and repeat your command.
>> 2016-10-10 07:50:09 PDT WARNING:  terminating connection because of
>> crash of another server process
>> 2016-10-10 07:50:09 PDT DETAIL:  The postmaster has commanded this
>> server process to roll back the current transaction and exit, because
>> another server process exited abnormally and possibly corrupted shared
>> memory.
>> 2016-10-10 07:50:09 PDT HINT:  In a moment you should be able to
>> reconnect to the database and repeat your command.
>> 2016-10-10 07:50:09 PDT LOG:  archiver process (PID 13066) exited with
>> exit code 1
>> 2016-10-10 07:50:10 PDT LOG:  all server processes terminated;
>> reinitializing
>> 2016-10-10 07:50:10 PDT LOG:  connection received: host=192.168.2.6
>> port=37700
>> 2016-10-10 07:50:10 PDT LOG:  database system was interrupted; last
>> known up at 2016-10-10 07:49:15 PDT
>> 2016-10-10 07:50:10 PDT FATAL:  the database system is in recovery mode
>> 2016-10-10 07:50:10 PDT LOG:  connection received: host=192.168.2.6
>> port=37702
>> 2016-10-10 07:50:10 PDT FATAL:  the database system is in recovery mode
>> 2016-10-10 07:50:15 PDT LOG:  database system was not properly shut
>> down; automatic recovery in progress
>> 2016-10-10 07:50:15 PDT LOG:  redo starts at 517/C928
>> 2016-10-10 07:50:15 PDT LOG:  unexpected pageaddr 517/7700 in log
>> segment 0001051700D2, offset 0
>> 2016-10-10 07:50:15 PDT LOG:  redo done at 517/D1C8
>> 2016-10-10 07:50:15 PDT LOG:  last completed transaction was at log
>> time 2016-10-10 07:49:09.891669-07
>> 2016-10-10 07:50:15 PDT LOG:  connection received: host=192.168.2.6
>> port=37704
>> 2016-10-10 07:50:15 PDT FATAL:  the database system is in recovery mode
>> 2016-10-10 07:50:15 PDT LOG:  connection received: host=192.168.2.6
>> port=37706
>> 2016-10-10 07:50:15 PDT FATAL:  the database system is in recovery mode
>> 2016-10-10 07:50:16 PDT LOG:  MultiXact member wraparound protections
>> are now enabled
>> 2016-10-10 07:50:16 PDT LOG:  database system is ready to accept
>> connections
>> 2016-10-10 07:50:16 PDT LOG:  autovacuum launcher started
>>
>> 2016-10-10 09:00:01 PDT LOG:  archiver process (PID 14004) exited with
>> exit code 1
>> 2016-10-10 09:00:01 PDT WARNING:  terminating connection because of
>> crash of another server process
>> 2016-10-10 09:00:01 PDT DETAIL:  The postmaster has commanded this
>> server process to roll back the current transaction and exit, because
>> another server process exited abnormally and possibly corrupted shared
>> memory.
>> 2016-10-10 09:00:01 PDT HINT:  In a moment you should be able to
>> reconnect to the database and repeat your command.
>> 2016-10-10 09:00:01 PDT WARNING:  terminati

Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
For the life time in odoo session, can u point me where I can manage that
setting?

The configuration /etc/openerp-server.conf doesn't have any parameter for
that.

That must be in a odoo file...?

Thanks.

On Mon, Oct 10, 2016 at 12:25 PM, Pavel Stehule <pavel.steh...@gmail.com>
wrote:

>
>
> 2016-10-10 21:12 GMT+02:00 Periko Support <pheriko.supp...@gmail.com>:
>
>> Andreo u got a good observation here.
>>
>> I got a script that run every hour why?
>>
>> Odoo got some issues with IDLE connections, if we don't check our current
>> psql connections after a while the system eat all connections and a lot of
>> them are IDLE and stop answering users, we create a script that runs every
>> hour, this is:
>>
>> """ Script is used to kill database connection which are idle from last
>> 15 minutes """
>> #!/usr/bin/env python
>> import psycopg2
>> import sys
>> import os
>> from os.path import join, expanduser
>> import subprocess, signal, psutil
>> import time
>>
>> def get_conn():
>>
>> conn_string = "host='localhost' dbname='template1' user='openerp'
>> password='s$p_p@r70'"
>>
>> try:
>> # get a connection, if a connect cannot be made an exception will
>> be raised here
>> conn = psycopg2.connect(conn_string)
>> cursor = conn.cursor()
>> #print "successful Connection"
>> return cursor
>> except:
>> exceptionType, exceptionValue, exceptionTraceback = sys.exc_info()
>> sys.exit("Database connection failed!\n ->%s" % (exceptionValue))
>>
>>
>> def get_pid():
>>
>> SQL="select pid, datname, usename from pg_stat_activity where usename
>> = 'openerp' AND query_start < current_timestamp - INTERVAL '15' MINUTE;"
>> cursor = get_conn()
>> cursor.execute(SQL)
>> idle_record = cursor.fetchall()
>> print "---
>> "
>> print "Date:",time.strftime("%d/%m/%Y")
>> print "idle record list: ", idle_record
>> print "---
>> "
>> for pid in idle_record:
>> try:
>> #print "process details",pid
>> #os.system("kill -9 %s" % (int(pid[0]), ))
>> os.kill(int(pid[0]), signal.SIGKILL)
>> except OSError as ex:
>> continue
>>
>> get_pid()
>>
>> I will move this to run not every hour and see the reaction.
>>
>> Is a easy move, about Tim, our current KVM server is good for me, see
>> picture please:
>>
>>
>> free
>>  total   used   free sharedbuffers cached
>> Mem: 181764228  136200312   45563916468  69904 734652
>> -/+ buffers/cache:  135395756   46368472
>> Swap:   261948  0 261948
>>
>> I got other vm but they are on other raid setup.
>>
>> Tim u mention that u recommend reduce memory pressure, u mean to lower
>> down my values like shared_buffers or increase memory?
>>
>
> try to decrease lifetime of odoo sessions - then memory will be returned
> back to system - set limit_memory_soft less in odoo config - I found some
> manuals on net with wrong settings on net.
>
> the odoo sessions should be refreshed more often.
>
> Regards
>
> Pavel
>
>
>
>>
>>
>> Melvin I try that value before but my server cry, I will add more memory
>> in a few weeks.
>>
>> Any comment I will appreciated, thanks.
>>
>> On Mon, Oct 10, 2016 at 11:22 AM, Tom Lane <t...@sss.pgh.pa.us> wrote:
>>
>>> Periko Support <pheriko.supp...@gmail.com> writes:
>>> > My current server has 82GB memory.
>>>
>>> You said this was running inside a VM, though --- maybe the VM is
>>> resource-constrained?
>>>
>>> In any case, turning off memory overcommit would be a good idea if
>>> you're not concerned about running anything but Postgres.
>>>
>>> regards, tom lane
>>>
>>
>>
>


Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
That script was from a vendor called 'allianzgrp.com'.

Was their solution.

Them I have a lot of work to do here.

On Mon, Oct 10, 2016 at 12:32 PM, Alban Hertroys <haram...@gmail.com> wrote:
>
>> On 10 Oct 2016, at 21:28, Alban Hertroys <haram...@gmail.com> wrote:
>>
>>
>>> On 10 Oct 2016, at 21:12, Periko Support <pheriko.supp...@gmail.com> wrote:
>>>
>>>for pid in idle_record:
>>>try:
>>> #print "process details",pid
>>> #os.system("kill -9 %s" % (int(pid[0]), ))
>>>os.kill(int(pid[0]), signal.SIGKILL)
>>>except OSError as ex:
>>>continue
>>
>> That query returns PostgreSQL backends and you're sending them SIGKILL. Not 
>> a recommended practice far as I know. Shouldn't you rather be sending those 
>> kill signals to the clients connecting to the db?
>> Worse, apparently at some time in the past (a month ago matching those logs, 
>> perhaps?) it used to send kill -9! That's absolutely a very bad idea.
>>
>> While on the topic, there is a PG function to cancel a backend query from 
>> within PG: https://www.postgresql.org/docs/9.5/static/functions-admin.html
>> I think that's the best way to go about this, and best of all, you can 
>> combine that with your select statement.
>
> Another idea struck me; if that script is under version control, you can 
> check when that change was committed. If it isn't, perhaps you should. My 
> current favourite is Hg (aka Mercurial), which happens to be written in 
> Python, just like your script.
>
> Alban Hertroys
> --
> If you can't see the forest for the trees,
> cut the trees and you'll find there is no forest.
>


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [SPAM] [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
/8E0126B0
2016-10-10 09:00:07 PDT LOG:  redo done at 51A/8E012680
2016-10-10 09:00:07 PDT LOG:  last completed transaction was at log
time 2016-10-10 09:00:01.142505-07
2016-10-10 09:00:08 PDT LOG:  connection received: host=127.0.0.1 port=35956
2016-10-10 09:00:08 PDT FATAL:  the database system is in recovery mode
2016-10-10 09:00:08 PDT LOG:  connection received: host=127.0.0.1 port=35957
2016-10-10 09:00:08 PDT FATAL:  the database system is in recovery mode
2016-10-10 09:00:08 PDT LOG:  MultiXact member wraparound protections
are now enabled
2016-10-10 09:00:08 PDT LOG:  database system is ready to accept connections
2016-10-10 09:00:08 PDT LOG:  autovacuum launcher started

Thanks.

On Mon, Oct 10, 2016 at 11:32 AM, Adrian Klaver
<adrian.kla...@aklaver.com> wrote:
> On 10/10/2016 11:14 AM, Moreno Andreo wrote:
>>
>>
>> Il 10/10/2016 18:24, Periko Support ha scritto:
>>>
>>> 2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
>>> terminated by signal 9: Killed
>>
>>
>>> 2016-09-12 10:00:01 PDT LOG:  server process (PID 30766) was
>>> terminated by signal 9: Killed
>>
>>
>>> 2016-09-12 15:00:01 PDT LOG:  server process (PID 22030) was
>>> terminated by signal 9: Killed
>>>
>>>
>> These datetimes could be suspect. Every crash (kill) is done at
>> "00"minutes and "01" minutes, that makes me ask "Isn't there something
>> like cron running something that interfere with postgres?"
>
>
> While we on the subject, the datetimes are almost a month old.
>
> Does that mean this problem was just noticed or are the datetimes wrong?
>
>>
>> Cheers,
>> Moreno.
>>
>>
>>
>>
>
>
> --
> Adrian Klaver
> adrian.kla...@aklaver.com
>
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] HA Cluster Solution?

2016-10-10 Thread Periko Support
I'm trying to get better numbers, is a option in the table.
Meanwhile I reading some system performance numbers.
Yes odoo is strange sometimes.
But a cluster will be good for HA.
Thanks.

On Mon, Oct 10, 2016 at 11:12 AM, Pavel Stehule <pavel.steh...@gmail.com> wrote:
> Hi
>
> 2016-10-10 17:20 GMT+02:00 Periko Support <pheriko.supp...@gmail.com>:
>>
>> I have done some tuning for psql base on odoo, but I want to know if a
>> cluster can help to get a better performance, this why I ask here in
>> the community who has experience with clusters.
>> Appreciate your help Pavel.
>
>
> It is hard to say if cluster helps - depends on data size - but odoo
> produces really strange queries - I am little bit sceptic. But I am sure, so
> cluster increase significantly maintenance costs.
>
> Regards
>
> Pavel
>
>>
>>
>> On Sun, Oct 9, 2016 at 9:29 PM, Pavel Stehule <pavel.steh...@gmail.com>
>> wrote:
>> > Hi
>> >
>> > 2016-10-10 6:22 GMT+02:00 Periko Support <pheriko.supp...@gmail.com>:
>> >>
>> >>   Hi.
>> >>
>> >>   We are searching for a cluster solutions for postgresql, we need to
>> >> increase our current psql server performance running under ubuntu 14
>> >> v9.3.
>> >>
>> >>The db is for odoo 7.x
>> >
>> >
>> > I have some experience with odoo 7.x - there are lot of pretty slow
>> > queries
>> > without good possibility of optimization. More - there are some articles
>> > on
>> > net that advices suboptimal configuration of Postgres, of odoo.
>> >
>> > If you can, you can try to upgrade to PostgreSQL 9.6 - more CPU per
>> > query
>> > can help, or you can upgrade to new odoo (I have not real experience,
>> > but
>> > the web speak about lot of optimization).
>> >
>> > If you have some own customization, look to slow queries - lot of
>> > performance issues can be fixed.
>> >
>> > Regards
>> >
>> > Pavel
>> >
>> >
>> >
>> >>
>> >>
>> >>Reading on psql doc cluster, exist different solutions like
>> >> postgresql-xl, pgpool which are more for clustering.
>> >>
>> >> In your experience what psql tools for clustering and HA have give
>> >> u good performance.
>> >>
>> >> Any comment are welcome, thanks for your time!!!
>> >>
>> >>
>> >> --
>> >> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
>> >> To make changes to your subscription:
>> >> http://www.postgresql.org/mailpref/pgsql-general
>> >
>> >
>>
>>
>> --
>> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-general
>
>


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
Andreo u got a good observation here.

I got a script that run every hour why?

Odoo got some issues with IDLE connections, if we don't check our current
psql connections after a while the system eat all connections and a lot of
them are IDLE and stop answering users, we create a script that runs every
hour, this is:

""" Script is used to kill database connection which are idle from last 15
minutes """
#!/usr/bin/env python
import psycopg2
import sys
import os
from os.path import join, expanduser
import subprocess, signal, psutil
import time

def get_conn():

conn_string = "host='localhost' dbname='template1' user='openerp'
password='s$p_p@r70'"

try:
# get a connection, if a connect cannot be made an exception will
be raised here
conn = psycopg2.connect(conn_string)
cursor = conn.cursor()
#print "successful Connection"
return cursor
except:
exceptionType, exceptionValue, exceptionTraceback = sys.exc_info()
sys.exit("Database connection failed!\n ->%s" % (exceptionValue))


def get_pid():

SQL="select pid, datname, usename from pg_stat_activity where usename =
'openerp' AND query_start < current_timestamp - INTERVAL '15' MINUTE;"
cursor = get_conn()
cursor.execute(SQL)
idle_record = cursor.fetchall()
print
"---"
print "Date:",time.strftime("%d/%m/%Y")
print "idle record list: ", idle_record
print
"---"
for pid in idle_record:
try:
#print "process details",pid
#os.system("kill -9 %s" % (int(pid[0]), ))
os.kill(int(pid[0]), signal.SIGKILL)
except OSError as ex:
continue

get_pid()

I will move this to run not every hour and see the reaction.

Is a easy move, about Tim, our current KVM server is good for me, see
picture please:


free
 total   used   free sharedbuffers cached
Mem: 181764228  136200312   45563916468  69904 734652
-/+ buffers/cache:  135395756   46368472
Swap:   261948  0 261948

I got other vm but they are on other raid setup.

Tim u mention that u recommend reduce memory pressure, u mean to lower down
my values like shared_buffers or increase memory?

Melvin I try that value before but my server cry, I will add more memory in
a few weeks.

Any comment I will appreciated, thanks.

On Mon, Oct 10, 2016 at 11:22 AM, Tom Lane <t...@sss.pgh.pa.us> wrote:

> Periko Support <pheriko.supp...@gmail.com> writes:
> > My current server has 82GB memory.
>
> You said this was running inside a VM, though --- maybe the VM is
> resource-constrained?
>
> In any case, turning off memory overcommit would be a good idea if
> you're not concerned about running anything but Postgres.
>
> regards, tom lane
>


Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
Or add more memory to my server?

On Mon, Oct 10, 2016 at 11:05 AM, Periko Support
<pheriko.supp...@gmail.com> wrote:
> My current server has 82GB memory.
>
> Default settings but the only parameter I had chance is shared_buffers
> from 128MB to 6G.
>
> This server is dedicated to postgresql+odoo.
>
> Is the only parameter I can thing can reduce my memory utilization?
>
> Thanks Tom.
>
>
> On Mon, Oct 10, 2016 at 10:03 AM, Tom Lane <t...@sss.pgh.pa.us> wrote:
>> Periko Support <pheriko.supp...@gmail.com> writes:
>>> I got some issues with my DB under ubuntu 14.x.
>>> PSQL 9.3, odoo 7.x.
>>
>>> 2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
>>> terminated by signal 9: Killed
>>
>> Usually, SIGKILLs coming out of nowhere indicate that the Linux OOM killer
>> has decided to target some database process.  You need to do something to
>> reduce memory pressure and/or disable memory overcommit so that that
>> doesn't happen.
>>
>> regards, tom lane


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
My current server has 82GB memory.

Default settings but the only parameter I had chance is shared_buffers
from 128MB to 6G.

This server is dedicated to postgresql+odoo.

Is the only parameter I can thing can reduce my memory utilization?

Thanks Tom.


On Mon, Oct 10, 2016 at 10:03 AM, Tom Lane <t...@sss.pgh.pa.us> wrote:
> Periko Support <pheriko.supp...@gmail.com> writes:
>> I got some issues with my DB under ubuntu 14.x.
>> PSQL 9.3, odoo 7.x.
>
>> 2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
>> terminated by signal 9: Killed
>
> Usually, SIGKILLs coming out of nowhere indicate that the Linux OOM killer
> has decided to target some database process.  You need to do something to
> reduce memory pressure and/or disable memory overcommit so that that
> doesn't happen.
>
> regards, tom lane


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
I want to add my server load normally, please see attachment, thanks.

​


On Mon, Oct 10, 2016 at 9:24 AM, Periko Support <pheriko.supp...@gmail.com>
wrote:

> I got some issues with my DB under ubuntu 14.x.
> PSQL 9.3, odoo 7.x.
>
> This machine is under KVM with centos  6.x
>
> It has a Raid1 with ssd drives only for this vm.
>
> I detect some unexpected shutdows, see this lines:
>
> 2016-09-12 08:59:25 PDT ERROR:  missing FROM-clause entry for table
> "rp" at character 73
> 2016-09-12 08:59:25 PDT STATEMENT:  select
> pp.default_code,pc.product_code,pp.name_template,pc.product_name,rp.name
> from product_product pp inner join product_customer_code pc on
> pc.product_id=pp.id
> 2016-09-12 08:59:26 PDT LOG:  connection received: host=192.168.2.153
> port=59335
> 2016-09-12 08:59:26 PDT LOG:  connection authorized: user=openerp
> database=Mueblex
> 2016-09-12 09:00:01 PDT LOG:  connection received: host=::1 port=43536
> 2016-09-12 09:00:01 PDT LOG:  connection authorized: user=openerp
> database=template1
> 2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
> terminated by signal 9: Killed
> 2016-09-12 09:00:01 PDT DETAIL:  Failed process was running: select
> pp.default_code,pc.product_code,pp.name_template,pc.product_name,rp.name
> from product_product pp inner join product_customer_code pc on
> pc.product_id=pp.id
> 2016-09-12 09:00:01 PDT LOG:  terminating any other active server processes
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
> server process to roll back the current transaction and exit, because
> another server process exited abnormally and possibly corrupted shared
> memory.
> 2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
> reconnect to the database and repeat your command.
> 2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
> crash of another server process
> 2016-09-12 09:00:01 PDT DETAIL:  The postmaster

[GENERAL] psql 9.3 automatic recovery in progress

2016-10-10 Thread Periko Support
I got some issues with my DB under ubuntu 14.x.
PSQL 9.3, odoo 7.x.

This machine is under KVM with centos  6.x

It has a Raid1 with ssd drives only for this vm.

I detect some unexpected shutdows, see this lines:

2016-09-12 08:59:25 PDT ERROR:  missing FROM-clause entry for table
"rp" at character 73
2016-09-12 08:59:25 PDT STATEMENT:  select
pp.default_code,pc.product_code,pp.name_template,pc.product_name,rp.name
from product_product pp inner join product_customer_code pc on
pc.product_id=pp.id
2016-09-12 08:59:26 PDT LOG:  connection received: host=192.168.2.153 port=59335
2016-09-12 08:59:26 PDT LOG:  connection authorized: user=openerp
database=Mueblex
2016-09-12 09:00:01 PDT LOG:  connection received: host=::1 port=43536
2016-09-12 09:00:01 PDT LOG:  connection authorized: user=openerp
database=template1
2016-09-12 09:00:01 PDT LOG:  server process (PID 23958) was
terminated by signal 9: Killed
2016-09-12 09:00:01 PDT DETAIL:  Failed process was running: select
pp.default_code,pc.product_code,pp.name_template,pc.product_name,rp.name
from product_product pp inner join product_customer_code pc on
pc.product_id=pp.id
2016-09-12 09:00:01 PDT LOG:  terminating any other active server processes
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 09:00:01 PDT HINT:  In a moment you should be able to
reconnect to the database and repeat your command.
2016-09-12 09:00:01 PDT WARNING:  terminating connection because of
crash of another server process
2016-09-12 09:00:01 PDT DETAIL:  The postmaster has commanded this
server process to roll back the current transaction and exit, because
another server process exited abnormally and possibly corrupted shared
memory.
2016-09-12 

Re: [GENERAL] HA Cluster Solution?

2016-10-10 Thread Periko Support
I have done some tuning for psql base on odoo, but I want to know if a
cluster can help to get a better performance, this why I ask here in
the community who has experience with clusters.
Appreciate your help Pavel.

On Sun, Oct 9, 2016 at 9:29 PM, Pavel Stehule <pavel.steh...@gmail.com> wrote:
> Hi
>
> 2016-10-10 6:22 GMT+02:00 Periko Support <pheriko.supp...@gmail.com>:
>>
>>   Hi.
>>
>>   We are searching for a cluster solutions for postgresql, we need to
>> increase our current psql server performance running under ubuntu 14
>> v9.3.
>>
>>The db is for odoo 7.x
>
>
> I have some experience with odoo 7.x - there are lot of pretty slow queries
> without good possibility of optimization. More - there are some articles on
> net that advices suboptimal configuration of Postgres, of odoo.
>
> If you can, you can try to upgrade to PostgreSQL 9.6 - more CPU per query
> can help, or you can upgrade to new odoo (I have not real experience, but
> the web speak about lot of optimization).
>
> If you have some own customization, look to slow queries - lot of
> performance issues can be fixed.
>
> Regards
>
> Pavel
>
>
>
>>
>>
>>Reading on psql doc cluster, exist different solutions like
>> postgresql-xl, pgpool which are more for clustering.
>>
>> In your experience what psql tools for clustering and HA have give
>> u good performance.
>>
>> Any comment are welcome, thanks for your time!!!
>>
>>
>> --
>> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-general
>
>


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] HA Cluster Solution?

2016-10-09 Thread Periko Support
  Hi.

  We are searching for a cluster solutions for postgresql, we need to
increase our current psql server performance running under ubuntu 14
v9.3.

   The db is for odoo 7.x

   Reading on psql doc cluster, exist different solutions like
postgresql-xl, pgpool which are more for clustering.

In your experience what psql tools for clustering and HA have give
u good performance.

Any comment are welcome, thanks for your time!!!


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Pentaho Odoo PSQL Slave.

2016-08-23 Thread Periko Support
Hi.

Do someone here running Pentaho(Odoo) on a PSQL Master-Slave in the
slave server?

Thanks.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] Tunning Server 9.1.

2016-08-04 Thread Periko Support
I read some sites on google that it was related to this settings.
Can u share your experience on this logs?


On Thu, Aug 4, 2016 at 11:17 AM, John R Pierce <pie...@hogranch.com> wrote:
> On 8/4/2016 6:01 AM, Periko Support wrote:
>>
>> This was my message:
>>
>>   PDT FATAL:  remaining connection slots are reserved for
>> non-replication superuser connections
>
>
> you said you got a message about shared memory ??   thats nothing to do with
> this ?
>
>
>
> --
> john r pierce, recycling bits in santa cruz
>
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Streaming Replica Master-Salve Config.

2016-08-04 Thread Periko Support
 Hi.

 I'm testing streaming replica with ubuntu 14 and psql9.3.

 I'm trying to understand how this works, my plan is to setup the
slave server for pentaho reports for queries only.

 Now, my master server it has 128GB max_connections = 200 maybe I will add more.
 shared_memory=18GB.

 My slave server doesn't have that resources, is a Xeon with 32GB of
RAM with psql same version
running on ubuntu14.

My questions, does the slave server need to have the same resources?
128GB and the same settings in specific max_connections and
shared_memory?

Any comment appreciated, thanks!!!


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] Tunning Server 9.1.

2016-08-04 Thread Periko Support
This was my message:

 PDT FATAL:  remaining connection slots are reserved for
non-replication superuser connections

Reading about, some points to max_connections because we have increase
users on the network, I tought has sense.

In 2 weeks will upgrade to ubuntu 14+psql 9.3

The docs say 25% of the memory, them I put there 18GB increasing
kernel settings.

Now need to support this version, on 9.3 this settings changes?

Thanks.



On Wed, Aug 3, 2016 at 11:02 PM, John R Pierce <pie...@hogranch.com> wrote:
> On 8/3/2016 10:13 PM, Periko Support wrote:
>>
>> This send me a message about shared_memory need to lower the value
>> which default settings = 24MB.
>
>
> what message was this, exactly ?
>
>
> on a 128GB ram system, I would probably have shared_buffers up around 4-8GB.
>
>
> btw, postgres 9.1 is getting on in age, and will soon be desupported, newer
> versions no longer used SysV shm, so you no longer need to adjust shmmax
> values in your kernel.
>
>
>
>
> --
> john r pierce, recycling bits in santa cruz
>
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Tunning Server 9.1.

2016-08-03 Thread Periko Support
Hi.

I have server that hras increase users and need to increase
max_connections from default value.

Current value = 100
New Value = 200

This send me a message about shared_memory need to lower the value
which default settings = 24MB.

My server has 128GB in size, for 200 connections what settings and
values u recommend for my server?

I'm reading tunning just would like to receive tips an suggestions.

Reading docs looks like if I lower shared_buffers will affect my
performance?, right now is 12MB, bigger values won't allow me to
increase max_connections.

Any comment will be appreciated, thanks.

Linux Ubuntu 12.
Postgresql 9.1.x
x64.
128GB RAM


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general