ifconfig and discovering the default Gateway? {Solved}

Booting, installing, newbie
Post Reply
Message
Author
User avatar
Dookus
Posts: 47
Joined: Tue 15 Mar 2011, 05:53
Location: now living in wonderful Stanmore, inner western suburb of Sydney Australia, where the sun shines nic

ifconfig and discovering the default Gateway? {Solved}

#1 Post by Dookus »

I'm trying to find with ifconfig the correct command to find all the adapter(s) and the default gateway, have tried ifconfig -a which shows all the info on the local adapter(s), how do you discover the default gateways IP? as you do with the string "ipconfig /all" in windows?

Lucid Puppy 520
Last edited by Dookus on Tue 19 Apr 2011, 12:57, edited 1 time in total.

User avatar
Ian
Official Dog Handler
Posts: 1234
Joined: Wed 04 May 2005, 12:00
Location: Queensland

#2 Post by Ian »

In Puppy.

Open a terminal and type in:

route -n

this should give you a couple of rows of info with headings:

Destination Gateway Genmask Flags Metric Ref Use Iface

the second row should have your gateway address.

User avatar
CatDude
Posts: 1563
Joined: Wed 03 Jan 2007, 17:49
Location: UK

#3 Post by CatDude »

Hello Dookus
Dookus wrote:...how do you discover the default gateways IP?
You could try this:

Code: Select all

route -n
That will give you something like this: (only formatted better :roll: )

Code: Select all

# 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     0      0        0 eth0
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 eth0
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0 lo
0.0.0.0         192.168.1.254   0.0.0.0         UG    0      0        0 eth0
Or, if you want to get the name of the gateway
do this:

Code: Select all

route
That will give you something like this: (only formatted better :roll: )

Code: Select all

# route   
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
169.254.0.0     *               255.255.0.0     U     0      0        0 eth0
127.0.0.0       *               255.0.0.0       U     0      0        0 lo
default         BThomehub.home  0.0.0.0         UG    0      0        0 eth0

For more information regarding route
enter the following command:

Code: Select all

man route
Or click here :wink:

Hope that helps
CatDude
.
[img]http://www.smokey01.com/CatDude/.temp/sigs/acer-futile.gif[/img]

User avatar
Dookus
Posts: 47
Joined: Tue 15 Mar 2011, 05:53
Location: now living in wonderful Stanmore, inner western suburb of Sydney Australia, where the sun shines nic

ifconfig and discovering the default Gateway?

#4 Post by Dookus »

Thanks guys, that's the stuff I had not found while reading the PDF I had downloaded.

This is the friendliest forum on the web
cheers
J

User avatar
Béèm
Posts: 11763
Joined: Wed 22 Nov 2006, 00:47
Location: Brussels IBM Thinkpad R40, 256MB, 20GB, WiFi ipw2100. Frugal Lin'N'Win

#5 Post by Béèm »

Dookus,

For the sake of fellow posters, could you edit the subject of your initial post and add [SOLVED] to the end?
Time savers:
Find packages in a snap and install using Puppy Package Manager (Menu).
[url=http://puppylinux.org/wikka/HomePage]Consult Wikka[/url]
Use peppyy's [url=http://wellminded.com/puppy/pupsearch.html]puppysearch[/url]

Post Reply