jhondra V.I.P. Member Xbox Version: Xbox V1.0 Modded: Xecuter3 CE
Joined: Sep 12, 2005 Posts: 288 Location: Boise, ID
Posted: Mon Dec 05, 2005 9:09 pm Post subject: Networking 101
I've seen a couple confused people out there regarding basic network settings. I'll try to clear up a couple of them (sorry, this was the closest topic I could find that seemed to fit...mods, please move it if it needs to be somewhere else).
Network Basics 101.
1) What is an IP address and why is it important?
IP (Internet Protocol) is a specific way or protocol agreed upon for computers and all sorts of devices to communicate on a network. The most common today is TCP (Transmission Control Protocol) and UDP (User Datagram Protocol).
Every device must have a unique "address" on a given network (dividing up that network into "local networks" allow you to have prive networks where you only need to be "unique" on your own private network. Routers provide this "dividing" up.
IP addresses are typically in a 4 field format from 0-255 in each field. So, 0.0.0.0 to 255.255.255.255 are normally the numbers you would see. The Internet Standards committee maintains a block allocation and keep track of all numbers assigned.
2) What is TCP/IP and UDP/IP?
TCP (Transmission Control Protocol) is "guaranteed delivery" protocol. Packets have a confirmation hand shaking that indicates back to the sender each packet that was recieved and that it was ok. If a packet is damaged/corrupt/lost, then the server will resend (this can cause OOP, or out of order packets, and can be very devastating to some applications where packet order is important).
UDP (User Datagram Packets) are blind packet sends that no confirmation is necessary. Voice over IP, gaming, and Network Time packets are prime candidates for this. Mostly because by the time the data can be confirmed as missing or corrupt and re-requested from the server and received again, it is too late (the time is no longer valid, or you don't need the data anymore). So UDP allows you to just drop packets that are corrupt and not bother requesting a resend (which could cause even MORE problems for subsequent packets on a slow or bottlenecked service).
3) What are the basic "network devices"? Routers? Hubs? Bridge? Switch? Gateway? Full and Half Duplex?
Hubs are the most basic of networking devices. They are usually 4 or more network ports (don't confuse this with an IP data port request), and basically, just jumper all network data from any one network port to all the others. In the most simple terms, it is a giant multiplexor that replicates all data from any one port to all the others. Now, how "good" the hub is, can vary, as well as uplink technology. In many cases, some are simple "cut through" technology and don't handle overflow and packet loss very well. Others have a good amount of high speed addressable memory to buffer packets and insert them onto the lines as space is available. Consider a network that is almost completely full (say one port is 98% saturating is upload 100Mbs bandwidth). How does a hub put more data into the stream? Some cheap ones with very little buffer memory, or cut through, either just cut through and place data on the stream where ever and cause lots of packet collisions (at which point it simple drops one packet or the other when there is a time slice contention) causing lots of packet loss. More expensive/better hubs may have a backpane that can handle buffering much higher than the 100Mbps and will store in a FIFO buffer up to a limited amount of time and try to more gracefully insert packets. This works well where there are burst periods and then more free time and doesn't cause as much lag or server resend of TCP data.
Duplex means how the system handles coming and going traffic. Full Duplex means there is dedicated send and receive lines as well as drivers and receptors. That means that a full duplex 100Base network can both SEND and RECEIVE a full 100Mbps at the same time (for a total of 200Mbps of traffic). Half Duplex means that you are probably sharing a line for sending/receiving, which means the total packets sent and received can only approach 100Mbps total.
Bridges, well, bridge networks. In some cases they span two different TYPES of networks and convert traffic from one to another. A Firewire to TCP bridge is an example of one. There normally is not any filtering of traffic. I suppose a 2-port HUB could also be called a "bridge" of some sort.
Switches are essentially intelligent hubs with the ability to decide, based on the address of the data, just which network ports need the data copied on to it. Just like hubs, there are various levels and performance differences. How big of an address match hash each port has, and the back plane speed are all considerations, as is the buffer memory, just like a HUB. Lets say that you had a 4 port switch. And 4 computers connected to it. Computer A and C were talking and B and D were talking to each other. A simple hub would have to send all of the B/D conversation to ports A and C, even though they weren't going to do anything with that information. This causes you to quickly saturate your network as you grow the network and as more data is put on that network. Probably not a problem in most home network environments, but you can see how it could become a problem. A switch knows the MAC address or IP address of all the computers on each network port. So, it can decompile the data packets, inspect them, and figure out which ports need the data and which don't. Which effectively buffers the explosion of data on the network. That doesn't mean that computer A can't talk to computer B, just that the data determines who it is meant for. Now, a 4 port switch needs the ability to send up to 400Mbps to guarantee full 100Mbps full duplex operation (an 8-port switch would need a full 800Mbps). This is known as the backplane speed. And how fast it can decompile and reassemble the data is also a factor (adding to ping times). Many cheap switches only have a 200Mbps backplane, and as the traffic approaches the full 100Mbps on each port, you end up losing lots of data.
Routers direct and segregate traffic on networks, similar to a switch, but it does it based on netmasks and IP addressing. If all of the networks of the world were connected with only hubs and bridges, then we would quickly swamp out even 1000Mbps networks as all the packets were indiscriminantly replicated to everyone. Routers segment the data packets and only send it across the division if it needs to be sent. Broadcast packets are not replicated across a router. Routers are what let NAT (network address translation) and local IP address reutilization work. These are probably the most complex of the typical network devices.
Gateway's are normally just routers that act as your main port of data entering or leaving the local network.
4) What is DHCP and how is it different than "static"?
DHCP is Dynamic Host Configureation Protocol. And basically, it means that a main server tells everyone it sees on its network how to set themselves to extract information from that network. It handles "address" conflicts and tells the clients who to talk to in order to get pretty much everything they need (mail, ftp, dns, etc.). Most current day routers have built in DHCP servers.
Essentially this sets up the client IP (Internet Address), tells it who is also on it's network (netmask), who the gateway host is (how to get out of the local network) and what the main domain name servers are (how to resolve a domain name to a static IP address).
The problem with this, is that sometimes you can lose a DHCP "lease", and then you not only don't know who to talk to, but you also don't know who YOU are (and windows can sometimes be a bit finicky about reassigning a lease).
Static IP addresses never change (or rarely without manually changing them) and are more often than not, setup by the client. Along with that, the client must then know who his gateway is, what netmask he should use (i.e. what packets he should/should not pay attention to) and who his local domain name servers are.
5) Ok, so, I want to setup a static network, what is this netmask, gateway, and DNS stuff?
On static networks, you typically need to indicate a couple things.
IP address is first, and needs to be unique on your local network. Normally, this is 10.0.0.0 - 10.255.255.255 or 192.168.0.0 - 192.168.255.255 for internal non-public addresses, as reserved by the Internet Standards Committee. That should give you over 65k of addresses for the later range for your home network (grin) or over 16 million for the first number. If you grow beyond that, you will need to sub-divide your network with routers, though given bandwidth limitations, you will probably choose to sub-divide it far before you reach those numbers.
Netmask, is a way for computers to disregard some data packets based simply on the sending computer's address. It is a 4 field number just like the IP (0.0.0.0 - 255.255.255.255), and you convert it all to binary to figure out how it masks. The mask is basically a comparison of your IP to the sending computer's IP to decide if you are on the same local network. A "1" means you must compare the same, and a "0" means you don't care. So, a common netmask is 255.255.255.0. Which, converted to binary, means 11111111.11111111.11111111.00000000 and means that ALL address fields except the last one need to be the same. If you wanted to grow your network, you could make it 255.255.0.0, which means only the first 2 need to be the same. 255.255.255.240 would be 11111111.11111111.11111111.11110000, which means only the first 4 binary portions of your IP need to match. 255.255.255.1 basically separates the last field into even/odd IP addresses networking. Sub-net masking below a single field can begin to become a challenge for those people that don't understand binary. Grin.
6) What is DNS, NAT, firewall and port forwarding?
DNS, or Domain Name Servers, are computers that are out on the internet with translation tables for english WWW type domain names, like yahoo.com or microsoft.com, that translate to a single static public IP address. When you request a domain name, the registered IP address is updated in the Domain Name look up tables and fanned out to all the servers. This is all because humans aren't very good at remembering numbers, and are better with names...
NAT is Network Address Translation. And basically, this is what happens at your cable modem or DSL modem/router when you have more than one computer on the inside. All of the data is coming to the ONE external public IP address (even if it is DHCP), but it gets translated as it comes in to different IP addresses on the internal network. Most home/small networks use 10.x.x.x or 192.168.x.x as the standard range and the Internet Standards committee has determined that no address like that should appear as a public IP. How this NAT works, is that multiple "ports" may be opened for the single external IP address.
A firewall is a term used to indicate a software or hardware barrier that prevents certain types of requests/packets from being transmitted across a router or at your computer, typically.
Port forwarding is the service many routers or gateways do for you in network address translation and firewalls. When a request comes from the outside world, or the WAN to your public IP address, it normally comes with a certain "port". FTP access is most often port 21, HTTP web request access normally comes with port 80, email is normally port 24, telnet is 23. Many other programs use many other ports. Anyway, say computer A on your internal network was providing HTTP web hosting service on port 80. You would set up a port forward to computer A's internal IP for all TCP requests on port 80. You could then setup a port forward for computer B for FTP service, etc. _________________ Xecutor 3 CE
X3 3294 Bios
14 total successful solder-mod xbox's (v1.0 to v1.6b; favorite is v1.4 Sept 2003; very clean motherboard and usually has Samsung DVD), including two 128MB upgrades and 2 X3 LCD/CP's.
enigma516 V.I.P. Lifetime
Joined: Feb 07, 2005 Posts: 2743 Location: Florida
Posted: Mon Dec 05, 2005 9:14 pm Post subject:
Yep, that pretty much sums it up. _________________
jhondra V.I.P. Member Xbox Version: Xbox V1.0 Modded: Xecuter3 CE
Joined: Sep 12, 2005 Posts: 288 Location: Boise, ID
Posted: Mon Dec 05, 2005 9:22 pm Post subject:
I'm certain there are some technical issues with some of my explainations that someone with REAL networking background can clue me in on, but this is basically my understanding of how it all works from my own research. I've built on this knowledge since the mid 90's when I was the only one that took the time to figure out networking and the 10-Base T coaxial networking with terminators and stuff and Windows 95 (BLECH) and mostly DOS to help us do some Descent and Warcraft nerd linking...
-Jhondra
P.S. I put it up as a "tutorial" as well. _________________ Xecutor 3 CE
X3 3294 Bios
14 total successful solder-mod xbox's (v1.0 to v1.6b; favorite is v1.4 Sept 2003; very clean motherboard and usually has Samsung DVD), including two 128MB upgrades and 2 X3 LCD/CP's.
|
All times are GMT |Page 1 of 1
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum