postgresql-9.1 0:off 1:off 2:off 3:off 4:off 5:off 6:off
postgresql-9.1 0:off 1:off 2:on 3:on 4:on 5:on 6:off
-bash-4.1$ psql -l
データベース一覧
名前 | 所有者 | エンコーディング | 照合順序 | Ctype(変換演算子) | アクセス権
-----------+----------+------------------+-------------+-------------------+-----------------------
postgres | postgres | UTF8 | ja_JP.UTF-8 | ja_JP.UTF-8 |
template0 | postgres | UTF8 | ja_JP.UTF-8 | ja_JP.UTF-8 | =c/postgres +
| | | | | postgres=CTc/postgres
template1 | postgres | UTF8 | ja_JP.UTF-8 | ja_JP.UTF-8 | =c/postgres +
| | | | | postgres=CTc/postgres
(3 行)
$ createuser ymko
新しいロールをスーパーユーザにしますか? (y/n)n
新しいロールに対してデータベースを作成する権限を与えますか? (y/n)y
新しいロールに対して別のロールを作成する権限を与えますか? (y/n)n
$ createdb testdb
$ psql -l | grep test
testdb | ymko | UTF8 | ja_JP.UTF-8 | ja_JP.UTF-8 |
- 続いてDBD::Pg入れる(pg_configにパスが通ってないとエラー)
$ echo "PATH=$PATH:/usr/pgsql-9.1/bin" >> ~/.bashrc
$ source ~/.bashrc
$ cpanm DBD::Pg