حاسبة تجزئة عناوين IP

تقوم حاسبة تجزئة الشبكات IP بإجراء حسابات الشبكات الفرعية لعنوان الشبكة وقناع الشبكة وعنوان IP المحدد. تدعم تجزئة IPv4 و IPv6 مع تحويل CIDR كامل ونطاقات الأجهزة المتاحة وعناوين البث وأقنعة البدل والتمثيل الثنائي.

حاسبة شبكات IPv4 الفرعية

حاسبة شبكات IPv6 الفرعية

الشبكات الفرعية الشائعة لـ IPv4:

البادئة قناع الشبكة الفرعية الأجهزة المتاحة لكل شبكة فرعية إجمالي الشبكات الفرعية
Class A
/8 255.0.0.0 16,777,214 1
/9 255.128.0.0 8,388,606 2
/10 255.192.0.0 4,194,302 4
/11 255.224.0.0 2,097,150 8
/12 255.240.0.0 1,048,574 16
/13 255.248.0.0 524,286 32
/14 255.252.0.0 262,142 64
/15 255.254.0.0 131,070 128
Class B
/16 255.255.0.0 65,534 1
/17 255.255.128.0 32,766 2
/18 255.255.192.0 16,382 4
/19 255.255.224.0 8,190 8
/20 255.255.240.0 4,094 16
/21 255.255.248.0 2,046 32
/22 255.255.252.0 1,022 64
/23 255.255.254.0 510 128
Class C
/24 255.255.255.0 254 1
/25 255.255.255.128 126 2
/26 255.255.255.192 62 4
/27 255.255.255.224 30 8
/28 255.255.255.240 14 16
/29 255.255.255.248 6 32
/30 255.255.255.252 2 64
/31 255.255.255.254 0 (2 for RFC 3021) 128
/32 255.255.255.255 1 256
حلول حساب الكسور وقياسات تقسيم الشبكات

غالباً ما تتطلب مخصصات النطاق الترددي للشبكة ومساحات وحدات خوادم الرفوف ونسب تقسيم الكتل الفرعية حسابات كسور دقيقة. يمكنك جمع وطرح وضرب وقسمة الأعداد الكسرية مع خطوات التبسيط والتحويل العشري.

إعدادات سريعة شائعة:

الدليل الشامل لتجزئة شبكات IPv4 و IPv6 وبنية CIDR

تجزئة الشبكات (Subnetting) هي التقنية الرياضية الأساسية المستخدمة في شبكات الحاسوب لتقسيم شبكة فيزيائية أو افتراضية كبيرة إلى شبكات فرعية أصغر ومنظمة منطقياً. من خلال تجزئة مساحات عناوين IP، يعزز مهندسو الشبكات الأمان عبر عزل التحكم في الوصول، واحتواء عواصف البث، وتقليل زمن الاستجابة، وضمان الحفاظ على عناوين IPv4 إلى أقصى حد. يعد فهم توجيه النطاقات غير المصنفة (CIDR) وأقنعة الشبكات الفرعية الثنائية مطلباً أساسياً لمهندسي الشبكات والحلول السحابية والأمن السيبراني.

1. الأسس الرياضية لتجزئة شبكات IPv4

An IPv4 address consists of 32 binary bits arranged into four 8-bit bytes called octets, separated by periods (e.g., 192.168.1.1). Every IP address is fundamentally divided into two segments: the Network Prefix (which identifies the subnet) and the Host Identifier (which identifies the individual interface or host on that subnet). (which identifies the individual interface or host on that subnet).

  • Bitwise AND Operation: A router determines the network address by performing a logical bitwise AND between the 32-bit IP address and the 32-bit subnet mask. Wherever the mask bit is 1, the IP bit is preserved; wherever the mask bit is 0, the result is forced to 0.
  • Total Host Formula: If a subnet mask reserves h host bits (where h = 32 - CIDR), the total number of IP addresses in the subnet is 2^h.
  • Usable Host Formula: In standard IPv4 networking, two addresses are reserved and cannot be assigned to endpoints: the Network Address (where all host bits are binary 0) and the Broadcast Address (where all host bits are binary 1). Therefore, the number of usable hosts is 2^h - 2.
  • Point-to-Point /31 Subnets (RFC 3021): For direct router-to-router point-to-point serial links, RFC 3021 eliminates dedicated network and broadcast addresses, allowing both addresses in a /31 block to be assigned to the two peer router interfaces, conserving vast blocks of IPv4 space.

2. نطاقات IP الخاصة (RFC 1918) مقابل التوجيه العام

لمنع النفاد المبكر لمجموعة عناوين IPv4 العالمية البالغة 4.29 مليار عنوان، خصصت مجموعة مهندسي الإنترنت (IETF) ثلاث كتل IPv4 خاصة بموجب وثيقة RFC 1918 يُضمن عدم توجيهها على شبكة الإنترنت العامة:

  • 10.0.0.0/8 (Class A Private): Range: 10.0.0.0 to 10.255.255.255 (16,777,216 total addresses). Ideal for large enterprise campus networks, global WANs, and cloud multi-tier VPC topologies.
  • 172.16.0.0/12 (Class B Private): Range: 172.16.0.0 to 172.31.255.255 (1,048,576 addresses across 16 contiguous /16 blocks). Frequently used in mid-sized enterprise networks, virtualization clusters, and Docker/Kubernetes container overlays.
  • 192.168.0.0/16 (Class C Private): Range: 192.168.0.0 to 192.168.255.255 (65,536 addresses across 256 contiguous /24 blocks). Standard default for home routers, small-office/home-office (SOHO) Wi-Fi networks, and lab benches.
  • 100.64.0.0/10 (Carrier-Grade NAT / CGNAT - RFC 6598): Range: 100.64.0.0 to 100.127.255.255 (4,194,304 addresses). Used by ISPs to aggregate multiple residential subscribers behind shared public IPv4 gateways.

3. بنية IPv6 والبادئة الإلزامية /64

IPv6 replaces IPv4's 32-bit limitation with a massive 128-bit address space, representing 2^128 (approximately 340 undecillion) unique addresses. IPv6 addresses are written as eight groups of four hexadecimal digits (hextets) separated by colons. (approximately 340 undecillion) unique addresses. IPv6 addresses are written as eight groups of four hexadecimal digits (hextets) separated by colons.

  • Global Routing Prefix (Typically /48 to /56): Assigned by Regional Internet Registries (RIRs) and ISPs to enterprises and organizations.
  • Subnet Identifier (Bits 48 through 64): Gives an enterprise up to 65,536 distinct /64 subnets from a single /48 assignment.
  • Interface Identifier (Bits 64 through 128): RFC 4291 mandates that standard subnets use a /64 prefix to allow Stateless Address Autoconfiguration (SLAAC). Each individual /64 subnet contains 18,446,744,073,709,551,616 unique host addresses.

4. تجزئة شبكات السحابة الافتراضية VPC (AWS و Azure و GCP)

عند تصميم الشبكات الفرعية في بيئات السحابة الرائدة مثل Amazon Web Services (AWS VPC) و Microsoft Azure و Google Cloud Platform (GCP VPC)، يحجز موفرو الخدمات السحابية عناوين IP إضافية داخل كل شبكة فرعية لخدمات البنية التحتية:

  • .0: Network address.
  • .1: VPC router / default gateway address.
  • .2: DNS resolver service (Amazon Provided DNS or Azure DNS).
  • .3: Cloud internal management or broadcast emulation.
  • .255: Network broadcast address.

Consequently, in an AWS VPC, a /24 subnet provides 251 usable host IP addresses rather than the traditional on-premise count of 254. Keep this cloud reserve in mind when sizing subnets for Kubernetes node pools or elastic load balancer clusters.

الأسئلة الشائعة (FAQ)

كيف أجد عنوان الشبكة وعنوان البث من عنوان IP و CIDR؟ ▾
قم بتحويل كل من عنوان IP وقناع الشبكة إلى أعداد صحيحة ثنائية من 32 بت. نفّذ عملية AND منطقية بين الـ IP والقناع للحصول على عنوان الشبكة. ثم اعكس قناع الشبكة لحساب قناع البدل (Wildcard)، ونفّذ عملية OR بين عنوان الشبكة وقناع البدل للحصول على عنوان البث.
لماذا توفر شبكة /30 عنواني IP متاحين فقط؟ ▾
تترك بادئة /30 عدد 32 - 30 = 2 بت للأجهزة المضيفة. إجمالي عدد العناوين هو 2^2 = 4. وبما أن العنوان الأول محجوز كمعرف للشبكة والعنوان الرابع محجوز كعنوان بث، يتبقى بالضبط 4 - 2 = 2 من العناوين القابلة للاستخدام، مما يجعل /30 المعيار التقليدي لروابط WAN بين نقطتين.
ما الفرق بين العنونة المصنفة (Classful) وغير المصنفة (CIDR)؟ ▾
قامت العنونة المصنفة (RFC 791) بتصنيف عناوين IP بشكل صارم إلى الفئة A (/8) والفئة B (/16) والفئة C (/24)، مما تسبب في إهدار هائل للعناوين. ألغى نظام CIDR (RFC 1519) هذه الحدود الثابتة، مما سمح بأقنعة شبكة فرعية بأي طول بادئة (/1 إلى /32) وأتاح تجميع مسارات التوجيه بمرونة.
كيف تعمل أقنعة البدل (Wildcard) في إعدادات موجهات Cisco؟ ▾
يخبر قناع البدل (Wildcard Mask) الموجه بالبتات التي يجب أن تتطابق (حيث البت 0) والبتات التي يمكن تجاهلها أو تغييرها (حيث البت 1). يُحسب بطرح قناع الشبكة من 255.255.255.255. على سبيل المثال، لشبكة /26 (قناع 255.255.255.192)، يكون قناع البدل هو 0.0.0.63.

آخر مراجعة: