[CentOS] Strange behaviour when using sudo+sh+executable.

Wed Sep 7 00:25:55 UTC 2016
Steven Tardy <sjt5atra at gmail.com>

> On Sep 6, 2016, at 6:18 AM, Rafał Radecki <radecki.rafal at gmail.com> wrote:
> 
> # sudo  -H -E -u postgres /bin/bash -c /usr/bin/python2.7


Works for me. *shrug*

Is your postgres user a service account or something else strange about it?
Does 'passwd --status postgres' hint at anything?