[pgsql-jp: 28566] Re: phpimageに接続できない
Norio Kikuta
kikuta.norio @ nifty.ne.jp
2003年 1月 7日 (火) 18:56:23 JST
石井さん、加藤さん、まいぱぱさん、井上さん、大場さん
ありがとうございます。
以下のようになっております。
> 閉じたマシンの中でちゃんと接続できる設定なのか?
データベースのあるPCでphpimageに接続できます。
> 使用できる人がちゃんと登録されているのか?
Ownerはpostgresですが、nobodyに設定してありますので、kikutaで
接続できます。
psql -l
List of databases
Name | Owner | Encoding
-----------+----------+----------
phpimage | postgres | EUC_JP
template0 | postgres | EUC_JP
template1 | postgres | EUC_JP
tes1db | kikuta | EUC_JP
tesdb | kikuta | EUC_JP
(5 rows)
> そのデータベースが使える権利があるのが誰なのか?
nobodyに設定してあります。
> 誰の権限で繋ぎに行ってるのか?
kikuta の権限でphpimageに繋いでいます。
接続した状況は下のようになっています。
> psql phpimage
Welcome to psql, the PostgreSQL interactive terminal.
Type: \copyright for distribution terms
\h for help with SQL commands
\? for help on internal slash commands
\g or terminate with semicolon to execute query
\q to quit
phpimage=# \d
List of relations
Name | Type | Owner
---------------------+----------+----------
groups | table | postgres
groups_group_id_seq | sequence | postgres
images | table | postgres
(3 rows)
石井さんのメールにあった
$conn = $connect_function($connstr);
を付け加えましたが、エラーメッセージはでませんでした。
pg_hba.confの設定は下記のようになっています。
# TYPE DATABASE IP_ADDRESS MASK AUTH_TYPE AUTH_ARGUMENT
local all trust
host all 127.0.0.1 255.255.255.255 trust
host all 192.168.x.xx 255.255.255.255 trust
接続は192.168.x.xxから行っています。
なお、PostgreSQLのあるマシンからもブラウザ経由では表示できません。
よろしくお願いします。
pgsql-jp メーリングリストの案内