Posts

Showing posts from 2018

HOw to Reset password in ubuntu

 Reset password in Ubuntu: 1.Open in the recovery mode 2. Go to root directory. 3. in terminal you are in read mode only so type the following to enable write mode also.     mount -o rw, remount / 4.Now set the user  password with the passwd command.     to view the username type : ls /home     ie:type the following command     password username     Enter new password     Reenter password 5.you have updated the password successfully 6.close it and restart ,you are done.

0/1 knapsack problem using dynamic approach

Image

Flow Control vs Congestion Control

Difference Between Flow Control and Congestion Control   Flow control and congestion control, both are the traffic controlling mechanism but, both controls the traffic at different situations. The main difference between flow control and congestion control is that the flow control is a mechanism that controls the traffic between sender and receiver. On the other hand, the congestion control mechanism controls the traffic that is placed by the transport layer into the network. Comparison Flow Control Congestion Control Basic It controls the traffic from a particular sender to a receiver. It controls the traffic entering the network. Purpose It prevents the receiver from being overwhelmed by the data. It prevents the network from getting congested. Responsibility Flow control is the responsibility handled by data link layer and the transport layer. Congestion Control is the responsibility handled by network layer and transport layer. Responsible The sender is

Frame vs Packet

Image
Difference Between Frame and Packet     The crucial difference between frame and packet is that frame is the serial collection of bits, and it encapsulates packets whereas packets are the fragmented form of data and it encapsulates segment. Data link layer performs framing process. On the other hand, Network layer performs fragmentation of the data and create smaller chunks known as packets. Another major difference is that a frame includes device’s MAC address while a packet includes device’s IP address. Basis for comparison Frame Packet Basic Frame is the data link layer protocol data unit. Packet is the network layer protocol data unit. Associated OSI layer Data link layer Network layer Includes Source and destination MAC address. Source and destination IP address. Correlation Segment is encapsulated within a packet. Packet is encapsulated within a frame. Conclusion: Frames and Packets function as protocol data units utilized on the

Flow Control vs Error Control

Difference Between Flow Control and Error Control Flow control and Error control are the control mechanism at data link layer and transport layer. Whenever the sends the data to the receiver these two mechanisms helps in proper delivering of the reliable data to the receiver. The main difference between the flow control and error control is that the flow control observes the proper flow of the data from sender to receiver, on the other hand, the error control observes that the data delivered to the receiver is error free and reliable. Basis for Comparison Flow Control Error Control Basic Flow control is meant for the proper transmission of the data from sender to the receiver. Error control is meant for delivering the error-free data to the receiver. Approach Feedback-based flow control and rate-based flow control are the approaches to achieve the proper flow control. Parity checking, Cyclic Redundancy Code (CRC) and checksum are the approaches to detect the er

Unicasting vs Multicasting

Image
Difference Between Unicasting and Multicasting:   In Computer Networks, the term unicast and multicast are the information transmission methods. In unicast, one station transfers the information to only one receiver station. In multicast, the sender transfers the information to a group of interested receiver stations. The fundamental difference between unicast and multicast is that unicast is a one-to-one communication and multicast is a one-to-many communication process. Basis for Comparison Unicast Multicast Basic One sender and one receiver. One sender and multiple receivers. Bandwidth Multiple unicasting utilizes more bandwidth as compared to multicast. Multicasting utilizes bandwidth efficiently. Scale It does not scale well for streaming media. It does not scale well across large networks. Mapping One-to-one. One-to-many. Examples Web surfing, file transfer. Multimedia delivery, stock exchange. Conclusion:   If some private or unique i

Pure ALOHA vs Slotted ALOHA

Image
Difference Between Pure ALOHA and Slotted ALOHA Pure ALOHA and Slotted ALOHA both are the Random Access Protocols, that are implemented on the Medium Access Control (MAC) layer, a sublayer of Data Link Layer. The purpose of the ALOHA protocol is to determine that which competing station must get the next chance of accessing the multi-access channel at MAC layer. The main difference between Pure ALOHA and Slotted ALOHA is that the time in Pure Aloha is continuous whereas, the time in Slotted ALOHA is discrete. Basis for Comparison Pure ALOHA Slotted ALOHA Introduced Introduced by Norman Abramson and his associates at the University of Hawaii in 1970. Introduced by Roberts in 1972. Frame Transmission The user can transmit the data frame whenever the station has the data to be transmitted. The user has to wait till the next time slot start, to transmit the data frame. Time In Pure ALOHA the time is continuous. In Slotted ALOHA the time is discrete. Successfu

Reasoning Vs Inference

Inference: Inference is a general term representing the derivation of new knowledge from existing knowledge and axioms (i.e., rules of derivation) within a single step, and can be one of many kinds, such as, induction, deduction and abduction. For example, "modus tollens" is a rule of inference. Thus, one inference is the derivation of new knowledge using a single step using modus tollens. Inference is about taking in data and trying to draw a conclusion based on the limited information you have in a situation where not all the data is given. Reasoning: Reasoning is in context of a goal (e.g., decide whether a propositional formula is satisfiable or not)  and is carried out via a search process involving multiple inferences. Choices during such search have to be made such as which axiom to "fire" along with which knowledge in order to derive new knowledge. Resolution is a particular kind of reasoning involving the "resolution rule". Reasoning is

Principles of Congestion Control

Image
In this section, we consider the problem of congestion control in a general context, seeking to understand why congestion is a "bad thing,"   how network congestion is manifested in the performance received by upper-layer applications, and various approaches that can be taken to avoid, or react to, network congestion. This more general study of congestion control is appropriate since, as with reliable data transfer, it is high on the "top-10" list of fundamentally important problems in networking. The Causes and the "Costs" of Congestion: Congestion control can be studied by examining three increasingly complex scenarios in which congestion occurs.  In each case, we'll look at why congestion occurs in the first place, and the  "cost" of congestion (in terms of  resources not fully utilized and poor performance received by the end systems). Scenario 1: Two senders, a router with infinite buffers We begin by considering perhaps the s

Subnetting Vs Supernetting

Subnetting is the technique of partitioning a large network into smaller networks. On the other hand, the supernetting is the method used for combining the smaller ranges of addresses into larger space. Supernetting was devised to make the routing process more convenient. Additionally, it reduces the size of routing table information so that it could consume less space in the router’s memory. The well-defined method for the subnetting is FLSM and VLSM while for supernetting CIDR is used. Difference between Subnetting and Supernetting Subnetting is the technique of partitioning a large network into smaller networks. On the other hand, the supernetting is the method used for combining the smaller ranges of addresses into larger space. Supernetting was devised to make the routing process more convenient. Additionally, it reduces the size of routing table information so that it could consume less space in the router’s memory. The well-defined method for the subnetting is FLSM and VLS

Go-Back-N Protocol Vs Selective Repeat Protocol

Image
“Go-Back-N Protocol and “Selective Repeat Protocol” are the sliding window protocols. The sliding window protocol is primarily an error control protocol, i.e. it is a method of error detection and error correction. The basic difference between go-back-n protocol and selective repeat protocol is that the “go-back-n protocol” retransmits all the frames that lie after the frame which is damaged or lost. The “selective repea t protocol” retransmits only that frame which is damaged or lost. Key Differences Between Go-Back-N and Selective Repeat Go-Back-N protocol is design to retransmit all the frames that are arrived after the damaged or a lost frame. On the other hand, Selective Repeat protocol retransmits only that frame that is damaged or lost. If the error rate is high i.e. more frames are being damaged and then retransmitting all the frames that arrived after a damaged frame waste the lots of bandwidth. On the other hand, selective repeat protocol re-transmits only damaged fra

Quick Sort Vs Merge Sort

The quick sort and merge sort algorithms are based on the divide and conquer algorithm which works in the quite similar way. The prior difference between the quick and merge sort is that in quick sort the pivot element is used for the sorting. On the other hand, merge sort does not use pivot element for performing the sorting. Both sorting techniques, quick sort and merge sort are built on the divide and conquer method in which the set of elements are parted and then combined after rearrangement. The quick sort usually requires more comparisons than merge sort for sorting a large set of elements. Key Differences Between Quick Sort and Merge Sort : In the merge sort , the array must be parted into just two halves (i.e. n/2). As against, in quick sort, there is no compulsion of dividing the list into equal elements. The worst case complexity of quick sort is O(n 2 ) as it takes a lot more comparisons in the worst condition. In contrast, merge sort have the same worst case and

Process Vs Thread

The Process and Thread are the essentially correlated. The process is an execution of a program whereas thread is an execution of a program driven by the environment of a process. Another major point which differentiates process and thread is that processes are isolated with each other whereas threads share memory or resources with each other. Key Differences Between Process and Thread : All threads of a program are logically contained within a process. A process is heavy weighted, but a thread is light weighted. A program is an isolated execution unit whereas thread is not isolated and shares memory. A thread cannot have an individual existence; it is attached to a process. On the other hand, a process can exist individually. Each thread has its own stack, so if a thread dies its stack is reclaimed. In contrast, if a process dies, all threads die including the process. Conclusion: Processes are used to achieve execution of programs in concurrent and sequential manner.

Deadlock Vs Starvation

Deadlock and Starvation both are the conditions where the processes requesting for a resource has been delayed for a long. Although deadlock and starvation both are different from each other in many aspects.  Deadlock  is a condition where no process proceeds for execution, and each waits for resources that have been acquired by the other processes. On the other hands, in  Starvation , process with high priorities continuously uses the resources preventing low priority process to acquire the resources. Key Differences Between Deadlock and Starvation: In a deadlock, none of the processes proceeds for execution, each process get blocked waiting for the resources acquired by the another process. On the other hand, starvation is a condition where the processes that possess higher priority is allowed to acquire the resources continuously by preventing the low priority processes to acquire resources resulting in indefinite blocking of low priority processes. Deadlock arises when four

Premptive Scheduling Vs Non-premptive Scheduling

The scheduling which takes place when a process switches from running state to ready state or from waiting state to ready state is called  Preemptive Scheduling . On the hands, the scheduling which takes place when a process terminates or switches from running to waiting for state this kind of CPU scheduling is called  Non-Preemptive Scheduling . The basic difference between preemptive and non-preemptive scheduling lies in their name itself. That is a Preemptive scheduling can be preempted; the processes can be scheduled. In Non-preemptive scheduling, the processes can not be scheduled. Key Differences Between Preemptive and Non-Preemptive Scheduling: The basic difference between preemptive and non-preemptive scheduling is that in preemptive scheduling the CPU is allocated to the processes for the  limited  time. While in Non-preemptive scheduling, the CPU is allocated to the process till it  terminates  or switches to  waiting state . The executing process in preemptive scheduli

Internal Fragmentation Vs External Fragmentation

Whenever a process is loaded or removed from the physical memory block, it creates a small hole in memory space which is called fragment. Due to fragmentation, the system fails in allocating the contiguous memory space to a process even though it have the requested amount of memory but, in a non-contiguous manner. The fragmentation is further classified into two categories Internal and External Fragmentation. Key Differences Between Internal and External fragmentation The basic reason behind the occurrences of internal and external fragmentation is that internal fragmentation occurs when memory is partitioned into  fixed-sized blocks  whereas external fragmentation occurs when memory is partitioned into  variable size blocks . When the memory block allotted to the process comes out to be slightly larger than requested memory, then the free space left in the allotted memory block causes internal fragmentation. On the other hands, when the process is removed from the memory it crea

Paging Vs Segmentation

The memory management in the operating system is an essential functionality, which allows the allocation of memory to the processes for execution and deallocates the memory when the process is no longer needed. If we talk about the basic differences between the paging and segmentation it is, a  page  is a fixed-sized block whereas, a  segment  is a variable-sized block. Key Differences Between Paging and Segmentation The basic difference between paging and segmentation is that a page is always of  fixed block size  whereas, a segment is of  variable size . Paging may lead to  internal fragmentation  as the page is of fixed block size, but it may happen that the process does not acquire the entire block size which will generate the internal fragment in memory. The segmentation may lead to  external fragmentation  as the memory is filled with the variable sized blocks. In paging the user only provides a  single integer  as the address which is divided by the hardware into a  page

Block Cipher Vs Stream Cipher

Block Cipher and Stream Cipher are the methods used for converting the plain text into cipher text directly and belong to the family of symmetric key ciphers. The major difference between a block cipher and a stream cipher is that the block cipher encrypts and decrypts a block of the text at a time. On the other hand, stream cipher encrypts and decrypts the text by taking the one byte of the text at a time. Key Differences Between Block Cipher and Stream Cipher Block cipher technique involves encryption of one block of text at a time, i.e. singly. Similarly, decrypt the text by taking one block after another. In contrast, Stream cipher technique involves encryption and decryption of one byte of the text at a time. Block cipher uses both confusion and diffusion while stream cipher relies only on confusion. The usual size of the block could be 64 or 128 bits in the Block cipher. As against, 1 byte (8 bits) at a time is converted in the stream cipher. Block cipher uses  ECB (El

AES vs DES

DES (Data Encryption Standard) and AES (Advanced Encryption Standard) both are the symmetric block cipher. AES was introduced to overcome the drawback of DES. As DES has a smaller key size which makes it less secure to overcome this triple DES was introduced but it turns out to be slower. Hence, later AES was introduced by the National Institute of Standard and Technology. The basic difference between DES and AES is that in  DES  plaintext block is divided into two halves before the main algorithm starts whereas, in  AES  the entire block is processed to obtain the ciphertext. Key Differences Between DES and AES. The basic difference between DES and AES is that the block in DES is divided into two halves before further processing whereas, in AES entire block is processed to obtain ciphertext. The DES algorithm works on the Feistel Cipher principle, and the AES algorithm works on substitution and permutation principle. The key size of DES is 56 bit which is comparatively smal

RansomeWare Vs SpyWare Vs ScareWare

Ransomware:  is a type of  m alicious software  from cryptovirology  that threatens to publish the victim's data or perpetually block access to it unless a ransome  is paid.  While some simple ransomware may lock the system in a way which is not difficult for a knowledgeable person to reverse, more advanced malware uses a technique called cryptiviral exortion  , in which it encrypts  the victim's files, making them inaccessible, and demands a ransom payment to decrypt them. In a properly implemented cryptoviral extortion attack, recovering the files without the decryption key  is an  intractable   problem – and difficult to trace digital currencies   such as Ukash  and BitCoin  are used for the ransoms, making tracing and prosecuting the perpetrators difficult. Spyware   is software that aims to gather information about a person or organization without their knowledge, that may send such information to another entity without the consumer's consent, or that asserts