LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking > Linux - Wireless Networking
User Name
Password
Linux - Wireless Networking This forum is for the discussion of wireless networking in Linux.

Notices


Reply
  Search this Thread
Old 10-18-2004, 09:03 PM   #1
robotik
LQ Newbie
 
Registered: Oct 2004
Posts: 2

Rep: Reputation: 0
Adding a gateway


Hi

i m very new at all this but i have my D-link card up and recognized as ath0, haven t figured out dhcp yet but i can assign an ip + subnet mask manually but i m still getting a 0.0.0.0 for the gateway.
i can reach my wireless router , but not the internet.
how could i add a gateway of 192.168.2.1 to my ath0 wireless device?

thanks
 
Old 10-18-2004, 11:32 PM   #2
masand
LQ Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 69
hi there

if u using redhat/fedora then run

setup

go to network settings and specify ur gateway there

or u can edit ur
/etc/sysconfig/network-scripts/ifcfg-eth0 script to specify the gateway

i do not have the porper syntax for that now woth me

also check for firewall settings on ur DHCP server

can u ping that machine?

regards

Last edited by masand; 10-18-2004 at 11:35 PM.
 
Old 10-19-2004, 03:13 AM   #3
darkleaf
Senior Member
 
Registered: Jun 2004
Location: the Netherlands
Distribution: debian SID
Posts: 2,170

Rep: Reputation: 45
Command line:
Code:
route add default gw 0.0.0.0
change the 0.0.0.0 to your router's IP address.
 
Old 10-19-2004, 07:54 PM   #4
robotik
LQ Newbie
 
Registered: Oct 2004
Posts: 2

Original Poster
Rep: Reputation: 0
It s weird it s like when i do that route add command it gives the default gateway to a 2nd instance of my wireless card>?!?!? result is the same i can ping and access my router but no internet.

here s how i brought the card "up"

root@darkstar:~# ifconfig ath0 192.168.2.99 netmask 255.255.255.0
root@darkstar:~# route add default gw 192.168.2.1 ath0
root@darkstar:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 ath0
127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo
0.0.0.0 192.168.2.1 0.0.0.0 UG 0 0 0 ath0
 
Old 10-19-2004, 10:36 PM   #5
masand
LQ Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 69
Quote:
Originally posted by robotik
It s weird it s like when i do that route add command it gives the default gateway to a 2nd instance of my wireless card>?!?!? result is the same i can ping and access my router but no internet.

here s how i brought the card "up"

root@darkstar:~# ifconfig ath0 192.168.2.99 netmask 255.255.255.0
root@darkstar:~# route add default gw 192.168.2.1 ath0
root@darkstar:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 ath0
127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo
0.0.0.0 192.168.2.1 0.0.0.0 UG 0 0 0 ath0
hey !!!
what about my suggestions
did u try that out
and what OS are u using??

regards
 
Old 10-20-2004, 03:38 AM   #6
darkleaf
Senior Member
 
Registered: Jun 2004
Location: the Netherlands
Distribution: debian SID
Posts: 2,170

Rep: Reputation: 45
Quote:
Originally posted by robotik
It s weird it s like when i do that route add command it gives the default gateway to a 2nd instance of my wireless card>?!?!? result is the same i can ping and access my router but no internet.

here s how i brought the card "up"

root@darkstar:~# ifconfig ath0 192.168.2.99 netmask 255.255.255.0
root@darkstar:~# route add default gw 192.168.2.1 ath0
root@darkstar:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 ath0
127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo
0.0.0.0 192.168.2.1 0.0.0.0 UG 0 0 0 ath0
Cause the code was
Code:
route add default gw x.x.x.x
without ath0 behind it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
What is a gateway? can I have more than one gateway on a vlan? abefroman Linux - Networking 3 09-06-2005 10:43 AM
Adding different gateway to the second NIC jomy Linux - Networking 3 12-25-2004 02:36 AM
Odd problem: Gateway unreachable after certain amount of time (Win XP Gateway) SocialEngineer Linux - Networking 2 08-13-2004 12:54 AM
Automatically adding default gateway when booting enjoyzj Linux - Networking 2 04-13-2004 04:05 PM
Adding a Gateway and making eth1 the primary unclebyron Linux - Networking 1 04-02-2002 07:35 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking > Linux - Wireless Networking

All times are GMT -5. The time now is 07:04 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration