Hi Lim,
>> It might also be in /etc/security/limits.conf.
>
> Thanks. I see these two lines in that file:
>
> postgres soft nofile 8192
> postgres hard nofile 8192
>
> How should I change these values? I am not sure how this reflects the
> "ulimit" options.
Those are limits to the allowed number of open files (ulimit -n). I think
8192 should be enough for PostgreSQL. The problem you had were related to
other settings, so if only the "nofile" setting is changed your strange
ulimits do not come from here :-)
- Sander