Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5991379
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T23:22:41+00:00 2026-05-22T23:22:41+00:00

I am extremely new to socket programming and I am implementaing a file server

  • 0

I am extremely new to socket programming and I am implementaing a file server that receives request like open(), read(), write(), close() from clients. The file server will process the requests and send the clients the return value of each system call.

I don’t know what type of socket I need to define(i.e. stream socket, datagram socket etc). and what command will send the request from the client, how will I receive the return value from the server, how will I receive it at the server end and send the return value to my client.

Will be gratefull to get some pointers.

Thanks

An edit: Is something simple like this work for starting Server not able to properly read/open a filename sent by client in C

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T23:22:42+00:00Added an answer on May 22, 2026 at 11:22 pm

    It depends in part upon your file server design.

    If you’re going for a stateless server, then datagram or stream would be fine. Datagram is relatively nice because your servers and clients don’t need to handle partial requests — the entire contents of the request are contained in the datagram.

    If you’re going for a stateful server, then stream might be nicer — you can automatically release locks and de-allocate resources ‘owned’ by a client when you receive a TCP RST packet. (Client gone, throw away their state.) You could of course build a stateful server with datagram services, but it doesn’t seem like a good fit.

    But on the open Internet, typically you have just UDP and TCP — I have no idea if RDP, a reliable datagram transport, is routed on given ISPs or not. And being forced between unreliable datagrams and reliable streams, I’d recommend reliable streams almost every time. Will your use your protocol on reliable LANs only? Or on lossy wireless or public Internet links?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is the new C++11 going to contain any socket library? So that one could
I am extremely new to python, having started to learn it less than a
I have some extremely weird behavior that seems to result in silent exceptions. How
A Web Socket detects the presence of a proxy server and automatically sets up
(See this question in ServerFault ) I have a Java client that uses Socket
I want to create an extremely simple web server for development purposes in Ruby
So I'm trying to make a client for my server in C#, that accepts
Extremely new to Java an just playing around with it. I'm trying to add
Still extremely new to the whole MVC/LINQ thing. I'm in the processes off building
I'm extremely new to SOAP and I'm trying to implement a quick test client

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.