Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h1knu-0001CO-Cy for pgsql-admin@arkaria.postgresql.org; Thu, 07 Mar 2019 04:38:49 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1h1kns-0001qW-4o for pgsql-admin@arkaria.postgresql.org; Thu, 07 Mar 2019 04:38:44 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h1knr-0001qO-MY for pgsql-admin@lists.postgresql.org; Thu, 07 Mar 2019 04:38:43 +0000 Received: from mail-oln040092253035.outbound.protection.outlook.com ([40.92.253.35] helo=APC01-SG2-obe.outbound.protection.outlook.com) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h1knn-0001ZE-CR for pgsql-admin@lists.postgresql.org; Thu, 07 Mar 2019 04:38:42 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=oky1bjUpZytQGokxmrZ+b7yPYWwf1My5wIJSYpp6ihs=; b=lWBm2ZGcIyYq3fWzePHl4Lw4kvikMDzTw6fMfYmm8M6jSdRr6lx0fxt5T9ethLZXeRbVhP+b8baS5lS/H4+sBUE0FXImNcfiPUfAoFkxDzYkqv2/cc8BEMAuVBLDHabv5MMUPt8z80Wt9nUTebZx2CPcayk3brg0RbHyy+smg2HSO8qpYPOhsFNkg9Ftf+Qvp4/jY9EZ0FRFeFJVsOTsOOaYyETLYk1zKxyaBK2JIrQS2nV7dvJwl+3vaQ3KZsOwCMZakn0HdbjxWd2wtkJYTE1cg+bJyVMtAKOwqmWq8JM7vTUWFPIa61PQvrAaJulql7eh9MvZ242fLuW5/vUe7Q== Received: from PU1APC01FT114.eop-APC01.prod.protection.outlook.com (10.152.252.55) by PU1APC01HT083.eop-APC01.prod.protection.outlook.com (10.152.253.43) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1643.15; Thu, 7 Mar 2019 04:38:34 +0000 Received: from MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM (10.152.252.58) by PU1APC01FT114.mail.protection.outlook.com (10.152.252.228) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1643.15 via Frontend Transport; Thu, 7 Mar 2019 04:38:33 +0000 Received: from MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM ([fe80::e90e:15ee:3a:a5a6]) by MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM ([fe80::e90e:15ee:3a:a5a6%3]) with mapi id 15.20.1686.018; Thu, 7 Mar 2019 04:38:33 +0000 From: soumitra bhandary To: Shreeyansh Dba CC: "pgsql-admin@lists.postgresql.org" , "pgsql-admin@postgresql.org" Subject: Re: Installation of Postgres 10.0 and running application with HA without postgres user at OS Thread-Topic: Installation of Postgres 10.0 and running application with HA without postgres user at OS Thread-Index: AQHUz/QDOrZPFsNJpka/Qs2aSFVNyqX/nbE9 Date: Thu, 7 Mar 2019 04:38:33 +0000 Message-ID: References: , In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-incomingtopheadermarker: OriginalChecksum:8E7AEFAC87E8CD44716C16D052E65ED4FA67D605D0DDCA6EF047D05CFEB3AE74;UpperCasedChecksum:41C90A6554C4361487CD2BD990ACF6B401DE2645B5CB6B2BBEEC87C722BEDBA9;SizeAsReceived:7169;Count:45 x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [lOgiN24TJr8Z4dWT2/JbwSE8MUAvvBj9] x-ms-publictraffictype: Email x-incomingheadercount: 45 x-eopattributedmessage: 0 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(20181119110)(201702061078)(5061506573)(5061507331)(1603103135)(2017031320274)(2017031324274)(2017031323274)(2017031322404)(1601125500)(1603101475)(1701031045);SRVR:PU1APC01HT083; x-ms-traffictypediagnostic: PU1APC01HT083: x-microsoft-antispam-message-info: yHKJjjtsgbnvidE413SXgmktBH03is/0aLlQHKhHMNR3dP54RqHOU+4xtJVKyxFX Content-Type: multipart/alternative; boundary="_000_MA1PR01MB35482F804330305944E7597AE04C0MA1PR01MB3548INDP_" MIME-Version: 1.0 X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-CrossTenant-Network-Message-Id: 3612538a-6e34-424e-7236-08d6a2b6c1cd X-MS-Exchange-CrossTenant-rms-persistedconsumerorg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Mar 2019 04:38:33.8358 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: PU1APC01HT083 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --_000_MA1PR01MB35482F804330305944E7597AE04C0MA1PR01MB3548INDP_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi Shreeyansh , Thanks for the response . I installed postgres 10.0 rpm . It created osuser postgres and executed ini= tdb and cluster is up and running . Then I took my current user (not root) to create another cluster using init= db . It successfully created but I am not able to log in to the new cluster= using psql and current user(through which initdb was executed). Thanks, Soumitra ________________________________ From: Shreeyansh Dba Sent: Friday, March 1, 2019 11:29 AM To: soumitra bhandary Cc: pgsql-admin@lists.postgresql.org; pgsql-admin@postgresql.org Subject: Re: Installation of Postgres 10.0 and running application with HA = without postgres user at OS Hi Sumintra, You have to create a postgres OS user,initdb must be run as the user that w= ill own the server process, because the server needs to have access to the = files and directories that initdb creates. Since the server cannot be run a= s root, you must not run initdb as root either. (It will in fact refuse to = do so.) Thanks & Regards, Shreeyansh DBA Team www.shreeyansh.com On Fri, Mar 1, 2019 at 10:37 AM soumitra bhandary > wrote: Hi , I am using RHEL to install Postgres 10 and setting up replication . But in = my OS no postgres user exists . Installed it with sudo access . Can I run t= he postgres DB with all it's utility (like psql, vaccumdb , pg_rewind , ini= tdb etc.) along with Master slave replication, archival process without pos= tgres user. If it can be done , do I need to follow any extra step to the os user apart= from postgres ? Is there any way to skip postgres os user ? Thanks , Soumitra --_000_MA1PR01MB35482F804330305944E7597AE04C0MA1PR01MB3548INDP_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hi Shreeyansh , 

Thanks for the response . 

I installed postgres 10.0 rpm . It created osuser postgres and executed ini= tdb and cluster is up and running . 

Then I took my current user (not root) to create another cluster using init= db . It successfully created but I am not able to log in to the new cluster= using psql and current user(through which initdb was executed). 


Thanks, 
Soumitra 

From: Shreeyansh Dba <sh= reeyansh2014@gmail.com>
Sent: Friday, March 1, 2019 11:29 AM
To: soumitra bhandary
Cc: pgsql-admin@lists.postgresql.org; pgsql-admin@postgresql.org
Subject: Re: Installation of Postgres 10.0 and running application w= ith HA without postgres user at OS
 
Hi Sumintra,

You have to create a postgres OS u= ser,initdb must be run as the user that will own the server process, becaus= e the server needs to have access to the files and directories that initdb = creates. Since the server cannot be run as root, you must not run initdb as root either. (It will in fact refuse to do so.)=

Thanks & Regards,
Shreeyansh DBA Team
ww= w.shreeyansh.com


On Fri, Mar 1, 2019 at 10:37 AM sou= mitra bhandary <soumitr= a.bhandary@hotmail.com> wrote:
Hi , 

I am using RHEL to install Postgres 10 and setting up replication . But in = my OS no postgres user exists . Installed it with sudo access . Can I run t= he postgres DB with all it's utility (like psql, vaccumdb , pg_rewind , ini= tdb etc.) along with Master slave replication, archival process without postgres user. 

If it can be done , do I need to follow any extra step to the os user apart= from postgres ?

Is there any way to skip postgres os user ?

Thanks , 
Soumitra 
--_000_MA1PR01MB35482F804330305944E7597AE04C0MA1PR01MB3548INDP_--