pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Unable to connect DB...?
6+ messages / 3 participants
[nested] [flat]

* Unable to connect DB...?
@ 2019-07-16 06:39 Venkataramana Aitla <avr1984@gmail.com>
  2019-07-16 11:44 ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  0 siblings, 1 reply; 6+ messages in thread

From: Venkataramana Aitla @ 2019-07-16 06:39 UTC (permalink / raw)
  To: pgsql-admin@lists.postgresql.org <pgsql-admin@lists.postgresql.org>

Hi,

Not able to connect DB...

psql -d <DB_name>
psql: FATAL:  could not open file "base/32777/14376902”: No such file or
directory

DB size is in ~1.5TB

What is the solution for this..?

-- 

Thanks & Regards
Venkataramana Aitla

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: Unable to connect DB...?
  2019-07-16 06:39 Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
@ 2019-07-16 11:44 ` Holger Jakobs <holger@jakobs.com>
  2019-07-16 12:07   ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  0 siblings, 1 reply; 6+ messages in thread

From: Holger Jakobs @ 2019-07-16 11:44 UTC (permalink / raw)
  To: pgsql-admin@lists.postgresql.org

Actually, the directory base and all its descendants must be owned by
the user postgres. Check this or correct by issuing this command as root:

chown -R postgres:postgres /path/to/directory

The /path/to/directory has to be to the directory where base resides in.

Regards,

Holger

Am 16.07.19 um 08:39 schrieb Venkataramana Aitla:
> Hi,
>
> Not able to connect DB...
>
> psql -d <DB_name>
> psql: FATAL:  could not open file "base/32777/14376902”: No such file
> or directory
>
> DB size is in ~1.5TB
>
> What is the solution for this..?
>
> -- 
>
> Thanks & Regards
> Venkataramana Aitla
-- 

Holger Jakobs, Bergisch Gladbach
instant messaging: xmpp:holger@jakobs.com
+49 178 9759012 <tel:+491789759012> oder +49 2202 817157
<tel:+492202817157>

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: Unable to connect DB...?
  2019-07-16 06:39 Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
  2019-07-16 11:44 ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
@ 2019-07-16 12:07   ` Holger Jakobs <holger@jakobs.com>
  2019-07-16 12:09     ` Re: Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
  2019-07-16 14:10     ` Re: Unable to connect DB...? Ron <ronljohnsonjr@gmail.com>
  0 siblings, 2 replies; 6+ messages in thread

From: Holger Jakobs @ 2019-07-16 12:07 UTC (permalink / raw)
  To: pgsql-admin@lists.postgresql.org

Since your message says that the file is completely missing, someone
must have deleted the file. There is nothing you can do except restoring
from a backup.

Making sure postgres owns the files and the access rights are restricted
to rw------- prevents this.

Even a file system error won't lead to this situation, as typically the
file remains with length 0.


Am 16.07.19 um 13:44 schrieb Holger Jakobs:
>
> Actually, the directory base and all its descendants must be owned by
> the user postgres. Check this or correct by issuing this command as root:
>
> chown -R postgres:postgres /path/to/directory
>
> The /path/to/directory has to be to the directory where base resides in.
>
> Regards,
>
> Holger
>
> Am 16.07.19 um 08:39 schrieb Venkataramana Aitla:
>> Hi,
>>
>> Not able to connect DB...
>>
>> psql -d <DB_name>
>> psql: FATAL:  could not open file "base/32777/14376902”: No such file
>> or directory
>>
>> DB size is in ~1.5TB
>>
>> What is the solution for this..?
>>
>> -- 
>>
>> Thanks & Regards
>> Venkataramana Aitla
> -- 
>
> Holger Jakobs, Bergisch Gladbach
> instant messaging: xmpp:holger@jakobs.com
> +49 178 9759012 <tel:+491789759012> oder +49 2202 817157
> <tel:+492202817157>
>
-- 

Holger Jakobs, Bergisch Gladbach
instant messaging: xmpp:holger@jakobs.com
+49 178 9759012 <tel:+491789759012> oder +49 2202 817157
<tel:+492202817157>

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: Unable to connect DB...?
  2019-07-16 06:39 Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
  2019-07-16 11:44 ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  2019-07-16 12:07   ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
@ 2019-07-16 12:09     ` Venkataramana Aitla <avr1984@gmail.com>
  1 sibling, 0 replies; 6+ messages in thread

From: Venkataramana Aitla @ 2019-07-16 12:09 UTC (permalink / raw)
  To: Holger Jakobs <holger@jakobs.com>; +Cc: pgsql-admin@lists.postgresql.org

Thanks for your response...

The directory base is already owned by user postgres only.

On Tue, 16 Jul 2019 at 17:38, Holger Jakobs <holger@jakobs.com> wrote:

> Since your message says that the file is completely missing, someone must
> have deleted the file. There is nothing you can do except restoring from a
> backup.
>
> Making sure postgres owns the files and the access rights are restricted
> to rw------- prevents this.
>
> Even a file system error won't lead to this situation, as typically the
> file remains with length 0.
>
>
> Am 16.07.19 um 13:44 schrieb Holger Jakobs:
>
> Actually, the directory base and all its descendants must be owned by the
> user postgres. Check this or correct by issuing this command as root:
>
> chown -R postgres:postgres /path/to/directory
>
> The /path/to/directory has to be to the directory where base resides in.
>
> Regards,
>
> Holger
> Am 16.07.19 um 08:39 schrieb Venkataramana Aitla:
>
> Hi,
>
> Not able to connect DB...
>
> psql -d <DB_name>
> psql: FATAL:  could not open file "base/32777/14376902”: No such file or
> directory
>
> DB size is in ~1.5TB
>
> What is the solution for this..?
>
> --
>
> Thanks & Regards
> Venkataramana Aitla
>
> --
>
> Holger Jakobs, Bergisch Gladbach
> instant messaging: xmpp:holger@jakobs.com
> +49 178 9759012 <+491789759012> oder +49 2202 817157 <+492202817157>
>
> --
>
> Holger Jakobs, Bergisch Gladbach
> instant messaging: xmpp:holger@jakobs.com
> +49 178 9759012 <+491789759012> oder +49 2202 817157 <+492202817157>
>
-- 

Thanks & Regards
Venkataramana Aitla

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: Unable to connect DB...?
  2019-07-16 06:39 Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
  2019-07-16 11:44 ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  2019-07-16 12:07   ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
@ 2019-07-16 14:10     ` Ron <ronljohnsonjr@gmail.com>
  2019-07-16 14:13       ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  1 sibling, 1 reply; 6+ messages in thread

From: Ron @ 2019-07-16 14:10 UTC (permalink / raw)
  To: pgsql-admin@lists.postgresql.org

Once, our developers had the bright idea of *deleting files* to quickly 
purge data.  Naturally, it corrupted everything, and points to the danger of 
developers having the postgres password...

On 7/16/19 7:07 AM, Holger Jakobs wrote:
>
> Since your message says that the file is completely missing, someone must 
> have deleted the file. There is nothing you can do except restoring from a 
> backup.
>
> Making sure postgres owns the files and the access rights are restricted 
> to rw------- prevents this.
>
> Even a file system error won't lead to this situation, as typically the 
> file remains with length 0.
>
>

-- 
Angular momentum makes the world go 'round.

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: Unable to connect DB...?
  2019-07-16 06:39 Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
  2019-07-16 11:44 ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  2019-07-16 12:07   ` Re: Unable to connect DB...? Holger Jakobs <holger@jakobs.com>
  2019-07-16 14:10     ` Re: Unable to connect DB...? Ron <ronljohnsonjr@gmail.com>
@ 2019-07-16 14:13       ` Holger Jakobs <holger@jakobs.com>
  0 siblings, 0 replies; 6+ messages in thread

From: Holger Jakobs @ 2019-07-16 14:13 UTC (permalink / raw)
  To: pgsql-admin@lists.postgresql.org,Ron <ronljohnsonjr@gmail.com>

Deleting files isn't really faster than drop table. But it can easily lead to a corrupt database.

No developer should ever have the password of the operating system account postgres on a productive machine. Actually, not even any postgresql superuser password.


Am 16. Juli 2019 16:10:39 MESZ schrieb Ron <ronljohnsonjr@gmail.com>:
>Once, our developers had the bright idea of *deleting files* to quickly
>
>purge data.  Naturally, it corrupted everything, and points to the
>danger of 
>developers having the postgres password...
>
>On 7/16/19 7:07 AM, Holger Jakobs wrote:
>>
>> Since your message says that the file is completely missing, someone
>must 
>> have deleted the file. There is nothing you can do except restoring
>from a 
>> backup.
>>
>> Making sure postgres owns the files and the access rights are
>restricted 
>> to rw------- prevents this.
>>
>> Even a file system error won't lead to this situation, as typically
>the 
>> file remains with length 0.
>>
>>
>
>-- 
>Angular momentum makes the world go 'round.

-- 
Holger Jakobs, Bergisch Gladbach
+49 178 9759012
- sent from mobile, therefore short -

^ permalink  raw  reply  [nested|flat] 6+ messages in thread


end of thread, other threads:[~2019-07-16 14:13 UTC | newest]

Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2019-07-16 06:39 Unable to connect DB...? Venkataramana Aitla <avr1984@gmail.com>
2019-07-16 11:44 ` Holger Jakobs <holger@jakobs.com>
2019-07-16 12:07   ` Holger Jakobs <holger@jakobs.com>
2019-07-16 12:09     ` Venkataramana Aitla <avr1984@gmail.com>
2019-07-16 14:10     ` Ron <ronljohnsonjr@gmail.com>
2019-07-16 14:13       ` Holger Jakobs <holger@jakobs.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox