[Linux-PowerEdge] xercesc_3_1::TranscodingException - alternative fix

Jon Diprose jon at well.ox.ac.uk
Tue Sep 22 09:17:33 CDT 2015


As the various other suggested fixes haven't worked for me and none seem to be forthcoming from Dell, I've resorted to rebuilding the libxerces-3.1.so locally using ICU transcoding:

# Xerces will need libicu at runtime plus libicu-devel and icu at buildtime
yum -y install libicu libicu-devel icu

# Bug in /usr/bin/icu-config
sed -i 's/bindir=`pkg-config --variable=sbindir icu`/sbindir=`pkg-config --variable=sbindir icu`/' /usr/bin/icu-config

# Obtain, build and install libxerces-c-3.1.so over the one in /usr/local/lib/dsulib
mkdir /tmp/xerces-c-3.1.2
pushd /tmp/xerces-c-3.1.2
wget http://mirrors.muzzy.org.uk/apache//xerces/c/3/sources/xerces-c-3.1.2.tar.bz2
tar xf xerces-c-3.1.2.tar.bz2
pushd xerces-c-3.1.2
./configure --prefix=/tmp/xerces-c-3.1.2 --enable-transcoder-icu --enable-msgloader-icu
make
make install
popd
/bin/rm -rf xerces-c-3.1.2
/bin/cp -p /tmp/xerces-c-3.1.2/lib/libxerces-c-3.1.so /usr/local/lib/dsulib/
popd
/bin/rm -rf /tmp/xerces-c-3.1.2

# If no longer required, you can probably remove icu and libicu-devel at this point
# yum -y erase icu libicu-devel


The change of transcoder was suggested by running the broken version under gdb, which lead to:

Starting program: /usr/sbin/dsu
[Thread debugging using libthread_db enabled]
Detaching after fork from child process 1940.
Detaching after fork from child process 1942.
Detaching after fork from child process 1944.
Detaching after fork from child process 1946.
Catchpoint 1 (exception caught), 0x00000038776bbc30 in __cxa_begin_catch () from /usr/lib64/libstdc++.so.6
Missing separate debuginfos, use: debuginfo-install dell-system-update-1.1-15.09.00.x86_64
(gdb) bt
#0  0x00000038776bbc30 in __cxa_begin_catch () from /usr/lib64/libstdc++.so.6
#1  0x00000038776bcd1d in __cxa_throw () from /usr/lib64/libstdc++.so.6
#2  0x00007ffff756870c in xercesc_3_1::IconvGNULCPTranscoder::calcRequiredSize(unsigned short const*, xercesc_3_1::MemoryManager*) () from /usr/local/lib/dsulib/libxerces-c-3.1.so
#3  0x00007ffff7568875 in xercesc_3_1::IconvGNULCPTranscoder::transcode(unsigned short const*, xercesc_3_1::MemoryManager*) () from /usr/local/lib/dsulib/libxerces-c-3.1.so
#4  0x00007ffff73d8c85 in xercesc_3_1::XMLString::transcode(unsigned short const*, xercesc_3_1::MemoryManager*) () from /usr/local/lib/dsulib/libxerces-c-3.1.so
#5  0x00007ffff7ae4a18 in CreateDSMNodesFromXercesNodes(xercesc_3_1::DOMNode*, DSMXMLNode*) () from /usr/local/lib/dsulib/libdsmxml.so
#6  0x00007ffff7ae4b57 in CreateDSMNodesFromXercesNodes(xercesc_3_1::DOMNode*, DSMXMLNode*) () from /usr/local/lib/dsulib/libdsmxml.so
#7  0x00007ffff7ae4b57 in CreateDSMNodesFromXercesNodes(xercesc_3_1::DOMNode*, DSMXMLNode*) () from /usr/local/lib/dsulib/libdsmxml.so
#8  0x00007ffff7ae4b57 in CreateDSMNodesFromXercesNodes(xercesc_3_1::DOMNode*, DSMXMLNode*) () from /usr/local/lib/dsulib/libdsmxml.so
#9  0x00007ffff7ae5016 in DSMDOMParser::Parse(DSMFile const&, int&, DSMString&) () from /usr/local/lib/dsulib/libdsmxml.so
#10 0x00007ffff7d670a9 in DCMKitAPI::Parse(DSMFile const&) () from /usr/local/lib/dsulib/libdcmkit.so
#11 0x000000000040e1af in DSUController::Run() ()
#12 0x000000000041d6f7 in main ()

Building Xerces-3.1.2 locally with the IconvGNU transcoder leads to what appears to be the same stacktrace, identifying lines 719 (calcRequiredSize) and 747 (transcode) of source file src/xercesc/util/Transcoders/IconvGNU/IconvGNUTransService.cpp. The underlying error is an invalid or incomplete multibyte character. A few debugging statements lead me to believe that it's barfing in the same place as:

[root at localhost ~]# iconv -f UTF-16 -t US /usr/libexec/dell_dup/Catalog.xml | tail -5
iconv: illegal input sequence at position 1571142
      </Device>
    </SupportedDevices>
    <ImportantInfo URL="http://www.dell.com/support/drivers/us/en/04/DriverDetails?driverId=DF0F2">
      <Display lang="en"><![CDATA[1. WARNING: THE SERVER MUST BE REBOOTED AFTER UPDATING THE FIRMWARE ON MD1120 ENCLOSURES IN ORDER TO MAINTAIN ENCLOSURE MANAGEMENT. ACCESS TO THE ENCLOSURES WILL BE LOST IF THE SERVER IS NOT REBOOTED.
2. WHEN PROMPTED FOR REBOOT AFTER UPDATE, SELECT

This and more possible tricky characters are highlighted by:

[root at localhost ~]# iconv -f UTF-16 -t UTF-8 /usr/libexec/dell_dup/Catalog.xml | grep --color='auto' -P -n "[\x80-\xFF]"
13297:2. WHEN PROMPTED FOR REBOOT AFTER UPDATE, SELECT âYESâ  ]]></Display>
15980:⢠Unified Server Configurator, a graphical UI for 1-to-1 local access
15981:⢠Remote Services, WSMan interfaces for remote access
17451:      <Display lang="en"><![CDATA[This release contains firmware version J350 for Hitachi SAS (10K rpm 2.5" SAS) 146GB and 300GB Hard Drives. Vendor model numbers HUC103014CSS600 and HUC103030CSS600. 
21106:      <Display lang="en"><![CDATA[Dell PERC6 firmware maintenance release version 6.2.0-0013 â Performance enhancements include significant improvements in random-write performance, multi-threaded write performance, and reduction in maximum and average I/O response times.]]></Display>
37156:      <Display lang="en"><![CDATA[This release contains firmware version HT62 for Seagate SAS (15K rpm 2.5" SAS) 73GB and 146GB Hard Drives. Vendor model numbers ST973452SS and ST9146852SS.  
37559:2.        WHEN PROMPTED FOR REBOOT AFTER UPDATE, SELECT âYESâ
47063:      <Display lang="en"><![CDATA[This release contains firmware version FS62 for Seagate SAS (10K rpm 2.5" SAS) 146GB and 300GB Hard Drives. Vendor model numbers ST9146803SS and ST9300603SS. 
50431:      <Display lang="en"><![CDATA[Dell PERC6/CERC6 firmware maintenance release version 6.2.0-0013 â Performance enhancements include significant improvements in random-write performance, multi-threaded write performance, and reduction in maximum and average I/O response times. ]]></Display>
54732:      <Display lang="en"><![CDATA[There is an architectural constraint with Dellâs DUP HDD firmware update utility, related to system memory utilization, which is typically encountered on systems with minimal system memory, memory-intensive configurations (multiple RAID controllers), or memory-intensive applications.  This issue is typically reported as âThe operation was not successful because the device buffer write has failedâ and will result in an aborted attempt to update firmware on the identified HDD.  Error codes associated with this failure mode include 8009 and 8017. Once an error is detected, the update session is aborted. There is no data integrity or data availability risk associated with this issue.  Subsequent attempts to update the HDD firmware may succeed, particularly if system resources are freed up.
55889:      <Display lang="en"><![CDATA[There is an architectural constraint with Dellâs DUP HDD firmware update utility, related to system memory utilization, which is typically encountered on systems with minimal system memory, memory-intensive configurations (multiple RAID controllers), or memory-intensive applications. This issue is typically reported as âThe operation was not successful because the device buffer write has failedâ and will result in an aborted attempt to update firmware on the identified HDD. Error codes associated with this failure mode include 8009 and 8017. Once an error is detected, the update session is aborted. There is no data integrity or data availability risk associated with this issue. Subsequent attempts to update the HDD firmware may succeed, particularly if system resources are freed up.
56142:      <Display lang="en"><![CDATA[This release contains firmware version ER62 for Seagate SAS (10K rpm 3.5" SAS) 600GB Hard Drives.  Vendor model number ST3600002SS. 

which might also explain why setting LANG works for some people. Looks like someone has been using unnecessarily complicated quote and bullet symbols.

The IconvGNU code and iconv binary appears to be supplied in the glibc-common package (and the iconv.h header from glibc-headers), which might explain my problem as I'm stuck on RHEL 6.6 for software support reasons. Perhaps the 6.7 glibc-common update would get me to the point where setting LANG would help.

Ho hum. I hope someone else finds this useful.

Jon



More information about the Linux-PowerEdge mailing list