Solved

Subnet Mask issue

Posted on 2013-12-06
28
757 Views
Last Modified: 2013-12-28
Hello Experts,

I have two subnets: 192.068.0.x and 192.168.4.x.

I would like to set up one Windows 7 computer to be able to access both subnets with one network card.

I thought I had read you can do that by adjusting the Subnet mask. Networking theory is not my strong point.

I have a computer with this address:

IP: 192.168.4.9
SM: 255.255.255.0
DG: 192.168.4.1
DNS: 192.168.4.1

Does anyone know how to adjust the SM of 255.255.255.0 in the TCP/IP configuration above in order to access both subnets (192.168.4.x and 192.168.0.x)?

Thanks!
0
Comment
Question by:Saxitalis
  • 11
  • 9
  • 3
  • +3
28 Comments
 
LVL 26

Expert Comment

by:pony10us
Comment Utility
Mask of 255.255.0.0 would permit it access to 192.168.0.1-192.168.255.255

Do you need to be more restrictive?

Mask of 255.255.248.0 would permit it access to 192.168.0.1-192.168.7.255

You can use an online subnet calculator.
0
 
LVL 17

Assisted Solution

by:Chris Millard
Chris Millard earned 71 total points
Comment Utility
Even without subnetting, you know that you can assign multiple IP addresses to a single card right? Under the advanced options of IPv4 or IPv6...
0
 

Author Comment

by:Saxitalis
Comment Utility
Hmm - I never understood that.

So I could have the main page be:
IP: 192.168.0.201SM: 255.255.255.0
DG: 192.168.0.1
DNS: 192.168.0.1


and the second IP scheme on the same Interface be:
IP: 192.168.4.9
SM: 255.255.255.0
DG: 192.168.4.1
DNS: 192.168.4.1

After this is accomplished, this computer will be able to communicate with both LANS (ping, IPCONFIG, ODBC etc)?
0
 
LVL 17

Expert Comment

by:Chris Millard
Comment Utility
Yes - I have a similar configuration on my work PC.
0
 
LVL 20

Expert Comment

by:masnrock
Comment Utility
Do you want to be able to communicate with machines on each subnet or combine the subnets into one?

The better question is whether you want any machines in general to communicate with both subnets.

What type of firewall are you using?
0
 
LVL 18

Expert Comment

by:Akinsd
Comment Utility
Supernetting?
192.18.0.1 - 192.168.4.255 is a really wide range. Okay if you don't have too many devices (not more than 500) as I imagine. ....And yes, the best subnet across the board would be 255.255.248.0
Supernetting combines multiple subnets (vlans) into 1.

You will need to change the subnet on the router also, not just on the computer.

Configuring an alternate address on your computer is okay but your computer can only be on "1 subnet (vlan) at a time in general". Please note the word in general

The solution I think you need may be as simple as creating a route between the two subnets on your router.
0
 

Author Comment

by:Saxitalis
Comment Utility
I am trying to solve an ODBC issue between two computers on the subnet...

1. Previously I was on a subnet with no Firewall. Address range 192.168.0.x.

ODBC between the two computers works great.

2. I added a firewall to the 192.168.0.x (Made that the "WAN" into the firewall) I gave the LAN an address range of 192.168.4.x

ODBC does not work for some reason in the 192.168.4.x range! I have been beating on this for days and cannot find out why. Maybe there is still a reference somewhere to 192.168.0.x because when I remove the firewall and change TCP/IP properties on the the two computers back to 192.168.0.x, ODBC works again.

I can't change the subnet addressing on the firewall LAN to 1912.168.0.x because it would be the same as the firewall "WAN" (cannot change the WAN to something else for complicated reason right now)

So, essentially, I am trying to keep all computers on the firewall LAN (192.168.4.x) but try and get the ODBC to talk on 192.168.0.x between the two computers using it. This is a SQL Anywhere 11 ODBC.

SO...

If I do as roybridge suggests:

Have the main TC/PIP on the two ODBC computers as:
IP: 192.168.4.x
SM: 255.255.255.0
DG: 192.168.4.1
DNS: 192.168.4.1

but set another IP and subnet mask in Advanced properts on the 2 ODBC computers of:
192.168.0.x
255.255.255

All networking should work on the 192.168.4.x subnet BUT THE QUESTION IS will ODBC work between the two ODBC computers on 192.168.0.x because 192.168.0.x has been set up in TCP/IP advanced on the two ODBC computers (.200 for one and .201 for the other)??
0
 
LVL 18

Expert Comment

by:Akinsd
Comment Utility
There is either no route or there is a filter (configured or implied) blocking the traffic. What models of switch, router and firewall do you have.
0
 

Author Comment

by:Saxitalis
Comment Utility
Here is some additional information.

 I have the firewall (SOPHOS UTM) in place. Firewall WAN is 192.168.0.x and firewall LAN is 192.168.4.x.

TCPIP/IP with SQL AnyWhere server:
IP: 192.168.4.11
SM: 255.255.255.0
DG: 192.168.4.1
DNS: 192.168.4.1

added IP and subnet in advanced properties:
192.168.0.201
255.255.255.

0DBC works fine from here (same machine that SQLAnywhere DB lives on). Will connect to 192.168.4.11 or 192.168.0.201!

but if I do the same on a networked computer:

TCP/IP of client computer wants to connect over network with ODBC:
IP: 192.168.4.5
SM: 255.255.255.0
DG: 192.168.4.1
DNS: 192.168.4.1

added IP and subnet in advanced properties:
192.168.0.200
255.255.255.

ODBC FAILS when trying to connect to 192.168.4.11 or 192.168.0.201!

I really think this is a networking issue not an ODBC issue.
0
 
LVL 18

Assisted Solution

by:Akinsd
Akinsd earned 71 total points
Comment Utility
Yes, it is a networking issue (route or filter)
It looks like your router is also your firewall.
How about the switch? How did you assign vlans?
Aparently, you have 2 vlans.

Look for routes on your firewall or filter (access list) and see where the traffic is dropping.
show ip route and show access-list are the commands you would issue if you had Cisco devices.


Concentrate on these 2 areas and you will solve the problem in no time
0
 
LVL 20

Assisted Solution

by:masnrock
masnrock earned 215 total points
Comment Utility
I think this is a multifaceted issue. Does the machine with SQLAnywhere have Windows firewall turned on? If so, what happens if you turn it off? What is the actual WAN address of the Sophos UTM?

Also, could you please give a diagram of your network along with the exact WAN address of the firewall that you put in? From the surface, it sounds like something very wonky you did with the firewall, both in terms of placement and addressing scheme. But only an accurate diagram that specifically shows the WAN address of the firewall will make it all make sense.
0
 

Author Comment

by:Saxitalis
Comment Utility
The real problem here is this: Cannot create ODBC connection over the network (client to server) but same ODBC connection works fine locally on server.

I have simplified things by taking out the Sophos firewall

1. I took the hardware firewall out of the network
2. I set the client and server up in my office (Clearwire Internet NATs to 192.168.1.x)

SQL Anywhere server TCP/IP: Win7 32bit

IP:   192.168.1.201
SM:  255.255.255.0
DG:  192.168.1.1
DNS: 192.168.1.1

Client trying to access TCP/IP: Win 7 64 bit

IP:   192.168.1.200
SM:  255.255.255.0
DG:  192.168.1.1
DNS: 192.168.1.1

3. Windows firewall is turned off on both computers
4. I cannot telnet into the server SQL Anywhere port from the client like this:

telnet 192.168.1.201 2638

note (I CAN telnet into the server when telnet string shown above is called FROM the server computer)

5. ODBC to the SQL Anywhere DB works from the server computer but WILL NOT work  from the client computer to server computer. Note. I am using the 32 bit ODBC on the client since the server is a 32 bit installation.

Can anyone see what may be going on here?
0
 
LVL 20

Expert Comment

by:masnrock
Comment Utility
Can you even ping the server from another machine? A machine connecting to itself might tell you that the server is running, but does not explain why clients can't connect. The problem isn't SQLAnywhere, it's involving the server itself.
0
 
LVL 20

Expert Comment

by:masnrock
Comment Utility
Also, could you check to make sure there is no conflict of IP address or machine name? If you disconnect the server from the network and ping that IP, what happens?
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:Saxitalis
Comment Utility
- pings work fine to and from server
- No IP conflicts anywhere. I disconnected all computers from network EXCEPT the client and server in question here
0
 
LVL 45

Assisted Solution

by:Craig Beck
Craig Beck earned 71 total points
Comment Utility
I have the firewall (SOPHOS UTM) in place. Firewall WAN is 192.168.0.x and firewall LAN is 192.168.4.x.
If that is the case you can't assign an IP from each range to the same network card and see devices on both subnets unless everything is plugged into the same switch and on the same VLAN.

That would be a BAD scenario though!
0
 

Author Comment

by:Saxitalis
Comment Utility
I agree - what would be the point of the firewall with "parallel" connections to both subnets.
0
 
LVL 20

Assisted Solution

by:masnrock
masnrock earned 215 total points
Comment Utility
I've seen it done, but it usually turns out ugly when network changes are made. But that's always why you see most of us NOT suggest to apply a second IP address to the NIC.
0
 
LVL 20

Expert Comment

by:masnrock
Comment Utility
@Saxitalis - Then we need to see how the server is handling incoming connections. You obviously don't even seem to be able to ping it. What happens if you try to trace the route of network traffic between the two machines. Can either machine ping the other?
0
 

Author Comment

by:Saxitalis
Comment Utility
Ping works fine
can map network drives etc.
Tracert resolves  immediately
0
 
LVL 20

Expert Comment

by:masnrock
Comment Utility
So in theory, if the client can ping the server fine, it *should* be able to connect to the server as long as SQLAnywhere is configured right. What type of virus/malware protection is on the server?
0
 

Author Comment

by:Saxitalis
Comment Utility
ODBC is configured correctly to SQL Anywhere because it works fine set up the same way on the server (not over the network)

I have all antivirus/malware etc. uninstalled from the server right now

Windows firewall is turned off.

Yeah I know it should work "In Theory" but it doesn't
0
 
LVL 20

Expert Comment

by:masnrock
Comment Utility
What software is installed on the server? The problem is definitely involving the server, especially since you cannot connect to anything on it from other machines. Just because of a possible issue, could you also try to define some Windows Firewall exceptions? Or just turning the service off completely?
0
 

Author Comment

by:Saxitalis
Comment Utility
"especially since you cannot connect to anything on it from other machines"

If you reread my previous posts you see that

1. Windows firewall IS turned off
2. I can connect to the server in every way BUT the ODBC
0
 
LVL 20

Assisted Solution

by:masnrock
masnrock earned 215 total points
Comment Utility
You could try tweaking the hosts file of the client, making an entry specifically for the machine server.
0
 
LVL 26

Accepted Solution

by:
pony10us earned 72 total points
Comment Utility
Have you gone through the steps in the troubleshooting guide?

http://www.sybase.com/content/1011225/ConnectionTroubleshooting-v2.pdf
0
 

Author Comment

by:Saxitalis
Comment Utility
I've requested that this question be closed as follows:

Accepted answer: 0 points for Saxitalis's comment #a39705057
Assisted answer: 84 points for roybridge's comment #a39702352
Assisted answer: 84 points for Akinsd's comment #a39703019
Assisted answer: 83 points for masnrock's comment #a39703403
Assisted answer: 83 points for masnrock's comment #a39705029
Assisted answer: 83 points for masnrock's comment #a39705086
Assisted answer: 83 points for pony10us's comment #a39706274

for the following reason:

Thanks All!
0
 

Author Closing Comment

by:Saxitalis
Comment Utility
Thanks All! I reset TCP/IP and created a PORT firewall rule and got it working
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Are you one of those front-line IT Service Desk staff fielding calls, replying to emails, all-the-while working to resolve end-user technological nightmares? I am! That's why I have put together this brief overview of tools and techniques I use in o…
I'm a big fan of Windows' offline folder caching and have used it on my laptops for over a decade.  One thing I don't like about it, however, is how difficult Microsoft has made it for the cache to be moved out of the Windows folder.  Here's how to …
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now