Tuesday, April 23, 2013

What will happen if we don’t override the hashcode method?



  • What will happen if we don’t override the hashcode method?


If two objects are same then they must return same value in hashcode() and equals() method whenever invoked.
It is not necessary that two different object must have different hashcode values. it might be possible that they share common hash bucket.

JVM assigns unique hashcode value to each object when they are created in memory
if developers don’t override the hashcode method then there is no way the two object returns same hashcode value.

equals() method is used to compare objects that they are having same value or not but why should we override the hashcode method ?
The answer to the question is for the hash technique based data structures like HashMap and HashTable.

every object is placed in Hash bucket depending on the hashcode they have
It is not necessary that every different object must have different hashcode
hashcode is used to narrow the search result

When we try to insert any key in HashMap first it checks whether any other object present with same hashcode and
if yes then it checks for the equals() method.
If two objects are same then HashMap will not add that key
instead it will replace the old value by new one.

http://shivasoft.in/blog/java/what-is-the-need-to-override-hashcode-and-equals-method/

Wednesday, April 17, 2013

Software design document



  • Software design document

A software design document (SDD) is a written description of a software product, that a software designer writes in order to give a software development team an overall guidance of the architecture of the software project.
There are two kinds of design documents called HLDD (high-level design document) and LLDD (low-level design document).
https://en.wikipedia.org/wiki/Software_design_document

Statement of work



  • Statement of work

A statement of work (SOW) is a formal document that captures and defines the work activities, deliverables, and timeline a vendor must execute in performance of specified work for a client. The SOW usually includes detailed requirements and pricing, with standard regulatory and governance terms and conditions.
https://en.wikipedia.org/wiki/Statement_of_work

Frameworx (NGOSS)



  • Frameworx (NGOSS)

Frameworx, formerly known as NGOSS or "New Generation Operations Systems and Software" is the TeleManagement Forum’s programme to provide ways to help Communication Service Providers to manage their business.
Frameworx includes a set of principles and technical deliverables.



2 Principles
    2.1 Separation of Business Process from Component Implementation
    2.2 Loosely Coupled Distributed System
    2.3 Shared Information Model
    2.4 Common Communications Infrastructure
    2.5 Contract defined interfaces


3 Technical Deliverables
    3.1 Process Model
    3.2 Shared Information Model
    3.3 Lifecycle Model
    3.4 Contract Specifications
    3.5 Telecom Application Map

https://en.wikipedia.org/wiki/Frameworx

Monday, April 15, 2013

Disk Performance Calculation



  • A disk is double interleaved, as in the figure bellow. 

It has 8 sectors of 512 bytes per track, and a rotation rate of 300 rpm

a)How long does it take to read all the sectors of a
track in order, assuming the arm is already
correctly positioned , and 1/2 rotation is needed to
get a sector 0 under the head?
b) What's the data rate?
c) Now repeat the problem for a non-interleaved disk with the same characteristics
d) How much does the data rate degrade due to interleaving?



300 rpm means that one complete turn
takes (60 sec * 1000 ms) / 300 rpm = 200 ms
Thus one sector needs 200 ms / 8 = 25 ms
To read all the sectors in order the head has to
go over 22 sectors starting from sector 0 (0-
3-6-1-4-7-2-5-0-3-6-1-4-7-2-5-0-3-6-1-4-7)
what takes 22*25 ms = 550 ms

a) 550 ms + 200 ms / 2 = 650 ms
Effective access time = seek time + latency time +
data transfer time = 0 + 200 ms / 2 + 550 ms = 650
ms, thus
b) data rate = (8 * 512 bytes / 650 ms) * 1000 ms/sec
˜ 6302 bytes / sec
c) read all the sectors: 8*25 ms + 200 ms / 2 = 300 ms
data rate = (8 * 512 bytes / 300 ms) * 1000 ms/sec =
13653 bytes / sec
d) the difference in data rate is 13653 bytes / sec –
6302 bytes / sec = 7351 bytes / sec

http://disi.unitn.it/~ilya/Download/os_course/input_output_lab.pdf




  • Disk Performance


Given the following Disk Parameters:
– Average seek time is 5 ms
– Disk spins at 10,000 RPM
– Transfer rate is 40 MB/sec

What is Average Disk read or write time for a 512-byte Sector?

Ave. seek + ave. rot delay + transfer time + controller overhead
5 ms + 0.5/(10000 RPM/60) + 0.5 KB/40 MB/s + 0.1 ms
 5 + 3 + 0.13 + 0.1 = 8.23 ms

 http://meseec.ce.rit.edu/eecc551-winter2003/551-exam-review-winter2003.pdf




  • Performance Example

How long does it take to read a 512 byte block from the disk?
How long does it take to read two 512 byte blocks from the disk?
http://williams.comp.ncat.edu/comp375/disk.pdf


  • Disk Performance Example


• Calculate time to read 512-byte sector for a disk.
Average seek time is 5ms,
the transfer rate is 40 MB/sec,
it rotates at 10,000 RPM, and
the controller overhead is 0.1 ms.
• Disk latency = average seek time +
average rotational delay + transfer time +
controller overhead

= 5 ms+ 0.5 * 1/(10000 RPM) + 512 B / (40 MB/s) + 0.1 ms
=5+3+0.013+0.1=8.11ms

https://docs.google.com/presentation/d/1zBhbZZoejmApfDjDkBvYg50DJ_4Aoq4EzGB_e_AYeLU/edit#slide=id.p5




  1. Disk Performance


Average Disk Access Time= average rotation time+ average seek time+data transfer time+controller overhead time.

For a disk with 7200RPM, the average rotation time= 0.5 rotations/7200RPM= 0.00415 sec

What is the average time to read/write a 512 byte sector for a typical disk:

average seeek time=9ms,
data transfer rate is 4MB/s,
RPM=7200,
controller overhead=1 ms.
Assume no queueing delay.

Ans: 9ms+(0.5/(7200/60))*1000 ms+0.5KB/4.0MB/s+1ms=9+4.15+0.125+1=14.3 ms.
http://cs.uccs.edu/~cs520/S99ch6.PDF



How does Assembly Code run on a microprocessor?


every program that is run on a computer is being executed inside the processor
The microprocessor or Central Processing Unit (CPU) is the heart of the computer
it is the piece of hardware that carries out the tasks or instructions sent to it by the user or operating system

 A program is a set of instructions that are written in a higher-level language, like C/C++ and Java, and translated to a lower-level language by the compiler to assembly and then object or machine code, 1’s and 0’s
 assembler and compiler maps the human readable instructions to machine code, in order to be read by the computer.

 the only language the computer hardware, including the processor, understands is Machine Language

 To code in machine language directly would be problematic and very confusing, so programmers invented a lower-level language called assembly language. Assembly language is just machine language translated to a human readable format that is standardized.

 Just like English there are many different types of assembly languages and each one is specific to the processor it is running on

 The simplest and widely used assembly language is MIPS.
 The MIPS architecture uses only three formats to organize its 128 different types of instructions.
 In a 32-bit architecture each instruction is 32 bits wide and the first six bits (opcode) represent the instruction the processor needs to execute.


 There are three stages in the cycle of the programs execution: Fetch, Decode, and Execute

 The first stage, Fetch, fetches the current instruction from the memory and stores it into the PC or program counter.
 In the decode stage, the instruction is decoded so the processor knows what to do
 The last stage, execute, executes the current decoded instruction.

 This cycle then repeats after PC is incremented by 4, to load the next instruction.
 Once all instructions are done executing the program is done executing.

 http://www.personal.psu.edu/scb5156/assignment5.html

Binary Arithmetic Operations



  • Rules of Binary Addition


0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
1 + 1 = 0, and carry 1 to the next more significant bit
For example,

00011010 + 00001100 = 00100110                1  1 carries
  0  0  0  1  1  0  1  0   =   26(base 10)
+ 0  0  0  0  1  1  0  0
   =   12(base 10)
  0  0  1  0  0  1  1  0   =   38(base 10)


00010011 + 00111110 = 01010001         1  1  1  1  1 carries
  0  0  0  1  0  0  1  1   =   19(base 10)
+ 0  0  1  1  1  1  1  0
   =   62(base 10)
  0  1  0  1  0  0  0  1   =   81(base 10)
Note:  The rules of binary addition (without carries) are the same as the truths of the XOR gate.

http://academic.evergreen.edu/projects/biophysics/technotes/misc/bin_math.htm#add



  • Binary Subtraction Examples

It's almost exactly the same as decimal subtraction except that when you need to borrow, you borrow 2 instead of 10.

Here are some examples of binary subtraction. These are computed without regard to the word size, hence there can be no sense of "overflow" or "underflow". Work the columns right to left subtracting in each column. If you must subtract a one from a zero, you need to “borrow” from the left, just as in decimal subtraction.

http://sandbox.mc.edu/~bennet/cs110/pm/sub.html

two's complement

  • two's complement is the way every computer I know of chooses to represent integers. To get the two's complement negative notation of an integer, you write out the number in binary. You then invert the digits, and add one to the result.


Suppose we're working with 8 bit quantities (for simplicity's sake) and suppose we want to find how -28 would be expressed in two's complement notation. First we write out 28 in binary form.

00011100
Then we invert the digits. 0 becomes 1, 1 becomes 0.

11100011
Then we add 1.

11100100
That is how one would write -28 in 8 bit binary.



Example 2

Now suppose we want to subtract 12 from 69. Now, 69 - 12 = 69 + (-12). To get the negative of 12 we take its binary representation, invert, and add one.

0000 0000 0000 0000 0000 0000 0000 1100
Invert the digits.

1111 1111 1111 1111 1111 1111 1111 0011
And add one.

1111 1111 1111 1111 1111 1111 1111 0100
The last is the binary representation for -12. As before, we'll add the two numbers together.

1111 1111 1111 1111 1111 1111 1    1
Carry Row
  0000 0000 0000 0000 0000 0000 0100 0101
(69)
+ 1111 1111 1111 1111 1111 1111 1111 0100
(-12)
  0000 0000 0000 0000 0000 0000 0011 1001
(57)

We result in 57, which is 69-12.

Example 3

Lastly, we'll subtract 69 from 12. Similar to our operation in example 2, 12 - 69 = 12 + (- 69). The two's complement representation of 69 is the following. I assume you've had enough illustrations of inverting and adding one.

1111 1111 1111 1111 1111 1111 1011 1011
So we add this number to 12.
111  
Carry Row
  0000 0000 0000 0000 0000 0000 0000 1100
(12)
+ 1111 1111 1111 1111 1111 1111 1011 1011
(-69)
  1111 1111 1111 1111 1111 1111 1100 0111
(-57)

This results in 12 - 69 = -57, which is correct.

http://www.cs.cornell.edu/~tomf/notes/cps104/twoscomp.html





  • Arithmetic operations


Addition
Adding two's-complement numbers requires no special processing if the operands have opposite signs: the sign of the result is determined automatically. For example, adding 15 and −5:
 11111 111   (carry)
  0000 1111  (15)
+ 1111 1011  (−5)
==================
  0000 1010  (10)
This process depends upon restricting to 8 bits of precision; a carry to the (nonexistent) 9th most significant bit is ignored, resulting in the arithmetically correct result of 1010.

http://en.wikipedia.org/wiki/Two's_complement






  • Calculation of 2's Complement


To calculate the 2's complement of an integer, invert the binary equivalent of the number by changing all of the ones to zeroes and all of the zeroes to ones (also called 1's complement), and then add one.

For example,

0001 0001(binary 17)      1110 1111(two's complement -17)

NOT(0001 0001) = 1110 1110  (Invert bits)
1110 1110 + 0000 0001 = 1110 1111  (Add 1)


2's Complement Addition

Two's complement addition follows the same rules as binary addition.

For example,

5 + (-3)  =  2    0000 0101 = +5
+ 1111 1101
 = -3
  0000 0010 = +2



 2's Complement Subtraction

Two's complement subtraction is the binary addition of the minuend to the 2's complement of the subtrahend (adding a negative number is the same as subtracting a positive one).

For example,

7 - 12  =  (-5)    0000 0111 = +7
+ 1111 0100
 = -12
  1111 1011 = -5



2's Complement Multiplication
Two's complement multiplication follows the same rules as binary multiplication.


2's Complement Division
Two's complement division is repeated 2's complement subtraction. The 2's complement of the divisor is calculated, then added to the dividend. For the next subtraction cycle, the quotient replaces the dividend. This repeats until the quotient is too small for subtraction or is zero, then it becomes the remainder. The final answer is the total of subtraction cycles plus the remainder
http://academic.evergreen.edu/projects/biophysics/technotes/program/2s_comp.htm#calculate



  • two's complement notation
If you have -30, and want to represent it in 2's complement,

you take the binary representation of 30
0000 0000 0000 0000 0000 0000 0001 1110

Invert the digits.
1111 1111 1111 1111 1111 1111 1110 0001

And add one.
1111 1111 1111 1111 1111 1111 1110 0010


Suppose we're working with 8 bit quantities
suppose we want to find how -28 would be expressed in two's complement notation

First we write out 28 in binary form.
00011100

Then we invert the digits. 0 becomes 1, 1 becomes 0.
11100011

Then we add 1.
11100100

That is how one would write -28 in 8 bit binary.


Two's Complement
Begin with the number in one's complement.
Add 1 if the number is negative

12 would be represented as 00001100 and -12 as 11110100.

To verify this, let's subtract 1 from 11110100, to get 11110011. If we flip the bits, we get 00001100, or 12 in decimal.

http://www.math.grin.edu/~rebelsky/Courses/152/97F/Readings/student-binary#sign

Flip Flops



  • In the electronics world, a flip-flop is a type of circuit that contains two states and are often used to store state information. By sending a signal to the flip-flop, the state can be changed. In sequential logic, it is the basic element of storage. Flip-flops are used in a number of electronics, including computers and communications equipment.

http://www.computerhope.com/jargon/f/flipflop.htm


  • In electronics, a flip-flop or latch is a circuit that has two stable states and can be used to store state information. 

The circuit can be made to change state by signals applied to one or more control inputs and will have one or two outputs. It is the basic storage element in sequential logic. Flip-flops and latches are a fundamental building block of digital electronics systems used in computers, communications, and many other types of systems.

http://en.wikipedia.org/wiki/Flip-flop_(electronics)#Flip-flop_types



  • Flip-flops are heavily used for digital data storage and transfer and are commonly used in banks called "registers" for the storage of binary numerical data.

http://hyperphysics.phy-astr.gsu.edu/hbase/electronic/flipflop.html

Flip Flops basics:
•Storage elements for synchronous circuits (what is synchronous?)
•Typical configurations:
•SR (set_reset)
•D
•JK
•T (toggle)
http://www.engr.uky.edu/~elias/lectures/ln_13.pdf

Sunday, April 14, 2013

Associative array



  • Associative array

In computer science, an associative array, map, or dictionary is an abstract data type composed of a collection of  pairs, such that each possible key appears at most once in the collection.

The dictionary problem is the task of designing a data structure that implements an associative array. A standard solution to the dictionary problem is a hash table; in some cases it is also possible to solve the problem using directly addressed arrays, binary search trees, or other more specialized structures

Associative arrays have many applications including such fundamental programming patterns as memoization and the decorator pattern.

http://en.wikipedia.org/wiki/Associative_array

What is MultiValue Database?



  • What is MultiValue Database?

MultiValue is a type of NoSQL and multidimensional database, typically considered synonymous with PICK, a database originally developed as the Pick operating system.
These databases differ from a relational database in that they have features that support and encourage the use of attributes which can take a list of values, rather than all attributes being single-valued.
Unlike SQL-DBMS tools, most MultiValue databases can be accessed both with or without SQL.

Data model example
In a MultiValue database system:
a Database is called an "Account"
a Table is called a "file"
a Column is an "Attribute" or "Dictionary": attributes generally point at raw data, while dictionaries apply some transformation to the raw data

For example, assume there's a file (table) called "PERSON". And in this file there is a Dictionary (column) called "eMailAddress". The eMailAddress field can store a variable number of email address values in the single record.
So the list [joe@abc132.info, jdb@gbmail.net, joe_bacde@thisorthat.edu] can be stored and accessed via a single query / disk read when accessing the associated record.

To achieve the same (1-to-many) relationship within a Relational Database system one would be required to create an additional table to store the variable number of email Addresses associated to a single "PERSON" record.
http://en.wikipedia.org/wiki/MultiValue

jbase database


jbase database
jBase is a MultiValue Database software developed by jBASE International
http://www.jbase.com/

Matrix management


Matrix management
Matrix management is a type of organizational management in which people with similar skills are pooled for work assignments. For example, all engineers may be in one engineering department and report to an engineering manager, but these same engineers may be assigned to different projects and report to a different engineering manager or a project manager while working on that project. Therefore, each engineer may have to work under several managers to get his job done
http://en.wikipedia.org/wiki/Matrix_management

Thursday, April 11, 2013

Stages of Linux Boot Process

  • Linux Init Process:


BIOS: The Basic Input/Output System is the lowest level interface between the computer and peripherals.
The BIOS perform integrity checks on memory and seeks instructions on the Master Boor Record (MBR) on the floppy drive or hard drive.

The MBR points to the boot loader (GRUB or LILO: Linux boot loader).

Boot loader (GRUB or LILO) will then ask for the OS label which will identify which kernel to run and where it is located (hard drive and partition specified). The installation process requires to creation/identification of partitions and where to install the OS. GRUB/LILO are also configured during this process. The boot loader then loads the Linux operating system.

The first thing the kernel does is to execute init program. Init is the root/parent of all processes executing on Linux.

The first processes that init starts is a script /etc/rc.d/rc.sysinit

Based on the appropriate run-level, scripts are executed to start various processes to run the system and make it functional.

http://www.yolinux.com/TUTORIALS/LinuxTutorialInitProcess.html




  • 6 Stages of Linux Boot Process (Startup Sequence)


1-BIOS
BIOS stands for Basic Input/Output System
Performs some system integrity checks
Searches, loads, and executes the boot loader program.
It looks for boot loader in floppy, cd-rom, or hard drive. You can press a key (typically F12 of F2, but it depends on your system) during the BIOS startup to change the boot sequence.
Once the boot loader program is detected and loaded into the memory, BIOS gives the control to it.
So, in simple terms BIOS loads and executes the MBR boot loader.

2. MBR
MBR stands for Master Boot Record.
It is located in the 1st sector of the bootable disk. Typically /dev/hda, or /dev/sda
MBR is less than 512 bytes in size. This has three components 1) primary boot loader info in 1st 446 bytes 2) partition table info in next 64 bytes 3) mbr validation check in last 2 bytes.
It contains information about GRUB (or LILO in old systems).
So, in simple terms MBR loads and executes the GRUB boot loader.

3. GRUB
GRUB stands for Grand Unified Bootloader.
If you have multiple kernel images installed on your system, you can choose which one to be executed.
GRUB displays a splash screen, waits for few seconds, if you don’t enter anything, it loads the default kernel image as specified in the grub configuration file.
GRUB has the knowledge of the filesystem (the older Linux loader LILO didn’t understand filesystem).
So, in simple terms GRUB just loads and executes Kernel and initrd images.

4. Kernel
Mounts the root file system as specified in the “root=” in grub.conf
Kernel executes the /sbin/init program
Since init was the 1st program to be executed by Linux Kernel, it has the process id (PID) of 1. Do a ‘ps -ef | grep init’ and check the pid.
initrd stands for Initial RAM Disk.
initrd is used by kernel as temporary root file system until kernel is booted and the real root file system is mounted. It also contains necessary drivers compiled inside, which helps it to access the hard drive partitions, and other hardware.

5. Init
Looks at the /etc/inittab file to decide the Linux run level.
Following are the available run levels
0 – halt
1 – Single user mode
2 – Multiuser, without NFS
3 – Full multiuser mode
4 – unused
5 – X11
6 – reboot
Init identifies the default initlevel from /etc/inittab and uses that to load all appropriate program.
Execute ‘grep initdefault /etc/inittab’ on your system to identify the default run level
If you want to get into trouble, you can set the default run level to 0 or 6. Since you know what 0 and 6 means, probably you might not do that.
Typically you would set the default run level to either 3 or 5.

6. Runlevel programs
When the Linux system is booting up, you might see various services getting started. For example, it might say “starting sendmail …. OK”. Those are the runlevel programs, executed from the run level directory as defined by your run level.
Depending on your default init level setting, the system will execute the programs from one of the following directories.
Run level 0 – /etc/rc.d/rc0.d/
Run level 1 – /etc/rc.d/rc1.d/
Run level 2 – /etc/rc.d/rc2.d/
Run level 3 – /etc/rc.d/rc3.d/
Run level 4 – /etc/rc.d/rc4.d/
Run level 5 – /etc/rc.d/rc5.d/
Run level 6 – /etc/rc.d/rc6.d/
Please note that there are also symbolic links available for these directories under /etc directly. So, /etc/rc0.d is linked to /etc/rc.d/rc0.d.
Under the /etc/rc.d/rc*.d/ directories, you would see programs that start with S and K.
Programs starts with S are used during startup. S for startup.
Programs starts with K are used during shutdown. K for kill.
There are numbers right next to S and K in the program names. Those are the sequence number in which the programs should be started or killed.
For example, S12syslog is to start the syslog deamon, which has the sequence number of 12. S80sendmail is to start the sendmail daemon, which has the sequence number of 80. So, syslog program will be started before sendmail.

http://www.thegeekstuff.com/2011/02/linux-boot-process/

Wednesday, April 10, 2013

IPsec interview questions

  • IPsec

Internet Protocol Security (IPsec) is a protocol suite for securing Internet Protocol (IP) communications by authenticating and encrypting each IP packet of a communication session
Some other Internet security systems in widespread use, such as Secure Sockets Layer (SSL), Transport Layer Security (TLS) and Secure Shell (SSH), operate in the upper layers of the TCP/IP model. In the past, the use of TLS/SSL had to be designed into an application to protect the application protocols. In contrast, since day one, applications did not need to be specifically designed to use IPsec. Hence, IPsec protects any application traffic across an IP network.
http://en.wikipedia.org/wiki/IPsec


  • 85) What do mean by tunnel mode?

This is a mode of data exchange wherein two communicating computers do not use IPSec themselves. Instead, the gateway that is connecting their LANs to the transit network creates a virtual tunnel that uses the IPSec protocol to secure all communication that passes through it.

IPsec consist of several protocols
ISAKMP
IKE
ESP - protocol 50
AH - protocol 51

IPsec Modes
Transport Mode
Tunnel Mode

Encryption Algols
DES
3DES
AES
RSA

Hashing Algols
MD5
SHA-1

IKE Phases

Data integrity - HMAC
Data Confidentiality - Encryption
Data Origin Authentication - SA peer
anti-replay - sequence numbers
HMAC
Diffie-Hellman
http://networkqna.com/ipsec/


  • Q1 – In which IPSEC Phase is the keys used for data encryption derived.

Q2 – In IPSEC, If ESP provides both encryption and authentication, why is AH required.
Q3 – Explain two methods by which two IPSEC routers can authenticate with each other.
Q4 – Which UDP ports should be open on a firewall to allow traffic from a L2TP/IPSEC based VPN clients to a PPTP VPN server on the inside
Q5 -Which IP protocol does AH and ESP headers use in IPSEC
Q6 – Which type of VPN would you use if data has to be encrypted at the network layer
Q7 – What is the use of configuring ACL in IPSEC configuration on a Cisco router
Q8 – If a packet sniffer is used on the VPN tunnel can the inner IP header be viewed
Q9 – Are the pre-shared keys used between the routers used for data encryption between systems at the different sites.
Q10 – How does the IPSEC protocols, ESP and AH provide replay protection
http://tcpipguru.com/ipsec-interview-questions/

  • IPSEC - The Internet Protocol Security is a set of protocols that provides security features to IP; like authentication, encryption and confidentiality.
L2TP -Layer Two Tunneling Protocol is a tunneling protocol (VPN) used to transport in L2 traffic over an IP Network ( Internet)
L2TP as follows from the name, is a layer 2 tunneling protocol. So, it can tunnel Layer 2 frames over IPSEC. 
https://learningnetwork.cisco.com/s/question/0D53i00000Kt2n1/ipsec-vs-l2tp-over-ipsec

PPTP or Point-to-Point Tunneling Protocol is an outdated method for implementing VPNs. It is developed by Microsoft and the easiest protocol to configure. PPTP VPN has low overhead and that makes it faster than other VPN protocols.

L2TP or Layer 2 Tunneling Protocol (L2TP) is the result of a partnership between Cisco and Microsoft.
It was created to provide a more secure VPN protocol than PPTP. L2TP is a tunneling protocol like PPTP that allows users to access the common network remotely.
https://www.purevpn.com/blog/difference-between-pptp-and-l2tp-protocols/

IEEE 802.1X is an IEEE Standard for port-based Network Access Control (PNAC). It is part of the IEEE 802.1 group of networking protocols. It provides an authentication mechanism to devices wishing to attach to a LAN or WLAN.
https://en.wikipedia.org/wiki/IEEE_802.1X


What is the difference between a PAL and a PLA?


PLA is programmable logic array while PAL is Programmable Array Logic.

PLA is a kind of programmable logic device used to implement combinational logic circuit.
It has Programmable AND Gate linked with Programmable OR Gate.

PAL is an combinational PLD that was developed to overcome certain disadvantage of PLA.
PLA shows longer delay due to additional fusible links which results from using two programmable array and increase circuit complexity.
Thus, PAL is used which is less complex and fast to implement. PAL consists of programmable AND linked with fixed OR.
http://wiki.answers.com/Q/What_is_the_difference_between_a_PAL_and_a_PLA

CMOS vs TTL


  • What are the Basic Differences Between CMOS and TTL Signals?



CMOS compared to TTL:

CMOS components are typically more expensive that TTL equivalents.
However, CMOS technology is usually less expensive on a system level due to CMOS chips being smaller and requiring less regulation.

CMOS circuits do not draw as much power as TTL circuits while at rest.
However, CMOS power consumption increases faster with higher clock speeds than TTL does.  Lower current draw requires less power supply distribution, therefore causing a simpler and cheaper design.

Due to longer rise and fall times, the transmission of digital signals become simpler and less expensive with CMOS chips.

CMOS components are more susceptible to damage from electrostatic discharge than TTL compenents.

http://digital.ni.com/public.nsf/allkb/2D038D3AE1C35011862565A8005C5C63

microprocessors




  • DRAM

Dynamic random-access memory (DRAM) is a type of random-access memory that stores each bit of data in a separate capacitor within an integrated circuit.
http://en.wikipedia.org/wiki/DRAM



  • SDRAM

Synchronous dynamic random access memory (SDRAM) is dynamic random access memory (DRAM) that is synchronized with the system bus. Classic DRAM has an asynchronous interface, which means that it responds as quickly as possible to changes in control inputs.
SDRAM has a synchronous interface, meaning that it waits for a clock signal before responding to control inputs and is therefore synchronized with the computer's system bus
http://en.wikipedia.org/wiki/SDRAM



  • SRAM

Static random-access memory (SRAM) is a type of semiconductor memory that uses bistable latching circuitry to store each bit.
The term static differentiates it from dynamic RAM (DRAM) which must be periodically refreshed.
SRAM exhibits data remanence, but it is still volatile in the conventional sense that data is eventually lost when the memory is not powered.



  • Data remanence
Data remanence is the residual representation of data that remains even after attempts have been made to remove or erase the data. This residue may result from data being left intact by a nominal file deletion operation, by reformatting of storage media that does not remove data previously written to the media, or through physical properties of the storage medium that allow previously written data to be recovered
http://en.wikipedia.org/wiki/Data_remanence



  • Transistor–transistor logic

Transistor–transistor logic (TTL) is a class of digital circuits built from bipolar junction transistors (BJT) and resistors. It is called transistor–transistor logic because both the logic gating function (e.g., AND) and the amplifying function are performed by transistors
http://en.wikipedia.org/wiki/Transistor-transistor_logic

IP address classes

  • An Internet Protocol address (IP address) is a numerical label assigned to each device connected to a computer network that uses the Internet Protocol for communication.[1][2] An IP address serves two principal functions: host or network interface identification and location addressing.

    IP networks may be divided into subnetworks in both IPv4 and IPv6. For this purpose, an IP address is recognized as consisting of two parts: the network prefix in the high-order bits and the remaining bits called the rest field, host identifier, or interface identifier (IPv6), used for host numbering within a network.The subnet mask or CIDR notation determines how the IP address is divided into network and host parts.
      The term subnet mask is only used within IPv4. Both IP versions however use the CIDR concept and notation. In this, the IP address is followed by a slash and the number (in decimal) of bits used for the network part, also called the routing prefix. For example, an IPv4 address and its subnet mask may be 192.0.2.1 and 255.255.255.0, respectively. The CIDR notation for the same IP address and subnet is 192.0.2.1/24, because the first 24 bits of the IP address indicate the network and subnet.

          Private addresses
            Early network design, when global end-to-end connectivity was envisioned for communications with all Internet hosts, intended that IP addresses be globally unique. However, it was found that this was not always necessary as private networks developed and public address space needed to be conserved.
              Computers not connected to the Internet, such as factory machines that communicate only with each other via TCP/IP, need not have globally unique IP addresses. Today, such private networks are widely used and typically connect to the Internet with network address translation (NAT), when needed.
                Three non-overlapping ranges of IPv4 addresses for private networks are reserved.These addresses are not routed on the Internet and thus their use need not be coordinated with an IP address registry. Any user may use any of the reserved blocks. Typically, a network administrator will divide a block into subnets; for example, many home routers automatically use a default address range of 192.168.0.0 through 192.168.0.255 (192.168.0.0/24).

                    IPv6 addresses
                      In IPv6, the address size was increased from 32 bits in IPv4 to 128 bits, thus providing up to 2128 (approximately 3.403×1038) addresses
                        Private addresses
                          Just as IPv4 reserves addresses for private networks, blocks of addresses are set aside in IPv6. In IPv6, these are referred to as unique local addresses (ULAs).


                                IP address assignment
                                  Dynamic IP addresses are assigned using methods such as Zeroconf for self-configuration, or by the Dynamic Host Configuration Protocol (DHCP) from a network server. The address assigned with DHCP usually has an expiration period, after which the address may be assigned to another device, or to the originally associated host if it is still powered up. A network administrator may implement a DHCP method so that the same host always receives a specific address.

                                      Sticky dynamic IP address
                                        A sticky dynamic IP address is an informal term used by cable and DSL Internet access subscribers to describe a dynamically assigned IP address which seldom changes.
                                          The addresses are usually assigned with DHCP. If a modem is turned off and powered up again before the next expiration of the address lease, it often receives the same IP address.

                                              Routing
                                                Unicast addressing
                                                  The most common concept of an IP address is in unicast addressing, available in both IPv4 and IPv6. It normally refers to a single sender or a single receiver, and can be used for both sending and receiving.
                                                    Broadcast addressing
                                                      Broadcasting is an addressing technique available in IPv4 to send data to all possible destinations on a network in one transmission operation, while all receivers capture the network packet (all-hosts broadcast). The address 255.255.255.255 is used for network broadcast.IPv6 does not implement broadcast addressing, and replaces it with multicast to the specially-defined all-nodes multicast address
                                                        Multicast addressing
                                                          A multicast address is associated with a group of interested receivers. In IPv4, addresses 224.0.0.0 through 239.255.255.255 (the former Class D addresses) are designated as multicast addresses
                                                            IPv6 uses the address block with the prefix ff00::/8 for multicast applications. In either case, the sender sends a single datagram from its unicast address to the multicast group address and the intermediary routers take care of making copies and sending them to all receivers that have joined the corresponding multicast group.

                                                                Anycast addressing
                                                                  Like broadcast and multicast, anycast is a one-to-many routing topology.
                                                                    Anycast address is an inherent feature of only IPv6. In IPv4, anycast addressing implementations typically operate using the shortest-path metric of BGP routing and do not take into account congestion or other attributes of the path

                                                                        Public address
                                                                          A public IP address is a globally routable unicast IP address,
                                                                            Public IP addresses may be used for communication between hosts on the global Internet.

                                                                                Firewalling
                                                                                  For security and privacy considerations, network administrators often desire to restrict public Internet traffic within their private networks. The source and destination IP addresses contained in the headers of each IP packet are a convenient means to discriminate traffic by IP address blocking or by selectively tailoring responses to external requests to internal servers. This is achieved with firewall software running on the networks gateway router. A database of IP addresses of permissible traffic may be maintained in blacklists or whitelists.

                                                                                      Address translation
                                                                                        Multiple client devices can appear to share an IP address, either because they are part of a shared hosting web server environment or because an IPv4 network address translator (NAT) or proxy server acts as an intermediary agent on behalf of the client, in which case the real originating IP address might be masked from the server receiving a request.
                                                                                          A common practice is to have a NAT mask a large number of devices in a private network. Only the "outside" interface(s) of the NAT needs to have an Internet-routable address.
                                                                                            Commonly, the NAT device maps TCP or UDP port numbers on the side of the larger, public network to individual private addresses on the masqueraded network.
                                                                                              In residential networks, NAT functions are usually implemented in a residential gateway. In this scenario, the computers connected to the router have private IP addresses and the router has a public address on its external interface to communicate on the Internet. The internal computers appear to share one public IP address.
                                                                                                http://en.wikipedia.org/wiki/IP_address
                                                                                                IP address classes


                                                                                                Note: Class A addresses 127.0.0.0 to 127.255.255.255 cannot be used and is reserved for loopback and diagnostic functions.

                                                                                                A 1 – 126*
                                                                                                B 128 – 191
                                                                                                C 192 – 223
                                                                                                D 224 – 239
                                                                                                E 240 – 254

                                                                                                http://www.vlsm-calc.net/ipclasses.php


                                                                                                • A private IP address is an IP address that's reserved for internal use behind a router or other Network Address Translation (NAT) device, apart from the public.


                                                                                                Private IP addresses are in contrast to public IP addresses, which are public and can not be used within a home or business network

                                                                                                Sometimes a private IP address is also referred to as a local IP address.

                                                                                                Which IP Addresses Are Private?
                                                                                                The Internet Assigned Numbers Authority (IANA) reserves the following IP address blocks for use as private IP addresses:

                                                                                                10.0.0.0 to 10.255.255.255 The first set of IP addresses from above allow for over 16 million addresses
                                                                                                172.16.0.0 to 172.31.255.255 The second for over 1 million
                                                                                                192.168.0.0 to 192.168.255.255 over 65,000 for the last range.



                                                                                                Why Private IP Addresses Are Used
                                                                                                Instead of having devices inside a home or business network each use a public IP address, of which there's a limited supply, private IP addresses provide an entirely separate set of addresses that still allow access on a network but without taking up a public IP address space.

                                                                                                For example, let's consider a standard router on a home network. Most routers in homes and businesses across the globe, probably yours and your next door neighbor's, all have the IP address of 192.168.1.1, and assign 192.168.1.2, 192.168.1.3, ... to the various devices that connect to it (via something called DHCP).

                                                                                                It doesn't matter how many routers use the 192.168.1.1 address, or how many dozens or hundreds of devices inside that network share IP addresses with users of other networks because they aren't communicating with each other directly.

                                                                                                Instead, the devices in a network use the router to translate their requests through the public IP address, which can communicate with other public IP addresses and eventually to other local networks.

                                                                                                For example, before landing on this page, your device (be it a computer, phone, or whatever), which uses a private IP address, requested this page through a router, which has a public IP address. Once the request was made and Livewire responded to deliver the page, it was downloaded to your device through a public IP address before reaching your router, after which it got handed off to your private/local address to reach your device

                                                                                                Reserved IP Addresses
                                                                                                Another set of IP addresses that are restricted even further are called reserved IP addresses. These are similar to private IP addresses in the sense that they can't be used for communicating on the greater internet, but they're even more restrictive than that.
                                                                                                The most famous reserved IP is 127.0.0.1. This address is called the loopback address and is used to test the network adapter or integrated chip.
                                                                                                No traffic addressed to 127.0.0.1 is sent over the local network or public internet.

                                                                                                Technically, the entire range from 127.0.0.0 to 127.255.255.255 is reserved for loopback purposes but you'll almost never see anything but 127.0.0.1 used in the real world.
                                                                                                Addresses in the range from 0.0.0.0 to 0.255.255.255 are also reserved but don't do anything at all. If you're even able to assign a device an IP address in this range, it will not function properly no matter where on the network it's installed


                                                                                                https://www.lifewire.com/what-is-a-private-ip-address-2625970

                                                                                                • Note: Class A addresses 127.0.0.0 to 127.255.255.255 cannot be used and is reserved for loopback and diagnostic functions.

                                                                                                Private IP Addresses
                                                                                                http://www.vlsm-calc.net/ipclasses.php



                                                                                                • Private IP Addresses

                                                                                                Most organizations have far more computers than available IP addresses. Using private IP addresses helps to tackle this issue by allowing companies to have a single Internet gateway with a public IP address. All of the other nodes have private IP addresses. The gateway uses a Network Address Translation (NAT) server to translate the private IP addresses to an address that can be routed across the Internet.
                                                                                                https://www.sqa.org.uk/e-learning/WebTech01CD/page_12.htm



                                                                                                • The most common use of private addresses is in residential IPv4 networks since most Internet service providers (ISPs) allocate only a single publicly routable IPv4 address to each residential customer, but many homes have more than one computer or another Internet-connected device, such as smartphones. In this situation, a network address translator (NAT/PAT) gateway is usually used to provide Internet connectivity to multiple hosts.


                                                                                                Private addresses are also commonly used in corporate networks, which for security reasons, are not connected directly to the Internet. Often a proxy, SOCKS gateway, or similar devices are used to provide restricted Internet access to network-internal users.

                                                                                                In both cases, private addresses are often seen as enhancing network security for the internal network, since it is difficult for the Internet (external) host to connect directly to an internal system.
                                                                                                https://en.wikipedia.org/wiki/Private_network



                                                                                                • Automatic Private IP Addressing (APIPA) is a DHCP fail-safe that protects a computer system from failure by invoking a standby mechanism for local Internet Protocol version 4 (IPv4) networks supported by Microsoft Windows. With APIPA, DHCP clients can obtain IP addresses even when DHCP servers are not functional. APIPA exists in all modern versions of Windows, including Windows 10.

                                                                                                How APIPA Works
                                                                                                Networks that are set up for dynamic addressing rely on a DHCP server to manage the pool of available local IP addresses. When a Windows client device attempts to join the local network, it contacts the DHCP server to request its IP address. If the DHCP server stops functioning, a network glitch interferes with the request, or some issue occurs on the Windows device, this process can fail.
                                                                                                When the DHCP process fails, Windows automatically assigns an IP address from the private range, which is 169.254.0.1 to 169.254.255.254. Using Address Resolution Protocol (ARP), clients verify that the chosen APIPA address is unique on the network before they use it. Clients then check back with the DHCP server at periodic intervals—usually every five minutes—and update their addresses automatically when the DHCP server is able to service requests.
                                                                                                All APIPA devices use the default network mask 255.255.0.0, and all reside on the same subnet.
                                                                                                Limitations of APIPA
                                                                                                APIPA addresses do not fall into any of the private IP address ranges defined by the Internet Protocol standard and are restricted for use on local networks only. Like private IP addresses, ping tests or any other connection requests from the internet and other outside networks cannot be made to APIPA devices directly.
                                                                                                APIPA-configured devices can communicate with peer devices on their local network but cannot communicate outside of it. While APIPA provides Windows clients a usable IP address, it does not provide the client with nameserver (DNS or WINS) and network gateway addresses as DHCP does.
                                                                                                Local networks should not attempt to manually assign addresses in the APIPA range because IP address conflicts will result. To maintain the benefit APIPA has of indicating DHCP failures, administrators should avoid using those addresses for any other purpose and instead limit their networks to use the standard IP address ranges.
                                                                                                https://www.lifewire.com/automatic-private-internet-protocol-addressing-816437


                                                                                                • If no DHCP server is currently available (either because the server is temporarily down or because none exists on the network), the computer selects an IP address from a range of addresses (from 169.254.0.0 - 169.254.255.255) reserved by the Internet Assigned Numbers Authority (IANA) for that purpose. The client uses the Address Resolution Protocol (ARP) to ensure that the chosen address is not already being used by another network computer. Once the computer has assigned itself an IP address, it can communicate over TCP/IP with other computers on the LAN that are either configured for APIPA or are manually set to the correct address range and a subnet mask value of 255.255.0.0. APIPA is enabled by default but can be disabled in some cases. DHCP messages notify the user when they are switched between DHCP addressing and APIPA.

                                                                                                https://whatis.techtarget.com/definition/Automatic-Private-IP-Addressing-APIPA
                                                                                                • IP Loopback Address

                                                                                                127.0.0.1 is the loopback address in IP. Loopback is a test mechanism of network adapters. Messages sent to 127.0.0.1 do not get delivered to the network. Instead, the adapter intercepts all loopback messages and returns them to the sending application. IP applications often use this feature to test the behavior of their network interface.

                                                                                                IPv6 uses 0:0:0:0:0:0:0:1 as its loopback address, equivalent to 127.0.0.1 in IPv4
                                                                                                http://compnetworking.about.com/od/workingwithipaddresses/l/aa042400c.htm


                                                                                                • Identifying the Problem Source

                                                                                                A logical approach is helpful when troubleshooting any problem. Some common questions to ask during troubleshooting include the following:

                                                                                                What works?

                                                                                                What does not work?

                                                                                                How are the things that do and do not work related?

                                                                                                Have the things that do not work ever worked?

                                                                                                If so, what has changed since it last worked?

                                                                                                Table 16-1 Tools and Services for Troubleshooting TCP/IP
                                                                                                Arp
                                                                                                Allows viewing and editing of the Address Resolution Protocol (ARP) cache.
                                                                                                Hostname

                                                                                                Displays the host name of the computer.

                                                                                                Ipconfig

                                                                                                Displays the current TCP/IP configuration for both IPv4 and IPv6. Also used to manage Dynamic Host Configuration Protocol (DHCP)-allocated IPv4 address configurations, display or flush the DNS client resolver cache, and register DNS names.

                                                                                                Nbtstat

                                                                                                Displays NetBIOS over TCP/IP (NetBT) configuration and allows management of the NetBIOS name cache.

                                                                                                Netsh

                                                                                                Configuration tool for many network services. For each network service, there is a context containing commands specific for that service. For the netsh interface ip and netsh interface ipv6 contexts, displays and administers TCP/IP protocol settings on either the local computer or a remote computer.

                                                                                                Netstat

                                                                                                Displays protocol statistics and information on current TCP connections.

                                                                                                Nslookup

                                                                                                Performs DNS queries and displays the results.

                                                                                                Ping

                                                                                                Sends Internet Control Message Protocol (ICMP) Echo or Internet Control Message Protocol for IPv6 (ICMPv6) Echo Request messages to test reachability.

                                                                                                Route

                                                                                                Allows viewing of the IPv4 and IPv6 routing tables and editing of the IPv4 routing table.

                                                                                                Tracert

                                                                                                Sends ICMP Echo or ICMPv6 Echo Request messages to trace the network route taken by IPv4 or IPv6 packets to a specific destination.

                                                                                                Pathping

                                                                                                Sends ICMP Echo or ICMPv6 Echo Request messages to trace the route an IPv4 or IPv6 packet takes to a destination and displays information on packet losses for each router and link in the path.

                                                                                                SNMP service

                                                                                                Provides status and statistical information to Simple Network Management System (SNMP) management systems.

                                                                                                Event Viewer

                                                                                                Records errors and events.

                                                                                                Performance Logs and Alerts

                                                                                                Logs TCP/IP core protocol performance and sends alerts (the SNMP service must be installed).

                                                                                                Network Monitor

                                                                                                Captures and displays the contents of TCP/IP packets sent to and from computers running Windows Server 2003.

                                                                                                Netdiag

                                                                                                Runs a series of diagnostics test on networking components. Netdiag is installed as part of the Windows XP and Windows Server 2003 Support Tools in the Support\Tools folder of the Windows XP or Windows Server 2003 product CD-ROM.

                                                                                                Telnet

                                                                                                Tests TCP connection establishment between two nodes.

                                                                                                Ttcp

                                                                                                Listens for and sends TCP segment data or UDP messages between two nodes.Ttcp.exe is provided with Windows XP Service Pack 2 in the Valueadd\Msft\Net\Tools folder of the Windows XP Service Pack 2 CD-ROM.



                                                                                                Troubleshooting IPv4
                                                                                                The following sections describe the tools and techniques used to identify a problem at successive layers of the TCP/IP protocol stack that is using an IPv4 Internet layer. Depending on the type of problem, you might do one of the following:

                                                                                                Start at the bottom of the stack and move up.

                                                                                                Start at the top of the stack and move down.

                                                                                                The following sections are organized from the top of the stack and describe how to:

                                                                                                Verify IPv4 connectivity.

                                                                                                Verify DNS name resolution for IPv4 addresses.

                                                                                                Verify NetBIOS name resolution.

                                                                                                Verify IPv4-based TCP sessions.


                                                                                                Repair the Connection
                                                                                                The tasks that are performed by Network Connection Repair are the following:
                                                                                                Checks whether DHCP is enabled and, if enabled, sends a broadcast DHCPRequest message to refresh the IPv4 address configuration.
                                                                                                Flushes the ARP cache. This is equivalent to the arp -d * command.
                                                                                                Flushes and reloads the DNS client resolver cache with entries from the Hosts file. This is equivalent to the ipconfig /flushdns command.
                                                                                                Re-registers DNS names using DNS dynamic update. This is equivalent to the ipconfig /registerdns command.
                                                                                                Flushes and reloads the NetBIOS name cache with #PRE entries in the Lmhosts file. This is equivalent to the nbtstat -R command.
                                                                                                Releases and then re-registers NetBIOS names with the Windows Internet Name Service (WINS). This is equivalent to the nbtstat -RR command.

                                                                                                Chapter Summary
                                                                                                The chapter includes the following pieces of key information:

                                                                                                To try and isolate the components that might be at fault when approaching a troubleshooting issue, you should determine what works, what does not work, whether it has ever worked, and what has changed since it last worked.

                                                                                                Windows provides the following tools for troubleshooting TCP/IP problems: Arp, Hostname, Ipconfig, Nbtstat, Netsh, Netstat, Nslookup, Ping, Route, Tracert, Pathping, SNMP service, Event Viewer, Performance Logs and Alerts, Network Monitor, and Netdiag.

                                                                                                Troubleshoot IPv4 communications by verifying IPv4 connectivity, verifying DNS name resolution for IPv4 addresses, verifying NetBIOS name resolution, and verifying IPv4-based TCP sessions.

                                                                                                Troubleshoot IPv6 communications by verifying IPv6 connectivity, verifying DNS name resolution for IPv6 addresses, and verifying IPv6-based TCP sessions.


                                                                                                https://docs.microsoft.com/en-us/previous-versions/tn-archive/bb727023(v=technet.10)


                                                                                                • What Is Straight Through Cable?

                                                                                                A straight through cable is a type of twisted pair cable that is used in local area networks to connect a computer to a network hub such as a router. This type of cable is also sometimes called a patch cable and is an alternative to wireless connections where one or more computers access a router through a wireless signal. On a straight through cable, the wired pins match. Straight through cable use one wiring standard: both ends use T568A wiring standard or both ends use T568B wiring standard.

                                                                                                What Is Crossover Cable?
                                                                                                An Ethernet crossover cable is a type of Ethernet cable used to connect computing devices together directly. Unlike straight through cable, crossover cables use two different wiring standards: one end uses the T568A wiring standard, and the other end uses the T568B wiring standard. The internal wiring of Ethernet crossover cables reverses the transmit and receive signals.

                                                                                                It is most often used to connect two devices of the same type: e.g. two computers (via network interface controller) or two switches to each other.
                                                                                                http://www.cables-solutions.com/difference-between-straight-through-and-crossover-cable.html



                                                                                                • Netstat: network analysis and troubleshooting, explained

                                                                                                    In lines saying 'ESTABLISHED', you need the remote port to identify what has connected to the remote site.
                                                                                                    In lines saying 'LISTENING', you need the local port to identify what is listening there.
                                                                                                    Each outbound TCP connection also causes a LISTENING entry on the same port.
                                                                                                    Most UDP listening ports are duplicates from a listening TCP port. Ignore them unless they don't have a TCP twin.
                                                                                                    TIME_WAIT entries are not important.
                                                                                                    If it says 0.0.0.0 on the Local Address column, it means that port is listening on all 'network interfaces' (i.e. your computer, your modem(s) and your network card(s)).
                                                                                                    If it says 127.0.0.1 on the Local Address column, it means that port is ONLY listening for connections from your PC itself, not from the Internet or network. No danger there.
                                                                                                    If it displays your online IP on the Local Address column, it means that port is ONLY listening for connections from the Internet.
                                                                                                    If it displays your local network IP on the Local Address column, it means that port is ONLY listening for connections from the local network.
                                                                                                https://sites.google.com/site/xiangyangsite/home/technical-tips/linux-unix/networks-related-commands-on-linux/how-to-read-netstat--an-results


                                                                                                • A bundle of network tools

                                                                                                The netstat command doesn’t really do unique things. It can print network statistics, but ifconfig can do so, too. It can print routing tables, but route can do that, too. It can print open connections, but lsof does that, and more. So why use netstat at all? There are two main reasons:

                                                                                                    netstat bundles a few often-used network analysis actions in a single command and
                                                                                                    netstat is multi-platform
                                                                                                https://linuxacademy.com/blog/linux/netstat-network-analysis-and-troubleshooting-explained/   

                                                                                                the following IPv4 address ranges are reserved by the IANA for private internets, and are not publicly routable on the global internet:


                                                                                                    10.0.0.0/8 IP addresses: 10.0.0.0 – 10.255.255.255
                                                                                                    172.16.0.0/12 IP addresses: 172.16.0.0 – 172.31.255.255
                                                                                                    192.168.0.0/16 IP addresses: 192.168.0.0 – 192.168.255.255


                                                                                                Note that only a portion of the “172” and the “192” address ranges are designated for private use. The remaining addresses are considered “public,” and thus are routable on the global Internet.

                                                                                                https://www.arin.net/reference/research/statistics/address_filters/ 

                                                                                                • Private network

                                                                                                In IP networking, a private network is a computer network that uses private IP address space. Both the IPv4 and the IPv6 specifications define private IP address ranges.[1][2] These addresses are commonly used for local area networks (LANs) in residential, office, and enterprise environments. 

                                                                                                Private network addresses are not allocated to any specific organization. Anyone may use these addresses without approval from regional or local Internet registries. Private IP address spaces were originally defined to assist in delaying IPv4 address exhaustion. IP packets originating from or addressed to a private IP address cannot be routed through the public Internet. 

                                                                                                24-bit block 10.0.0.0 – 10.255.255.255 16777216 10.0.0.0/8 (255.0.0.0) 24 bits 8 bits single class A network
                                                                                                20-bit block 172.16.0.0 – 172.31.255.255 1048576 172.16.0.0/12 (255.240.0.0) 20 bits 12 bits 16 contiguous class B networks
                                                                                                16-bit block 192.168.0.0 – 192.168.255.255 65536 192.168.0.0/16 (255.255.0.0) 16 bits 16 bits 256 contiguous class C networks 

                                                                                                Private IPv6 addresses
                                                                                                The concept of private networks has been extended in the next generation of the Internet Protocol, IPv6, and special address blocks are reserved. 
                                                                                                The address block fc00::/7 is reserved by IANA for Unique Local Addresses (ULA)

                                                                                                https://en.wikipedia.org/wiki/Private_network

                                                                                                • 0.0.0.0
                                                                                                In the Internet Protocol Version 4, the address 0.0.0.0 is a non-routable meta-address used to designate an invalid, unknown or non-applicable target.

                                                                                                As a host address

                                                                                                A way to specify "any IPv4 address at all". It is used in this way when configuring servers (i.e. when binding listening sockets). This is known to TCP programmers as INADDR_ANY.
                                                                                                The address a host claims as its own when it has not yet been assigned an address. Such as when sending the initial DHCPDISCOVER packet when using DHCP.
                                                                                                The address a host assigns to itself when address request via DHCP has failed, provided the host's IP stack supports this. This usage has been replaced with the APIPA mechanism in modern operating systems.
                                                                                                A way to explicitly specify that the target is unavailable
                                                                                                A way to route request to a nonexistent target instead of the original target. Often used for adblocking purposes.

                                                                                                In the context of servers, 0.0.0.0 can mean "all IPv4 addresses on the local machine". If a host has two IP addresses, 192.168.1.1 and 10.1.2.1, and a server running on the host is configured to listen on 0.0.0.0, it will be reachable at both of those IP addresses. 

                                                                                                Routing

                                                                                                In the context of routing tables, a network destination of 0.0.0.0 is used with a network mask of 0 to depict the default route as a destination subnet. This destination is expressed as "0.0.0.0/0" in CIDR notation. It matches all addresses in the IPv4 address space and is present on most hosts, directed towards a local router.

                                                                                                In routing tables, 0.0.0.0 can also appear in the gateway column. This indicates that the gateway to reach the corresponding destination subnet is unspecified. This generally means that no intermediate routing hops are necessary because the system is directly connected to the destination

                                                                                                In IPv6
                                                                                                In IPv6, the all-zeros address is typically represented by ::, which is the short notation of 0000:0000:0000:0000:0000:0000:0000:0000
                                                                                                The IPv6 variant serves the same purpose as its IPv4 counterpart. 

                                                                                                https://en.wikipedia.org/wiki/0.0.0.0

                                                                                                • IANA IPv4 Special-Purpose Address Registry

                                                                                                • Private-Use
                                                                                                Documentation (TEST-NET-1)
                                                                                                Documentation (TEST-NET-2)
                                                                                                Documentation (TEST-NET-3)
                                                                                                http://www.iana.org/assignments/iana-ipv4-special-registry/iana-ipv4-special-registry.xhtml

                                                                                                • Reserved IP addresses
                                                                                                Assigned as TEST-NET-1, documentation and examples.
                                                                                                Assigned as TEST-NET-2, documentation and examples
                                                                                                Assigned as TEST-NET-3, documentation and examples
                                                                                                https://en.wikipedia.org/wiki/Reserved_IP_addresses














                                                                                                • a link-local address is a network address that is valid only for communications within the network segment or the broadcast domain that the host is connected to.
                                                                                                Link-local addresses are most often assigned automatically with a process known as stateless address autoconfiguration or link-local address autoconfiguration
                                                                                                also known as automatic private IP addressing (APIPA) or auto-IP. 
                                                                                                Link-local addresses are not guaranteed to be unique beyond their network segment. Therefore, routers do not forward packets with link-local source or destination addresses. 
                                                                                                IPv4 link-local addresses are assigned from address block 169.254.0.0/16 (169.254.0.0 through 169.254.255.255). IPv6, they are assigned from the block fe80::/10
                                                                                                https://en.wikipedia.org/wiki/Link-local_address

                                                                                                Network 169.254.0.0/16 is a "reserved network" named IPv4 Link-Local Addresses
                                                                                                IPv4 Link-Local addresses are not suitable for communication with
                                                                                                devices not directly connected to the same physical (or logical)
                                                                                                link, and are only used where stable, routable addresses are not
                                                                                                available (such as on ad hoc or isolated networks)
                                                                                                https://access.redhat.com/solutions/4403501

                                                                                                Link local addresses allow machines to automatically have an IP address on a network if they haven't been manually configured or automatically configured by a special server on the network (DHCP).
                                                                                                 Before an address is chosen from that range, the machine sends out a special message (using ARP which stands for address resolution protocol) to the machines on the network around it (assuming that they also haven't been assigned an address manually or automatically) to find out if 169.254.1.1 is free. If it is, then the machine assigns that address to its network card. If that address is already in use by another machine on the same network, then it tries the next IP 169.254.1.2 and so on, until it finds a free address

                                                                                                IP addresses, either IPv4 or IPv6. It is valid in some circumstances to refer to a MAC address as a link-local address but it is a less common use of the term. 

                                                                                                the range for IPv4 is 169.254.0.0/16 (169.254.0.1 to 169.254.255.254), with 169.254.0.0 and 169.254.255.255 reserved as network/broadcast addresses

                                                                                                IPv6 has fe80::/10 reserved for Link-Local addresses with most automatically assigned ones being in the fe80::/64 range. 
                                                                                                The link-local IP address must be unique within its network segment

                                                                                                The process a device assigning an address to itself is a common use for Link-local IP addresses but it is not the only way they are used. In stateless address autoconfiguration the device should check that an address it wants to try and use is available and then use it. There is nothing to stop you manually assigning the same link-local IP address to two devices you administe

                                                                                                https://serverfault.com/questions/118324/what-is-a-link-local-address