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

恒创科技SonderCloud,美国VPS综合性能测评报告,美国洛杉矶机房,CN2+BGP优质线路,2核4G内存10Mbps带宽,适用于稳定建站业务需求

最近主机参考拿到了一台恒创科技的美国VPS云服务器测试机器,那具体恒创科技美国云服务器性能到底怎么样呢?主机参考进行了一番VPS测评,大家可以参考一下,总体来说还是非常不错的,是值得购买的。非常适用于稳定建站业务需求。恒创科技服务器怎么样?恒创科技服务器好不好?henghost怎么样?henghost值不值得购买?SonderCloud服务器好不好?恒创科技henghost值不值得购买?恒创科技是...

Megalayer优化带宽和VPS主机主机方案策略 15M CN2优化带宽和30M全向带宽

Megalayer 商家主营业务是以独立服务器和站群服务器的,后来也陆续的有新增香港、菲律宾数据中心的VPS主机产品。由于其线路的丰富,还是深受一些用户喜欢的,有CN2优化直连线路,有全向国际线路,以及针对欧美的国际线路。这次有看到商家也有新增美国机房的VPS主机,也有包括15M带宽CN2优化带宽以及30M带宽的全向线路。Megalayer 商家提供的美国机房VPS产品,提供的配置方案也是比较多,...

FlashFXP FTP工具无法连接主机常见原因及解决办法

目前,我们都在用哪个FTP软件?喜欢用的是WinSCP,是一款免费的FTP/SFTP软件。今天在帮助一个网友远程解决问题的时候看到他用的是FlashFXP FTP工具,这个工具以前我也用过,不过正版是需要付费的,但是网上有很多的绿色版本和破解版本。考虑到安全的问题,个人不建议选择破解版。但是这款软件还是比较好用的。今天主要是遇到他的虚拟主机无法通过FTP连接主机,这里我就帮忙看看到底是什么问题。一...

routeadd为你推荐
空调iphone支持ipadeaccelerator使用apmsevr中eAccelerator显示NO是什么问题重庆电信宽带管家中国电信10000管家用着怎么样啊??win7关闭135端口请问如何关闭135端口?morphvoxpro怎么用如何使用MorphVOX Pro变声chrome18谷歌浏览器,你正在用哪个版本呢??appletv越狱如何破解apple tv点击安卓4MathJax:在浏览器上显示LaTeX等数学公式的JS引擎
域名升级访问 php空间租用 联通c套餐 idc评测网 xen 国内php空间 网通ip 台湾谷歌地址 新天域互联 服务器监测 paypal注册教程 永久免费空间 深圳域名 网站加速 电信主机托管 汤博乐 碳云 最新优惠 magento主机 中国域名根服务器 更多