사용자 도구

사이트 도구


dbms:pgsql:clientenv

문서의 이전 판입니다!


PostgreSQL 환경설정

The Password File(~/.pgpass)

  1. The file ‘.pgpass’ in a user's home directory or the file referenced by PGPASSFILE can contain passwords to be used if the connection requires a password (and no password has been specified otherwise).
  2. On Microsoft Windows the file is named ‘%APPDATA%\postgresql\pgpass.conf’ (where ‘%APPDATA%’ refers to the Application Data subdirectory in the user's profile).
  3. This file should contain lines of the following format:
    hostname:port:database:username:password
  4. Each of the first four fields may be a literal value, or *, which matches anything.
  5. The password field from the first line that matches the current connection parameters will be used.
    (Therefore, put more-specific entries first when you are using wildcards.)
  6. If an entry needs to contain : or \, escape this character with \. A host name of localhost matches both TCP (hostname localhost) and Unix domain socket (pghost empty or the default socket directory) connections coming from the local machine.
  7. The permissions on ‘.pgpass’ must disallow any access to world or group;
    achieve this by the command chmod 0600 ~/.pgpass.
  8. If the permissions are less strict than this, the file will be ignored.
    (The file permissions are not currently checked on Microsoft Windows, however.)
dbms/pgsql/clientenv.1202443711.txt.gz · 마지막으로 수정됨: 2008/02/08 13:08 저자 starlits