Solved

Upload multiple files from different computers concurrently into a single file on server windows server 2003.

Posted on 2011-09-03
5
236 Views
Last Modified: 2012-09-07
Hi,

I want to upload several files from different workstations to a single file in the server. These files might be concurrently uploaded, that is one workstation might be uploading a file at the same time with another. Of course these files will need to go into a single file in the server. I can use FTP or HTTP.

Regards
0
Comment
Question by:lxfdirs
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 19

Expert Comment

by:lamaslany
ID: 36477839
To confirm:  You are looking to merge concurrently uploading files of the same name together rather overwrite it?  If so this will not work.  I'd suggest that the file names be different and to have a scheduled/triggered service on the server to sequentially merge the files together.
0
 
LVL 25

Expert Comment

by:Tony Giangreco
ID: 36477863
I agree, you need to either create a seperate folder for each machine or set a unique prefix to the files on each Pc other wise all duplicte files will be over written. This could create a real mes.

I suggest rethinking your logic and come up with a new plan.
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 36478368
No that won't happen.  You have to use a program on the server to merge them After they are uploaded.
0
 
LVL 16

Accepted Solution

by:
AlexPace earned 500 total points
ID: 36489603
If you have fine control over the FTP client and the server supports resumable uploads you could trick the server into doing it but the clients would need to do the uploads sequentially in a sort of round-robin approach like shuffling a deck of cards.

Suppose 3 clients lets call them A, B, and C and they want to upload a file named foo.txt
All clients connect to the FTP server and request a directory listing every X seconds.
Client B can begin an upload only if a file named A.done is on the the remote folder.
Client C can begin an upload only if a file named B.done is on the remote folder.
Client A can begin an upload only if a file named C.done is on the remote folder.

So, when we are ready to start we create a signal file named C.done and it will be noticed by Client A which will upload 100 bytes of foo.txt then rename C.done to A.done.  At this point Client B will detect the A.done file and set the resume point for foo.txt at 100 and then upload another 100 bytes, rename A.done to B.done.  This will be noticed by Client C which will now have a turn.  If any client has less than 100 bytes they just do what they can and rename the file. If any client has zero bytes they create a file named X.empty.  The file is "done" when the server has A.empty and B.empty and C.empty.

So, after all this work you have an interleaved data file.

Instead of this, why don't you tell us what you are trying to achieve and perhaps we can suggest an alternative.
0
 

Author Comment

by:lxfdirs
ID: 36494861
Experts:

Appreciate all your responses. Let me analyze my approach and your suggestions a litte bit more and I will come back to you.

Regards
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Organizations create, modify, and maintain huge amounts of data to help their businesses earn money and generally function.  Typically every network user within an organization has a bit of disk space to store in process items and personal files.   …
ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question