Public bug reported:

NOTE: this bug report is for the package iputils-ping, but the website did not 
let me enter that:
$ dpkg-query -S /bin/ping
iputils-ping: /bin/ping
$ dpkg-query -l iputils-ping
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-===============================================
ii  iputils-ping   3:20211215-1 amd64        Tools to test the reachability of 
network hosts
$

This is on 22.04 (Jammy Jellyfish), but the bug is also present in 20.04
(Focal Fossa)


The deadline option is documented to exit on receiving an ICMP error:

       -w deadline
           Specify a timeout, in seconds, before ping exits regardless of how 
many packets have been sent or received. In this case ping does not stop after 
count packet are sent, it waits
           either for deadline expire or until count probes are answered or for 
some error notification from network.

However, it exits too when a redirect is received, which is not an
error. This make it useless for liveness probes when a redirect occurs.


$ ping -w 2 strange.soleus.nu
PING strange.soleus.nu (94.142.246.148) 56(84) bytes of data.
>From hv02.rtij.nl (10.0.2.4) icmp_seq=1 Redirect Host(New nexthop: lte.rtij.nl 
>(10.0.0.137))

--- strange.soleus.nu ping statistics ---
1 packets transmitted, 0 received, +1 errors, 100% packet loss, time 0ms
$

Note that the -c <n> option suffers from the same problem.

This does not happen in 18.04 (Bionic Beaver), which shows the expected
behaviour:

martijn@popeye:~$ ping -w 2 strange.soleus.nu
PING strange.soleus.nu (94.142.246.148) 56(84) bytes of data.
>From hv02.rtij.nl (10.0.2.4): icmp_seq=1 Redirect Host(New nexthop: 
>lte.rtij.nl (10.0.0.137))
64 bytes from strange.soleus.nu (94.142.246.148): icmp_seq=1 ttl=53 time=47.9 ms

--- strange.soleus.nu ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 47.908/47.908/47.908/0.000 ms
martijn@popeye:~$ grep VERSION /etc/os-release
VERSION="18.04.6 LTS (Bionic Beaver)"
VERSION_ID="18.04"
VERSION_CODENAME=bionic
martijn@popeye:~$ dpkg-query -S /bin/ping
iputils-ping: /bin/ping
martijn@popeye:~$

** Affects: iputils (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to iputils in Ubuntu.
https://bugs.launchpad.net/bugs/1972897

Title:
  redirect seen as error

Status in iputils package in Ubuntu:
  New

Bug description:
  NOTE: this bug report is for the package iputils-ping, but the website did 
not let me enter that:
  $ dpkg-query -S /bin/ping
  iputils-ping: /bin/ping
  $ dpkg-query -l iputils-ping
  Desired=Unknown/Install/Remove/Purge/Hold
  | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
  |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
  ||/ Name           Version      Architecture Description
  
+++-==============-============-============-===============================================
  ii  iputils-ping   3:20211215-1 amd64        Tools to test the reachability 
of network hosts
  $

  This is on 22.04 (Jammy Jellyfish), but the bug is also present in
  20.04 (Focal Fossa)

  
  The deadline option is documented to exit on receiving an ICMP error:

         -w deadline
             Specify a timeout, in seconds, before ping exits regardless of how 
many packets have been sent or received. In this case ping does not stop after 
count packet are sent, it waits
             either for deadline expire or until count probes are answered or 
for some error notification from network.

  However, it exits too when a redirect is received, which is not an
  error. This make it useless for liveness probes when a redirect
  occurs.

  
  $ ping -w 2 strange.soleus.nu
  PING strange.soleus.nu (94.142.246.148) 56(84) bytes of data.
  From hv02.rtij.nl (10.0.2.4) icmp_seq=1 Redirect Host(New nexthop: 
lte.rtij.nl (10.0.0.137))

  --- strange.soleus.nu ping statistics ---
  1 packets transmitted, 0 received, +1 errors, 100% packet loss, time 0ms
  $

  Note that the -c <n> option suffers from the same problem.

  This does not happen in 18.04 (Bionic Beaver), which shows the
  expected behaviour:

  martijn@popeye:~$ ping -w 2 strange.soleus.nu
  PING strange.soleus.nu (94.142.246.148) 56(84) bytes of data.
  From hv02.rtij.nl (10.0.2.4): icmp_seq=1 Redirect Host(New nexthop: 
lte.rtij.nl (10.0.0.137))
  64 bytes from strange.soleus.nu (94.142.246.148): icmp_seq=1 ttl=53 time=47.9 
ms

  --- strange.soleus.nu ping statistics ---
  1 packets transmitted, 1 received, 0% packet loss, time 0ms
  rtt min/avg/max/mdev = 47.908/47.908/47.908/0.000 ms
  martijn@popeye:~$ grep VERSION /etc/os-release
  VERSION="18.04.6 LTS (Bionic Beaver)"
  VERSION_ID="18.04"
  VERSION_CODENAME=bionic
  martijn@popeye:~$ dpkg-query -S /bin/ping
  iputils-ping: /bin/ping
  martijn@popeye:~$

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/iputils/+bug/1972897/+subscriptions


-- 
Mailing list: https://launchpad.net/~desktop-packages
Post to     : desktop-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~desktop-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to