From: Pallav Kalva <pkalva@deg.cc>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@postgresql.org
Cc: pgsql-admin@postgresql.org
Subject: Re: Postgres crashed on invalid IP entry in pg_hba.conf
Date: Wed, 16 Feb 2005 15:15:03 -0500
Message-ID: <4213A9C7.2010404@deg.cc> (raw)
In-Reply-To: <26829.1108584317@sss.pgh.pa.us>
References: <1108578986.421392aad28bd@mail.deg.cc>
<26829.1108584317@sss.pgh.pa.us>
Hi Tom,
Thanks! for the quick reply actually i forgot to attach the log file
in my first email, the next email has the attachment, anyways here is
the output from the log file. as you can see i have 5 numbers in the ip
address which was a typo and postgres crashes when it reads the hba file
with this entry. do you think this problem is specific to the 7.4.2
version .
Feb 15 17:30:55 prod postgres[2322]: [702-1] LOG: invalid IP address
"100.1.100.1.50" in pg_hba.conf file: Name or service not known
Feb 15 17:30:55 prod postgres[13585]: [702-1] LOG: server process (PID
2322) was terminated by signal 11
Feb 15 17:30:55 prod postgres[13585]: [703-1] LOG: terminating any
other active server processes
Feb 15 17:30:55 prod postgres[13585]: [704-1] LOG: all server processes
terminated; reinitializing
Feb 15 17:30:55 prod postgres[2323]: [705-1] LOG: database system was
interrupted at 2005-02-15 17:30:51 EST
Feb 15 17:30:55 prod postgres[2323]: [706-1] LOG: checkpoint record is
at D5/796387A8
Feb 15 17:30:55 prod postgres[2323]: [707-1] LOG: redo record is at
D5/796387A8; undo record is at 0/0; shutdown TRUE
Feb 15 17:30:55 prod postgres[2323]: [708-1] LOG: next transaction ID:
146738745; next OID: 565698175
Feb 15 17:30:55 prod postgres[2323]: [709-1] LOG: database system was
not properly shut down; automatic recovery in progress
Feb 15 17:30:55 prod postgres[2323]: [710-1] LOG: record with zero
length at D5/796387E8
Feb 15 17:30:55 prod postgres[2323]: [711-1] LOG: redo is not required
Feb 15 17:30:55 prod postgres[2324]: [705-1] FATAL: the database system
is starting up
Feb 15 17:30:57 prod postgres[2323]: [712-1] LOG: database system is ready
Feb 15 17:30:59 prod postgres[2329]: [705-1] LOG: invalid IP address
"100.1.100.1.50" in pg_hba.conf file: Name or service not known
Feb 15 17:30:59 prod postgres[2329]: [706-1] LOG: invalid entry in
pg_hba.conf file at line 206, token "100.1.100.1.50"
Feb 15 17:30:59 prod postgres[2329]: [707-1] FATAL: missing or
erroneous pg_hba.conf file
Feb 15 17:30:59 prod postgres[2329]: [707-2] HINT: See server log for
details.
Feb 15 17:30:59 prod postgres[13585]: [705-1] LOG: server process (PID
2329) was terminated by signal 11
Feb 15 17:30:59 prod postgres[13585]: [706-1] LOG: terminating any
other active server processes
Tom Lane wrote:
>pkalva@deg.cc writes:
>
>
>> Yesterday, our production database was crashed as soon as we added an invlid
>>entry in the pg_hba.conf file. Immediately, after the SIGHUP it tried to read
>>the pg_hba.conf file and it couldnt validate the IP address and restarted the
>>postgres server, as soon as we change the pg_hba.conf with the right entry
>>everything was back to normal. Attached you will see the postgres log file at
>>the time of the crash. Postgres version we are using is 7.4.2.
>>
>>
>
>Works fine for me in 7.4.7 ... I get log entries like this:
>
>LOG: invalid IP address "1727.0.0.1" in pg_hba.conf file: Unknown server error
>LOG: invalid entry in pg_hba.conf file at line 56, token "1727.0.0.1"
>FATAL: missing or erroneous pg_hba.conf file
>HINT: See server log for details.
>
>and after I fix the pg_hba.conf file it lets me in again. I see no crash.
>
> regards, tom lane
>
>
>
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: pkalva@deg.cc, tgl@sss.pgh.pa.us, pgsql-bugs@postgresql.org
Subject: Re: Postgres crashed on invalid IP entry in pg_hba.conf
In-Reply-To: <4213A9C7.2010404@deg.cc>
References: <1108578986.421392aad28bd@mail.deg.cc> <26829.1108584317@sss.pgh.pa.us> <4213A9C7.2010404@deg.cc>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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