← Back to team overview

openerp-india team mailing list archive

[Bug 331065] Re: "could not create database" on a new installation of ubuntu and postgresql 8.3

 

Or you can simple do the same thing as follows:

/etc/init.d/postgresql-8.3 stop
pg_dropcluster --stop 8.3 main
pg_createcluster --locale en_US.UTF-8 --start 8.3 main
/etc/init.d/postgresql-8.3 start

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/331065

Title:
  "could not create database" on a new installation of ubuntu and
  postgresql 8.3

Status in OpenERP Server:
  Invalid
Status in “openerp-server” package in Ubuntu:
  Confirmed

Bug description:
  After installing and executing openerp-server-5.0.0-3 over ubuntu 8.04
  (I used this image http://isv-
  image.ubuntu.com/vmware/Ubuntu-7.10-desktop-i386.zip and upgraded to
  8.04) with postgresql 8.3, I get the following while creating a new
  database:

  [2009-02-18 16:17:47,507] INFO:dbpool:Connecting to template1
  [2009-02-18 16:17:47,517] DEBUG:sql:bad query: CREATE DATABASE "dev" ENCODING 'unicode'
  [2009-02-18 16:17:47,517] DEBUG:sql:[01]: encoding UTF8 does not match server's locale en_US
  [2009-02-18 16:17:47,518] DEBUG:sql:[02]: DETAIL:  The server's LC_CTYPE setting requires encoding LATIN1.
  [2009-02-18 16:17:47,518] INFO:dbpool:Closing all connections to template1
  Closing connection <connection object at 0x883c818; dsn: 'user=root  dbname=template1', closed: 0>

  I tried to set all locales to en_US.UTF-8 (my ubuntu's default was
  just en_US):

  ubuntu@ubuntu:~$ locale
  LANG=en_US.UTF-8
  LC_CTYPE="en_US.UTF-8"
  LC_NUMERIC="en_US.UTF-8"
  LC_TIME="en_US.UTF-8"
  LC_COLLATE="en_US.UTF-8"
  LC_MONETARY="en_US.UTF-8"
  LC_MESSAGES="en_US.UTF-8"
  LC_PAPER="en_US.UTF-8"
  LC_NAME="en_US.UTF-8"
  LC_ADDRESS="en_US.UTF-8"
  LC_TELEPHONE="en_US.UTF-8"
  LC_MEASUREMENT="en_US.UTF-8"
  LC_IDENTIFICATION="en_US.UTF-8"
  LC_ALL=

  
  After that, I reinstalled postgresql, but it did not work.

  I even did a "initdb" for postgresql:

  # sudo -u postgres /usr/lib/postgresql/8.3/bin/initdb -D /var/lib/postgresql/8.3/main
  The files belonging to this database system will be owned by user "postgres".
  This user must also own the server process.

  The database cluster will be initialized with locale en_US.UTF-8.
  The default database encoding has accordingly been set to UTF8.
  The default text search configuration will be set to "english".

  fixing permissions on existing directory /var/lib/postgresql/8.3/main ... ok
  creating subdirectories ... ok
  selecting default max_connections ... 100
  selecting default shared_buffers/max_fsm_pages ... 24MB/153600
  creating configuration files ... ok
  creating template1 database in /var/lib/postgresql/8.3/main/base/1 ... ok
  initializing pg_authid ... ok
  initializing dependencies ... ok
  creating system views ... ok
  loading system objects' descriptions ... ok
  creating conversions ... ok
  creating dictionaries ... ok
  setting privileges on built-in objects ... ok
  creating information schema ... ok
  vacuuming database template1 ... ok
  copying template1 to template0 ... ok
  copying template1 to postgres ... ok

  WARNING: enabling "trust" authentication for local connections
  You can change this by editing pg_hba.conf or using the -A option the
  next time you run initdb.

  Success. You can now start the database server using:

      /usr/lib/postgresql/8.3/bin/postgres -D /var/lib/postgresql/8.3/main
  or
      /usr/lib/postgresql/8.3/bin/pg_ctl -D /var/lib/postgresql/8.3/main -l logfile start

  but result remains the same

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/331065/+subscriptions