Bug 197941 - mail/cclient segmentation fault
Summary: mail/cclient segmentation fault
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-02-23 02:29 UTC by David Benfell
Modified: 2015-05-19 10:08 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Benfell 2015-02-23 02:29:20 UTC
I have documented my tale of woe at https://parts-unknown.org/wp/2015/02/22/my-web-sites-are-mostly-down/

php-fpm (under lang/php55) was failing to start, complaining of a segmentation fault. After (mostly) ruling out a memory defect and discovering that I could only find instances of segmentation faults associated with apache24 and httpd, I eventually ran gdb on php-fpm and obtained:

Program received signal SIGSEGV, Segmentation fault.
0x000000080a9903e8 in hash_lookup () from /usr/local/lib/libc-client4.so.9

When I removed the php55-imap extension, php-fpm started successfully and my sites now seem to be running.

You may have difficulty reproducing this. The bug only appears on one, not both, of my systems. Following a suggestion on the freebsd-questions list, I obtained the following. vegan is the newer, bigger system and is the system on which I encountered the problem. home is my older system; the problem does not appear on it:

[benfell@home ~]% grep Features /var/run/dmesg.boot
  Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
  Features2=0x7fdafbbf<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
  AMD Features=0x2c100800<SYSCALL,NX,Page1GB,RDTSCP,LM>
  AMD Features2=0x21<LAHF,ABM>
  Structured Extended
Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
  XSAVE Features=0x1<XSAVEOPT>
  Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
  Features2=0x7fdafbbf<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
  AMD Features=0x2c100800<SYSCALL,NX,Page1GB,RDTSCP,LM>
  AMD Features2=0x21<LAHF,ABM>
  Structured Extended
Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
  XSAVE Features=0x1<XSAVEOPT>

Now the newer machine:

vegan# grep Features /var/run/dmesg.boot
  Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
  Features2=0x7ffafbff<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,SMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
  AMD Features=0x2c100800<SYSCALL,NX,Page1GB,RDTSCP,LM>
  AMD Features2=0x21<LAHF,ABM>
  Structured Extended
Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
  XSAVE Features=0x1<XSAVEOPT>
  Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
  Features2=0x7ffafbff<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,SMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
  AMD Features=0x2c100800<SYSCALL,NX,Page1GB,RDTSCP,LM>
  AMD Features2=0x21<LAHF,ABM>
  Structured Extended
Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
  XSAVE Features=0x1<XSAVEOPT>

Perhaps a diff will help:

[benfell@vegan ~]% diff -u Features.home Features.vegan
--- Features.home       2015-02-22 17:09:32.000000000 -0800
+++ Features.vegan      2015-02-22 17:09:01.000000000 -0800
@@ -1,15 +1,13 @@
-[benfell@home ~]% grep Features /var/run/dmesg.boot
+vegan# grep Features /var/run/dmesg.boot
   Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
-  Features2=0x7fdafbbf<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
+
Features2=0x7ffafbff<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,SMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
   AMD Features=0x2c100800<SYSCALL,NX,Page1GB,RDTSCP,LM>
   AMD Features2=0x21<LAHF,ABM>
-  Structured Extended
-Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
+  Structured Extended
Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
   XSAVE Features=0x1<XSAVEOPT>
   Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
-  Features2=0x7fdafbbf<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
+
Features2=0x7ffafbff<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,SMX,EST,TM2,SSSE3,<b11>,FMA,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
   AMD Features=0x2c100800<SYSCALL,NX,Page1GB,RDTSCP,LM>
   AMD Features2=0x21<LAHF,ABM>
-  Structured Extended
-Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
+  Structured Extended
Features=0x27ab<FSGSBASE,TSCADJ,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID>
   XSAVE Features=0x1<XSAVEOPT>

Another suggestion that came up on the list was that it might be related to https://bugs.php.net/bug.php?id=66313&edit=3 , however, that applies to the php-recode extension.

I'm new at this; please let me know if there's anything else I can or should do.
Comment 1 Thierry Thomas freebsd_committer freebsd_triage 2015-02-23 09:06:15 UTC
Unfortunately I have no idea about your problem, but mail/cclient is the legacy version. Maybe you could try to switch to the newer mail/panda-cclient and check if it works?

Note: your URL https://parts-unknown.org/wp/2015/02/22/my-web-sites-are-mostly-down/ displays a 404 page.
Comment 2 David Benfell 2015-02-23 09:23:13 UTC
Sorry about the link. That post seems to have gotten completely lost somehow. I've actually been going back through mysql dumps trying to retrieve it. Don't know what happened and so much for backups....

How would I tell lang/php55-imap to depend on mail/panda-cclient instead?

According to this page < https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/makefile-depend.html > this should be defined somewhere with some kind of DEPENDS . But I must be looking in the wrong place because I'm not finding it, or any reference to cclient in /usr/ports/lang/php55-imap.
Comment 3 David Benfell 2015-02-23 09:51:55 UTC
I have now recovered the post at https://parts-unknown.org/wp/2015/02/22/my-web-sites-are-mostly-down/
Comment 4 Thierry Thomas freebsd_committer freebsd_triage 2015-02-23 10:10:40 UTC
(In reply to David Benfell from comment #2)

Just run `make config' and select the Panda option before rebuilding the port.
Comment 5 David Benfell 2015-02-23 10:39:02 UTC
Okay then. Yes, at first blush anyway, mail/panda-cclient seems to work fine. I haven't tested its functionality.
Comment 6 John Marino freebsd_committer freebsd_triage 2015-05-19 10:08:15 UTC
Issue seems to be resolved...