Cache user and group names

I checked strace and it was reading /etc/passwd every time it needed to
look up a user or group. Now it only does it once per.