Skip to Content
Odoo Meniu
  • Autentificare
  • Try it free
  • Aplicații
    Finanțe
    • Contabilitate
    • Facturare
    • Cheltuieli
    • Spreadsheet (BI)
    • Documente
    • Semn
    Vânzări
    • CRM
    • Vânzări
    • POS Shop
    • POS Restaurant
    • Abonamente
    • Închiriere
    Site-uri web
    • Constructor de site-uri
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Lanț Aprovizionare
    • Inventar
    • Producție
    • PLM
    • Achiziție
    • Maintenance
    • Calitate
    Resurse Umane
    • Angajați
    • Recrutare
    • Time Off
    • Evaluări
    • Referințe
    • Flotă
    Marketing
    • Social Marketing
    • Marketing prin email
    • SMS Marketing
    • Evenimente
    • Automatizare marketing
    • Sondaje
    Servicii
    • Proiect
    • Foi de pontaj
    • Servicii de teren
    • Centru de asistență
    • Planificare
    • Programări
    Productivitate
    • Discuss
    • Aprobări
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    Aplicații Terțe Odoo Studio Platforma Odoo Cloud
  • Industrii
    Retail
    • Book Store
    • Magazin de îmbrăcăminte
    • Magazin de Mobilă
    • Magazin alimentar
    • Magazin de materiale de construcții
    • Magazin de jucării
    Food & Hospitality
    • Bar and Pub
    • Restaurant
    • Fast Food
    • Guest House
    • Distribuitor de băuturi
    • Hotel
    Proprietate imobiliara
    • Real Estate Agency
    • Firmă de Arhitectură
    • Construcție
    • Estate Managament
    • Grădinărit
    • Asociația Proprietarilor de Proprietăți
    Consultanta
    • Firma de Contabilitate
    • Partener Odoo
    • Agenție de marketing
    • Law firm
    • Atragere de talente
    • Audit & Certification
    Producție
    • Textil
    • Metal
    • Mobilier
    • Mâncare
    • Brewery
    • Cadouri corporate
    Health & Fitness
    • Club Sportiv
    • Magazin de ochelari
    • Centru de Fitness
    • Wellness Practitioners
    • Farmacie
    • Salon de coafură
    Trades
    • Handyman
    • IT Hardware and Support
    • Asigurare socială de stat
    • Cizmar
    • Servicii de curățenie
    • HVAC Services
    Altele
    • Organizație nonprofit
    • Agenție de Mediu
    • Închiriere panouri publicitare
    • Fotografie
    • Închiriere biciclete
    • Asigurare socială
    Browse all Industries
  • Comunitate
    Învăță
    • Tutorials
    • Documentație
    • Certificări
    • Instruire
    • Blog
    • Podcast
    Empower Education
    • Program Educațional
    • Scale Up! Business Game
    • Visit Odoo
    Obține Software-ul
    • Descărcare
    • Compară Edițiile
    • Lansări
    Colaborați
    • Github
    • Forum
    • Evenimente
    • Translations
    • Devino Partener
    • Services for Partners
    • Înregistrează-ți Firma de Contabilitate
    Obține Servicii
    • Găsește un Partener
    • Găsiți un contabil
    • Meet an advisor
    • Servicii de Implementare
    • Referințe ale clienților
    • Suport
    • Actualizări
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Obține un demo
  • Prețuri
  • Ajutor

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Contabilitate
  • Inventar
  • PoS
  • Proiect
  • MRP
All apps
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
All Posts Oameni Insigne
Etichete (View all)
odoo accounting v14 pos v15
Despre acest forum
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
All Posts Oameni Insigne
Etichete (View all)
odoo accounting v14 pos v15
Despre acest forum
Suport

How do I use openERP with multiple domains on single server?

Abonare

Primiți o notificare când există activitate la acestă postare

Această întrebare a fost marcată
v7
9 Răspunsuri
40025 Vizualizări
Imagine profil
Boyd Lynn Gerber

I have over 40 domains and I would like to have a specific database associated with each domain. Do I have to have multiple installs? I know how to use a specific database. But I cannot seem to control. I have tried having apache2 listen to specific 8069 ports for the domains. But I always seem to have issues.

I use apache2 named services. I have in /etc/apache2/vhosts a file

name-vitrual-host.XXX.XXX.XXX.XX9.80.conf
name-vitrual-host-XXX.XXX.XXX.XX2.80.conf
name-vitrual-host-XXX.XXX.XXX.XX9.443.conf
name-vitrual-host-XXX.XXX.XXX.XX2.443.conf

with

name-vitrual-host-XXX.XXX.XXX.XX9.8069.conf
name-vitrual-host-XXX.XXX.XXX.XX2.8069.conf

or name-vitrual-host-XXX.XXX.XXX.XX9.8069.conf.org name-vitrual-host-XXX.XXX.XXX.XX2.8069.conf.org

I have apache2 setup to only read and use a .conf So I am doing it with and without I have also tried using in my /srv/apache2/listen.conf a global *:8069

The above file has a different location for each openerp config in a domain. I have linked the source code from /usr/share/openerp to each domain.

cd /srv/www/vhosts/domain_name/
ln -s /usr/share/openerp openerp
cd /srv/www/vhosts/domain_name/
ln -s /usr/share/openerp openerp
...
cd /srv/www/vhosts/domain_name#/
ln -s /usr/share/openerp openerp

I have in each index.html or apporiate html file

Note each below have a http: in front //www.sample.com:8069/?db=openerp //www.sample1.com:8069/?db=openerp1 //www.sample2.com:8069/?db=openerp2 //www.sample3.com:8069/?db=openerp3

It is getting the openerp working. Seems openERP wants to bind to the IP:Port and not the domainname:Port

Been trying to get customized config files working. What I do for other programs is for example put the source in /usr/share/openerp with links in all the virtual hosts as shown above.

Each .conf file has the following in them [options] addons_path = /usr/share/openerp/addons or /srv/www/vhosts/domain_name/addons

then a specific db db_name=openerp db_name=openerp1 db_name=openerp2 db_name=openerp3

all have the same db_user = openerp

My problem is I get post already in use. I do the following:

/location_domain/openerp/openerp-server -c /location_domain/openerp.cfg &

Then on the next add using the -c with a different cfg and location I get the already in use. I have different names in the config file but they are using the same IP. Making use of the apache2 named configurations. So if the system uses the name it should work, but if using IP it will fail

Any known way to do this?

14
Imagine profil
Abandonează
Imagine profil
Olivier Dony (odo)
Cel mai bun răspuns

You can perfectly well serve all the databases with a single OpenERP server on your machine. Unfortunately you did not mention what error you were seeing and what you expected as a result - makes it a bit harder to help you ;-)

Anyway, here are some random ideas based on the information you provided:

  • If you have a problem with OpenERP not listening on all interfaces, try to specify 0.0.0.0 as the xmlrpc_interface in the configuration file, this should have OpenERP listen on 8069 on all IPs.
  • Note that Apache is not relevant if you're connecting to e.g. http://www.sample.com:8069/?db=openerp because you're directly connecting to OpenERP. If you want to go through Apache, you need to setup ReverseProxy rules in your vhost configs, and OpenERP does not need to listen to all public IPs then.
  • OpenERP 6.1 and later can autodetect the database name based on the virtual host name, and filter the name of the available databases: you need to start it with the --db-filter parameter, which represents a pattern used to filter the list of available databases. %h represents the domain name and %d is the first domain component of that domain. So for example with --db-filter=^%d$ I will only see the test database if I end up on the server using http://test.example.com:8069. If there's only one database match, the list is not displayed and the user will directly end up on the right database. This works even behind Apache reverse proxies if you make sure that OpenERP see the external hostname, i.e. by setting a X-Forwarded-Host header in your Apache proxy config and enabling the --proxy mode of OpenERP.

Update: The port reuse problem comes because you are trying to start multiple OpenERP servers on the same interface/port combination. This is simply not possible unless you are careful to start just one server per IP with the IP set in the xmlrpc_interface parameter, and I don't think you need that. The named-based virtual hosts that Apache supports are all handled by a single master process that listens on port 80 on all the interfaces. If you want to do the same with OpenERP you only need to start one OpenERP server for all your domains, and make it listen on 0.0.0.0, port 8069, as I explained above.
On top of that it's not clear what you would have set differently in the various config files. Running 40 different OpenERP servers on the same machine with identical code sounds like a lot of overkill. OpenERP is designed to be multi-tenant so that many (read: hundreds) of databases can be served from the same server.

12
Imagine profil
Abandonează
Boyd Lynn Gerber
Autor

My problem is I get post already in use. I do the following. /location_domain/openerp/openerp-server -c /location_domain/openerp.cfg &

Boyd Lynn Gerber
Autor

Then on the next add using the -c with a different cfg and location I get the already in use. I have different names in the config file but they are using the same IP. Making use of the apache2 named configurations. So if the system uses the name it should work, but if using IP it will fail as i

Olivier Dony (odo)

Thanks for the extra info, I updated my answer

Luis Leiva

Important note on using --db-filter=^%d$ Database names ARE case sensitive while URL is NOT case sensitive, so if you have uppercases on database names the --db-filter=^%d$ will not work as URL converts everything to lower cases. Conclusion: use only lowercases in database names to use this.

bino oetomo

Hi Oliver and All

I create 2 db : db1 and db2

I also have hostname setup on my dns server ; db1.erp.bno db2.erp.bno

and in my /etc/openerp/openerp-server.conf , I put :

  1. list_db = False To disable the DB choice list, and
  2. db_filter=^%d$ In hope that web UI will select the db in regards of hostname (first part of FQDN)

But both didn't work 1. when I try to open http://db2.erp.bno:8069 , web UI forwardme to http://db2.erp.bno:8069/?db=db1 2. the DB choice list still there.

My installation is in ubuntu using apt-get

Kindly please give me your enlighten

Sincerely -bino-

Michael Karrer

Same for me db_filter seems to be not working on OpenERP Version 7

Michael Karrer

db-filter is working if i use it as a startup command for the server BUT is not working if i use it in the server config file ?!?

FRACHT FWO CZECH

Olivier, thanks for the explanation. I believe that the --proxy setting is in fact called --proxy-mode? I see a problem with the --db-filter setting: we have to make database names always be exactly the same like subdomains - this might be for whatever reason not always possible and it would be much better to have some way of mapping subdomains to arbitrary db names, this could be achieved e.g. with an Apache environment variable. Is there any possibility of creating such a mapping (without patching the OE7 code?). Also it would be great to have this kind of configuration available via web.

FRACHT FWO CZECH

Yes, we could add a mod_rewrite rule to add / replace the query string on every request, but I do not know if this will work with every request that OE7 generates... so fixing this in config file would be the best way.

FRACHT FWO CZECH

Another problem with this approach: if %h is the domain name, like e.g. http://example.com - this can not be a PostgreSQL database name, as the dot is an illegal character. So it is not possible to use a dbfilter like e.g. %h_%d because it would result in example.com_subdomain - you can not add such a database via the database creation dialog.

www postgresql org / docs / current / interactive / sql-syntax-lexical.html#SQL-SYNTAX-IDENTIFIERS (can not post links)

Imagine profil
Abner Galeno Jr.
Cel mai bun răspuns

I have no idea yet how XML-RPC works, but it might be the answer you are looking for.

References:

https://accounts.openerp.com/forum/Help-1/question/336/ https://accounts.openerp.com/forum/Help-1/question/915/ https://accounts.openerp.com/forum/Help-1/question/429/ I would say doing multiple installs would be one hell of a installation+maintenance job.

2
Imagine profil
Abandonează
Imagine profil
test
Cel mai bun răspuns

Configure

I have try this and its working well.

http://tinyurl.com/oe-multi-domain-easy-config

This one of easy to setup.

0
Imagine profil
Abandonează
Patrice Gaillard

This one sounds great. How did you apply this patch ? I don't get it...

Imagine profil
Lucio
Cel mai bun răspuns

I think you can do the trick by launching different servers using the -c option when launching them.

With that option you can specify which configuration your server will use, in particular, which port to 'hear'.

For example, I am not sure but I think the default values in server.conf will be:

netrpc_port = 8070
...
smtp_port = 25
...
xmlrpc_port = 8069
...
xmlrpcs_port = 8071

By changing those you could specify which ports you want to use in every server process.

Hope it helps you!

-1
Imagine profil
Abandonează
Boyd Lynn Gerber
Autor

Thanks, I should have been more explicit about what I have tried. Each doman has a config file with its database. My Problem is because I am using named services. I had over 750 public IP's but when my local phone company added Fiber their old DSL stopped working reliably. So Now I have to pay.

Boyd Lynn Gerber
Autor

Problem is I now only have 5 public IP addresses. I am able to come in to any domain and not have a problem. Seem openERP does not like to share IP addresses and wants to bind to the IP rather than the name. Thanks

Imagine profil
Luis Leiva
Cel mai bun răspuns

Have you tried by redirecting subdomains to this: http://server:8069/?db=database

Almost works. For some thing I don't understand it seems to not recognize the database when redirected, but if you refresh the page with that URL the it does works fine.

Try it and tell me how it goes.

-1
Imagine profil
Abandonează
Boyd Lynn Gerber
Autor

That is what I am doing. http://www.sample.com:8069/?db=openerp and so one for each domain and its database. The apache part is working. But the openERP with each having their own conig is not.

Imagine profil
Supreeth KV
Cel mai bun răspuns

hello can you please provide me all step of installing multiple instances of openerp

-1
Imagine profil
Abandonează
Supreeth KV

Please read bugs . launchpad . net /openobject-server/+bug/1195341

Imagine profil
sepdau
Cel mai bun răspuns

Why don't use specific_url_db option. It must be easiest way to do this job.

specific_url_db=abc.com:sr4,cde.com:sr2

Use add this option in openerp-server config file

-1
Imagine profil
Abandonează
Felipe

I tried this in v8 with no result. specific_url_db=database1.mydomain.com.co:DatabaseName1,database2.mydomain.com.co:DatabaseName2

Imagine profil
Boyd Lynn Gerber
Autor Cel mai bun răspuns

Sovled by using *:8069 in /etc/apache2/listen.conf Then adding to each domain where desire

www.sample.com:8069/?db=openerp having a unique db for each domain.

Having a goood generic config and uses and using it with the -c config.cfg file.

-1
Imagine profil
Abandonează
Olivier Dony (odo)

This makes no sense, why force Apache to listen to port 8069? If you're making Apache proxy requests to OpenERP, why don't you do it on the normal port (80/443)? Then just direct your customers to their own URL. So far it looks like you're just testing random things without trying to understand :-/

Imagine profil
Prosper G. Nitcheu
Cel mai bun răspuns

Have you tried apache "VirtualHost" configuration ?

-1
Imagine profil
Abandonează
Boyd Lynn Gerber
Autor

Yes, I have that part working for the domains . It is getting the openerp working. Been trying to get customized config files working. What I do for other programs is put the source in /usr/share/openerp with links in all the virtual hosts. name-vitrual-host-168.103.176.49.8069.conf domains

Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Înscrie-te
Related Posts Răspunsuri Vizualizări Activitate
How to add a "Delete" button on the popup form? Rezolvat
v7
Imagine profil
Imagine profil
1
oct. 25
5860
Minimum Lot Charge For Sales Order Line Items
v7
Imagine profil
0
dec. 24
10636
Record Rule to allow a User to update their own Employee object without belonging to Officer group Rezolvat
v7
Imagine profil
Imagine profil
Imagine profil
Imagine profil
3
sept. 24
23177
How to activate the Technical Features? Rezolvat
v7
Imagine profil
Imagine profil
Imagine profil
Imagine profil
Imagine profil
5
dec. 24
55451
Way to only allow a specific DB to be the default? Rezolvat
v7
Imagine profil
Imagine profil
Imagine profil
Imagine profil
Imagine profil
4
iul. 24
11992
Comunitate
  • Tutorials
  • Documentație
  • Forum
Open Source
  • Descărcare
  • Github
  • Runbot
  • Translations
Servicii
  • Hosting Odoo.sh
  • Suport
  • Actualizare
  • Custom Developments
  • Educație
  • Găsiți un contabil
  • Găsește un Partener
  • Devino Partener
Despre Noi
  • Compania noastră
  • Active de marcă
  • Contactați-ne
  • Locuri de muncă
  • Evenimente
  • Podcast
  • Blog
  • Clienți
  • Aspecte juridice • Confidențialitate
  • Securitate
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo este o suită de aplicații de afaceri open source care acoperă toate nevoile companiei dvs.: CRM, comerț electronic, contabilitate, inventar, punct de vânzare, management de proiect etc.

Propunerea de valoare unică a Odoo este să fie în același timp foarte ușor de utilizat și complet integrat.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now