LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-18-2009, 09:37 PM   #16
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682

Evilted: You posted your last message as I was writing mine. Rather than re-editing mine, I'll post it as is.

-------

Could we handle one item from the original post at a time.
Quote:
when I have a machine on 10.10.1.0/24 I cannot remote desktop to a virtual windows server (sitting on linux vmware server), which is set to 10.10.12.201 netmask 255.255.255.0
I assume the client on 10.10.1.0/24 is a windows client. You probably have a gateway device or computer on 10.10.1.1 or 10.10.1.254. Is the gateway setting correct on this client?

What is the device, a router or another computer? If it is a router, did the routes to the other subnets survive the power outage. If it is a Linux computer, please post the outputs of "ifconfig" and "route". Doing so in [ code ] [ /code ] blocks will preserve the formatting.

Post the output of "cat /proc/sys/net/ipv4/ip_forward". It should be "1".
I once had a problem getting forwarding to work when I used my laptop to share a wireless connection. I found that I needed the "ip_conntrack" module loaded. Then it worked.
It may go by another name now, depending on your kernel. Please post the output of "lsmod | grep conntrack". I wasn't using NAT on the laptop, just forwarding packages. Since you mentioned a power outage, I thought perhaps that either the ip_forward wasn't set to "1" during the reboot, or maybe you are missing a needed kernel module. Either could prevent packets from being forwarded from one interface to another (including virtual interfaces).

Last edited by jschiwal; 08-18-2009 at 09:38 PM.
 
Old 08-19-2009, 12:22 AM   #17
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,979

Rep: Reputation: Disabled
Well,
Code:
Adresse IP. . . . . . . . . . . .  : 10.10.1.10
Masque de sous-réseau . . . . . .  : 255.255.255.0
Passerelle par défaut . . . . . .  : 10.10.12.245
This configuration can never work! As I wrote above, the gateway has to be in the same subnet as the computer. In this case you have a computer in the 10.10.1.0/24 subnet and a gateway in 10.10.12.0/24. When in the case that the server has a 16bit mask the configuration works, it is because the server is in the same subnet as the computer, namely both are in the 10.10.0.0/16 net. So there is no routing needed.

If you want to get your second configuration working, you must add a route between the two subnets. This means you have to add a router with a nic in the 10.10.1.0/24 net and an appropriate route.

Markus

@jschiwal: I did not see your post when writing mine because it was on the second page of the thread.

Last edited by markush; 08-19-2009 at 12:26 AM. Reason: added some text
 
Old 08-19-2009, 05:10 AM   #18
evilted
Member
 
Registered: Aug 2009
Location: Ouagadougou, Burkina Faso
Distribution: centos
Posts: 92

Original Poster
Rep: Reputation: 18
Quote:
Originally Posted by markush View Post
Well,
Code:
Adresse IP. . . . . . . . . . . .  : 10.10.1.10
Masque de sous-réseau . . . . . .  : 255.255.255.0
Passerelle par défaut . . . . . .  : 10.10.12.245
This configuration can never work! As I wrote above, the gateway has to be in the same subnet as the computer. In this case you have a computer in the 10.10.1.0/24 subnet and a gateway in 10.10.12.0/24. When in the case that the server has a 16bit mask the configuration works, it is because the server is in the same subnet as the computer, namely both are in the 10.10.0.0/16 net. So there is no routing needed.

If you want to get your second configuration working, you must add a route between the two subnets. This means you have to add a router with a nic in the 10.10.1.0/24 net and an appropriate route.

Markus

@jschiwal: I did not see your post when writing mine because it was on the second page of the thread.
its a typo. there are 2 physical devices. the linux server is running vmware and windows server is installed on the vmware server.

windows pc -->> linux server -->> windows server

Code:
Adresse IP. . . . . . . . . . . .  : 10.10.1.10
Masque de sous-réseau . . . . . .  : 255.255.255.0
Passerelle par défaut . . . . . .  : 10.10.1.245
yes ip forwarding is on.
Code:
sysctl -p
net.ipv4.ip_forward = 1
 
Old 08-19-2009, 05:15 AM   #19
evilted
Member
 
Registered: Aug 2009
Location: Ouagadougou, Burkina Faso
Distribution: centos
Posts: 92

Original Poster
Rep: Reputation: 18
the problem is when the windows server is on the /24 subnet it wont work.
when its on the /16 subnet it does.

the windows pc and the linux machine (router & gateway) are both on the /24

all i would like to know is why.
 
Old 08-20-2009, 05:16 AM   #20
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
Does a route exist in the gateway device at 10.10.1.245 to route traffic to the 10.10.12.0 subnet?

When you use 10.10/16, you aren't using subnetting. The third octet of the IP address becomes part of the host address instead of the network address. Since all the addresses start with 10.10. all of the host addresses are on the same network.
 
  


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
subnets configuration and routing manolo_caracol Linux - Networking 4 03-17-2008 08:39 AM
Routing between two subnets ScottReed Linux - Networking 22 10-24-2006 10:32 PM
Routing problem with subnets G-Fox Linux - Networking 3 01-24-2006 05:20 AM
Firewall, Routing and Subnets - is this possible? donoss Linux - Networking 2 10-28-2004 12:34 PM
Routing between different subnets ... suvajit Linux - Networking 1 05-15-2003 07:07 AM

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

All times are GMT -5. The time now is 06:35 PM.

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