原 pgbouncer启动报错evdns_base_new failed Segmentation fault (core dumped)
现象
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | [gpadmin@mdw pgbouncer]$ pgbouncer pgbouncer.ini -v 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: [databases] 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: '*' = 'host=127.0.0.1 port=5432' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: '*' = 'host=127.0.0.1 port=5432' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: [pgbouncer] 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'pool_mode' = 'session' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'pool_mode' = 'session' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'listen_port' = '6432' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'listen_port' = '6432' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'listen_addr' = '*' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'listen_addr' = '*' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'auth_type' = 'md5' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'auth_type' = 'md5' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'auth_user' = 'pgbouncer' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'auth_user' = 'pgbouncer' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'auth_file' = '/usr/local/greenplum-db/pgbouncer/users.txt' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'auth_file' = '/usr/local/greenplum-db/pgbouncer/users.txt' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'logfile' = '/usr/local/greenplum-db/pgbouncer/pgbouncer.log' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'logfile' = '/usr/local/greenplum-db/pgbouncer/pgbouncer.log' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'pidfile' = '/usr/local/greenplum-db/pgbouncer/pgbouncer.pid' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'pidfile' = '/usr/local/greenplum-db/pgbouncer/pgbouncer.pid' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'admin_users' = 'pgbouncer' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'admin_users' = 'pgbouncer' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'default_pool_size' = '1000' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'default_pool_size' = '1000' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'max_client_conn' = '4000' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'max_client_conn' = '4000' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'ignore_startup_parameters' = 'extra_float_digits,search_path' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'ignore_startup_parameters' = 'extra_float_digits,search_path' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'so_reuseport' = '1' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'so_reuseport' = '1' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'application_name_add_host' = '1' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'application_name_add_host' = '1' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'query_wait_timeout' = '0' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'query_wait_timeout' = '0' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'log_connections' = '0' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'log_connections' = '0' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'log_disconnections' = '0' 2025-01-08 15:44:31.518 CST [180197] DEBUG parse_ini_file: 'log_disconnections' = '0' ok:1 2025-01-08 15:44:31.518 CST [180197] DEBUG loading auth_file: "/usr/local/greenplum-db/pgbouncer/users.txt" 2025-01-08 15:44:31.518 CST [180197] DEBUG pktbuf_dynamic(128): 0x14a7370 2025-01-08 15:44:31.518 CST [180197] DEBUG make_room(0x14a7370, 9): realloc newlen=256 2025-01-08 15:44:31.518 CST [180197] DEBUG pktbuf_dynamic(128): 0x14a7550 2025-01-08 15:44:31.518 CST [180197] LOG kernel file descriptor limit: 655350 (hard: 655350); max_client_conn: 4000, max expected fd use: 4012 2025-01-08 15:44:31.518 CST [180197] DEBUG adns_create_context: evdns2 2025-01-08 15:44:31.518 CST [180197] ERROR evdns_base_new failed Segmentation fault (core dumped) |
原因
缺失/etc/resolv.conf 文件,且该文件必须有内容。
解决
1 | echo 'nameserver 127.0.0.1' >> /etc/resolv.conf |