On 2020-08-03 09:36, ToddAndMargo via users wrote:
> On 2020-08-02 18:26, Samuel Sieb wrote:
>> On 8/2/20 6:22 PM, ToddAndMargo via users wrote:
>>> I am not after what the gateway address is, but rather
>>>
>>> 1) if gateway is up or not
>>
>> That can only be determined by pinging it or something past it.
>
> That is one way of doing it, but it gives a lot
> more information than I want.  It tell me the
> Internet is working.  I am not testing that.
>
> I only want to know if the device is connected to the
> gateway and the gateway is up.

So, ping the gateway?

>
>>
>>> 2) if my device connected to the gateway that is up
>>
>> Since you should know which interface goes to the gateway, why isn't it 
>> enough to check if the interface is connected?
>
> I am setting up my iptables so it is universal.  This
> is only one of about 15 parameters I read from the
> system.
>

Define "connected to".  If by mean "accessible" then a ping or may do.  That is 
assuming the gateway
is configured to respond to pings.  "Connected" usually means a connection is 
established.  As in an
ssh session.


-- 
The key to getting good answers is to ask good questions.
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org

Reply via email to