title: Replace SNMP "Timeout: No Response from <IP_Address>" with Specific Text
body: <p>I have a script that queries OID details via SNMPWalk, the problem is when the certain IP (example is 172.20.36.8) is not reachable, it displays <code>Timeout: No Response from 172.20.36.8</code>. Is there a code that could replace that response from snmp query so that if it displays like that, I would like to appear the word "Idle" instead of that "Timeout:..."</p>
  
  <p>here is the part of the script that I am running:</p>
  
  <pre><code>for EACH in `echo $APIP`
    do
      SectorID=`$SNMPWALK -v2c -c Canopy ${EACH} ${SNMPOID}.1.1.16 | awk '{print $4}'
      ActiveSubs=`$SNMPWALK -v2c -c Canopy ${EACH} ${SNMPOID}.1.7.1 | awk '{print $4}'
      UniqueSubs=`$SNMPWALK -v2c -c Canopy ${EACH} ${SNMPOID}.1.7.18 | awk '{print $4}'
      printf "%s\t| %s\t| %s\t| %s\t|\n" "${EACH}" "${SectorID}" "${ActiveSubs}" "${UniqueSubs}"
    done
  </code></pre>
  
  <p>Now here is the result of the said part of script</p>
  
  <pre><code>172.20.36.3     |   1   |      2        |      4        |
  172.20.36.4     |   2   |      5        |      8        |
  172.20.36.5     |   3   |      11       |      16       |
  Timeout: No Response from 172.20.36.6
  Timeout: No Response from 172.20.36.6
  Timeout: No Response from 172.20.36.6
  172.20.36.6     |       |               |      0        |
  172.20.36.7     |   5   |      0        |      1        |
  Timeout: No Response from 172.20.36.8
  Timeout: No Response from 172.20.36.8
  Timeout: No Response from 172.20.36.8
  172.20.36.8     |       |               |      0        |
  </code></pre>
  
  <p>when it reaches the ip address <code>.6</code> and <code>.8</code>, it displays <code>"Timeout: No Response..."</code>. I wanted somehow to display it like this if it encounters no response from the said ip address:</p>
  
  <pre><code>172.20.36.3     |   1   |      2        |      4        |
  172.20.36.4     |   2   |      5        |      8        |
  172.20.36.5     |   3   |      11       |      16       |
  172.20.36.6     |  Idle |     Idle      |     Idle      |
  172.20.36.7     |   5   |      0        |      1        |
  172.20.36.8     |  Idle |     Idle      |     Idle      |
  </code></pre>
  
  <p>can anyone out there that can help me to resolve this? I greatly appreciate your responses. :)</p>