Sending a file to a server


 
Thread Tools Search this Thread
Operating Systems Solaris Sending a file to a server
# 1  
Old 05-27-2009
Sending a file to a server

Dear Experts,

please help i am very much confused here and not getting the right path,

actually i want to send a file from client to a server,
initially i used mmap() which is failing most of the time so i want to use general IO streams to do that,
i can open a file in "rb" mode
and read to a buffer by using malloc ,
after this i have to use send(buffer(empty, filesize) to send the contents ow to relate them please give me some good suggestion overall i want to replace mmap with general IO methods please tell me how to achieve send(from server)
recv(from client) to work properly.
# 2  
Old 05-27-2009
There are examples of how to do this in almost every UNIX network programming book. I don't believe it to be productive or worthwhile for anyone here to answer this type of question because you will not learn anything by being told the answer.

Also the wording used to explain your problem lead me to conclude that this is a set exercise or assignment and we do not allow homework/classwork problems. I am therfore closing this thread.
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Web Development

Sending file to WebDav Server

Hi All, I am using a webdav server host name : abc.xyz.com.ak username : user123 password : password123 port : 80 I need to send files stored in my windows system to the server, any idea how to do it. I dont know how to create a url in linux for webdav server using details. (2 Replies)
Discussion started by: prakhar_dubey
2 Replies

2. Shell Programming and Scripting

Perl: Sending file from UNIX server to Windows server

I'm trying to write a Perl script where a file from a UNIX server box connects to a Windows server box and copies that file into the Window box. The main problem I have right now is that whenever I try to connect to the Windows box, the connection is refused. The error message that always pops... (2 Replies)
Discussion started by: kooshi
2 Replies

3. Shell Programming and Scripting

Sending a file to 24 Server locations parallely

Hi All, I have to send a processed file to 24 different server locations. I feel, if this job can be done parallel in the background - Time will come down. I found the script to FTP the file for a single server location through past Unix posts as below: #!/usr/bin/ksh ftp -v -n... (16 Replies)
Discussion started by: vsmeruga
16 Replies

4. Shell Programming and Scripting

Perl and sending file to server

Hi, I am trying to write some test code for bigger project where my perl script will send file over to server. This is the current SERVER and CLIENT code I have so far. When I type "hi" from client I get hello back from server and like wise I send send command I get respond back the problem... (1 Reply)
Discussion started by: Dabheeruz
1 Replies

5. Linux

help sending mail on linux server

Hi, I coded a bash script.I m trying to use this command in the script mail -s "test" user@abc.com I tried this command on prompt.however it hangs.I check /var/log/maillog/ stat=Deferred: Connection timed out with mail.rdmedia.com. sendmail: n0M8lscO014303: localhost did not issue... (2 Replies)
Discussion started by: sunsail
2 Replies

6. Programming

Sending mail in C/C++ in unix server

Hi Frnds, I have a task in my project wherein i have to send out a mail from my C++ code.With some file attachements.Please help me in this. At a higher level wat i can tell is my code generated 3 csv file and i have to send these files as attachement. My code is executed in unix... (6 Replies)
Discussion started by: electroon
6 Replies

7. Programming

sending file from server to client

hi dear i m very new to socket programing . i need the source code which sends file from server to client . i mean both server n client programe which sends file . can u do this for me please my email id is email id removed regards bilal (1 Reply)
Discussion started by: bilal
1 Replies

8. UNIX for Advanced & Expert Users

sending email via mail server

hi everyone i am facing one problem. there is one unix server in our organisation which stores daily routine backup, and one mail server which is on windows 2k3, they are on one intranet. now i want that a mail should be generated and sent to the e-mail id of employees like nitin@hotmail.com... (1 Reply)
Discussion started by: parmeet
1 Replies

9. Shell Programming and Scripting

FTP script for sending a file from one unix directory to another unix server director

Hi, My local server is :/usr/abcd/ Remote server is :/Usr/host/test/ I want to send files from local unix directory(All files starting with O_999) to remote host unix directory. Can any body give me the Unix Shell script to do this. One more doubt: Shall we need to change the file... (1 Reply)
Discussion started by: raja_1234
1 Replies
Login or Register to Ask a Question