stackencapsulationEachrouteadd
routeadd 时间:2021-05-24 阅读:(
)
TCP/IPnetworkingTCP/IPAnetworkingprotocolsuiteUseseveralprotocols,mainonesaretcpandip.
IPstandsforInternetProtocolTCPstandsforTransmissionControlProtocol.
ThenativelanguageoftheInternetSupportedbymostOSs(Unix,MacOS,Windows,Netware,etc)DefinesauniformprogramminginterfacetodifferenttypesofnetworkhardwareTCP/IPandInternet1969ARPAnetExperimentalpacket-switchingnetworkStudyrobust,reliable,vendor-independentdatacommunicationVerysuccessful1975ARPAnetbecameoperationnetworkDevelopmentcontinuingTCP/IPwasdeveloped1983TCP/IPprotocolswereadoptedasMilitaryStandardsTCP/IPwasimplementedinBerkeleyUnix.
ARPAnetwasdividedintoMILNETandARPAnetTCP/IPandInternet1985NSFNetConnectedtothethenexistingInternet(MILNETplusARPAnet)LinkedtogetherthefiveNSFsupercomputercentersWantedtoextendthenetworktoeveryscientist1987newNSFNetbackboneFasterThree-tieredtopology:backbone,regionalnetworks,andlocalnetworks.
TCP/IPandInternet1990ARPAnetpassedoutofexistence1995NSFnetceaseditsroleasaprimaryInternetbackbonenetworkTodayInternetisbuildbycommercialproviders.
InfrastructureisbeingcreatedbyNationalnetworkprovider,callertier-oneprovidersRegionalnetworkproviderLocalaccessanduserservicesisprovidedbyInternetServiceProviders(ISPs)NetworkAccessPoints(NAPS):majorinterconnectionpointsTCP/IPandInternetHowtheinternetismanagedtodayCommercialforceSeveralorganizationInternetCorporationforAssignedNamesandNumbers(ICANN)www.
icann.
orgInternetEngineeringTaskForce(IETE)www.
ietf.
orgInternetSociety(ISOC)www.
isoc.
orgTCP/IPandInternetNetworkstandardsanddocumentationRequestforComments(RFC)Over4000hasbeencreatedFYSTDBCPDispatchcentralforRFC-relatedmatterswww.
rfc-editor.
orgNetworkingRoadMapTCP/IPcomponentsIP,theInternetProtocolroutesdatapacketsfromonemachinetoanotherICMP,theInternetControlMessageProtocolProvidesseveralkindsoflow-levelsupportforIPErrormessageRoutingassistanceDebugginghelpARP,theAddressResolutionProtocolTranslatesIPaddressestohardwareaddressesNetworkingRoadMapUDP,theUserDatagramProtocolDeliversdatatospecificapplicationsonthedestinationmachineProvides"unverified","besteffort"transportforindividualmessagesTCP,theTransmissionControlProtocolDeliversdatatospecificapplicationsonthedestinationmachineProvidesreliable,flowcontrolled,errorcorrectedconversationbetweenprocessesontwohosts.
TCP/IPnetworkmodelUTPcopper,fiber,radiawavesARP,DeviceDriversIPICMPTCPUDPARPSSH,FTP,WEBDNS,QuakeTraeroutePhysicallayerLinkLayerNetworkLayerTransportLayerApplicationLayerPacketsandencapsulationDatatravelsonanetworkintheformofpacketsEachpacketconsistsofAheader–whereitcamefromandwhereit'sgoing,protocolinfo,checksum,etc.
Apayload-dataAsapackettravelsdowntheprotocolstackencapsulationEachprotocoladdsitsownheaderinformationEachprotocol'sfinishedpacketbecomesthepayloadpartofthepacketgeneratedbythenextprotocol.
Onareceivingmachine,theencapsulationisreversedasthepackettravelsbackuptheprotocolstack.
PacketsandEncapsulationExample:AtypicalnetworkpacketEthernetheaderIPheaderUDPheaderApplicationdataEthernetCRCUDPpacket(108bytes)IPpacket(128bytes)Ethernetframe(146bytes)AddressingPacketsaddressingPacketsmustbeproperlyaddressedinordertoreachtheirdestinationAddressingschemesMAC(mediaaccesscontrol)addressesforhardwareIPaddressesforsoftwareHostnamesforpeoplePorts16bitnumberAddressparticularprocessesorservicesWell-knownportsaredefinedin/etc/servicesUnixsystemsrestrictaccessportunder1024toroot.
AddressingAddresstypesUnicast–addressesthatrefertoasinglehost(interface)Multicat–addressesthatidentifyagroupofhostsBroadcast–addressesthatincludeallhostsonthelocalnetworkIPaddressesFourbyteslongNetworkpartandhostpartWrittenasdecimalnumbers,oneforeachbyteseparatedbyperiodsWhen127isthefirstbyteofanaddress,itdenotesthe"loopbacknetwork"Lookbackaddress127.
0.
0.
1-localhostAddressingIPaddressclassesThetraditionalclassdeterminewhichbytesoftheaddresswereinthenetworkportionandwhichwereinthehostportionA1-126N.
H.
H.
HVeryearlynetworkB128-191N.
N.
H.
Hlargesites(65536)C192-223N.
N.
N.
H(256)D224-239MultipleaddressesE240-254ExperimentaladdressesAddressingSubnettingandnetmasksHostportionofanaddressis"borrowed"toextendthenetworkportionThisreassignmentisdonebyusingifconfigcommandtoassociateanexplicit"subnetmask"withanetworkinterface.
EachbitofthenetmaskthatcorrespondstothenetworkportionofanIPaddressissetto1,hostbitsaresetto0ThedivisionofnetworkpartandhostpartneednotfallonabyteboundaryNetworkbitsmustbecontiguousandmustappearatthehighorderendoftheaddressesAddressingNotationIpaddressnetmaskIpaddress/lengthofthenetworkpart128.
138.
243.
0/26Example128.
138.
243.
100/24NetmaskNetworkBroadcast128.
138.
243.
100/26100=01100100NetmaskNetworkBroadcastUseipcalctogetthevalues.
AddressingTheIPaddresscrisisFundamentalproblemswiththeoriginalclassallocatingschemeRunoutofBclassesRoutingtableweregrowingsolargeIPaddresswereallocatedonafirst-com,first-servedbasiswithnolocalityofreferencesolutionsShortterm:ClasslessInter-DomainRouting(CIDR)IPV6:extendtheaddressto16bytes665,570,793,348,866,943,898,599addressesAddressingAddressallocationRegionalIPaddressregistriesARINNorthandSouthAmericaAPNICAsia/PacificregionRIPEEuropeandsurroundingareasPrivateaddressesPacketsbearingprivateaddressescannotgetintointernetIPaddressreservedforprivateuse10.
0.
0.
0/8172.
16.
0.
0/12192.
168.
0.
0/16RoutingRoutingistheprocessofdirectingapacketthroughthemazeofnetworksthatstandbetweenitssourceanditsdestination.
Routinginfoisstoredinatableinthekernel.
Examineituse"netstat–r"ConfiguredynamicallyConfigurestatically#routeadd–net132.
236.
220.
64netmask255.
255.
255.
192132.
236.
212.
6#routeadddefault132.
236.
227.
1ARPTheaddressResolutionProtocoldiscoversthehardwareaddressassociatedwithaparticularIPaddress.
APRusesbroadcastpackets,cannotcrossnetworks"Doesanyoneknowthehardwareaddressfor128.
138.
116.
4"Checkthearpcachetablewitharpcommand#/usr/sbin/arp–aRARPReversetranslationQueryacentralservertodiscoveritsownaddressNeedconfigurationAdditionsofmachinestoanetworkBasicstepsareAssignaIPaddressandhostnameSetupthenewhosttoconfigureitsnetworkinterfacesatboottimeSetupadefaultrouteandperhapsfancierroutingPointtoaDNSnameserver,toallowaccesstotherestoftheInternet.
DebuggingAlwaystorebootifchangesaffectbootingAssigninghostnamesandIPaddressesMappinghostnamestoIPHostsfileNISorNIS+DNSOrCombinationaboveHostsfile/etc/hostsEachlinestartwithIP,continueswithvarioussymbolicnamesbywhichthataddressisknown.
EntriesLocalhost,gateway,specialhosts,…ReplicatesamehostsfileonmachinesConfigurehostnameCommandhostnamerunattheboottimeConfigurationfileAssigninghostnamesandIPaddressesConfigurenetworkinterfaces:ifconfigEnableordisablenetworkinterfaceSetIPaddressSetsubnetmaskSetotheroptionsRunattheboottime(usecommandwiththevaluefromconfigurefiles)Format$ifconfiginterfaceaddressoptions…up|downEx:#ifconfigeth0128.
138.
240.
7network255.
255.
255.
0upAssigninghostnamesandIPaddressesInterfacename:IdentifiesthehardwaretowhichthecommandappliesTwoorthreecharacterdevicenamefollowedbyanumber.
Theloopbackinterfaceisnamedlo0ThecommoninterfacenamesareIe0,le0,ln0,we0,hme0,eri0,lan0,…Displaytheinterfaces$netstat–iDisplaythesettingofinterfaces$ifconfig–aAssigninghostnamesandIPaddressesConfigurethenetworkinterfaceTheifconfigcommandssupportmanyoptionsSpecifyaddressSpecifynetmask,otherwiseitusesaddressclass(A,B,C)SpecifybroadcastDefaultcanbecalculatedfromIP+netmaskSomesitessetittoavoidcertaintypesofdenialofserviceattacks.
Notgood.
ActivateordeactivatethedevicedriverUsekeyworkup,down.
Ifconfigallowsyoutoconfigureainterfacecardbyhand,butthevalueisonlyinkernel.
Tomakeitsurvivethereboot,changetherightconfigurationfileConfigurestaticroutesCommandroutedefinesstaticroutesStaticroutewillstayintheroutingtableinmostcaseconfigurethedefaultroutingwhenaddingahosttolocalnetworkRoutingisperformedatwhatlayerThepackets'destinationIPiscomparedwiththeroute,ifitmatches,thepacketisforwardedtothe"nextgateway"IPaddressassociatedwiththatrouteRoutingaddedwhenconfiguretheinterface-PacketsdestinedforhostonadirectoryconnectednetworkDefaultrouteisinvokedwhenthereisnoroutethatmatchesthedestinationaddress.
ConfigurestaticroutesTheformat:#routeop[type]destinationgateway[hop-count]WhereOp:add,delete,get,change,flush,monitorDestination:hostaddress,networkaddress,orthekeyword"default"(0.
0.
0.
0)Gateway:amachinetowhichpacketsshouldbeforwardedMustbeonadirectlyconnectednetworkForwardingcanonlybeperformedonehopatatimeType:-net,-hostChecktheroutingtable:#netstat-nrConfigurestaticroutesdefaultroute#routeadddefaultgateway_ip_addressChangetheconfigurefileSolaris:/etc/defaultrouterHp-UX:/net/rc.
config.
d/netconfRedhat:/etc/sysconfig/networkConfiguringDNSToconfigureamachineasaDNSclientConfigure/etc/resolv.
confListDBSdomainsthatshouldbesearchedtoresolvenamethatareincompleteLinetheIPaddressesofthenameserverstocontactfornamelookupsExample:[ruihong@dafinn~]$more/etc/resolv.
confsearchcs.
mtu.
educsl.
mtu.
edumtu.
edunameserver141.
219.
152.
253nameserver141.
219.
152.
254ConfiguringDNSConfiguretheserviceswitchfileWhichonetakeeffect/etc/hosts,NIS,DNSSolaris,Hp-UX,Redhat:/etc/nsswitch.
confExample:hosts:filesnisdnsClause:[NOTFOUND=return]NetworkconfigurationfilesbysystemAll/etc/hosts/etc/recolv.
confSolaris/etc/hostname.
ifname/etc/nodename/etc/defaultrouter/etc/inet/netmasks/etc/inet/hostsHP-UX/etc/rc.
config.
d/netconfRedHat/etc/sysconfig/networkNetwork-scripts/ifcfg-ifnamePracticeCheckIPaddress/netmask/broadcastrouteArptableHostnameDNSModifyHostnameDnsresearchlistPingwoprDnsserversRemotedefaultroutePingwoprAddthedefaultroutebackagainRebootDHCPDynamicHostConfigurationProtocolDistributenetworkandadministrativeparameterstoDHCPclient,includeIPaddressandnetmasksGatewaysDNSnameserversSysloghostsWINsServers,Xfontservers,proxyservers,NTPserversTFTPservers(forloadingabootimage)Andmore…DHCPHowDHCPworksClientsends"WhoamI"DHCPDISCOVERmessageTobroadcast255.
255.
255.
255With0.
0.
0.
0asitsownaddressServerrespondswithOFFERmessagesClientsendsbackaREQUESTmessagesServerrespondswithACKorNAKClientrenewtheleasebysendinganotherREQUESTmessage
春节期间我们很多朋友都在忙着吃好喝好,当然有时候也会偶然的上网看看。对于我们站长用户来说,基本上需要等到初八之后才会开工,现在有空就看看是否有商家的促销。这里看到来自HMBcloud半月湾服务商有提供两款春节机房方案的VPS主机88折促销活动,分别是来自洛杉矶CN2 GIA和日本CN2的方案。八八折优惠码:CNY-GIA第一、洛杉矶CN2 GIA美国原生IP地址、72小时退款保障、三网回程CN2 ...
IMIDC发布了6.18大促销活动,针对香港、台湾、日本和莫斯科独立服务器提供特别优惠价格最低月付30美元起。IMIDC名为彩虹数据(Rainbow Cloud),是一家香港本土运营商,全线产品自营,自有IP网络资源等,提供的产品包括VPS主机、独立服务器、站群独立服务器等,数据中心区域包括香港、日本、台湾、美国和南非等地机房,CN2网络直连到中国大陆。香港服务器 $39/...
ProfitServer怎么样?ProfitServer好不好。ProfitServer是一家成立于2003的主机商家,是ITC控股的一个部门,主要经营的产品域名、SSL证书、虚拟主机、VPS和独立服务器,机房有俄罗斯、新加坡、荷兰、美国、保加利亚,VPS采用的是KVM虚拟架构,硬盘采用纯SSD,而且最大的优势是不限制流量,大公司运营,机器比较稳定,数据中心众多。此次ProfitServer正在对...
routeadd为你推荐
建筑业127支持ipadtcpip上的netbiostcp 协议里的 netbios . 在哪,找不到x-router思科路由器有线端无法上网,而无线段却可以,用的是PPPOE拨号上网,一开始两种方法都不可以,检查宽google中国地图谷歌中国地图用的是什么投影,什么坐标系谷歌sb为什么搜索SB第一个是google?googleadsense如何通过Google adsense???google搜图google自定义搜索是什么?怎么用ipad无法加入网络我的IPAD无法加入网络支付宝白领日记支付宝生活在海外在哪里?支付宝生活在海外怎么进
域名买卖 lamp 贵州电信宽带测速 警告本网站 qq数据库下载 godaddy域名证书 老左来了 万网空间购买 新睿云 华为云盘 英雄联盟台服官网 国外网页代理 阵亡将士纪念日 服务器硬件配置 万网服务器 ncp是什么 ubuntu安装教程 网络安装 极域网 衡天主机 更多