Bug 201718 - sysutils/arcconf: fix 1.7 segfault on CERC SATA RAID (Dell PowerEdge 750) by upgrade to 3.0
Summary: sysutils/arcconf: fix 1.7 segfault on CERC SATA RAID (Dell PowerEdge 750) by ...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: i386 Any
: --- Affects Only Me
Assignee: Kurt Jaeger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-20 14:54 UTC by Eric
Modified: 2019-03-17 09:05 UTC (History)
4 users (show)

See Also:
pi: maintainer-feedback+


Attachments
patch for update to 2.03.22746 (950 bytes, patch)
2017-02-21 13:43 UTC, michael
no flags Details | Diff
patch to update to 3_00_23488 (1.05 KB, patch)
2019-03-16 13:44 UTC, michael
michael: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric 2015-07-20 14:54:58 UTC
Hi,

I just install FreeBSD 10 on old dell server PE 750 with Dell CERC raid card and I have this problem below with the arcconf soft (Segmentation fault (core dumped)).
If you need more information aks them :o)

Information about FreeBSD:
uname -a :FreeBSD srv1789.xxxx.xx 10.1-RELEASE-p10 FreeBSD 10.1-RELEASE-p10 #0: Thu Jun  4 07:48:38 CEST 2015     root@srv1789.xxxx.xxt:/usr/obj/usr/src/sys/CustomKernel  i386

Information about ARCCONF:
  | UCLI |  Adaptec by PMC uniform command line interface
  | UCLI |  Version 1.7 (B21229)
  | UCLI |  (C) Adaptec by PMCS 2003-2014
  | UCLI |  All Rights Reserved

Dell CERC SATA RAID Hardware information:
dev.aac.%parent:
dev.aac.0.%desc: Dell CERC SATA RAID 2
dev.aac.0.%driver: aac
dev.aac.0.%location: slot=1 function=0
dev.aac.0.%pnpinfo: vendor=0x9005 device=0x0285 subvendor=0x1028 subdevice=0x0291 class=0x010400
dev.aac.0.%parent: pci2
dev.aac.0.firmware_build: 7419

If I don't indicate ID controller i have this output:
root@srv1789:/usr/local/sbin # arcconf GETCONFIG AL
Controllers found: 1
Invalid arguments.

But if I indicate ID controller i have this error:
root@srv1789:/usr/local/sbin # arcconf GETCONFIG 1 AL
Segmentation fault (core dumped)

I have also information about arcconf soft:
root@srv1789:/usr/local/sbin # ldd arcconf
arcconf:
        libthr.so.3 => /lib/libthr.so.3 (0x28337000)
        libncurses.so.8 => /lib/libncurses.so.8 (0x28359000)
        libstdc++.so.6 => /usr/local/lib/compat/libstdc++.so.6 (0x28396000)
        libm.so.5 => /lib/libm.so.5 (0x28491000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x284b7000)
        libc.so.7 => /lib/libc.so.7 (0x284c3000)

GDB information:
root@srv1789:/usr/local/sbin # gdb
GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-marcel-freebsd".
(gdb) core arcconf.core
Core was generated by `arcconf'.
Program terminated with signal 11, Segmentation fault.
#0  0x082241aa in ?? ()
(gdb) quit
Comment 1 michael 2015-07-20 17:58:13 UTC
I submitted several cases to my FAE at PMC/Adaptec but they don't care. I never got any relevant feedback.

Perhaps we should mark this port as broken/ do not use?
Comment 2 Eric 2015-07-20 18:37:29 UTC
Hi, thank you to your answer, but i just find a tweak to works it :o)

I use a very old version of the precompiled arcconf soft which is works on a very old FreeBSD (6.1)

This version of arcconf works great
./arcconf

  | UCLI |  Adaptec by PMC uniform command line interface
  | UCLI |  Version 7.0 (B18781)
  | UCLI |  (C) Adaptec by PMC 2003-2011
  | UCLI |  All Rights Reserved

I use the precompiled version to freebsd8 include into the archive.
You can find the link below:
http://download.adaptec.com/raid/storage_manager/asm_freebsd_x86_v7_00_18781.tgz
Comment 3 Eric 2015-07-21 16:22:27 UTC
I check few other version.
The last arcconf version which works great on my Dell CERC RAID Adapter is the ARCCONF Command Line Utility v1.4.20859

It can be download at this location:
http://www.adaptec.com/fr-fr/speed/raid/storage_manager/arcconf_v1_4_20859_zip.php

All other newer version crash with segmentation fault.

If it can help you.
Comment 4 michael 2015-07-22 06:27:27 UTC
I just saw a newer Version- could you please test 1.8.21375?

http://download.adaptec.com/raid/storage_manager/arcconf_v1_8_21375.zip
Comment 5 Eric 2015-07-22 08:24:39 UTC
Hi,

I just test this latest version it's the worst of all.

I don't have any error but when i try to execute the command below, my RAID card crash completely and i need a hard reboot to relaunch the server.

I try it on 2 different server with the same RAID card and I have the same problem.


trying to display all information with this command:
arcconf GETCONFIG 1 AL

I have any output and after 15-20 sec dell CERC card crash and server don't respond at anything, i must proceed a hard reboot.

Do you know if adaptec publish a detailed changelog between each version (I can't find any changelog) because the problem is after the v1.4.20859 no other one works.
Comment 6 michael 2015-07-29 17:38:04 UTC
Adaptec asked me if you were using the current driver (seems inbox driver is known to be buggy):


http://www.adaptec.com/en-us/speed/raid/aac/unix/aacraid_freebsd_b41018_tgz.php
Comment 7 Eric 2015-07-29 19:56:16 UTC
Hi,

Thank you to continue to work on the bug :o)

I use the last firmware available on the support dell website.

You can find the complete adapter information below, this output is produce with the arcconf Version 6.50 (B18570):

arcconf GETCONFIG 1 AD
Controllers found: 1
----------------------------------------------------------------------
Controller information
----------------------------------------------------------------------
   Controller Status                        : Optimal
   Channel description                      : SATA
   Controller Model                         : CERC SATA1.5/6ch
   Controller Serial Number                 : 6F954
   Installed memory                         : 64 MB
   Copyback                                 : Disabled
   Background consistency check             : Disabled
   Automatic Failover                       : Enabled
   Stayawake period                         : Disabled
   Spinup limit internal drives             : 0
   Spinup limit external drives             : 0
   Defunct disk drive count                 : 0
   Logical devices/Failed/Degraded          : 1/0/0
   --------------------------------------------------------
   Controller Version Information
   --------------------------------------------------------
   BIOS                                     : 4.1-0 (7419)
   Firmware                                 : 4.1-0 (7419)
   Driver                                   : 2.1-9 (1)
   Boot Flash                               : 0.0-0 (0)
   --------------------------------------------------------
   Controller Battery Information
   --------------------------------------------------------
   Status                                   : Not Installed


I use the driver include in the FreeBSD distribution 10.1 download from the official website and with the last patch available too.
you can find below the log when I boot server:
Jul 21 18:14:09 srv1789 kernel: aac0: <Dell CERC SATA RAID 2> mem 0xf4000000-0xf7ffffff irq 24 at device 1.0 on pci2
Jul 21 18:14:09 srv1789 kernel: aac0: CERC SATA1.5/6ch, aac driver 2.1.9-1
Jul 21 18:14:09 srv1789 kernel: aacd0 on aac0
Jul 21 18:14:09 srv1789 kernel: aacd0: 76260MB (156182272 sectors)
Jul 21 18:14:09 srv1789 kernel: Trying to mount root from ufs:/dev/aacd0s1a [rw]...
Comment 8 Eric 2015-07-31 07:43:42 UTC
Hi,

I try o use the adaptec driver ( http://www.adaptec.com/en-us/speed/raid/aac/unix/aacraid_freebsd_b41018_tgz.php ) but I have a problem.
I can't find any solution to load the driver to the raid controller.

I modify the loader.conf with this line:
aacraidu_load="YES"

I copy aacraidu.ko to /boot/kernel

When i do kldstat command, I have this output:
Id Refs Address    Size     Name
 1    6 0xc0400000 bfd124   kernel
 2    1 0xc0ffe000 ff08     aacraidu.ko

but when I run arcconf utility to add config info about the adapter I have always the old driver :
./arcconf GETCONFIG 1 AD
Controllers found: 1
----------------------------------------------------------------------
Controller information
----------------------------------------------------------------------
   Controller Status                        : Optimal
   Channel description                      : SATA
   Controller Model                         : CERC SATA1.5/6ch
   Controller Serial Number                 : C74813
   Installed memory                         : 64 MB
   Copyback                                 : Disabled
   Background consistency check             : Disabled
   Automatic Failover                       : Enabled
   Stayawake period                         : Disabled
   Spinup limit internal drives             : 0
   Spinup limit external drives             : 0
   Defunct disk drive count                 : 0
   Logical devices/Failed/Degraded          : 1/0/0
   --------------------------------------------------------
   Controller Version Information
   --------------------------------------------------------
   BIOS                                     : 4.1-0 (7419)
   Firmware                                 : 4.1-0 (7419)
   Driver                                   : 2.1-9 (1)
   Boot Flash                               : 0.0-0 (0)
   --------------------------------------------------------
   Controller Battery Information
   --------------------------------------------------------
   Status                                   : Not Installed


Could you explain me how can I use the new driver and not the old ?

When I read the boot log, system always use the old driver:
aac0: CERC SATA1.5/6ch, aac driver 2.1.9-1

I can't do how to use the aacraidu.ko instead of aac.ko

Thank you very much to your help.
Comment 9 michael 2015-08-10 07:08:51 UTC
could you build a new kernel without aacraid included?
Comment 10 Eric 2015-08-10 15:12:50 UTC
Hi,

I try to compile a new kernel without any aac driver.
But Server can't boot and i don't find any solution to load the adaptec driver when it boot :(
Comment 11 michael 2015-08-11 07:52:57 UTC
http://download.adaptec.com/pdfs/user_guides/adaptec_raid_controller_iug_6_2015.pdf -> page 57, but it is quite outdated
Comment 12 Eric 2015-08-19 18:15:27 UTC
Hi, 
sorry to the delay, but I try much much solution, but any solution doesn't work to load the adaptec driver.

In last resort I try to rename their driver to the base driver (aka aac.ko) but when server boot just after the driver is loaded when the FreeBSD mount the partition, I have a kernel panic or server reboot.
Comment 13 Kurt Jaeger freebsd_committer freebsd_triage 2016-01-24 13:13:52 UTC
Can you try to download

http://download.adaptec.com/raid/storage_manager/arcconf_v1_8_21375.zip

and test with that ?
Comment 14 Eric 2016-01-24 16:46:07 UTC
Hi, I already test this version ( check my comment NĀ° 5 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=201718#c5 )

This version is the Worth, adaptec controller crash since i try to GETCONFIG on it :(

I try again this version today but same problem, when I try to invoke arcconf with this command (arcconf GETCONFIG 1 ALL) adaptec controller crash, i loose all control on it and I must do an electric reboot on the server to control it again.
Comment 15 Kurt Jaeger freebsd_committer freebsd_triage 2016-01-24 18:25:15 UTC
(In reply to Eric from comment #14)
Which binary did you from the distfile ?

The distfile provides 9 i386/amd64 files and 10 amd64 only. Your system
uses i386, so which executable did you use ?
Comment 16 Eric 2016-01-24 18:38:37 UTC
Hi, 
I try all x86 binary (folder FreeBSD7, freebsd8 and freebsd9) with compiled kernel to support compat 4,5,6,7 and with this ports misc/compat9x

Kernel conf:
options         COMPAT_FREEBSD4         # Compatible with FreeBSD4
options         COMPAT_FREEBSD5         # Compatible with FreeBSD5
options         COMPAT_FREEBSD6         # Compatible with FreeBSD6
options         COMPAT_FREEBSD7         # Compatible with FreeBSD7
Comment 17 Kurt Jaeger freebsd_committer freebsd_triage 2016-01-24 19:01:09 UTC
Is it possible to install 10amd64 on that box and to try to 10amd64 arcconf with a generic kernel ?
Comment 18 Eric 2016-01-24 19:38:39 UTC
Hi,

Unfortunately, Dell PE 750 supports only 32Bits processor :o(
You can find here hardware specs http://www.dell.com/downloads/global/products/pedge/en/750_specs.pdf

So i can't test 64 bits binary.
Comment 19 Kirill 2016-06-20 13:12:16 UTC
Hi.

FreeBSD srv.ru 9.3-RELEASE-p44 FreeBSD 9.3-RELEASE-p44 #0 r301925: Wed Jun 15 18:22:44 MSK 2016     root@srv.ru:/usr/obj/usr/src/sys/UNIVERSAL  amd64

smbios.system.product="IBM x3850-[88644RG]-"

dev.aac.0.%desc: IBM ServeRAID 8i
dev.aac.0.%driver: aac
dev.aac.0.%location: slot=2 function=0
dev.aac.0.%pnpinfo: vendor=0x9005 device=0x0285 subvendor=0x1014 subdevice=0x02f2 class=0x010400
dev.aac.0.%parent: pci1
dev.aac.0.firmware_build: 15432
dev.aacd.0.%driver: aacd
dev.aacd.0.%parent: aac0


This problem actual. On old version arcconf-7.30.18837 - all good.
Comment 20 emz 2016-12-15 08:41:32 UTC
Same stuff on 10.3-STABLE #0 r303958 and IBM Serveraid-8k. Took an old arcconf from microsemi site, works like a charm.

Could you please just rollback the port ?

Although I should admit that on an installation from scratch arcconf from ports works too (it doesn't see the raid though, but this is another problem).
Comment 21 michael 2017-02-21 13:43:02 UTC
Created attachment 180189 [details]
patch for update to 2.03.22746

patch for update to 2.03.22746- still doesn't work for FreeBSD 11
Comment 22 michael 2019-03-16 13:44:39 UTC
Created attachment 202911 [details]
patch to update to 3_00_23488

updates to the recent version, please commit
Comment 23 commit-hook freebsd_committer freebsd_triage 2019-03-16 15:41:07 UTC
A commit references this bug:

Author: pi
Date: Sat Mar 16 15:40:37 UTC 2019
New revision: 495888
URL: https://svnweb.freebsd.org/changeset/ports/495888

Log:
  sysutils/arcconf: update 1_8_21375 -> 3_00_23488

  PR:		201718
  Submitted by:	michael@fuckner.net (maintainer)

Changes:
  head/sysutils/arcconf/Makefile
  head/sysutils/arcconf/distinfo
  head/sysutils/arcconf/pkg-descr
Comment 24 Kurt Jaeger freebsd_committer freebsd_triage 2019-03-16 19:49:51 UTC
Please test with the new version of arcconf, if the segfault still happens.

(I tested on 11.2, works for me)
Comment 25 Eric 2019-03-17 08:34:09 UTC
Thank you to this new version, it works fine now for me.
Comment 26 Kurt Jaeger freebsd_committer freebsd_triage 2019-03-17 09:05:46 UTC
Thanks all!