HPE 9000 and HPE e3000 Servers
1748249 Members
3610 Online
108760 Solutions
New Discussion юеВ

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

 
Torsten.
Acclaimed Contributor

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

What I found about valid SCSI speed settings:

SLOW            10 Mbytes/sec
 FAST            20 Mbytes/sec
 ULTRA           40 Mbytes/sec
 ULTRA2          80 Mbytes/sec
 ULTRA160       160 Mbytes/sec
 ULTRA320       320 Mbytes/sec
 NOLIMIT        use maximum that is negotiated between SCSI host and target

and

<width> is either 0, 8, or 16 (where 0 means use max)    Default: max

 

I would try to set another speed, let's say ULTRA2 first and check if the speed and the ioscan output changes.


Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Rudolf Fischer
Advisor

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

Hi Torsten,

Thank you for your reply.

The what command shows that all 3 objects installed.

# what /stand/vmunix | grep c8xx
         scsi_c8xx_dbg.c $Date: 2002/06/10 17:07:37 $Revision: r11.11/2 PATCH_11.11 (PHKL_27025)
         scsi_c8xx.c $Date: 2007/07/17 17:07:07 $Revision: r11.11/17 PATCH_11.11 (PHKL_36521)
         scsi_c8xx_pdk.c $Date: 2004/12/01 21:28:40 $Revision: r11.11/7 PATCH_11.11 (PHKL_32089)

The latest SCSI Ultra160 patch PHKL_36521 is installed.

I tested various speed rates. If speed rate ULTRA2 is set, the Target Limit changed to 80 MB/s and the Negotiated Target Value stays at 40 MB/s. With rate FAST the Target Limit and the Negotiated Target Value changed at 20 MB/s. In all cases nothing is changed by ioscan output. I think as long as ioscan doesn┬┤t show the interfaces as "SCSI C1010 Ultra160 Wide LVD" we will not be successful.

Best regards,

Rudolf

 

Torsten.
Acclaimed Contributor

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

If you can access this page

https://h20565.www2.hpe.com/portal/site/hpsc/patch/home/

you could check if other patches are missing.

 

Patches.png


Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Bill Hassell
Honored Contributor

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

Here's a copy of the disk manual from Seagate:
http://www.seagate.com/support/disc/manuals/scsi/100148123b.pdf

The internal disk rate varies from 632-891 Mbits/sec. That's approximately 60-80 MBytes/sec inside the disk. While the internal 8 MByte cache may be able to push data faster, after 8 MBytes, the rotational speed and internal controller overhead will not allow continuous transfers faster than about 50 MBytes/sec. I've measured serial read speeds for internal disks from K370's, n4000's, rp8420's and rp3440's (raw disk, no interlace) using dd and none of the internal disks get much above 70 MBytes/sec, averaging about 35-50 MBytes/sec.

Here's the code for my diskperf script. It's just a wrapper around dd with some math to make the results easier to read. It is pasted here due to attached file restrictions in the Community forums. Here is the usage:

Requires MB (or all) and at least one DSF
=========================================

   Usage: diskperf [-l log] [-a] [-r <KB>] <MB> <DSF/lvol> [<DSF/lvol>... ]
   where: -l log file
          -a = always append to log, otherwise new log started
          -r <KB> where <KB> is a 1024 block
             (min=1 KB, default=1024 KB, max=16384 KB)
          -v verbose messages

   and:   MB  = megabytes to read (MB = 1024*1024) or "all"
                The keyword "all" reads the entire disk/LUN
          DSF = fullpath to LUN device file or any directory


   Will run a dd read test on the raw device or directory (lvol)
   and report performance.  Optionally write the results to a logfile.

It is useful to see the effects of interlacing either at the LVM lavel or through a Smart Array.

#!/usr/bin/sh

#######################
#                     #
#   D I S K P E R F   #
#                     #
#######################


# Simple dd tests of a raw disk device or lvol

# Date       By    What
###########  ##### #########################################################
# 2015.0804  blh   Fixed error when bdf line is split
# 2015.0504  blh   Warn that diskperf doesn't run in an SRP container
# 2015.0424  blh   Remove time from the dd line (errmo and stderr lost)
#                  Report using $SECONDS and stderr
# 2014.0711  blh   Added directory as input
# 2014.0422  blh   Added ability to specify alternate disk types as iSCSI or
#                  VG components such as lvols. Script will verify raw.
#                  Basename only has been dropped - requires fullpath
#                  Moved timestamp on results to VERBOSE only
#                  Added -a to always append to the log
# 2013.0628  blh   Added all keyword for a full dd of the disk
#                  Added -v for details
# 2011.0527  blh   Added recsize option
# 2008.0821  blh   Original version


set -u
export PATH=/usr/bin:/usr/sbin
MYNAME=${0##*/}
MYID=$(id -un)
tty -s                                          # Check if interactive
[[ $? -eq 0 ]] &&
   export MYTTY=true ||
   export MYTTY=false

TRACEME=${TRACEME:-false} # TRACEME non-null = trace on
[[ $TRACEME != false ]]  && set -x && PS4='[$LINENO]: '

RECSZKB=1024      # default records size in KB (ie, 1024 KB or 1 MB)
MAXRECSZKB=16384  # larger may exceed HP-UX buffers (rev dependent)

###############################################################
USAGETXT="
   Usage: $MYNAME [-l log] [-a] [-r <KB>] <MB> <DSF/lvol> [<DSF/lvol>... ]
   where: -l log file
          -a = always append to log, otherwise new log started
          -r <KB> where <KB> is a 1024 block
             (min=1 KB, default=$RECSZKB KB, max=$MAXRECSZKB KB)
          -v verbose messages

   and:   MB  = megabytes to read (MB = 1024*1024) or \"all\"
                The keyword \"all\" reads the entire disk/LUN
          DSF = fullpath to LUN device file or any directory


   Will run a dd read test on the raw device or directory (lvol)
   and report performance.  Optionally write the results to a logfile.

"
###############################################################



#########################
#   F U N C T I O N S   #
#########################

          ###########
          #  Usage  #
          ###########

function Usage
{
 # Minimum Usage function
 # Requires $USAGETXT to be assigned externally.
 #   Typically, this is done at the start of a script
 #   to act as both documentation and a Usage message

  TRACEME=${TRACEME:-false}      # TRACEME non-null = trace on
  [ $TRACEME != false ]  && set -x && PS4='[$LINENO]: '
  MYNAME=${MYNAME:-${0##*/}}

# If supplied, show an error message
  if [ $# -gt 0 ]
  then
     ERRMSG="$*"
     echo "\n$ERRMSG"
     WIDTH=${#ERRMSG}
     eval typeset -Z$WIDTH BAR=0
     echo "$BAR" | tr "0" "="
  fi

# Show the usage message - handle missing USAGETXT

  USAGETXT=${USAGETXT:-NotSet}
  [[ "$USAGETXT" = "NotSet" || "$USAGETXT" = "" ]] &&
     echo "\n$MYNAME: USAGETXT is null or not assigned" ||
     echo "$USAGETXT"
  exit 1
}

          ##############
          #   Indent   #
          ##############



function Indent
{

  TRACEME=${TRACEME:-false}   # TRACEME non-null = trace on
  [[ $TRACEME != false ]]  && set -x && PS4='[$LINENO]: '

# Indent multiple text lines
# Usage:
#   Indent "text" [ indent-num ]
# or
#   cat something | Indent "" [ indent-num ]
#
# Maintains leading spaces by changing IFS temporarily

# No text? Just return

   [[ "$1" = "" ]] && return


# If no indent-num, use 4 as a default

   [ $# -gt 1 ] && INDENT=$2 || INDENT=4

# $1 is the string to indent. Don't use $@ as $1
# could be multiple lines in 1 string
#
# But if "$1" = "" (null), then read from STDIN and use
#   "" (null string) as a placeholder when using the
#   optional indent value:
#
#        vgdisplay -v | Indent "" 6

  if [[ $# -eq 0 ]]
  then
     READTEXT="cat"           # stdin with no indent amount
  else
     [[ "$1" = "" ]] &&         # stdin with null text and indent amount
        READTEXT="cat" ||
        READTEXT="echo \"$1\""  # indent the $1 text
  fi

# To preserve leading white space with a read, change IFS to the null string,
#    then change back # because it is exported from the parent env.

  OLDIFS="$IFS"
  IFS=""

  eval "$READTEXT" | while read TEXT
  do
    eval "typeset -R$INDENT SPACES=' '"
    echo "$SPACES$TEXT"
  done


 # Always put back the original IFS

  IFS="$OLDIFS"

  return
}

          #################
          #  MakeBDFLIST  #
          #################

function MakeBDFLIST
{

## run bdf with a specific directory location, or nothing for a complete list
## The exported variable BDFLIST contains the result

TRACEME=${TRACEME:-false} # TRACEME non-null = trace on
[[ $TRACEME != false ]]  && set -x && PS4='[$LINENO]: '

 [[ $# -eq 0 ]] && MNTPNT="" || MNTPNT="$1"
 export BDFLIST="$(bdf -l "$MNTPNT" 2>/dev/null | while read FS TOT USED AVAIL PERCENT MNT
 do
    if [ $FS != "Filesystem" ]                       # skip header
    then
       if [ "$TOT" = "" ]                            # check for split lines
       then
          read TOT USED AVAIL PERCENT MNT
       fi
       echo  $FS $TOT $USED $AVAIL $PERCENT $MNT     # single line result
    fi
 done)"

 return

}

########################################################################
# M A I N   P R O G R A M
########################################################################

## bailout if inside an SRP container

if [[ -r /opt/hpsrp/bin/srp_env ]]
then
   SRPTEXT="$(/opt/hpsrp/bin/srp_env 2>&1)"
   RTN=$?
   if [[ $RTN -eq 0 ]]
   then
      if [[ $(echo "$SRPTEXT" | grep -c -i "enabled") -eq 0 ]]
      then
         if [[ "$(echo "$SRPTEXT" | awk '/^type:/{print $NF}')" != global ]]
         then
            echo "\n($MYNAME not supported inside an SRP container)\n"
            exit 1
         fi
      fi
   fi
fi


[[ $# -eq 0 ]] &&
   CMDLINE="$(whence $0)" ||
   CMDLINE="$(whence $0) $@"

RESULTSLOG="/dev/null"          # This way, everything is sent to the log
APPEND=false                    # start new log
VERBOSE=false

# Look for optional logfile and recsize
########################################

while getopts ":al:r:v" OPTCHR
do
  case $OPTCHR in
    a) APPEND=true
       ;;
    l) RESULTSLOG="$OPTARG"
       ;;
    r) RECSZKB="$OPTARG"
       ;;
    v) VERBOSE=true
       ;;
    *) eval "ERROPT=\$$(($OPTIND-1))"
       Usage "Invalid option: $ERROPT"
       ;;
  esac
done
shift $(($OPTIND -1))

# Validity checks
#####################################

[[ $# -lt 2 ]] &&
   Usage "Requires MB (or all) and at least one DSF"

MEGS=$1

if [[ "$MEGS" != "all" && "$MEGS" != "ALL" ]]
then
   [[ $(print -n $MEGS | tr -d '[:digit:]' | wc -c) -gt 0 ]] &&
      Usage "MB ($MEGS) is not a number"
   [[ $MEGS -lt 5 ]] &&
      Usage "MB must be 5 or larger"
else
   MEGS=ALL
fi

# Validate record size option

[[ $(print -n $RECSZKB | tr -d '[:digit:]' | wc -c) -gt 0 ]] &&
   Usage "KB recsize is not a number"

[[ $RECSZKB -lt 1 || $RECSZKB -gt 16384 ]] &&
   Usage "Invalid record size ($RECSZKB)"


shift 1

## Logfile setup

touch $RESULTSLOG
RTN=$?
[[ $RTN -ne 0 ]] && Usage "$RESULTSLOG logfile not writable by $MYID"
[[ $APPEND = false ]] && cat /dev/null > $RESULTSLOG

echo "==================================================" >> $RESULTSLOG

[[ $VERBOSE = true ]] &&
   TEEORNOT=" | tee -a $RESULTSLOG" ||
   TEEORNOT=" >> $RESULTSLOG"

eval echo "$(date)" $TEEORNOT

# Always show command line when logging, and only stdout when VERBOSE

eval echo "CMD: $CMDLINE" $TEEORNOT

## Loop through each device
## Fullpath LUN names are normalized to the raw device
## Directories are translated to the rlvol name
## NFS/CDFS locations are rejected

## Make a bdf list of 1-liners

for SOURCEDEV in $@
do
   case $SOURCEDEV in
      /dev/d*sk/*)              ## block devicefile
         DSKDEV=$(echo $SOURCEDEV | awk -F/ '{print "/dev/r"$3"/"$4}')
         ;;
      /dev/rd*sk/*)             ## raw devicefile
         DSKDEV=$SOURCEDEV
         ;;
      *) if [[ -d $SOURCEDEV ]] ## must be a directory
         then

# Handle split line bdf

            MakeBDFLIST $SOURCEDEV
            SOURCE="$(echo $BDFLIST | awk '{print $1}')"
            RTN=$?
            if [[ $RTN -ne 0 ]]
            then
               echo "\n$SOURCEDEV is not a disk device or directory name\n" | tee -a $RESULTSLOG
               break
            else
               if [[ "$(bdf -l $SOURCEDEV 2>&1)" = "" ]]
               then
                  echo "\n$SOURCEDEV is a network filesystem, cannot test.\n" | tee -a $RESULTSLOG
                  break
               fi
               DSKDEV=$(echo $SOURCE | awk -F/ '{print "/dev/"$3"/r"$4}')
            fi
         else
            echo "$SOURCEDEV is not disk device or directory name\n" | tee -a $RESULTSLOG
            break
         fi
         ;;
   esac

## The DSKDEV is a raw LUN or raw lvol now
## An lvol returns nothing from lssf if it exists

   DISKTYPE=""
   LSSF="$(lssf $DSKDEV 2>&1)"
   if [[ "$LSSF" != "" ]]
   then


# DSKDEV is a LUN
# Is the h/w connected?

      if [[ $(echo "$LSSF" | grep -c '???') -ne 0 ]]
      then
         echo "$DSKDEV: is in NO_HW state" | tee -a $RESULTSLOG
         continue
      fi

# How big is this disk?

      DISKSTAT=$(diskinfo $DSKDEV 2>&1)
      RTN=$?
      if [[ $RTN -ne 0 ]]
      then
         echo "$DSKDEV failed diskinfo\n$(Indent "$DISKSTAT")" | tee -a $RESULTSLOG
         continue
      fi
      DISKTYPE="$(echo "$DISKSTAT" | awk '/type: /{print $NF}')"
      DISKSIZEKB="$(echo "$DISKSTAT" | awk '/size:/{print $2}')"
      [[ $VERBOSE = true ]] &&
         echo "==> diskinfo $DSKDEV:\n$(Indent "$DISKSTAT")" | tee -a $RESULTSLOG

# logical volume - only LVM for now
# If non-standard names are used, the read-entire-disk option won't work
# DSKDEV is raw lvol here

   else
      DIRNAME=${DSKDEV%/*}
      BASENAME=${DSKDEV##*/}
      BLOCKNAME="$(echo "$BASENAME" | cut -c2-)"
      if [[ ! -b $DIRNAME/$BLOCKNAME && $MEGS = all ]]
      then
         echo "For $DSKDEV, block device $DIRNAME/$BLOCKNAME not found\n\"all\" megs not available" |
                tee -s $RESULTSLOG
         break
      else
         [[ $MEGS = ALL ]] &&
            MEGS=$(lvdisplay $DIRNAME/$BLOCKNAME | awk '/LV Size/{print $4}')
      fi
   fi

# run a short dd test to see if the device is readable
######################################################

   dd if=$DSKDEV of=/dev/null bs=1024 count=1 >/dev/null 2>&1
   RTN=$?

   if [[ $RTN -ne 0 ]]
   then
      [[ "$DISKTYPE" = "" ]] && DT="" || DT=" (type=$DISKTYPE)"
      echo "$DSKDEV:$DT not readable, skipping"  | tee -a $RESULTSLOG
      continue
   fi

# Compute size of disk if MEGS=ALL and adjust record count

   if [[ "$MEGS" = "ALL" ]]
   then
      RECCOUNT=$(($DISKSIZEKB/$RECSZKB))
      [[ $VERBOSE = true ]] &&
         echo "==> Read entire disk $DSKDEV" | tee -a $RESULTSLOG
   else
      RECCOUNT=$(($MEGS*1024/$RECSZKB))
   fi
   TOTALTOREAD=$(($RECCOUNT*$RECSZKB/1024))
   [[ $VERBOSE = true ]] &&
      echo "==> RecSZ=${RECSZKB}KB count=$RECCOUNT total=${TOTALTOREAD} MB" | tee -a $RESULTSLOG

# busy prompt

   if [[ $MYTTY = true ]]
   then
      echo "...reading $DSKDEV, $MEGS MB...\r\c"
   fi

## Run the full dd test
#######################

#  SECS=$(time dd if=$DSKDEV of=/dev/null bs=${RECSZKB}k count=$RECCOUNT 2>&1 \
#         | awk '/real/ {print $2}')

   SECONDS=0
   TXT="$(dd if=$DSKDEV of=/dev/null bs=${RECSZKB}k count=$RECCOUNT 2>&1)"
   RTN=$?
   SECS=$SECONDS

   if [[ $RTN -ne 0 ]]
   then
      echo "\n$DSKDEV read error has occurred"  | tee -a $RESULTSLOG
      Indent "$TXT" | tee -a $RESULTSLOG
      continue
   fi

# Handle a very short elapsed time (0 secs) as a special case to avoid
#  divide by zero

   if [[ $SECS -eq 0 ]]
   then
     echo "$DSKDEV elapsed time = 0 secs, increase data size"  | tee -a $RESULTSLOG
     continue
   fi

   MBS=$(echo "scale=1;$RECSZKB*$RECCOUNT/1024/$SECS" | bc)
   MYDATE=$(date '+%Y%m%d.%H%M%S')

# Show the results
##################

   [[ $VERBOSE = true ]] &&
      STATMSG="$MYDATE " ||
      STATMSG=""
   echo "${STATMSG}$DSKDEV: read ${MEGS} MB in $SECS secs ($RECCOUNT recs @ ${RECSZKB} KB) = ${MBS} MB/sec" |
        tee -a $RESULTSLOG
done

Tested on HP-UX 10.20 through 11.31.



Bill Hassell, sysadmin
Rudolf Fischer
Advisor

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

Hi Torsten,

I have checked all the patches between the HP rp3440 and the HP rp8420 and all the patches or their successors are installed. Patching seems not to be the issue.

Best regards,

Rudolf Fischer

Rudolf Fischer
Advisor

Re: rp8420: scsictl shows bus speed at 160 MB/s and Negotiated Target Values at 40 MB/s

Hi Bill,

many thanks for your diskperf script. I have tested that on the HP rp3440 where the Ultra160 SCSI bus is working normally. The read speed is constantly at 128 MB/sec. After that, I moved this disk to the HP rp8420 and diskperf shows a read speed from about 36 MB/sec. This is not a disk issue. It must have something to do with the SCSI bus.

Best regards,

Rudolf Fischer