Issue Running Tryton After Migrating from VPS to Local Machine

Hello everyone,

I recently migrated my Tryton installation from a VPS to my local machine and restored a database backup (database.sql) from the VPS to my local PostgreSQL database. However, when I try to run Tryton with:

trytond -c trytond.conf

I encounter the following errors:

python

CopyEdit

/home/name/.virtualenvs/envs/bin/trytond:4: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
  __import__('pkg_resources').require('trytond==6.0.51')
['ERROR_CORRECT_H', 'ERROR_CORRECT_L', 'ERROR_CORRECT_M', 'ERROR_CORRECT_Q', 'LUT', 'QRCode', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__path__', '__spec__', 'base', 'compat', 'constants', 'exceptions', 'image', 'main', 'make', 'run_example', 'util']
['BarcodeNotFoundError', 'BinaryIO', 'CODABAR', 'Code128', 'Code39', 'Dict', 'EAN13', 'EAN13_GUARD', 'EAN14', 'EAN8', 'EAN8_GUARD', 'Gs1_128', 'ISBN10', 'ISBN13', 'ISSN', 'ITF', 'JAN', 'Optional', 'PROVIDED_BARCODES', 'PZN', 'UPCA', 'Union', '__BARCODE_MAP', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__path__', '__spec__', 'base', 'charsets', 'codabar', 'codex', 'ean', 'errors', 'generate', 'get', 'get_barcode', 'get_barcode_class', 'get_class', 'isxn', 'itf', 'os', 'upc', 'version', 'writer']
Cannot assign requested address

What I Have Done So Far:

  1. Restored the database from the VPS backup using:

bash

CopyEdit

psql -U udatabase -h localhost -d database -f database.sql
  1. Checked PostgreSQL connection and ensured the database exists.
  2. Verified trytond.conf configuration, ensuring the correct database URI:

ini

CopyEdit

[database]
uri = postgresql://database:password@127.0.0.1:5432/database
  1. Tried changing the [web] listen address to 0.0.0.0:8002 and different ports, but the issue persists.
  2. Ensured required Python packages are installed, including python-barcode and pillow.

Questions:

  1. What could be causing the “Cannot assign requested address” error?
  2. Is there anything I might have missed when migrating the Tryton setup from VPS to local?
  3. Could this be related to some misconfiguration in trytond.conf or an issue with dependencies?

Any insights would be greatly appreciated! Thanks in advance.

How did you run the tryton server on your VPS? And how do you run it locally? Using containers or virtual environments?

This means that trytond can not open the configured address to listen to.
You should try first with 127.0.0.1 (or ::1 if you do not have IPv4).

Ah, yes i forgot to change the IP Address

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.