Re: What on Centos is wiping out my eth0 IP address every 5 minutes?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On 07/24/2013 12:51 AM, Rock wrote:
> On Wed, 24 Jul 2013 01:09:29 -0400, Darr247 wrote:
>
>> I inferred you wanted to make the laptop talk to the ubiquiti 
>> nano through the RJ45 port in order to configure it.
> Well, that is a necessary evil, so, yes, that is the first step, 
> to configure it.
>
> But, I'll take up that configuration elsewhere, as that's not a
> CentOS issue per se. 
>
> Right now, I only want to know what to set the gateway to, as that
> is somewhat of a CentOS issue (regarding how it's set anyway).
>
> When my Centos laptop (192.168.1.3) is connected wirelessly to my 
> home network (192.168.1.x), on wlan0, the following is seen on Centos:
> $ ifconfig wlan0
> => wlan0 Link encap:Ethernet HWaddr 0A:2B:DC:7D:8E:AF
> => inet addr:192.168.1.3 Bcast:192.168.1.255 Mask:255.255.255.0
> => etc.
>
> The gateway is apparently set to the home broadband router IP 
> address (192.168.1.1):
> $ route -n
> => Kernel IP routing table
> => Destination Gateway Genmask Flags Metric Ref Use Iface
> => 192.168.1.0 0.0.0.0 255.255.255.0 U 2 0 0 wlan0
> => 0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 wlan0
> Where the gateway is 192.168.1.1 and it's up (U) and it's a gateway (G).
>
> This command confirms the current gateway, when acting through wlan0, 
> is 192.168.1.1 (which is the Netgear N600 broadband router):
> $ route (or netstat -r):
> => Kernel IP routing table
> => Destination Gateway Genmask Flags Metric Ref Use Iface
> => 192.168.1.0 * 255.255.255.0 U 2 0 0 wlan0
> => default 192.168.1.1 0.0.0.0 UG 0 0 0 wlan0
>
> I think this shows similar information:
> $ ip route show
> => 192.168.1.0/24 dev wlan0 proto kernel scope link src 192.168.1.3 metric 2
> => default via 192.168.1.1 dev wlan0 proto static
>
> And, I must have edited the gateway in the past, because of this comment:
> $ cat /etc/sysconfig/network
> NETWORKING=yes
> HOSTNAME=rock
> #GATEWAY=192.168.1.1
>
> Given that the Centos Network Manager requires a gateway in its GUI, 
> I'm wondering if I should use a gateway of the Nanobridge M2 (192.168.1.20)
> or a gateway of my N600 broadband router (192.168.1.1).
>
> PS: I really do not understand what a gateway is. :(

A default gateway is the IP address of the device that routes traffic
out of the current subnet that the computer is on.  On a home network,
it is usually the router that connects to the Internet.

In any network subnet, a default gateway is required to talk to any
other subnet ... this is not a CentOS thing, it is a TCP/IP thing.

If you can ping 192.168.1.1 from your current location once you assign
an IP address of 192.168.1.x to the computer, then you would use
192.168.1.1 as the gateway.  You can look at any other device that is on
the current network that talks to the outside world and see what it's
default gateway is and use that on a manual setup.

You will also need to assign a valid DNS server (or servers) to the
device as well.  If you do any local name lookups and if there is a
local DNS server, then you have to use that.  If you do not need to look
up local names, you can use 8.8.8.8 and 8.8.4.4 as DNS servers (those
are DNS servers provided by Google and usually fast from everywhere).

This guide explains routing and subnets:

http://www.eventhelix.com/realtimemantra/networking/ip_routing.htm#.Ue_QrdfKNvs




Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux