Sponsored Content
Top Forums UNIX for Advanced & Expert Users Unable to ping default gateway Post 302992667 by Junaid Subhani on Tuesday 28th of February 2017 11:51:21 AM
Old 02-28-2017
Wrench Unable to ping default gateway

I have setup a Linux machine on my server but for some reason Im unable to reach my default gateway. This is causing me to not communicate with the outside world (unable to connect to CentOS repos)

Code:
[root@localhost init.d]# ifconfig 
enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 142.133.50.11  netmask 255.255.252.0  broadcast 142.133.51.255
        inet6 fe80::a00:27ff:fec2:f9b5  prefixlen 64  scopeid 0x20<link>
        ether 08:00:27:c2:f9:b5  txqueuelen 1000  (Ethernet)
        RX packets 19699  bytes 1668673 (1.5 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 611  bytes 44086 (43.0 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

Code:
[root@localhost init.d]# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         142.133.48.1    0.0.0.0         UG    0      0        0 enp0s3
142.133.48.0    0.0.0.0         255.255.252.0   U     0      0        0 enp0s3
169.254.0.0     0.0.0.0         255.255.0.0     U     1002   0        0 enp0s3
169.254.0.0     0.0.0.0         255.255.0.0     U     1003   0        0 enp0s8
172.16.16.0     0.0.0.0         255.255.255.0   U     0      0        0 enp0s8
192.168.122.0   0.0.0.0         255.255.255.0   U     0      0        0 virbr0

Now the default gateway here is 142.133.48.1 and it falls under my network.

Code:
142.133.48.0/22

Address:   142.133.48.0          10001110.10000101.001100 00.00000000
Netmask:   255.255.252.0 = 22    11111111.11111111.111111 00.00000000
Wildcard:  0.0.3.255             00000000.00000000.000000 11.11111111
=>
Network:   142.133.48.0/22       10001110.10000101.001100 00.00000000 (Class B)
Broadcast: 142.133.51.255        10001110.10000101.001100 11.11111111
HostMin:   142.133.48.1          10001110.10000101.001100 00.00000001
HostMax:   142.133.51.254        10001110.10000101.001100 11.11111110
Hosts/Net: 1022

But I cannot ping it.

Code:
[root@localhost init.d]# ping -c 1 142.133.48.1
PING 142.133.48.1 (142.133.48.1) 56(84) bytes of data.
From 142.133.50.11 icmp_seq=1 Destination Host Unreachable

--- 142.133.48.1 ping statistics ---
1 packets transmitted, 0 received, +1 errors, 100% packet loss, time 0ms

Firewall and iptables is off. So I have no idea what else might be wrong here.
 

10 More Discussions You Might Find Interesting

1. IP Networking

Unable to ping the gateway IP itself

We are unable to bring one of our linux boxes into the network once it was restarted. But once we stop and start the network service. We are able to ping the gateway and get into network. After a minute or two we get the following reponse for the ping command 64 bytes from 124.168.215.40:... (6 Replies)
Discussion started by: chrisanto_2000
6 Replies

2. IP Networking

Multihomed can not ping gateway

Hello this is my first post at this forum. Apologize for my lack of network understanding but Im posting to learn. I have a problem reaching default gateway 10.18.110.1 If I use my laptop I can ping 10.18.110.1 but with our red hat multihomed server the gateway does not respond to ping. cat... (11 Replies)
Discussion started by: vettec3
11 Replies

3. Solaris

ping -s to default gateway very slow

I was install new solaris10 on m4000 model after that i "ping -s" to default gateway but it's take longtime (2 Min) to reply and if i use "ping" only it's reply to fase(2 sec). any body who can tell me about my problem and how to fix it please. i'm try to fix several days. (2 Replies)
Discussion started by: cesmk
2 Replies

4. AIX

Can not Ping Gateway

Hello, I am new to Unix :D and have been trying to configure an AIX server running 5.3. I used smitty or smit to configure interface 0 on the server. I am able to ping the IP I set, however I am still unable to ping the gateway. I configured the IP by navigating to Communications Applications... (6 Replies)
Discussion started by: cdub50
6 Replies

5. Red Hat

Cannot ping gateway

I know the subject line is very similar to: destination host unreachable but the problem with my machine appears to be somewhat different from that thread. apologies if I missed something from there. We recently moved a machine physically and from one subnet to another . I used... (1 Reply)
Discussion started by: mirage
1 Replies

6. UNIX for Dummies Questions & Answers

Cannot ping default gateway

I have NCR MP-RAS unix. I have been trying for several months to get our network working since we had never used it before. I have setup all routes that I can think of. I know it has something to do with the routing table, because out of sheer luck I was able to get it working, and than like a... (4 Replies)
Discussion started by: Rutgerncas
4 Replies

7. AIX

Cant ping default gateway aix 53 07 new install

I just reinstalled a fresh install of 5300 07 on an old 44p model 170, after installing I set an IP Address on en2 and I tried to the ping default gateway, no response. I tried a startsrc -g tcpip ... and then I can ping the default gateway. I broke the ping and tried again to ping. I cannot... (1 Reply)
Discussion started by: asyed123
1 Replies

8. Red Hat

Can not ping default gateway

Hi, Here is the issue: There are 2 identical systems in the same subnet here. They can ping and ssh each other. One can ping the default gateway and one can not with error '... icmp_seq Destination Host Unreachable'. I can't find any difference between the two systems in terms of network... (4 Replies)
Discussion started by: aixlover
4 Replies

9. AIX

Networking Issue (Cant Ping the gateway)

Hi, I installed AIX 7.1 on a blade though (hmc with vio). I can ping the IP address, but not the gateway. Is there anything that I should configure? Is there anything that I have to check with vio setting or Am I missing any configuration? Please let me know further. Thank you (5 Replies)
Discussion started by: pjeedu2247
5 Replies

10. UNIX for Beginners Questions & Answers

Inconsistency between RedHat 6.5 global gateway and single gateway leads to loss of default gateway

Dear friends I use RedHat 6.5, which sets the gateway in the configuration file / etc / sysconfig / network as GATEWAY = 192.168.1.26, and the gateway in the configuration file / etc / sysconfig / network-scripts / ifcfg-eth11 as GATEWAY = 192.168.1.256. The two gateways are different.... (6 Replies)
Discussion started by: tanpeng
6 Replies
netmasks(4)							   File Formats 						       netmasks(4)

NAME
netmasks - network mask database SYNOPSIS
/etc/inet/netmasks /etc/netmasks DESCRIPTION
The netmasks file contains network masks used to implement IP subnetting. It supports both standard subnetting as specified in RFC-950 and variable length subnetting as specified in RFC-1519. When using standard subnetting there should be a single line for each network that is subnetted in this file with the network number, any number of SPACE or TAB characters, and the network mask to use on that network. Network numbers and masks may be specified in the conventional IP `.' (dot) notation (like IP host addresses, but with zeroes for the host part). For example, 128.32.0.0 255.255.255.0 can be used to specify that the Class B network 128.32.0.0 should have eight bits of subnet field and eight bits of host field, in addition to the standard sixteen bits in the network field. When using variable length subnetting, the format is identical. However, there should be a line for each subnet with the first field being the subnet and the second field being the netmask that applies to that subnet. The users of the database, such as ifconfig(1M), perform a lookup to find the longest possible matching mask. It is possible to combine the RFC-950 and RFC-1519 form of subnet masks in the net- masks file. For example, 128.32.0.0 255.255.255.0 128.32.27.0 255.255.255.240 128.32.27.16 255.255.255.240 128.32.27.32 255.255.255.240 128.32.27.48 255.255.255.240 128.32.27.64 255.255.255.240 128.32.27.80 255.255.255.240 128.32.27.96 255.255.255.240 128.32.27.112 255.255.255.240 128.32.27.128 255.255.255.240 128.32.27.144 255.255.255.240 128.32.27.160 255.255.255.240 128.32.27.176 255.255.255.240 128.32.27.192 255.255.255.240 128.32.27.208 255.255.255.240 128.32.27.224 255.255.255.240 128.32.27.240 255.255.255.240 128.32.64.0 255.255.255.192 can be used to specify different netmasks in different parts of the 128.32.0.0 Class B network number. Addresses 128.32.27.0 through 128.32.27.255 have a subnet mask with 28 bits in the combined network and subnet fields (often referred to as the subnet field) and 4 bits in the host field. Furthermore, addresses 128.32.64.0 through 128.32.64.63 have a 26 bits in the subnet field. Finally, all other addresses in the range 128.32.0.0 through 128.32.255.255 have a 24 bit subnet field. Invalid entries are ignored. SEE ALSO
ifconfig(1M), inet(7P) Postel, Jon, and Mogul, Jeff, Internet Standard Subnetting Procedure, RFC 950, Network Information Center, SRI International, Menlo Park, Calif., August 1985. V. Fuller, T. Li, J. Yu, K. Varadhan, Classless Inter-Domain Routing (CIDR): an Address Assignment and Aggregation Strategy, RFC 1519, Network Information Center, SRI International, Menlo Park, Calif., September 1993. T. Pummill, B. Manning, Variable Length Subnet Table For IPv4, RFC 1878, Network Information Center, SRI International, Menlo Park, Calif., December 1995. NOTES
/etc/inet/netmasks is the official SVr4 name of the netmasks file. The symbolic link /etc/netmasks exists for BSD compatibility. SunOS 5.10 7 Jan 1997 netmasks(4)
All times are GMT -4. The time now is 01:59 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy