SlideShare a Scribd company logo
1 of 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

More Related Content

Similar to 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
 

Similar to 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
 

Recently uploaded

Work-Permit-Receiver-in-Saudi-Aramco.pptx
Work-Permit-Receiver-in-Saudi-Aramco.pptxWork-Permit-Receiver-in-Saudi-Aramco.pptx
Work-Permit-Receiver-in-Saudi-Aramco.pptxJuliansyahHarahap1
 
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxOrlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxMuhammadAsimMuhammad6
 
Online electricity billing project report..pdf
Online electricity billing project report..pdfOnline electricity billing project report..pdf
Online electricity billing project report..pdfKamal Acharya
 
DC MACHINE-Motoring and generation, Armature circuit equation
DC MACHINE-Motoring and generation, Armature circuit equationDC MACHINE-Motoring and generation, Armature circuit equation
DC MACHINE-Motoring and generation, Armature circuit equationBhangaleSonal
 
Moment Distribution Method For Btech Civil
Moment Distribution Method For Btech CivilMoment Distribution Method For Btech Civil
Moment Distribution Method For Btech CivilVinayVitekari
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXssuser89054b
 
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLEGEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLEselvakumar948
 
Hospital management system project report.pdf
Hospital management system project report.pdfHospital management system project report.pdf
Hospital management system project report.pdfKamal Acharya
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiessarkmank1
 
Computer Networks Basics of Network Devices
Computer Networks  Basics of Network DevicesComputer Networks  Basics of Network Devices
Computer Networks Basics of Network DevicesChandrakantDivate1
 
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARKOUSTAV SARKAR
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwaitjaanualu31
 
Wadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxWadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxNadaHaitham1
 
Unleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leapUnleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leapRishantSharmaFr
 
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...drmkjayanthikannan
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VDineshKumar4165
 
DeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesDeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesMayuraD1
 
Design For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the startDesign For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the startQuintin Balsdon
 

Recently uploaded (20)

Work-Permit-Receiver-in-Saudi-Aramco.pptx
Work-Permit-Receiver-in-Saudi-Aramco.pptxWork-Permit-Receiver-in-Saudi-Aramco.pptx
Work-Permit-Receiver-in-Saudi-Aramco.pptx
 
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxOrlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
 
Online electricity billing project report..pdf
Online electricity billing project report..pdfOnline electricity billing project report..pdf
Online electricity billing project report..pdf
 
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
 
Integrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - NeometrixIntegrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - Neometrix
 
DC MACHINE-Motoring and generation, Armature circuit equation
DC MACHINE-Motoring and generation, Armature circuit equationDC MACHINE-Motoring and generation, Armature circuit equation
DC MACHINE-Motoring and generation, Armature circuit equation
 
Moment Distribution Method For Btech Civil
Moment Distribution Method For Btech CivilMoment Distribution Method For Btech Civil
Moment Distribution Method For Btech Civil
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
 
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLEGEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
 
Hospital management system project report.pdf
Hospital management system project report.pdfHospital management system project report.pdf
Hospital management system project report.pdf
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
Computer Networks Basics of Network Devices
Computer Networks  Basics of Network DevicesComputer Networks  Basics of Network Devices
Computer Networks Basics of Network Devices
 
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
 
Wadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxWadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptx
 
Unleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leapUnleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leap
 
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - V
 
DeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesDeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakes
 
Design For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the startDesign For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the start
 

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.