473,606 Members | 2,101 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Copying files across network

Sue
Hello

We have an application where the user would upload files (max size of
200 mb) from their client machine. This application will run on a web
server (its a web server which would be used by the general public),
because of obvious reason, this server will not have access to any
shared directory on the network.

Currently we store the file on the local drive (c:) of that server and
an other application running on an internal server will move that file
to the network. I'm looking for a better way to have the files streamed
across the network. I have the file content stored as a byte array.

Could someone please show me examples of how to do it.

Thanks in advance
Sue..

Feb 7 '06 #1
4 3124
Sue,

Are you in fact not asking for a possibility from a SharePoint server?

You can of course use a webservice do manage the job and let the files go in
the server folders from your users.

However I would never do that on the open webserver.

Just my idea.

Cor
Feb 7 '06 #2
CMM
> because of obvious reason, this server will not have access to any
shared directory on the network.


You can create a service on the internal machine to monitor the the
directory where files are placed using the FileSystemWatch er classes (it
works over the network too) and pull in the file.

But, I'm curious... what's the obvious reason you state? You can create a
locked down domain account for the network share you want to move the files
to and have your web app impersonate the limited account to copy the files
itself. I dunno...

I guess if you don't trust built-in OS filesystem mechanics and security you
can have the the web service communicate with another service across the
network (a remoted .NET application?... or- the equivalent- possibly another
web service internal to the LAN?). But, I don't see how that's any better
than the simpler solutions above.
Feb 7 '06 #3
Sue
Having a shared directory is not an option..(don't ask why, the higher
up's have made that decision) Web service is the last option to
consider...I was asked to look to see if the (200mb) huge file can be
stored in a byte array and streamed across the network...

Also, do you know what is the max limit for a byte array...

Feb 7 '06 #4
CMM
A file *is* a byte array. AFAIK there is no limit on how large a byte array
can be.... though there are RAM considerations with such a huge file. You
will probably want to use a filestream instead as it is optimized to buffer
file contents as it reads them.

Is the problem that you need to throttle the file across the network so that
it doesn't swamp the LAN?

In any case, a novel approach that addresses all your problems would be to
set up an internal FTP server (this is built into Windows Server as an
optional component I think). If you need to throttle the transfer, FTP
server has throttle settings so you don't swamp the network with your 200mb
file transfers. You can even have the web service communicate directly with
it as neither has any domain rights (both run as a locked down web user
account)... that would solve your problem no?

Alternatively, I think the FileSystemWatch er is viable... whether you put
the service on the web server and "push" the file across the LAN or put it
on the destination and "pull" the file. If you need to throttle the file
copy, you would read the file in several bytes at a time (perhaps at some
millisecond or second interval). But, in that case, I think the Internal FTP
server solution is way more robust and easier to implement.

"Sue" <iy*********@ho tmail.com> wrote in message
news:11******** **************@ g43g2000cwa.goo glegroups.com.. .
Having a shared directory is not an option..(don't ask why, the higher
up's have made that decision) Web service is the last option to
consider...I was asked to look to see if the (200mb) huge file can be
stored in a byte array and streamed across the network...

Also, do you know what is the max limit for a byte array...

Feb 7 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
3633
by: Robert Tarantino | last post by:
Hello, I am trying to find a way to create a scheduled task or service that will copy my local profile folders under "Documents and settings" to a network drive. This would allow me to restore my settings if my profile became tampered with or corrupt. Is there any sample code available out there? -Robert
2
1478
by: Richard Jonas | last post by:
I've written a Windows Application in C#.net that runs in the background and silently archives files to a network drive (using the System.IO.File.Copy function). Sometimes, users may run this application when connected to our network via a dial-up connection. This means that files take a long time to copy. If users try and shut down their computer whilst a file is copying, an error message is shown and the only way to shut down the...
0
1529
by: Dan | last post by:
We debug a VB.Net App that uses compact framework to a DAP Windows CE.Net device. When I debug I would like to only have the EXE copied down. Right now it copies any referrences as well and checks the .NET CF version. The first message I receive is: Files in the package 'netcf.all.wce4.armv4.cab' are more recent on the device than on the development computer. Consider upgrading to the latest version. Files affected are:
0
1575
by: surya | last post by:
Hi, I need to enable shadow copying network share folder assemblies. Currently if the path is given as the network share folder path, shadow copying is not enabled. Should something special be done to enable shadow copying of files on network share folders? Thanks in advance, Regards Surya
2
1844
by: | last post by:
Hello, I have a program that starts a new thread to backup files from a computer over the network to our server. The problem is when it is copying the files you can hardly navigate around in windows explorer. I would like this program to backup users files somewhat transparently. As it is now they can hardly navigate through their files and folders while it's running. Is there a way to slow this proccess down or keep it from tying...
10
7824
by: Martin Ho | last post by:
I am running into one really big problem. I wrote a script in vb.net to make a copy of folders and subfolder to another destination: - in 'from.txt' I specify which folders to copy - in 'to.txt' I specify where to copy it - After I read content of 'to.txt' I create one more subfolder named by current date and thats where everything gets to be copied
6
1429
by: Sue | last post by:
Hello We have an application where the user would upload files (max size of 200 mb) from their client machine. This application will run on a web server (its a web server which would be used by the general public), because of obvious reason, this server will not have access to any shared directory on the network. Currently we store the file on the local drive (c:) of that server and an other application running on an internal server...
2
8018
by: Jerad Rose | last post by:
I have a fairly simple C# console app which copies files from a network folder to a local folder. When the app resides on my local C: drive, it runs just fine. However, when the app resides on a network drive, copying the same files from the same source drive and to the same destination drive, it gives me the following exception: System.Security.SecurityException: Request for the permission of type...
3
16993
by: =?Utf-8?B?U2Vhbk1hYw==?= | last post by:
How do I programmatically copy files across a network (from a local workstation to another local workstation on the network) using visual basic 2005? In other words, when in explorer and you enter a unc path to a network workstation, you are prompted with a dialog box asking for the user name and password that has access rights to that computer. After validating, you can access the files on the remote pc just like you can on your own pc,...
0
8010
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8433
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8429
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8084
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8300
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6761
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
5963
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
3969
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1550
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.