PAGER setting in windows for psql client

psql is a great tool. Oftentimes, output of the particular command in psql is too big to fit on one screen, hence outputs are wrapped to fit in one screen which becomes output unreadable. To custommize command output in readable format we have system variable called PAGER. If its on linux, I can simply set PAGER variable with LESS command + options to view command ouptut in readable format. Eg:-

Continue reading →

PostgreSQL Processes Names in Windows

If you are from linux then its simple to see all processes names (writer process, wal writer, autovacuum etc.,) just by typing ‘ps -ef | grep postgres’, but if you are from windows then its bit tough to see without any help of windows system internal tools. Process Explorera windows system internal tool will brief about active/running process including names. Many options in Process explorer which are very useful to know about processes in windows.

Continue reading →

Swapping Provider, not within slony replicating nodes

My title might be slight contradictory, as per Slony-I, swapping can be achieved among nodes, if nodes are connected to each other by anyway as PROVIDER or RECEIVER and replicating. If you see in my diagram, “DR-Prod” is nowhere related to Slony replicating nodes, still swapping is possible(with some extra care). Here are some valueable inputs from Steve & Jan.Thanks. When we need such kind of swapping, if you are planning to move “PROD” from one data center to another or from existing disk volumn to another (many reasons).

Continue reading →

Simple Slony-I Replication Setup.

Above shown is an overview about Slony-I Asynchronous replication in short. For more information,Slony-I documentation is your best friend :). Let’s start with replication methods, in perltools method,you need to configure slony at the time of source installation to enable built-in perl scripts. These scripts start with “SLONIK_” and they are designed to carry replication administrative tasks. My demo for two methods shell(slonik) & Perl is on Localhost Single instance(5432) with two databases Master & Slave replicating one table “rep_table”.

Continue reading →

PostgreSQL Process names on Solaris

PostgreSQL Processes are very few and countable like, writer process, wal writer proces,stats collector,autovacuum process,syslogger process,archiver process & daemon postmaster. If replication enabled then there will be wal sender & wal receiver process. In my trainings, I use to show process information by executing “ps -ef | grep postgres”, but how could I show the same on Solaris. So, I checked with Solaris Documentation and found its very simple and easy to get the process names as linux.

Continue reading →