Protocols and the TCP/IP model · Protocolos y el modelo TCP/IP
| English | Español |
|---|---|
| protocol/ˈprəʊtəkɒl/ | protocolo |
| TCP/ˌtiː siː ˈpiː/ | TCP |
| UDP/ˌjuː diː ˈpiː/ | UDP |
| modularity/ˌmɒdjʊˈlærɪti/ | modularidad |
| link layer/lɪŋk ˈleɪə/ | capa de enlace |
| abstraction/əbˈstrækʃn/ | abstracción |
| application layer/ˌæplɪˈkeɪʃn ˈleɪə/ | capa de aplicación |
| transport layer/ˈtrænspɔːt ˈleɪə/ | capa de transporte |
| port numbers/pɔːt ˈnʌmbəz/ | números de puerto |
| internet layer/ˈɪntənet ˈleɪə/ | capa internet |
| packets/ˈpækɪts/ | paquetes |
| IP address/ˌaɪ ˈpiː əˈdres/ | dirección IP |
| routers/ˈruːtəz/ | routers |
| MAC addresses/mæk əˈdresɪz/ | direcciones MAC |
| connection-oriented/kəˈnekʃn ˈɔːrɪəntɪd/ | orientado a conexión |
| connectionless/kəˈnekʃənləs/ | sin conexión |
| layering/ˈleɪərɪŋ/ | capas |
The two-word message that started the internet
- On 29 October 1969 a student at UCLA typed the word LOGIN to a machine at Stanford, one letter at a time, with a colleague on the telephone confirming each one. After L and O the system crashed.
- The problem was never the wire. It was that two machines built by different companies had no agreed rules about what a byte meant, when to speak, or what to do when something was lost.
- Everything since has been the writing down of those rules. A protocol 协议 is that agreement, and the internet is a stack of them.
- This lesson is why protocols exist, why they are layered 分层, the four TCP/IP layers, and the difference between TCP and UDP.
El mensaje de dos palabras que dio inicio a internet
- El 29 de octubre de 1969, un estudiante en UCLA escribió la palabra LOGIN a una máquina en Stanford, letra por letra, mientras un colega confirmaba cada una por teléfono. Después de L y O, el sistema se bloqueó.
- El problema nunca fue el cable. Fue que dos máquinas construidas por diferentes empresas no tenían reglas acordadas sobre qué significaba un byte, cuándo hablar o qué hacer cuando se perdía algo.
- Todo lo que ha venido después ha sido la escritura de esas reglas. Un protocolo es ese acuerdo, e internet es una pila de ellos.
- Esta lección explica por qué existen los protocolos, por qué están capados, las cuatro capas TCP/IP y la diferencia entre TCP y UDP.
What a protocol defines
- A protocol is a set of rules for how devices communicate. Both ends must follow the same rules, or one side's signals are meaningless to the other.
- It defines the format of the data, where the addresses sit and where the payload starts; the order of messages, who speaks first and when to acknowledge; the meaning of each message; the timing, timeouts and retransmissions; and what to do on an error.
- Without one, communication fails completely, the way two people with no shared language fail.
Rules agreed in advance, by both ends
Qué define un protocolo
- Un protocolo es un conjunto de reglas para cómo se comunican los dispositivos. Ambos extremos deben seguir las mismas reglas, de lo contrario, las señales de un lado son sin sentido para el otro.
- Define el formato de los datos, dónde se sitúan las direcciones y dónde comienza la carga útil; el orden de los mensajes, quién habla primero y cuándo se confirma; el significado de cada mensaje; el temporizado, tiempos de espera y retransmisiones; y qué hacer ante un error.
- Sin uno, la comunicación falla completamente, igual que dos personas sin un idioma común.

Reglas acordadas de antemano, por ambos extremos
A network protocol is: · Un protocolo de red es:
A protocol defines the format, order, meaning, timing and error handling of messages — both ends must agree. · Un protocolo define el formato, orden, significado, temporización y manejo de errores de los mensajes; ambos extremos deben estar de acuerdo.
What does a protocol define? Select all · todos that apply. · ¿Qué define un protocolo? Selecciona todos los que correspondan.
Format, order, meaning, timing and error handling. The cable's speed is a property of the hardware, not of the agreement. · Formato, orden, significado, temporización y manejo de errores. La velocidad del cable es una propiedad del hardware, no del acuerdo.
Why the protocols are layered
- Networking is too complex for one set of rules, so it is split into layers, each with one focused job, each talking only to the layer above and the layer below. The implementation is a stack.
- Modularity 模块化: one layer can be replaced without touching the others, so swapping Ethernet for Wi-Fi changes nothing above the link layer.
- Standardisation: equipment from different vendors interoperates because each layer's interface is agreed. Abstraction 抽象: a programmer writing a web app ignores everything the lower layers handle.
Four layers, each with one job
Por qué los protocolos están capados
- La red es demasiado compleja para un solo conjunto de reglas, por lo que se divide en capas, cada una con un trabajo enfocado, cada una hablando solo con la capa superior y la inferior. La implementación es una pila.
- Modularidad: una capa puede reemplazarse sin tocar las otras, así como cambiar Ethernet por Wi-Fi no cambia nada por encima de la capa de enlace.
- Estandarización: el equipo de diferentes fabricantes interoperan porque la interfaz de cada capa está acordada. Abstracción: un programador que escribe una aplicación web ignora todo lo que manejan las capas inferiores.

Cuatro capas, cada una con un trabajo
A benefit of splitting networking into layers is: · Una ventaja de dividir la red en capas es:
Each layer has one job and a clear interface, so (e.g.) Ethernet can be swapped for Wi-Fi without touching higher layers. · Cada capa tiene una sola tarea y una interfaz clara, así que (por ejemplo) Ethernet puede intercambiarse por Wi-Fi sin tocar las capas superiores.
The four TCP/IP layers
| Layer | Purpose | Examples |
|---|---|---|
| application layer 应用层 | services for user programs, and the protocols they speak | HTTP, FTP, SMTP, IMAP |
| transport layer 传输层 | end-to-end delivery between processes, identified by port numbers 端口号 | TCP, UDP |
| internet layer 网络层 | carrying packets 数据包 between hosts by IP address IP地址, forwarded by routers 路由器 | IP |
| link layer 链路层 | sending bits over one physical link, framing with MAC addresses MAC地址 | Ethernet, Wi-Fi |
- The internet layer does not guarantee delivery. That is the transport layer's job, and only if TCP is used.
Las cuatro capas TCP/IP
| Capa | Propósito | Ejemplos |
|---|---|---|
| capa de aplicación | servicios para programas de usuario y los protocolos que hablan | HTTP, FTP, SMTP, IMAP |
| capa de transporte | entrega de extremo a extremo entre procesos, identificados por números de puerto | TCP, UDP |
| capa de internet | envío de paquetes entre hosts mediante direcciones IP, reenviado por routers | IP |
| capa de enlace | envío de bits a través de un enlace físico, enmarcado con direcciones MAC | Ethernet, Wi-Fi |
- La capa de internet no garantiza la entrega. Ese es el trabajo de la capa de transporte, y solo si se usa TCP.
Tap the four layers of the TCP/IP model · Toca las cuatro capas del modelo TCP/IP
Explore each layer. Data travels DOWN the stack as it's sent (each layer adds its header) and back UP as it's received — and any layer can be swapped without touching the others. · Explora cada capa. Los datos viajan HACIA ABAJO por la pila al enviarse (cada capa añade su encabezado) y hacia ARRIBA al recibirse, y cualquier capa puede intercambiarse sin tocar las demás.
Match each TCP/IP layer to its job. · Asocia cada capa TCP/IP con su función.
Application = user protocols; Transport = TCP/UDP delivery; Internet = IP routing; Link = bits on the medium. · Aplicación = protocolos del usuario; Transporte = entrega TCP/UDP; Internet = enrutamiento IP; Enlace = bits en el medio.
The internet layer (IP) guarantees that every packet arrives. · La capa internet (IP) garantiza que cada paquete llegue.
IP forwards packets and does not guarantee delivery. Reliability is added above it, by TCP, and UDP deliberately does without it. · IP forwarding de paquetes y no garantiza la entrega. La confiabilidad se añade encima, por TCP, y UDP deliberadamente carece de ella.
Worked example: a message crossing the internet
- Describe what happens at each layer when a browser requests a page from a server.
- Application: the browser builds an HTTP request for the page.
- Transport: TCP splits it into segments, adds the port numbers, and will acknowledge and retransmit anything lost.
- Internet: IP adds the source and destination IP addresses to each packet, and routers forward it hop by hop across networks.
- Link: each hop puts the packet in a frame with MAC addresses and sends the bits over the cable or radio. At the server the layers are unwrapped in reverse.
Ejemplo resuelto: un mensaje cruzando internet
- Describe qué sucede en cada capa cuando un navegador solicita una página de un servidor.
- Aplicación: el navegador construye una solicitud HTTP para la página.
- Transporte: TCP la divide en segmentos, añade los números de puerto y confirmará y retransmitirá cualquier cosa perdida.
- Internet: IP añade las direcciones IP de origen y destino a cada paquete, y los routers lo reenvían salto a salto a través de redes.
- Enlace: cada salto coloca el paquete en un marco con direcciones MAC y envía los bits por el cable o radio. En el servidor, las capas se desenrollan en sentido inverso.
Put the TCP/IP layers in order, from the user's program down to the wire. · Coloca las capas TCP/IP en orden, desde el programa del usuario hasta el cable.
Each layer wraps the one above; at the far end they are unwrapped in reverse order. · Cada capa envuelve a la superior; en el extremo opuesto se desenrollan en orden inverso.
TCP and UDP
- TCP 传输控制协议 is connection-oriented 面向连接: it sets up a connection first, ensures all data arrives and in order, retransmits lost packets and controls flow. Reliable, at the cost of overhead and delay. Used by HTTP, HTTPS, SMTP and FTP.
- UDP 用户数据报协议 is connectionless 无连接: it sends and forgets, with no acknowledgements, no ordering and no retransmission. Low overhead, no guarantees.
- UDP is used for live streaming, DNS and online gaming, where speed beats reliability: a retransmitted video frame would arrive after the moment it was needed, so dropping it is better than waiting.
Guaranteed and slower, or fast and unguaranteed
TCP y UDP
- TCP es orientado a conexión: establece una conexión primero, asegura que lleguen todos los datos y en orden, retransmite paquetes perdidos y controla el flujo. Fiable, al costo de sobrecarga y retraso. Usado por HTTP, HTTPS, SMTP y FTP.
- UDP es sin conexión: envía y olvida, sin confirmaciones, sin ordenamiento ni retransmisión. Baja sobrecarga, sin garantías.
- UDP se usa para transmisión en vivo, DNS y juegos en línea, donde la velocidad supera la fiabilidad: un fotograma de video retransmitido llegaría después del momento en que era necesario, por lo que perderlo es mejor que esperar.

Garantizado y más lento, o rápido y sin garantía
How does TCP differ from UDP? · ¿Cómo difiere TCP de UDP?
TCP sets up a connection and ensures reliable, ordered delivery (with overhead); UDP is fire-and-forget. · TCP establece una conexión y asegura entrega confiable y ordenada (con sobrecarga); UDP es disparar y olvidar.
TCP is connection-oriented and guarantees ordered, complete delivery (with overhead), while UDP is fire-and-forget — faster but with no delivery guarantee. · TCP es orientado a conexión y garantiza entrega ordenada y completa (con sobrecarga), mientras que UDP es disparar y olvidar: más rápido pero sin garantía de entrega.
That's why UDP suits live streaming, gaming and DNS, but TCP is used for files, email and secure web pages where every byte must arrive. · Por eso UDP se adapta a transmisión en vivo, juegos y DNS, pero TCP se usa para archivos, correo electrónico y páginas web seguras donde debe llegar cada byte.
Live video streaming uses ____ because speed matters more than retransmitting lost packets. · La transmisión de video en vivo usa ____ porque la velocidad importa más que retransmitir paquetes perdidos.
A resent frame would arrive after the moment it was needed, so dropping it beats waiting. TCP's guarantees are worth their cost for a payment page. · Un marco reenviado llegaría después del momento en que era necesario, así que descartarlo es mejor que esperar. Las garantías de TCP valen su costo para una página de pago.
Worked example: choose the transport protocol
- A company streams a live sports match and also sells tickets through a web page. Which transport protocol for each, and why?
- The live stream: UDP. A lost frame is worthless by the time it could be resent, so speed and low delay matter more than completeness, and the viewer would rather lose a frame than watch the picture stall.
- The ticket page: TCP. Every byte of the payment and booking must arrive, correct and in order, so the acknowledgements and retransmissions are worth their overhead.
- Name the protocol, then give the property of the data that decides it.
Ejemplo resuelto: elegir el protocolo de transporte
- Una empresa transmite un partido deportivo en vivo y también vende entradas a través de una página web. ¿Qué protocolo de transporte para cada uno, y por qué?
- Transmisión en vivo: UDP. Un fotograma perdido no tiene valor para cuando podría ser reenviado, por lo que la velocidad y baja latencia importan más que la integridad, y el espectador prefiere perder un fotograma a ver la imagen congelada.
- Página de entrada: TCP. Cada byte del pago y la reserva debe llegar, correcto y en orden, por lo que las confirmaciones y retransmisiones valen su sobrecarga.
- Nombra el protocolo, luego da la propiedad de los datos que lo decide.
Marks that slip away
- A protocol is a set of rules, not a program or a cable. Name at least two of the things it defines.
- The benefit of layering is modularity, standardisation and abstraction, not "it is faster".
- IP does not guarantee delivery; TCP does. Do not credit the internet layer with reliability.
- UDP is not "worse". It is chosen where speed beats reliability, and the answer must say which kind of data that is.
Puntos que se pierden
- Un protocolo es un conjunto de reglas, no un programa ni un cable. Nombra al menos dos de las cosas que define.
- El beneficio de la capada es modularidad, estandarización y abstracción, no "es más rápido".
- IP no garantiza la entrega; TCP sí. No otorgues confiabilidad a la capa de internet.
- UDP no es "peor". Se elige donde la velocidad supera la fiabilidad, y la respuesta debe decir qué tipo de datos es ese.
You've got it
- a protocol is agreed rules for format, order, meaning, timing and error handling, followed by both ends
- protocols form a stack of layers, giving modularity, standardisation and abstraction
- TCP/IP layers: application (HTTP, SMTP), transport (TCP, UDP, port numbers), internet (IP addresses, routers), link (Ethernet, Wi-Fi, MAC addresses)
- TCP is connection-oriented, ordered and reliable; UDP is connectionless with no guarantees, for streaming, DNS and gaming
Lo has logrado
- un protocolo son reglas acordadas para formato, orden, significado, temporizado y manejo de errores, seguidas por ambos extremos
- los protocolos forman una pila de capas, dando modularidad, estandarización y abstracción
- capas TCP/IP: aplicación (HTTP, SMTP), transporte (TCP, UDP, números de puerto), internet (direcciones IP, routers), enlace (Ethernet, Wi-Fi, direcciones MAC)
- TCP es orientado a conexión, ordenado y fiable; UDP es sin conexión sin garantías, para streaming, DNS y juegos