gnumed-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-devel] bootstrap error on Mandriva 2010


From: Sebastian Hilbert
Subject: Re: [Gnumed-devel] bootstrap error on Mandriva 2010
Date: Sun, 7 Mar 2010 10:23:40 +0100
User-agent: KMail/1.13.1 (Linux/2.6.31.12-0.1-default; KDE/4.4.1; i686; ; )

Am Samstag 06 März 2010 20:06:15 schrieb Michael Schütt:
> I dont know, where is the problem.
>
I am not quite sure what you are trying to do ?
Are you trying to boostrap a local database ?
 
> address@hidden bootstrap]# passwd postgres
> ändere Passwort für Benutzer postgres.
> Geben Sie ein neues Passwort ein:
> Geben Sie das neue Passwort erneut ein:
> Schlechtes Passwort: it is too short
> passwd: alle Authentifizierungsmerkmale erfolgreich aktualisiert.

Here you have set a password. It seemed to work.

> address@hidden bootstrap]# su - postgres
> address@hidden ~]$ psql template1
> psql (8.4.2)
> Type "help" for help.
> 
> template1=# create user web_user;
> CREATE ROLE
> template1=# create database web_database owner web_user;
> CREATE DATABASE
> template1=# \q

you created a new user. Do you want that user to log in to the future database 
?

have a look at the output of

'\l'

> address@hidden ~]$ exit
> logout
> address@hidden bootstrap]# service postgresql restart
> Stopping postgresql service:
> 
>                         [  OK  ]
> Starting postgresql service:
> 
>                         [  OK  ]
> address@hidden bootstrap]# psql -U web_user web_database
> psql (8.4.2)
> Geben Sie »help« für Hilfe ein.
> 
> web_database=> \q

It looks like postgres is running and you are able to log into the database 
you created with the user you created.

> address@hidden bootstrap]# ./bootstrap-latest.sh
> ===========================================================
> Bootstrapping latest GNUmed database.
> 
> ==> bootstrapping "config" ...
> ==> cloning [template1] (5280 kB) as target database [gnumed_v2] ...
> Cannot bootstrap bundles.
> 
> Please check the log file for details:
> 
>   /usr/lib/gnumed-server/server/bootstrap/bootstrap-latest.log
> 
> Bootstrapping "gnumed_v12" did not finish successfully. Aborting.
> 
> 
> bootstrap-latest.log:
> 
> 2010-03-06 19:58:03  ERROR     gm.bootstrapper
> (./bootstrap_gm_db_system.py::__create_db() #781): >>>[
>                                 create database "gnumed_v2" with
>                                         owner = "gm-dbo"
>                                         template = "template1"
>                                         encoding = 'unicode'
>                                 ;]<<< failed
> Traceback (most recent call last):
>   File "./bootstrap_gm_db_system.py", line 779, in __create_db
>     cursor.execute(cmd)
>   File "/usr/lib/python2.6/site-packages/psycopg2/extras.py", line 110,
> in execute
>     return _cursor.execute(self, query, vars, async)
> DataError: new encoding (UTF8) is incompatible with the encoding of the
> template database (SQL_ASCII)
> TIP:  Use the same encoding as in the template database, or use
> template0 as template.

Here it tells you what the problem is. Mandriva creates the postgresql cluster 
in SQL_ASCII (Debian, Ubuntu, openSUSE now create the default cluster in 
Unicode).

Therefore the bootstrap procedure fails. 

As outlined by Karsten recently :
- re-initdb the cluster using a contemporary encoding (that means Unicode)
- use your own cluster
- modify the bootstrapper to accept SQL_ASCII

I would go for manually creating a Unicode cluster which will make your 
problem go away. For users which have databases in the SQL_ASCII cluster this 
option is not feasible. They need to choose from the other options.

Postgresql 8.5 will allow to specify the ecoding per database and will make 
that problem go away i believe.

Sebastian




reply via email to

[Prev in Thread] Current Thread [Next in Thread]