Liebe alle

Da ich gerade sehr kämpfen musste, bis die (veraltete) Version 3.2 des 
Trytonservers gelaufen ist (die in diesem Fall wegen bestimmter 
Zusatzmodule benötigt wurde, die nur damit kompatibel sind), schreibe ich 
hier die Installationsschritte im Detail auf.

Eins vorab: Mir scheint, die Anleitung, die in der Distribution 
mitgeliefert wird (at/usr/share/doc/tryton-server/README.Debian) hat in 
einem Punkt einen Fehler, und an einem anderen ist sie mindestens 
unvollständig.

Der Fehler: In der Readme wird behauptet, dass man den db_host - Eintrag 
nur setzen müsse, wenn man den Postgre-Server auf einem anderen Rechner 
betreibt.
Dem ist nicht so. Wenn man den Eintrag 

db_host = localhost

*nicht* macht, bekommt man später, wenn man die neu erstellte Datenbank 
initialisieren will mit 

/usr/bin/trytond -i all -d tryton" 

 den Fehler 

psycopg2.OperationalError: FATAL:  Peer authentication failed for user 
"tryton"

Sobald der localhost in trytond.conf gesetzt ist, verschwindet der Fehler. 
Portangabe ist nicht nötig (solange man Postgre eben auf derselben Maschine 
hat, wie von der Distribution installiert).

Der unvollständige Punkt:
In der Readme heisst es weiter, man könne den Port in der conf-Datei setzen 
mit

jsonrpc = 0.0.0.0:8000,*:8000 

um ihn sowohl für IPv4 als auch für IPv6 freizugeben.

Mindestens bei der Installation auf Ubuntu-1404-trusty-64-minimal ist es 
aber so, dass das nicht mit dem Windows-Client funktioniert ("Can't connect 
to server").
Setzt man stattdessen den einfacheren Eintrag:

jsonrpc = *:8000

 
Dann läuft es sofort, oh Wunder! :-)

In der Hoffnung, jemandem damit zu helfen, poste ich hier die 
Installationsbefehle im Einzelnen + die vollständige trytond.conf.
Nicht vergessen, den passenden Client für die Serverversion (muss mit 3.2 
anfangen in diesem Fall) zu installieren.
Und falls Ihr Tryton auf einer VM bei Windows Azure laufen habt: Ihr müsst 
auf der Azure-Oberfläche separat nochmal den Endpunkt für Port 8000 
definieren.

Liebe Grüsse
Wolfgang

Installationsbefehle (von Login mit root aus, sonst mit sudo):


   apt-get update
   
   apt-get install software-properties-common
   
   add-apt-repository ppa:rayanayar/tryton-3.2
   
   sudo apt-get update
   
   apt-get install tryton-server tryton-modules-all
   
   /etc/init.d/postgresql* restart
   
   su - postgres -c "createuser --createdb --no-createrole --no-superuser 
   --pwprompt tryton"
   
   nano /etc/trytond.conf
   chown tryton:tryton /etc/trytond.conf -R
   /etc/init.d/tryton-server restart
   su - postgres -c "createdb --encoding=UNICODE --owner=tryton tryton"
   /usr/bin/trytond -i all -d tryton
   
     Natürlich eigene Passworte und Datenbanknamen verwenden.

Und hier noch die vollständige trytond.conf (dran denken, dass sie bei 
Version 3.6 ins Verzeichnis "/etc/tryton/" gehört, hier bei 3.2. aber 
direkt in "/etc/"! ;-)

#This file is part of Tryton.  The COPYRIGHT file at the top level of
 #this repository contains the full copyright notices and license terms.
 [options]
 
 # Activate the json-rpc protocol
 jsonrpc = *:8000
 #ssl_jsonrpc = False
 
 # This is the hostname used when generating tryton URI
 #hostname_jsonrpc =
 
 # Configure the path of json-rpc data
 #jsondata_path = /var/www/localhost/tryton
 
 # Activate the xml-rpc protocol
 #xmlrpc = *:8069
 #ssl_xmlrpc = False
 
 # Activate the webdav protocol
 #webdav = *:8080
 #ssl_webdav = False
 
 # This is the hostname used when generating WebDAV URI
 #hostname_webdav =
 
 # Configure the database type
 # allowed values are postgresql, sqlite, mysql
 db_type = postgresql
 
 # Configure the database connection
 ## Note: Only databases owned by db_user will be displayed in the 
connection dialog
 ## of the Tryton client. db_user must have create permission for new 
databases
 ## to be able to use automatic database creation with the Tryton client.
 db_host = localhost
 #db_port = False
 db_user = tryton
 db_password = tryton
 #db_minconn = 1
 #db_maxconn = 64
 
 # Configure the postgresql path for the executable
 #pg_path = None
 
 # Configure the Tryton server password
 admin_passwd = admin
 
 # Configure the path of the files for the pid and the logs
 #pidfile = False
 #logfile = False
 
 privatekey = /etc/ssl/private/ssl-cert-snakeoil.key
 certificate = /etc/ssl/certs/ssl-cert-snakeoil.pem
 
 # Configure the SMTP connection
 #smtp_server = localhost
 #smtp_port = 25
 #smtp_ssl = False
 #smtp_tls = False
 #smtp_password = False
 #smtp_user = False
 #smtp_default_from_email = False
 
 # Configure the path to store attachments and sqlite database
 data_path = /var/lib/tryton
 
 # Allow to run more than one instance of trytond
 #multi_server = False
 
 # Configure the session timeout (inactivity of the client in sec)
 #session_timeout = 600
 
 # Enable auto-reload of modules if changed
 #auto_reload = True
 
 # Prevent database listing
 prevent_dblist = False
 
 # Enable cron
 # cron = True
 
 # unoconv connection
 #unoconv = pipe,name=trytond;urp;StarOffice.ComponentContext
 
 # Number of retries on database operational error
 # retry = 5
 
 # Default language code
 language = en_US


 

 

-- 
Sie erhalten diese Nachricht, weil Sie Mitglied der Google Groups-Gruppe 
"tryton-de" sind.
Weitere Optionen: https://groups.google.com/d/optout

Antwort per Email an