Bỏ qua để đến Nội dung
Odoo Menu
  • Đăng nhập
  • Dùng thử miễn phí
  • Ứng dụng
    Tài chính
    • Kế toán
    • Hóa đơn
    • Chi phí
    • Bảng tính (BI)
    • Tài liệu
    • Ký tên
    Bán hàng
    • CRM
    • Bán hàng
    • POS Cửa hàng
    • POS Nhà hàng
    • Đăng ký
    • Cho thuê
    Trang web
    • Trình tạo trang web
    • Thương mại điện tử
    • Blog
    • Diễn đàn
    • Trò chuyện trực tiếp
    • Học trực tuyến
    Chuỗi cung ứng
    • Tồn kho
    • Sản xuất
    • PLM
    • Mua hàng
    • Bảo dưỡng
    • Chất lượng
    Nhân sự
    • Nhân viên
    • Tuyển dụng
    • Ngày nghỉ
    • Đánh giá
    • Giới thiệu
    • Đội xe
    Marketing
    • Marketing trên MXH
    • Marketing qua email
    • Marketing qua SMS
    • Sự kiện
    • Tự động hóa Marketing
    • Khảo sát
    Dịch vụ
    • Dự án
    • Bảng chấm công
    • Dịch vụ hiện trường
    • Hỗ trợ
    • Kế hoạch
    • Lịch hẹn
    Năng suất
    • Thảo luận
    • Phê duyệt
    • IoT
    • VoIP
    • Kiến thức
    • WhatsApp
    Ứng dụng của bên thứ ba Studio Odoo Nền tảng Đám mây Odoo
  • Ngành
    Bán lẻ
    • Nhà sách
    • Cửa hàng quần áo
    • Cửa hàng nội thất
    • Cửa hàng tạp hóa
    • Cửa hàng đồ kim khí
    • Cửa hàng đồ chơi
    Ẩm thực & Dịch vụ lưu trú
    • Bar và quán rượu
    • Nhà hàng
    • Đồ ăn nhanh
    • Guest house
    • Nhà phân phối đồ uống
    • Khách sạn
    Bất động sản
    • Công ty môi giới bất động sản
    • Công ty kiến trúc
    • Xây dựng
    • Quản lý bất động sản
    • Làm vườn
    • Hiệp hội chủ sở hữu bất động sản
    Tư vấn
    • Công ty kế toán
    • Đối tác Odoo
    • Công ty marketing
    • Công ty luật
    • Tuyển dụng
    • Thanh tra & chứng nhận
    Sản xuất
    • Dệt may
    • Kim loại
    • Nội thất
    • Ẩm thực
    • Nhà máy bia
    • Quà tặng doanh nghiệp
    Sức khoẻ & fitness
    • CLB thể thao
    • Cửa hàng kính mắt
    • Trung tâm fitness
    • Chuyên gia chăm sóc sức khỏe
    • Hiệu thuốc
    • Tiệm làm tóc
    Thương mại
    • Dịch vụ sửa chữa
    • Phần cứng CNTT & Hỗ trợ
    • Hệ thống năng lượng mặt trời
    • Công ty sản xuất giày
    • Dịch vụ vệ sinh
    • Dịch vụ HVAC
    Khác
    • Tổ chức phi lợi nhuận
    • Cơ quan môi trường
    • Cho thuê biển quảng cáo
    • Nhiếp ảnh
    • Cho thuê xe đạp
    • Đại lý phần mềm
    Xem tất cả ngành
  • Cộng đồng
    Học tập
    • Khóa học
    • Tài liệu
    • Chứng chỉ
    • Đào tạo
    • Blog
    • Podcast
    Thúc đẩy đào tạo
    • Chương trình đào tạo
    • Trò chơi kinh doanh Scale Up!
    • Tham quan Odoo
    Nhận phần mềm
    • Tải xuống
    • So sánh các phiên bản
    • Phiên bản
    Hợp tác
    • Github
    • Diễn đàn
    • Sự kiện
    • Dịch thuật
    • Trở thành đối tác
    • Dịch vụ dành cho Đối tác
    • Đăng ký công ty kế toán của bạn
    Nhận dịch vụ
    • Tìm đối tác
    • Tìm kế toán
    • Gặp chuyên gia hỗ trợ
    • Dịch vụ Triển khai
    • Khách hàng tham khảo
    • Hỗ trợ
    • Nâng cấp
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Nhận một buổi demo
  • Bảng giá
  • Trợ giúp

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

  • CRM
  • e-Commerce
  • Kế toán
  • Tồn kho
  • PoS
  • Dự án
  • MRP
All apps
Bạn cần phải đăng ký để tương tác với cộng đồng.
Tất cả bài viết Người Huy hiệu
Thẻ (Xem tất cả)
odoo accounting v14 pos v15
Về diễn đàn này
Bạn cần phải đăng ký để tương tác với cộng đồng.
Tất cả bài viết Người Huy hiệu
Thẻ (Xem tất cả)
odoo accounting v14 pos v15
Về diễn đàn này
Hỗ trợ

How to correctly setup odoo with postgres9.5 and pgbouncer?

Đăng ký nhận tin

Nhận thông báo khi có hoạt động trên bài viết này

Câu hỏi này đã bị gắn cờ
odoo10
2 Trả lời
8250 Lượt xem
Ảnh đại diện
Samo Arko

I'm running odoo 10 on a ubuntu 10.04 server with postgresql 9.5 database. Because multiple odoo instances and configured workers I have 300+ idle postgres tasks. This eats up nearly all my RAM. Now I'm trying to install pgbouncer. When I lunch the pgbouncer service the first time it works, but stop/start or just restart fails and so I can't run the pgbouncer.

I've installed it from git and from apt-get. Both times the same. Have googled for two days to try to fix the issue but nothing works.

Can someone explain me the order what you need to do when you install pgbouncer that it works. Do I need to install it before the db?! do I need to stop the odoo, postgres services when I install it?

The way I tried:

sudo apt-get update
sudo apt-get install pgbouncer

# write the users
sodu -u postgres psql
COPY ( SELECT '"' || rolname || '" "' || CASE WHEN rolpassword IS null THEN '' ELSE rolpassword END || '"' FROM pg_authid ) TO '/etc/pgbouncer/userlist.txt';

# sudo nano pgbouncer.ini
[databases] ;* = port=5432 postgres = host=localhost dbname=postgres [pgbouncer] listen_port = 6432 listen_addr = 127.0.0.1 auth_type = md5 auth_file = /etc/pgbouncer/userlist.txt logfile = /var/log/pgbouncer.log pidfile = /var/run/pgbouncer/pgbouncer.pid admin_users = postgres pool_mode = session server_reset_query = DISCARD ALL default_pool_size=56 max_client_conn=1000


# and then change the db_port to 6432 in odoo.conf

when I started the first time it worked... all the other times I get ...fail!

 Hope someone can help! 

1
Ảnh đại diện
Huỷ bỏ
Ảnh đại diện
Stashell Esteban Charpentier Santamaria
Câu trả lời hay nhất

Pgbouncer is quite tricky you have to keep checking the errors in the logs and clear them one by one.

test your setup first open your terminal and start with reducing your pgbouncer to the bare minimal:

[databases] 
* = port=5432 postgres = host=localhost dbname=postgres

[pgbouncer]
listen_port = 6432
listen_addr = 127.0.0.1
auth_file = /etc/pgbouncer/userlist.txt

save and try to activate the connection

$ /usr/sbin/pgbouncer  pgbouncer.ini

most probably you will have some errors post them will see what it is

if no errors show on the screen and pgbouncer is started do a connection test from a second terminal, following your settings type the following:

psql -U postgres -p 6432 -h localhost dbname=postgres

it should show you the connection problem and what needs to be fix, it could be 1 of 3 things or the 3 all together, the userlist, the IPs not properly configure or the authorization.

Once you have clear all the errors from the files and postgres configuration you can go ahead and start adding settings to pgbouncer, keep in mind this apps have a lot of interactions going on but the base needs to be clear to work out.

1
Ảnh đại diện
Huỷ bỏ
Samo Arko
Tác giả

thanks, but I gave up on pgbouncer.

Roland Lee

Try the Heimdall Proxy. Most Odoo users need statement-level pooling. PgBouncer cannot support this. It's also open source; you get what you pay for. The Heimdall Proxy also supports query caching and read/write split for ACID compliance.

Victor Diaz

Heimdall proxy is not open source, you can download it and try it for 30 days but then it will disconnect you from database and you have to pay for the subscription. I tried it and it works but after 30 days you will be asked to buy a license

Roland Lee

@Victor, that is correct. The Heimdall Database Proxy is a commercial product. We get what you pay for :)

Ảnh đại diện
Roland Lee
Câu trả lời hay nhất

Have you tried out the Heimdall Proxy? It supports 1) Query caching, ACID-Compliant Read/Write splitting, and 3) Connection Pooling. www.heimdalldata.com/odoo

To be clear, pg-bouncer or pg-Pool-II will not work with Odoo as queries are in transactions and query splitting requires strong consistency. The Heimdall Proxy was specifically designed for the Odoo application.

0
Ảnh đại diện
Huỷ bỏ
Muhammad Awais

we can specify the mode=transaction in pgbouncer

Roland Lee

Odoo uses transactions for all units of work, preventing statement pooling from operating. It is the inability to operate pooling at the statement level that we say it is "broken", as this is what many customers are looking for: The ability to dramatically reduce the number of connections coming from their application to the database. With the Heimdall Proxy, it is common to see 100-1 reduction or greater on the number of connections to the database. Added to this, our proxy can to cache and read/write split, beyond what PgBouncer provides. We typically target larger-scale deployments with Postgres CPU cores of 48+.

Bạn có hứng thú với cuộc thảo luận không? Đừng chỉ đọc, hãy tham gia nhé!

Tạo tài khoản ngay hôm nay để tận hưởng các tính năng độc đáo và tham gia cộng đồng tuyệt vời của chúng tôi!

Đăng ký
Bài viết liên quan Trả lời Lượt xem Hoạt động
Create schedule action For sending emails
odoo10
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
2
thg 7 25
6799
How to send messages that are not shown in chatter? Đã xử lý
odoo10
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
2
thg 10 25
8942
How to ORDER BY? [Odoo 10] Đã xử lý
odoo10
Ảnh đại diện
Ảnh đại diện
2
thg 11 24
29887
Dynamic domain functionality - possible to change domain of a field in another model with onchange? (Odoo 10) Đã xử lý
odoo10
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
2
thg 5 24
8519
Change state of other module
odoo10
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
3
thg 3 24
7939
Cộng đồng
  • Khóa học
  • Tài liệu
  • Diễn đàn
Open source
  • Tải xuống
  • Github
  • Runbot
  • Dịch thuật
Dịch vụ
  • Lưu trữ Odoo.sh
  • Hỗ trợ
  • Nâng cấp
  • Phát triển tùy chỉnh
  • Đào tạo
  • Tìm kế toán
  • Tìm đối tác
  • Trở thành đối tác
Giới thiệu công ty
  • Công ty của chúng tôi
  • Tài sản thương hiệu
  • Liên hệ
  • Việc làm
  • Sự kiện
  • Podcast
  • Blog
  • Khách hàng
  • Pháp lý • Riêng tư
  • Bảo mật
الْعَرَبيّة 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 là bộ ứng dụng kinh doanh có open source đáp ứng tất cả các nhu cầu của công ty bạn: CRM, thương mại điện tử, kế toán, tồn kho, POS, quản lý dự án, v.v.

Định hướng giá trị riêng biệt của Odoo là tích hợp hoàn toàn và dễ dàng sử dụng.

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