Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segmentation fault (core dumped) when calling pgagroal-cli #124

Closed
dtseiler opened this issue Dec 22, 2020 · 4 comments
Closed

Segmentation fault (core dumped) when calling pgagroal-cli #124

dtseiler opened this issue Dec 22, 2020 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@dtseiler
Copy link

Describe the bug

When I set up pgagroal and try to test it by calling pgagroal-cli status, I get a seg fault.

I'm able to connect to the DB through pgagroal (on port 2345) via psql:

$ psql -h localhost -p 2345 -U dts -d dts_test -c "select now();"
              now
-------------------------------
 2020-12-22 22:03:54.719825+00
(1 row)

To Reproduce

$ pgagroal-cli -c /usr/local/etc/pgagroal/pgagroal.conf status
Segmentation fault (core dumped)

Version

1.0.2

PostgreSQL

12.5

libev

1:4.22

OpenSSL

1.1.1

Access method

md5

OS

Ubuntu 18.04 LTS

$ uname -a
Linux pgagroal-test 4.15.0-122-generic #124-Ubuntu SMP Thu Oct 15 13:03:05 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

ulimit

$ ulimit -a
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 3693
max locked memory       (kbytes, -l) 65536
max memory size         (kbytes, -m) unlimited
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 8192
cpu time               (seconds, -t) unlimited
max user processes              (-u) 3693
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited

Configuration

Can you provide the configuration pgagroal ?

  • pgagroal.conf
[pgagroal]
host = localhost
port = 2345

log_type = file
log_level = debug1
log_path = /var/log/postgresql/pgagroal.log

max_connections = 100
idle_timeout = 600
validation = off
unix_socket_dir = /tmp/

[primary]
host = localhost
port = 5432
  • pgagroal_hba.conf

# TYPE  DATABASE USER  ADDRESS  METHOD
#
host    all      all   all      all
  • pgagroal_databases.conf
    N/A

  • pgagroal_users.conf
    N/A

Debug logs

Can you provide any debug logs (log_level = debug5) of the issue ?

Tip

Use ``` before and after the text to keep the output as is.

@dtseiler dtseiler added the bug Something isn't working label Dec 22, 2020
@jesperpedersen jesperpedersen self-assigned this Jan 4, 2021
jesperpedersen added a commit that referenced this issue Jan 4, 2021
jesperpedersen added a commit that referenced this issue Jan 4, 2021
@jesperpedersen
Copy link
Collaborator

Must be a permission problem or non-existing directory.

Thanks Don !

@jesperpedersen
Copy link
Collaborator

See #125

@dtseiler
Copy link
Author

dtseiler commented Jan 5, 2021

Ah yeah when I run pgagroal-cli as postgres then it works. When I ran it as the vagrant user in 1.1.0 I get the warning about log file permissions. I'll test that in 1.0.2 again to confirm.

@dtseiler
Copy link
Author

dtseiler commented Jan 5, 2021

Yes in 1.0.2 I get the same segmentation fault when trying to run pgagroal-cli as the vagrant user, but it works fine as the postgres user. In 1.1.0 now I get the friendly log permission warning as the vagrant user.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants