SlideShare une entreprise Scribd logo
1  sur  6
INFORMATION SCIENCE AND TECHNOLOGY
Computer Networking
Topic : An example of socket programming :
An internet file server
Subject Faculty :
Asst Professor
Mrs Pradeepa J
Topic By :
Anubhav S
1KT21IS004
Socket Programming
 Socket programming is a fundamental technique for
enabling communication between applications on a
network.
 It provides a way for programs to establish connections,
exchange data, and coordinate actions, regardless of their
physical locations
 Each socket has a unique address (IP address and port
number) that identifies it.
 Applications can "plug into" sockets to create
connections and start sending and receiving data.
Server Setup
 This consists of a basic Internet file server and client. The server serves files
to clients, while the client requests and receives files from the server.
 The server and client code are designed to be platform-independent, meaning
they can be compiled and executed on any UNIX system connected to the
Internet.
Port Selection
 Ports are numerical identifiers used to distinguish between different network
services running on the same host.
 The server code selects a port number (e.g., 12345) for communication. It's
essential to choose a port within the range of 1024 to 65535 to avoid conflicts
with other processes.
 Ports below 1024 are typically reserved for privileged users or standard
services.
Constants Definition:
 The server code defines constants for the chunk size and maximum pending
connections.
 The chunk size determines the size of data packets transmitted during file transfer,
impacting the efficiency of data transmission.
Chunk Size and Efficiency:
 The chunk size influences the efficiency of file transfer by determining the size of
data packets transmitted over the network.
 Choosing an appropriate chunk size helps optimize network utilization and minimize
overhead associated with data transmission.
Handling Pending Connections:
 The specified maximum number of pending connections determines how many
clients can wait in the queue before additional connections are rejected.
 Effective management of pending connections helps prevent server overload
and ensures optimal performance.
Output Handling:
 The fetched file is written to standard output on the client side, allowing it to
be displayed in the console or redirected to a file or pipe.
 This basic mechanism for output handling provides a simple yet effective way
to retrieve and view file content on the client side.
computernetworkingmodule4vtu5thsemppt.pptx

Contenu connexe

Similaire à computernetworkingmodule4vtu5thsemppt.pptx

important network terminologies
important network terminologiesimportant network terminologies
important network terminologiesevelyn
 
Glossary of introduction to networks
Glossary of introduction to networksGlossary of introduction to networks
Glossary of introduction to networksevelyn
 
A Deep Dive in the World of IT Networking (Part 2)
A Deep Dive in the World of IT Networking (Part 2)A Deep Dive in the World of IT Networking (Part 2)
A Deep Dive in the World of IT Networking (Part 2)Tuan Yang
 
lec3_10.ppt
lec3_10.pptlec3_10.ppt
lec3_10.pptImXaib
 
Introduction-to-Networking-and-types(junaid_ali)[1].pptx
Introduction-to-Networking-and-types(junaid_ali)[1].pptxIntroduction-to-Networking-and-types(junaid_ali)[1].pptx
Introduction-to-Networking-and-types(junaid_ali)[1].pptxjunaidinamdar999
 
Computer networks - CBSE New Syllabus (083) Class - XII
Computer networks - CBSE  New Syllabus (083) Class - XIIComputer networks - CBSE  New Syllabus (083) Class - XII
Computer networks - CBSE New Syllabus (083) Class - XIIDeepak Singh
 
Advance Java Programming( CM5I) 4. Networking Basics
Advance Java Programming( CM5I) 4. Networking BasicsAdvance Java Programming( CM5I) 4. Networking Basics
Advance Java Programming( CM5I) 4. Networking BasicsPayal Dungarwal
 
Brown Simple Digital Marketing Presentation.pdf
Brown Simple Digital Marketing Presentation.pdfBrown Simple Digital Marketing Presentation.pdf
Brown Simple Digital Marketing Presentation.pdfWendieEscaliente
 
DEFENSE IN DEPTH6IntroductionThe objective of this pap
DEFENSE IN DEPTH6IntroductionThe objective of this papDEFENSE IN DEPTH6IntroductionThe objective of this pap
DEFENSE IN DEPTH6IntroductionThe objective of this papLinaCovington707
 
unit 4 cds computer networking notesnotes.pdf
unit 4 cds computer networking notesnotes.pdfunit 4 cds computer networking notesnotes.pdf
unit 4 cds computer networking notesnotes.pdfshubhangisonawane6
 
Chapter01 -- introduction to networking
Chapter01  -- introduction to networkingChapter01  -- introduction to networking
Chapter01 -- introduction to networkingRaja Waseem Akhtar
 
Module1 Mobile Computing Architecture
Module1 Mobile Computing ArchitectureModule1 Mobile Computing Architecture
Module1 Mobile Computing Architectureraksharao
 
Socket Programming by Rajkumar Buyya
Socket Programming by Rajkumar BuyyaSocket Programming by Rajkumar Buyya
Socket Programming by Rajkumar BuyyaiDhawalVaja
 
Network Built For Local Area Networks Essay
Network Built For Local Area Networks EssayNetwork Built For Local Area Networks Essay
Network Built For Local Area Networks EssayKatyana Londono
 

Similaire à computernetworkingmodule4vtu5thsemppt.pptx (20)

important network terminologies
important network terminologiesimportant network terminologies
important network terminologies
 
Glossary of introduction to networks
Glossary of introduction to networksGlossary of introduction to networks
Glossary of introduction to networks
 
A Deep Dive in the World of IT Networking (Part 2)
A Deep Dive in the World of IT Networking (Part 2)A Deep Dive in the World of IT Networking (Part 2)
A Deep Dive in the World of IT Networking (Part 2)
 
lec3_10.ppt
lec3_10.pptlec3_10.ppt
lec3_10.ppt
 
Introduction-to-Networking-and-types(junaid_ali)[1].pptx
Introduction-to-Networking-and-types(junaid_ali)[1].pptxIntroduction-to-Networking-and-types(junaid_ali)[1].pptx
Introduction-to-Networking-and-types(junaid_ali)[1].pptx
 
Ecommerce final ppt
Ecommerce final pptEcommerce final ppt
Ecommerce final ppt
 
Computer networks - CBSE New Syllabus (083) Class - XII
Computer networks - CBSE  New Syllabus (083) Class - XIIComputer networks - CBSE  New Syllabus (083) Class - XII
Computer networks - CBSE New Syllabus (083) Class - XII
 
Advance Java Programming( CM5I) 4. Networking Basics
Advance Java Programming( CM5I) 4. Networking BasicsAdvance Java Programming( CM5I) 4. Networking Basics
Advance Java Programming( CM5I) 4. Networking Basics
 
Computer Networks basics
Computer Networks basicsComputer Networks basics
Computer Networks basics
 
Brown Simple Digital Marketing Presentation.pdf
Brown Simple Digital Marketing Presentation.pdfBrown Simple Digital Marketing Presentation.pdf
Brown Simple Digital Marketing Presentation.pdf
 
Dasar komputer chapter8
Dasar komputer chapter8Dasar komputer chapter8
Dasar komputer chapter8
 
DEFENSE IN DEPTH6IntroductionThe objective of this pap
DEFENSE IN DEPTH6IntroductionThe objective of this papDEFENSE IN DEPTH6IntroductionThe objective of this pap
DEFENSE IN DEPTH6IntroductionThe objective of this pap
 
unit 4 cds computer networking notesnotes.pdf
unit 4 cds computer networking notesnotes.pdfunit 4 cds computer networking notesnotes.pdf
unit 4 cds computer networking notesnotes.pdf
 
nv.ppt
nv.pptnv.ppt
nv.ppt
 
Chapter01 -- introduction to networking
Chapter01  -- introduction to networkingChapter01  -- introduction to networking
Chapter01 -- introduction to networking
 
Java Networking
Java NetworkingJava Networking
Java Networking
 
OSI model.pptx
OSI model.pptxOSI model.pptx
OSI model.pptx
 
Module1 Mobile Computing Architecture
Module1 Mobile Computing ArchitectureModule1 Mobile Computing Architecture
Module1 Mobile Computing Architecture
 
Socket Programming by Rajkumar Buyya
Socket Programming by Rajkumar BuyyaSocket Programming by Rajkumar Buyya
Socket Programming by Rajkumar Buyya
 
Network Built For Local Area Networks Essay
Network Built For Local Area Networks EssayNetwork Built For Local Area Networks Essay
Network Built For Local Area Networks Essay
 

Dernier

Research Methodolgy & Intellectual Property Rights Series 1
Research Methodolgy & Intellectual Property Rights Series 1Research Methodolgy & Intellectual Property Rights Series 1
Research Methodolgy & Intellectual Property Rights Series 1T.D. Shashikala
 
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdfInstruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdfEr.Sonali Nasikkar
 
Augmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxAugmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxMustafa Ahmed
 
handbook on reinforce concrete and detailing
handbook on reinforce concrete and detailinghandbook on reinforce concrete and detailing
handbook on reinforce concrete and detailingAshishSingh1301
 
Filters for Electromagnetic Compatibility Applications
Filters for Electromagnetic Compatibility ApplicationsFilters for Electromagnetic Compatibility Applications
Filters for Electromagnetic Compatibility ApplicationsMathias Magdowski
 
Circuit Breakers for Engineering Students
Circuit Breakers for Engineering StudentsCircuit Breakers for Engineering Students
Circuit Breakers for Engineering Studentskannan348865
 
Intro to Design (for Engineers) at Sydney Uni
Intro to Design (for Engineers) at Sydney UniIntro to Design (for Engineers) at Sydney Uni
Intro to Design (for Engineers) at Sydney UniR. Sosa
 
Artificial Intelligence in due diligence
Artificial Intelligence in due diligenceArtificial Intelligence in due diligence
Artificial Intelligence in due diligencemahaffeycheryld
 
Maher Othman Interior Design Portfolio..
Maher Othman Interior Design Portfolio..Maher Othman Interior Design Portfolio..
Maher Othman Interior Design Portfolio..MaherOthman7
 
Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Ramkumar k
 
Interfacing Analog to Digital Data Converters ee3404.pdf
Interfacing Analog to Digital Data Converters ee3404.pdfInterfacing Analog to Digital Data Converters ee3404.pdf
Interfacing Analog to Digital Data Converters ee3404.pdfragupathi90
 
Adsorption (mass transfer operations 2) ppt
Adsorption (mass transfer operations 2) pptAdsorption (mass transfer operations 2) ppt
Adsorption (mass transfer operations 2) pptjigup7320
 
Seizure stage detection of epileptic seizure using convolutional neural networks
Seizure stage detection of epileptic seizure using convolutional neural networksSeizure stage detection of epileptic seizure using convolutional neural networks
Seizure stage detection of epileptic seizure using convolutional neural networksIJECEIAES
 
Diploma Engineering Drawing Qp-2024 Ece .pdf
Diploma Engineering Drawing Qp-2024 Ece .pdfDiploma Engineering Drawing Qp-2024 Ece .pdf
Diploma Engineering Drawing Qp-2024 Ece .pdfJNTUA
 
Basics of Relay for Engineering Students
Basics of Relay for Engineering StudentsBasics of Relay for Engineering Students
Basics of Relay for Engineering Studentskannan348865
 
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...Amil baba
 
Developing a smart system for infant incubators using the internet of things ...
Developing a smart system for infant incubators using the internet of things ...Developing a smart system for infant incubators using the internet of things ...
Developing a smart system for infant incubators using the internet of things ...IJECEIAES
 
Dynamo Scripts for Task IDs and Space Naming.pptx
Dynamo Scripts for Task IDs and Space Naming.pptxDynamo Scripts for Task IDs and Space Naming.pptx
Dynamo Scripts for Task IDs and Space Naming.pptxMustafa Ahmed
 
15-Minute City: A Completely New Horizon
15-Minute City: A Completely New Horizon15-Minute City: A Completely New Horizon
15-Minute City: A Completely New HorizonMorshed Ahmed Rahath
 
Artificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfArtificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfKira Dess
 

Dernier (20)

Research Methodolgy & Intellectual Property Rights Series 1
Research Methodolgy & Intellectual Property Rights Series 1Research Methodolgy & Intellectual Property Rights Series 1
Research Methodolgy & Intellectual Property Rights Series 1
 
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdfInstruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
 
Augmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxAugmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptx
 
handbook on reinforce concrete and detailing
handbook on reinforce concrete and detailinghandbook on reinforce concrete and detailing
handbook on reinforce concrete and detailing
 
Filters for Electromagnetic Compatibility Applications
Filters for Electromagnetic Compatibility ApplicationsFilters for Electromagnetic Compatibility Applications
Filters for Electromagnetic Compatibility Applications
 
Circuit Breakers for Engineering Students
Circuit Breakers for Engineering StudentsCircuit Breakers for Engineering Students
Circuit Breakers for Engineering Students
 
Intro to Design (for Engineers) at Sydney Uni
Intro to Design (for Engineers) at Sydney UniIntro to Design (for Engineers) at Sydney Uni
Intro to Design (for Engineers) at Sydney Uni
 
Artificial Intelligence in due diligence
Artificial Intelligence in due diligenceArtificial Intelligence in due diligence
Artificial Intelligence in due diligence
 
Maher Othman Interior Design Portfolio..
Maher Othman Interior Design Portfolio..Maher Othman Interior Design Portfolio..
Maher Othman Interior Design Portfolio..
 
Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)
 
Interfacing Analog to Digital Data Converters ee3404.pdf
Interfacing Analog to Digital Data Converters ee3404.pdfInterfacing Analog to Digital Data Converters ee3404.pdf
Interfacing Analog to Digital Data Converters ee3404.pdf
 
Adsorption (mass transfer operations 2) ppt
Adsorption (mass transfer operations 2) pptAdsorption (mass transfer operations 2) ppt
Adsorption (mass transfer operations 2) ppt
 
Seizure stage detection of epileptic seizure using convolutional neural networks
Seizure stage detection of epileptic seizure using convolutional neural networksSeizure stage detection of epileptic seizure using convolutional neural networks
Seizure stage detection of epileptic seizure using convolutional neural networks
 
Diploma Engineering Drawing Qp-2024 Ece .pdf
Diploma Engineering Drawing Qp-2024 Ece .pdfDiploma Engineering Drawing Qp-2024 Ece .pdf
Diploma Engineering Drawing Qp-2024 Ece .pdf
 
Basics of Relay for Engineering Students
Basics of Relay for Engineering StudentsBasics of Relay for Engineering Students
Basics of Relay for Engineering Students
 
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
 
Developing a smart system for infant incubators using the internet of things ...
Developing a smart system for infant incubators using the internet of things ...Developing a smart system for infant incubators using the internet of things ...
Developing a smart system for infant incubators using the internet of things ...
 
Dynamo Scripts for Task IDs and Space Naming.pptx
Dynamo Scripts for Task IDs and Space Naming.pptxDynamo Scripts for Task IDs and Space Naming.pptx
Dynamo Scripts for Task IDs and Space Naming.pptx
 
15-Minute City: A Completely New Horizon
15-Minute City: A Completely New Horizon15-Minute City: A Completely New Horizon
15-Minute City: A Completely New Horizon
 
Artificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfArtificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdf
 

computernetworkingmodule4vtu5thsemppt.pptx

  • 1. INFORMATION SCIENCE AND TECHNOLOGY Computer Networking Topic : An example of socket programming : An internet file server Subject Faculty : Asst Professor Mrs Pradeepa J Topic By : Anubhav S 1KT21IS004
  • 2. Socket Programming  Socket programming is a fundamental technique for enabling communication between applications on a network.  It provides a way for programs to establish connections, exchange data, and coordinate actions, regardless of their physical locations  Each socket has a unique address (IP address and port number) that identifies it.  Applications can "plug into" sockets to create connections and start sending and receiving data.
  • 3. Server Setup  This consists of a basic Internet file server and client. The server serves files to clients, while the client requests and receives files from the server.  The server and client code are designed to be platform-independent, meaning they can be compiled and executed on any UNIX system connected to the Internet. Port Selection  Ports are numerical identifiers used to distinguish between different network services running on the same host.  The server code selects a port number (e.g., 12345) for communication. It's essential to choose a port within the range of 1024 to 65535 to avoid conflicts with other processes.  Ports below 1024 are typically reserved for privileged users or standard services.
  • 4. Constants Definition:  The server code defines constants for the chunk size and maximum pending connections.  The chunk size determines the size of data packets transmitted during file transfer, impacting the efficiency of data transmission. Chunk Size and Efficiency:  The chunk size influences the efficiency of file transfer by determining the size of data packets transmitted over the network.  Choosing an appropriate chunk size helps optimize network utilization and minimize overhead associated with data transmission.
  • 5. Handling Pending Connections:  The specified maximum number of pending connections determines how many clients can wait in the queue before additional connections are rejected.  Effective management of pending connections helps prevent server overload and ensures optimal performance. Output Handling:  The fetched file is written to standard output on the client side, allowing it to be displayed in the console or redirected to a file or pipe.  This basic mechanism for output handling provides a simple yet effective way to retrieve and view file content on the client side.