[prev in list] [next in list] [prev in thread] [next in thread]
List: gpfsug-discuss
Subject: [gpfsug-discuss] =?utf-8?Q?=E2=80=94subblocks-per-full-block_?=in 5.0.1
From: Barry Evans <bevans () pixitmedia ! com>
Date: 2018-05-17 13:41:57
Message-ID: c3e437d8-874d-4ae5-a2fa-724000a2184a () Spark
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
Slight wonkiness in mmcrfs script that spits this out —subblocks-per-full-block as \
an invalid option.
No worky:
777 subblocks-per-full-block )
778 if [[ -z $optArg ]]
779 then
780 # The expected argument is not in the same string as its
781 # option name. Get it from the next token.
782 eval optArg="\${$OPTIND}"
783 [[ -z $optArg ]] && \
784 syntaxError "missingValue" $noUsageMsg "--$optName_lc"
785 shift 1
786 fi
787 [[ -n $subblocksPerFullBlockOpt ]] && \
788 syntaxError "multiple" $noUsageMsg "--$optName_lc"
789 subblocksPerFullBlockOpt="--$optName_lc"
790
791 nSubblocksArg=$(checkIntRange --subblocks-per-full-block \
$optArg 32 8192) 792 [[ $? -ne 0 ]] && syntaxError nomsg $noUsageMsg
793 tscrfsParms="$tscrfsParms --subblocks-per-full-block \
$nSubblocksArg" 794 ;;
Worky:
777 subblocks-per-full-block )
778 if [[ -z $optArg ]]
779 then
780 # The expected argument is not in the same string as its
781 # option name. Get it from the next token.
782 eval optArg="\${$OPTIND}"
783 [[ -z $optArg ]] && \
784 syntaxError "missingValue" $noUsageMsg "--$optName_lc"
785 shift 1
786 fi
787 #[[ -n $subblocksPerFullBlockOpt ]] && \
788 [[ -n $nSubblocksArg ]] && \
789 syntaxError "multiple" $noUsageMsg "--$optName_lc"
790 #subblocksPerFullBlockOpt="--$optName_lc"
791 nSubblocksArg="--$optName_lc"
792
793 nSubblocksArg=$(checkIntRange --subblocks-per-full-block \
$optArg 32 8192) 794 [[ $? -ne 0 ]] && syntaxError nomsg $noUsageMsg
795 tscrfsParms="$tscrfsParms --subblocks-per-full-block \
$nSubblocksArg" 796 ;;
Looks like someone got halfway through the variable change "subblocksPerFullBlockOpt" \
is referenced elsewhere in the script:
if [[ -z $forceOption ]]
then
[[ -n $fflag ]] && \
syntaxError "invalidOption" $usageMsg "$fflag"
[[ -n $subblocksPerFullBlockOpt ]] && \
syntaxError "invalidOption" $usageMsg "$subblocksPerFullBlockOpt"
fi
...so this is probably naughty on my behalf.
Kind Regards,
Barry Evans
CTO/Co-Founder
Pixit Media Ltd
+44 7950 666 248
bevans@pixitmedia.com
--
<http://pixitmedia.com>
This email is confidential in that it is intended
for the exclusive attention of the addressee(s) indicated. If you are not
the intended recipient, this email should not be read or disclosed to any
other person. Please notify the sender immediately and delete this email
from your computer system. Any opinions expressed are not necessarily those
of the company from which this email was sent and, whilst to the best of
our knowledge no viruses or defects exist, no responsibility can be
accepted for any loss or damage arising from its receipt or subsequent use
of this email.
[Attachment #5 (text/html)]
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
</head>
<body>
<div name="messageBodySection" style="font-size: 14px; font-family: -apple-system, \
BlinkMacSystemFont, sans-serif;">Slight wonkiness in mmcrfs script that spits this \
out —subblocks-per-full-block as an invalid option. <div><br /></div>
<div>No worky:<br />
<div><br /></div>
<div>
<div><font face="Courier">    777         \
subblocks-per-full-block )</font></div> <div><font face="Courier">    778 \
          if [[ -z $optArg ]]</font></div> <div><font \
face="Courier">    779           then</font></div> \
<div><font face="Courier">    780             \
# The expected argument is not in the same string as its</font></div> <div><font \
face="Courier">    781             # option \
name.  Get it from the next token.</font></div> <div><font face="Courier">  \
  782             eval \
optArg="\${$OPTIND}"</font></div> <div><font face="Courier">    783   \
          [[ -z $optArg ]] &&  \</font></div> \
<div><font face="Courier">    784             \
  syntaxError "missingValue" $noUsageMsg "--$optName_lc"</font></div> <div><font \
face="Courier">    785             shift \
1</font></div> <div><font face="Courier">    786       \
    fi</font></div> <div><font face="Courier">    787   \
        [[ -n $subblocksPerFullBlockOpt ]] && \
 \</font></div> <div><font face="Courier">    788       \
      syntaxError "multiple" $noUsageMsg "--$optName_lc"</font></div> \
<div><font face="Courier">    789           \
subblocksPerFullBlockOpt="--$optName_lc"</font></div> <div><font \
face="Courier">    790</font></div> <div><font face="Courier">    \
791           nSubblocksArg=$(checkIntRange \
--subblocks-per-full-block $optArg 32 8192)</font></div> <div><font \
face="Courier">    792           [[ $? -ne 0 ]] \
&& syntaxError nomsg $noUsageMsg</font></div> <div><font \
face="Courier">    793           \
tscrfsParms="$tscrfsParms --subblocks-per-full-block $nSubblocksArg"</font></div> \
<div><font face="Courier">    794           \
;;</font></div> </div>
</div>
<div><br /></div>
<div>Worky:</div>
<div><br /></div>
<div><br /></div>
<div>
<div><font face="Courier">    777         \
subblocks-per-full-block )</font></div> <div><font face="Courier">    778 \
          if [[ -z $optArg ]]</font></div> <div><font \
face="Courier">    779           then</font></div> \
<div><font face="Courier">    780             \
# The expected argument is not in the same string as its</font></div> <div><font \
face="Courier">    781             # option \
name.  Get it from the next token.</font></div> <div><font face="Courier">  \
  782             eval \
optArg="\${$OPTIND}"</font></div> <div><font face="Courier">    783   \
          [[ -z $optArg ]] &&  \</font></div> \
<div><font face="Courier">    784             \
  syntaxError "missingValue" $noUsageMsg "--$optName_lc"</font></div> <div><font \
face="Courier">    785             shift \
1</font></div> <div><font face="Courier">    786       \
    fi</font></div> <div><font face="Courier">    787   \
        #[[ -n $subblocksPerFullBlockOpt ]] && \
 \</font></div> <div><font face="Courier">    788       \
    [[ -n $nSubblocksArg  ]] &&  \</font></div> \
<div><font face="Courier">    789             \
syntaxError "multiple" $noUsageMsg "--$optName_lc"</font></div> <div><font \
face="Courier">    790           \
#subblocksPerFullBlockOpt="--$optName_lc"</font></div> <div><font \
face="Courier">    791           \
nSubblocksArg="--$optName_lc"</font></div> <div><font face="Courier">    \
792</font></div> <div><font face="Courier">    793       \
    nSubblocksArg=$(checkIntRange --subblocks-per-full-block $optArg 32 \
8192)</font></div> <div><font face="Courier">    794       \
    [[ $? -ne 0 ]] && syntaxError nomsg $noUsageMsg</font></div> \
<div><font face="Courier">    795           \
tscrfsParms="$tscrfsParms --subblocks-per-full-block $nSubblocksArg"</font></div> \
<div><font face="Courier">    796           \
;;</font></div> </div>
<div><br /></div>
<div>Looks like someone got halfway through the variable change "<span \
style="font-family: Courier;">subblocksPerFullBlockOpt" </span><font \
face="Arial">is referenced elsewhere in the script:</font></div> <div><font \
face="Arial"><br /></font></div> <div>
<div><font face="Courier">if [[ -z $forceOption ]]</font></div>
<div><font face="Courier">then</font></div>
<div><font face="Courier">  [[ -n $fflag ]] &&  \</font></div>
<div><font face="Courier">    syntaxError "invalidOption" $usageMsg \
"$fflag"</font></div> <div><font face="Courier">  [[ -n \
$subblocksPerFullBlockOpt ]] &&  \</font></div> <div><font \
face="Courier">    syntaxError "invalidOption" $usageMsg \
"$subblocksPerFullBlockOpt"</font></div> <div><font face="Courier">fi</font></div>
</div>
<div><br /></div>
<div><font face="Arial">...so this is probably naughty on my behalf.</font></div>
<div><span style="font-family: Courier;"><br /></span></div>
<div><span style="font-family: Courier;"><br /></span></div>
</div>
<div name="messageSignatureSection" style="font-size: 14px; font-family: \
-apple-system, BlinkMacSystemFont, sans-serif;"><br /> Kind Regards,
<div>Barry Evans</div>
<div>CTO/Co-Founder</div>
<div>Pixit Media Ltd</div>
<div>+44 7950 666 248</div>
<div>bevans@pixitmedia.com</div>
<div><br /></div>
<div><br /></div>
</div>
</body>
</html>
<br>
<div><a href="http://pixitmedia.com" target="_blank"><img \
src="http://pixitmedia.com/sig/sig-bve2018.jpg"></a><font face="Arial, Helvetica, \
sans-serif" size="1"><br>This email is confidential in that it is intended for the \
exclusive attention of the addressee(s) indicated. If you are not the intended \
recipient, this email should not be read or disclosed to any other person. Please \
notify the sender immediately and delete this email from your computer system. Any \
opinions expressed are not necessarily those of the company from which this email was \
sent and, whilst to the best of our knowledge no viruses or defects exist, no \
responsibility can be accepted for any loss or damage arising from its receipt or \
subsequent use of this email.</font></div>
_______________________________________________
gpfsug-discuss mailing list
gpfsug-discuss at spectrumscale.org
http://gpfsug.org/mailman/listinfo/gpfsug-discuss
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic