LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 08-15-2008, 06:41 AM   #1
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Rep: Reputation: 31
Static LAN (wired and WiFi) IP in Debian setup problems.


Hi,

I'm trying to setup static IP's on my Debian laptop (sony vaio).

With the Default DHCP setup everything works fine, but for some server applications I'd like to setup static IP's to make it easier to access.

When I setup my NIC as static it only works for the LAN not the internet. After some tinkering I found that the DNS settings kept beeing deleted in resolv.conf. I can manually add the DNS to make it work but that only works until a reboot or when the WiFi in enabled.

I tried to disable the WiFi (switch at the front of the laptop) to prevent this from deleting the DNS information but that doesn't seem to work.

I found some settings for static IP's with WiFi but from what I understand that only works with WEP encryption and not WPA (what my Wireless Access Point uses).

so is there anybody here who can help me with this, the ideal situation would be that the WiFi connection uses a static IP and when a wired connection is established (when faster speed is needed or when there is no Wlan available) that one also get's a static IP.

this is my network layout

interface : eth1 (wired LAN)
address : 192.168.123.56
gateway : 192.168.123.1

interface : eth2 (WiFi)
address : 192.168.123.57
gateway : 192.168.123.1
encryption : WPA Personal
ssid : wireless
key : network

dns : 195.XXX.X.XX (this is the DNS that my ISP provided, I guess it's also possible to use someting like OpenDNS or something).

(bot the ssid and key are just examples offcourse).
 
Old 08-15-2008, 07:36 AM   #2
radiodee1
Member
 
Registered: Oct 2006
Location: New York
Distribution: Debian
Posts: 675
Blog Entries: 11

Rep: Reputation: 36
instead of resolv.conf you might really want to use '/etc/network/interfaces'. You can find out more about it with 'man interfaces'. Maybe that will help you.
 
Old 08-15-2008, 07:49 AM   #3
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by radiodee1 View Post
instead of resolv.conf you might really want to use '/etc/network/interfaces'. You can find out more about it with 'man interfaces'. Maybe that will help you.
I tried this, somewhere I found instructions to add the DNS to /etc/network/interfaces but that didn't seem to work.
 
Old 08-15-2008, 09:21 AM   #4
utanja
Member
 
Registered: Apr 2004
Location: Europe:Salzburg Austria USA:Orlando,Florida;
Distribution: Debian
Posts: 643

Rep: Reputation: 32
Quote:
Originally Posted by CloudyWizzard View Post
Hi,

I'm trying to setup static IP's on my Debian laptop (sony vaio).

With the Default DHCP setup everything works fine, but for some server applications I'd like to setup static IP's to make it easier to access.

When I setup my NIC as static it only works for the LAN not the internet. After some tinkering I found that the DNS settings kept beeing deleted in resolv.conf. I can manually add the DNS to make it work but that only works until a reboot or when the WiFi in enabled.

I tried to disable the WiFi (switch at the front of the laptop) to prevent this from deleting the DNS information but that doesn't seem to work.

I found some settings for static IP's with WiFi but from what I understand that only works with WEP encryption and not WPA (what my Wireless Access Point uses).

so is there anybody here who can help me with this, the ideal situation would be that the WiFi connection uses a static IP and when a wired connection is established (when faster speed is needed or when there is no Wlan available) that one also get's a static IP.

this is my network layout

interface : eth1 (wired LAN)
address : 192.168.123.56
gateway : 192.168.123.1

interface : eth2 (WiFi)
address : 192.168.123.57
gateway : 192.168.123.1
encryption : WPA Personal
ssid : wireless
key : network

dns : 195.XXX.X.XX (this is the DNS that my ISP provided, I guess it's also possible to use someting like OpenDNS or something).

(bot the ssid and key are just examples offcourse).
I have a Sony Vaio running XP and a network of Linux workstations....all are configured for static and work fine.....You have to configure the wireless separately from the wired network......When I get in from a flight later this evening I can post my configuration....I use a DLINK Wifi router with addional switches to be able to have a total of 9 workstations....all can access the internet and each other as well as file and printer sharing....works super....
 
Old 08-15-2008, 11:30 AM   #5
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Original Poster
Rep: Reputation: 31
If you can post your configurations that would be great !

I hope that fixes the problems with the disappearing DNS settings
 
Old 03-25-2009, 01:47 PM   #6
hardly
LQ Newbie
 
Registered: Jan 2009
Location: Tulsa, OK
Distribution: Fedora, Ubuntu
Posts: 18

Rep: Reputation: 0
This is why I have so many unsolved problems.

Where's the resolution? Was this problem solved? How? There are so many threads like this. It seems like about half of the search results I get have no resolution and the other half do not pertain to what I'm looking for.

I guess I need to keep looking and continue reading.
 
Old 03-25-2009, 03:47 PM   #7
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
Quote:
Originally Posted by hardly View Post
Where's the resolution? Was this problem solved? How? There are so many threads like this. It seems like about half of the search results I get have no resolution and the other half do not pertain to what I'm looking for.

I guess I need to keep looking and continue reading.
If searching doesn't produce the answer you seek, you could always start a new thread and ask a specific question..
 
Old 03-26-2009, 09:50 AM   #8
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by hardly View Post
Where's the resolution? Was this problem solved? How? There are so many threads like this. It seems like about half of the search results I get have no resolution and the other half do not pertain to what I'm looking for.

I guess I need to keep looking and continue reading.
I never saw the configurations that utanja was gonna post here so I guess he forgot

I finally gave up onto this problem.
 
Old 03-27-2009, 06:00 PM   #9
hardly
LQ Newbie
 
Registered: Jan 2009
Location: Tulsa, OK
Distribution: Fedora, Ubuntu
Posts: 18

Rep: Reputation: 0
Bummer.

I went a head and plugged my Debian box into a wire and gave up on trying to get a static IP on wlan0.
So I'm set.

THanks all.
 
Old 03-28-2009, 04:26 AM   #10
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Original Poster
Rep: Reputation: 31
Well maybe utanja sees this thread again and realizes "oh, yeah I had to post that"
 
Old 03-28-2009, 06:04 AM   #11
utanja
Member
 
Registered: Apr 2004
Location: Europe:Salzburg Austria USA:Orlando,Florida;
Distribution: Debian
Posts: 643

Rep: Reputation: 32
Quote:
Originally Posted by CloudyWizzard View Post
Well maybe utanja sees this thread again and realizes "oh, yeah I had to post that"
I have been away out from the US.....got in last nite and leaving again this AM.....will try to get this while in europe


btw...what kind of router
 
Old 03-28-2009, 07:32 AM   #12
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by utanja View Post
I have been away out from the US.....got in last nite and leaving again this AM.....will try to get this while in europe


btw...what kind of router
I have a Linksys one (older one with 4 ports) BEFSR41
 
Old 03-28-2009, 11:50 AM   #13
utanja
Member
 
Registered: Apr 2004
Location: Europe:Salzburg Austria USA:Orlando,Florida;
Distribution: Debian
Posts: 643

Rep: Reputation: 32
Quote:
Originally Posted by CloudyWizzard View Post
I have a Linksys one (older one with 4 ports) BEFSR41
my setup is with a dlink 615 which is both wired and wireless...

on my HP laptop

static address wifi =192.168.0.4
netmask=255.255.255.0
gateway=192.168.0.1 (this is the address of the router)
dns 1 = the one from my ISP
dns2 = the other from my ISP

wired is DHCP using defaults

if I use static for the wired, it must be different from the wifi and the wifi I usually turn off...

workgroups are the same for both.

hope this helps.
 
Old 03-28-2009, 01:54 PM   #14
CloudyWizzard
Member
 
Registered: Jul 2004
Location: Belgium
Distribution: Debian Squeeze
Posts: 194

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by utanja View Post
my setup is with a dlink 615 which is both wired and wireless...

on my HP laptop

static address wifi =192.168.0.4
netmask=255.255.255.0
gateway=192.168.0.1 (this is the address of the router)
dns 1 = the one from my ISP
dns2 = the other from my ISP

wired is DHCP using defaults

if I use static for the wired, it must be different from the wifi and the wifi I usually turn off...

workgroups are the same for both.

hope this helps.
So IF I understand correctly, the WiFi must be off when you use the wired network (you can't use both ?)

and this information is added to /etc/network/interfaces ?

Thanks for the information (oh and is it dns1 or dns 1 ?? since you have dns 1 and dns2 I guess one of them is wrong )
 
Old 03-28-2009, 10:15 PM   #15
utanja
Member
 
Registered: Apr 2004
Location: Europe:Salzburg Austria USA:Orlando,Florida;
Distribution: Debian
Posts: 643

Rep: Reputation: 32
Quote:
Originally Posted by CloudyWizzard View Post
So IF I understand correctly, the WiFi must be off when you use the wired network (you can't use both ?)

and this information is added to /etc/network/interfaces ?

Thanks for the information (oh and is it dns1 or dns 1 ?? since you have dns 1 and dns2 I guess one of them is wrong )
correct....you cannot use both at the same time unless you set it as a bridge...but I am not aware of how to do this...

dns 1 and dns2 are the dns server for my isp....they are entered automically...
 
  


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
2 ISPs, LAN, WiFi, Bandwidth Limiting, Which Distro/Setup? crowy Linux - Wireless Networking 5 09-18-2006 02:05 AM
MN-520 Wifi Card Setup Problems odbII Linux - Wireless Networking 1 01-04-2006 03:07 PM
How to setup LAN with Debian-Windows psa Linux - Newbie 2 08-26-2004 01:58 AM
Got debian installed!! - Need to setup static ip now?? trey85stang Debian 5 04-10-2004 05:24 PM
Sharing Internet+WiFi+Wired flying_eyes Linux - Wireless Networking 4 10-28-2003 08:07 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 06:11 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