OPNsense Forum

English Forums => General Discussion => Topic started by: chgoudinho on March 14, 2019, 06:02:14 pm

Title: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: chgoudinho on March 14, 2019, 06:02:14 pm
Hi everyone, I'm new here ..
I am having a problem after updating the version below the error log. How can I fix it?
System Information:
Code: [Select]
User-Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.121 Safari/537.36
FreeBSD 11.2-RELEASE-p9-HBSD  28502678862(stable/19.1) amd64
OPNsense 19.1.4 736dc49c3
Plugins os-api-backup-1.0 os-arp-scan-1.1 os-bind-1.4_1 os-cache-1.0 os-clamav-1.5_1 os-collectd-1.2 os-debug-1.3 os-dyndns-1.13 os-redis-1.0 os-relayd-2.3 os-smart-1.5 os-theme-rebellion-1.8.2
Time Thu, 14 Mar 2019 08:28:52 -0300
OpenSSL 1.0.2r  26 Feb 2019
PHP 7.1.27]
PHP Errors:
Code: [Select]
[14-Mar-2019 07:26:47 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_file_create() in /usr/local/www/crash_reporter.php:43
Stack trace:
#0 /usr/local/www/crash_reporter.php(130): upload_crash_report(Array, 'OPNsense/19.1.4')
#1 {main}
  thrown in /usr/local/www/crash_reporter.php on line 43
[14-Mar-2019 10:56:51 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 08:15:22 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/www/widgets/widgets/dyn_dns_status.widget.php(52): get_dyndns_ip('wan', 4)
#1 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
[14-Mar-2019 08:15:27 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/www/widgets/widgets/dyn_dns_status.widget.php(52): get_dyndns_ip('wan', 4)
#1 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
[14-Mar-2019 08:15:30 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/www/widgets/widgets/dyn_dns_status.widget.php(52): get_dyndns_ip('wan', 4)
#1 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
[14-Mar-2019 08:20:31 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/www/widgets/widgets/dyn_dns_status.widget.php(52): get_dyndns_ip('wan', 4)
#1 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
[14-Mar-2019 11:27:13 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 11:27:40 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 11:28:09 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 11:28:28 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 08:28:47 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/www/widgets/widgets/dyn_dns_status.widget.php(52): get_dyndns_ip('wan', 4)
#1 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
dmesg.boot:
Code: [Select]
Copyright (c) 2013-2018 The HardenedBSD Project.
Copyright (c) 1992-2018 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 11.2-RELEASE-p9-HBSD  28502678862(stable/19.1) amd64
FreeBSD clang version 6.0.0 (tags/RELEASE_600/final 326565) (based on LLVM 6.0.0)
VT(efifb): resolution 800x600
HardenedBSD: initialize and check features (__HardenedBSD_version 1100056 __FreeBSD_version 1102000).
CPU: Intel(R) Core(TM)2 Quad CPU    Q6600  @ 2.40GHz (2400.13-MHz K8-class CPU)
  Origin="GenuineIntel"  Id=0x6fb  Family=0x6  Model=0xf  Stepping=11
  Features=0xbfebfbff
  Features2=0xe3bd
  AMD Features=0x20100800
  AMD Features2=0x1
  VT-x: HLT,PAUSE
  TSC: P-state invariant, performance statistics
real memory  = 4294967296 (4096 MB)
avail memory = 4020043776 (3833 MB)
Event timer "LAPIC" quality 100
ACPI APIC Table:
FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs
FreeBSD/SMP: 1 package(s) x 4 core(s)
ioapic0: Changing APIC ID to 2
ioapic0  irqs 0-23 on motherboard
SMP: AP CPU #3 Launched!
SMP: AP CPU #1 Launched!
SMP: AP CPU #2 Launched!
Timecounter "TSC-low" frequency 1200067060 Hz quality 1000
random: entropy device external interface
wlan: mac acl policy registered
netmap: loaded module
module_register_init: MOD_LOAD (vesa, 0xffffffff8113fe30, 0) error 19
kbd1 at kbdmux0
nexus0
cryptosoft0:  on motherboard
acpi0:  on motherboard
acpi0: Power Button (fixed)
cpu0:  on acpi0
cpu1:  on acpi0
cpu2:  on acpi0
cpu3:  on acpi0
atrtc0:  port 0x70-0x71,0x74-0x77 irq 8 on acpi0
atrtc0: registered as a time-of-day clock, resolution 1.000000s
Event timer "RTC" frequency 32768 Hz quality 0
attimer0:  port 0x40-0x43,0x50-0x53 irq 0 on acpi0
Timecounter "i8254" frequency 1193182 Hz quality 0
Event timer "i8254" frequency 1193182 Hz quality 100
Timecounter "ACPI-fast" frequency 3579545 Hz quality 900
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x408-0x40b on acpi0
acpi_button0:  on acpi0
pcib0:  port 0xcf8-0xcff on acpi0
pci0:  on pcib0
vgapci0:  port 0x3460-0x3467 mem 0xe8300000-0xe837ffff,0xe0000000-0xe7ffffff,0xe8200000-0xe82fffff irq 16 at device 2.0 on pci0
agp0:  on vgapci0
agp0: aperture size is 128M, detected 7164k stolen memory
vgapci0: Boot video device
pci0:  at device 3.0 (no driver attached)
em0:  port 0x30e0-0x30ff mem 0xe8380000-0xe839ffff,0xe83a4000-0xe83a4fff irq 20 at device 25.0 on pci0
em0: Using an MSI interrupt
em0: Ethernet address: 00:1c:c0:22:84:8c
em0: netmap queues/slots: TX 1/1024, RX 1/1024
uhci0:  port 0x30c0-0x30df irq 18 at device 26.0 on pci0
uhci0: LegSup = 0x2f00
usbus0 on uhci0
usbus0: 12Mbps Full Speed USB v1.0
uhci1:  port 0x30a0-0x30bf irq 21 at device 26.1 on pci0
uhci1: LegSup = 0x2f00
usbus1 on uhci1
usbus1: 12Mbps Full Speed USB v1.0
uhci2:  port 0x3080-0x309f irq 17 at device 26.2 on pci0
uhci2: LegSup = 0x2f00
usbus2 on uhci2
usbus2: 12Mbps Full Speed USB v1.0
ehci0:  mem 0xe83a5400-0xe83a57ff irq 17 at device 26.7 on pci0
usbus3: EHCI version 1.0
usbus3 on ehci0
usbus3: 480Mbps High Speed USB v2.0
hdac0:  mem 0xe83a0000-0xe83a3fff irq 22 at device 27.0 on pci0
pcib1:  at device 28.0 on pci0
pcib1: [GIANT-LOCKED]
pcib2:  at device 28.1 on pci0
pcib2: [GIANT-LOCKED]
pci1:  on pcib2
atapci0:  port 0x2018-0x201f,0x2024-0x2027,0x2010-0x2017,0x2020-0x2023,0x2000-0x200f mem 0xe8100000-0xe81001ff irq 17 at device 0.0 on pci1
ata2:  at channel 0 on atapci0
pcib3:  at device 28.2 on pci0
pcib3: [GIANT-LOCKED]
pcib4:  at device 28.3 on pci0
pcib4: [GIANT-LOCKED]
pcib5:  at device 28.4 on pci0
pcib5: [GIANT-LOCKED]
uhci3:  port 0x3060-0x307f irq 23 at device 29.0 on pci0
uhci3: LegSup = 0x2f00
usbus4 on uhci3
usbus4: 12Mbps Full Speed USB v1.0
uhci4:  port 0x3040-0x305f irq 19 at device 29.1 on pci0
uhci4: LegSup = 0x2f00
usbus5 on uhci4
usbus5: 12Mbps Full Speed USB v1.0
uhci5:  port 0x3020-0x303f irq 18 at device 29.2 on pci0
uhci5: LegSup = 0x2f00
usbus6 on uhci5
usbus6: 12Mbps Full Speed USB v1.0
ehci1:  mem 0xe83a5000-0xe83a53ff irq 23 at device 29.7 on pci0
usbus7: EHCI version 1.0
usbus7 on ehci1
usbus7: 480Mbps High Speed USB v2.0
pcib6:  at device 30.0 on pci0
pci2:  on pcib6
re0:  port 0x1400-0x14ff mem 0xe8004900-0xe80049ff irq 21 at device 0.0 on pci2
re0: Using Memory Mapping!
re0: Using line-based interrupt
re0: version:1.95.00
re0: Ethernet address: 00:1d:0f:be:93:ce

This product is covered by one or more of the following patents:           
US6,570,884, US6,115,776, and US6,327,625.
re0: Ethernet address: 00:1d:0f:be:93:ce
vr0:  port 0x1000-0x10ff mem 0xe8004800-0xe80048ff irq 22 at device 1.0 on pci2
vr0: Quirks: 0x0
vr0: Revision: 0x86
miibus0:  on vr0
ukphy0:  PHY 1 on miibus0
ukphy0:  none, 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto, auto-flow
vr0: Ethernet address: 00:e0:7d:f2:be:f6
pci2:  at device 3.0 (no driver attached)
isab0:  at device 31.0 on pci0
isa0:  on isab0
atapci1:  port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0x3430-0x343f,0x3420-0x342f irq 21 at device 31.2 on pci0
ata0:  at channel 0 on atapci1
ata1:  at channel 1 on atapci1
atapci2:  port 0x3448-0x344f,0x346c-0x346f,0x3440-0x3447,0x3468-0x346b,0x3410-0x341f,0x3400-0x340f irq 21 at device 31.5 on pci0
ata3:  at channel 0 on atapci2
ata4:  at channel 1 on atapci2
uart0: <16550 or compatible> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0
orm0:  at iomem 0xcb800-0xcc7ff on isa0
vga0:  at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
atkbdc0:  at port 0x60,0x64 on isa0
atkbd0:  irq 1 on atkbdc0
kbd0 at atkbd0
atkbd0: [GIANT-LOCKED]
ppc0: cannot reserve I/O port range
est0:  on cpu0
est1:  on cpu1
est2:  on cpu2
est3:  on cpu3
Timecounters tick every 1.000 msec
hdacc0:  at cad 2 on hdac0
hdaa0:  at nid 1 on hdacc0
pcm0:  at nid 20 and 25,26 on hdaa0
pcm1:  at nid 21 and 24 on hdaa0
ugen0.1:  at usbus0
ugen5.1:  at usbus5
ugen6.1:  at usbus6
ugen7.1:  at usbus7
uhub0:  on usbus0
ugen3.1:  at usbus3
uhub1:  on usbus6
ugen2.1:  at usbus2
uhub3:  on usbus5
uhub4:  on usbus2
ugen4.1:  at usbus4
uhub5:  on usbus3
uhub6:  on usbus4
ugen1.1:  at usbus1
uhub2:  on usbus7
uhub7:  on usbus1
uhub0: 2 ports with 2 removable, self powered
uhub1: 2 ports with 2 removable, self powered
uhub4: 2 ports with 2 removable, self powered
uhub3: 2 ports with 2 removable, self powered
uhub6: 2 ports with 2 removable, self powered
uhub7: 2 ports with 2 removable, self powered
uhub5: 6 ports with 6 removable, self powered
uhub2: 6 ports with 6 removable, self powered
ada0 at ata0 bus 0 scbus1 target 0 lun 0
ada0:  ATA-7 SATA 1.x device
ada0: Serial Number 5RY0YH3H
ada0: 150.000MB/s transfers (SATA 1.x, UDMA5, PIO 8192bytes)
ada0: 238474MB (488395055 512 byte sectors)
random: unblocking device.
Trying to mount root from ufs:/dev/gpt/rootfs [rw]...
cd0 at ata3 bus 0 scbus3 target 0 lun 0
cd0:  Removable CD-ROM SCSI device
cd0: 150.000MB/s transfers (SATA 1.x, UDMA5, ATAPI 12bytes, PIO 8192bytes)
cd0: Attempt to query device size failed: NOT READY, Medium not present
/var/crash/PHP_errors.log:
Code: [Select]
[14-Mar-2019 09:56:01 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:24 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:24 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:25 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:26 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:29 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:29 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:30 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:31 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:33 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:33 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:33 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:33 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:34 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:34 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:38 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:38 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 06:56:38 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/etc/inc/plugins.inc.d/dyndns/phpDynDNS.inc(1416): get_dyndns_ip('re0', 4)
#1 /usr/local/etc/inc/plugins.inc.d/dyndns/phpDynDNS.inc(263): updatedns->_checkIP()
#2 /usr/local/etc/inc/plugins.inc.d/dyndns.inc(172): updatedns->__construct('noip-free', 'horrsistemas.dd...', 'suporte@horr.co...', 'horr6100', NULL, '', 'wan', NULL, NULL, NULL, '', '1', '', '', '', 'wan', '0', true, false, false)
#3 /usr/local/etc/inc/plugins.inc.d/dyndns.inc(197): dyndns_configure_client(Array)
#4 /usr/local/etc/inc/plugins.inc(213): dyndns_configure_do(true)
#5 /usr/local/etc/rc.bootup(117): plugins_configure('bootup', true)
#6 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
[14-Mar-2019 09:56:50 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:50 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:51 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 09:56:51 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20160303/curl.so' - Shared object "libnghttp2.so.14" not found, required by "libcurl.so.4" in Unknown on line 0
[14-Mar-2019 07:26:24 America/Sao_Paulo] PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /usr/local/etc/inc/services.inc:1749
Stack trace:
#0 /usr/local/www/widgets/widgets/dyn_dns_status.widget.php(52): get_dyndns_ip('wan', 4)
#1 {main}
  thrown in /usr/local/etc/inc/services.inc on line 1749
Title: Re: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: franco on March 14, 2019, 06:03:24 pm
Sounds like a damaged install. Go to system: settings: firmware and run audit -> health and maybe share the output if the problem persists.


Cheers,
Franco
Title: Re: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: chgoudinho on March 14, 2019, 07:35:16 pm
Hi, it did not help. There is the same error. The log is attached.
Title: Re: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: franco on March 14, 2019, 07:39:46 pm
That's a lot of broken packages right there.

From the console you can do this:

# opnsense-update -pf


Cheers,
Franco
Title: Re: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: chgoudinho on March 14, 2019, 09:06:30 pm
Once the command is executed, it displays no error, only the version.

***GOT REQUEST TO AUDIT HEALTH***
>>> Check installed kernel version
Version 19.1.2 is incorrect, expected: 19.1.4
>>> Check for missing or altered kernel files
No problems detected.
>>> Check installed base version
Version 19.1.2 is incorrect, expected: 19.1.4
>>> Check for missing or altered base files
No problems detected.
>>> Check for and install missing package dependencies
Checking all packages: .......... done
>>> Check for missing or altered package files
Checking all packages: .......... done
***DONE***
Title: Re: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: chgoudinho on March 14, 2019, 09:49:38 pm
Solved, thank you
Title: Re: PHP Warning: PHP Startup: Unable to load dynamic library
Post by: franco on March 15, 2019, 07:13:09 am
Ok, thanks. If kernel and base were older also the command to reinstall all three components at the same time:

# opnsense-update -fpbk

(-f for reinstall, -p for packages, -b for base and -k for kernel)

Or short versions:

# opnsense-update -f

All three components are the default for opnsense-update. ;)


Cheers,
Franco