RE: Writing a file to another computer on the LAN?

2005-05-05 Thread MisterX
Why not write a networking protocol that resembles scripting in Rev?

Make a library of it

requestsendfiletohost hostip,filepath

sendfile
cancelfilesend
receivefile
etc...

(dont limit it to sendstack...)

and it's not even complicated actually!!!

PC1
wait for call c on port p
validateuser/data = get file from me (pc2) with this id
go stack url pc2ipaddress:p
or
read from socket url blabla to url (file:thisfilepath)

PC2
send call get file from me... to pc1ipaddress
open socket on port p with message sendfile to pc2 whatever...

on sendfile x
  write to socket p url (file:x) to pc2ipaddress
end sendfile

just off my head but it should work like a charm. There's a full example 

Or the taoo way, all we need is:
1 stack in the backscript/stackinuse (the network manager) to monitor
network traffic or establish the connections. Much like I've seen with the
revChat stack. but as a library with a protocol language to exchange files,
scripts, information or objects in xml, etcml formats.

Naturally there will be issues as threading is still a dream in RunRev but
it allows the following doors to open if listening on multiple ports is not
viable:
Use multiple instances of RunRev to communicate across different ports with
1 or more portlistening runrev-instances. Transfer stacks to them to make
remote/distributed execution or send remote scripts/data (synchronicity and
security is an issue without or without threading). But i think i got a
quick solution for that - the roundrobin heartbeat method as it is known in
clusters.

Im certainly on this path at work (large server farm multi-site
LAN/SAN/NAS/WAN environment) to manage different servers without any NT
tools to depend on (they tend to break/change parameters depending on
windows versions). Although with windows base networking, transfering files
across the network is a simple as 

get shell(robocopy \\server1\driveletterorsharename[$]\filepath.fileext \
  \\server2\driveletterorsharename[$]\filepath.fileext   \ 
  myoptionswitcheswhichvaries[situationcontext])

xcopy, scopy, robocopy, xxxcopy (the best - 10 pages of switches for all
occasions - i have plans one day to write an interface for it for
synchronized copies but Robocopy has done the job so far.). One other thing
to know is regarding extra long file paths. Most copy programs will choke
and abort that file. It's good to keep logs. For extra long file path
xxxcopy or subst.exe (Net use only maps the share's root, subst can mount as
a drive any path in a shared resource.) 

Using file sharing is so much simpler than with net use Franz. Although
there's performance hits depending on how you copy from where to where. If
you copy from server a to server c via server b (in rdp - terminal service
remote desktop p?) there will be a cached copy from a to b to c... Things to
know... 

As you see, a one liner suffices for any occasion.

And all this i already have in an NTResKit library stack that handles
multiple shares, files, security and audit settings or permissions, log
errors parsing (and fixing), user-editing, etc etc etc that NT domain admins
do. Not free! But there's a couple simple examples on MonsieurX.com.

I've done all of it in MC with shell calls - never the RevTools. Having to
delete around 50GBs of files here and there using rev is unthinkeable... And
it doesn't support unc file paths //servername/share. Would this solve all
our problems? Send script to stack on //PCServer

I dont want to write externals because someone already wrote the wheel using
shell tools which i can launch and forget! (actually not a good idea to
forget unless you're sure nothing iwll break down in between - which happens
all the time!)

But for rev-networking, like the libURL code we enjoy so much, there's lots
of benefits to have it built in rather than use external tools. 

For example, if the shell program stalls or awaits an answer, rev doesn't
know what to do... (besides the fact that your shell(start...) because
that too can fail (the directory being set for a non existent folder or
drive letter for example! 

And there is still no timeout for any commands unless you trick Rev to do so
with a second instance of Rev that kills the first one if it stops
responding - round-robin cluster technique for better availability (google
it). 

Also, some shells require interactive messages and we can't do that that I
know (like writting to the args[] or typing text into the shell (like the
message!). 

Net use can block you this way btw if a password is required... Know your
switches!

All it takes is a little scratching to see all the problems and limits in
RunRev's current engine in this particular field. 

But i'll be experimenting with that soon. We'll see:

SendObject hostobject, ascriptobject,
returnmessageandparametersinforequiredobject

In terms of long-term reliability, relying on other programs can create
issues of incompatibility with parameters or output which are also out of
your control but it does save a lot 

Re: Writing a file to another computer on the LAN?

2005-05-04 Thread Alex Tweedly
Malte Brill wrote:
Hi list,
I´m new to all this Networking stuff, so please be patient. ;-)
What I want to do is create a set of folders and files on another 
computer connected to a small LAN.  How do I go about this? I 
configured my router to assign a static IP to one of the computers 
(running OsX). I now can get files from library/webserver by using

get URL http://staticIPAdd/test.txt;
but I can´t use
put blah into URL http://staticIP/test.txt;
-Error 405 Method not allowed
How do I go about this? How can I write text to a file on the other 
machine? Can I write to a different folderthan library/webserver?
Thanks a lot!
There are lots of options  probably too many :-)
1. Change your webserver to allow http put operations.
Most webservers disallow this, and will default to disallowing it, but 
you can change the config to allow it. It's generally disallowed because 
it opens a security hole by allowing other people to write to your 
webserver - but if this server is simply serving an internal network for 
some app, not open to the wide, dangerous, world that could be OK.
Google for xxx allow http put where xxx is your webserver, and you'll 
find instructions - especially if xxx == Apache.

2. Export and mount files systems, and access them through that.
3. Run a FTP server on the server, and use put URL ftp://; etc.
and many, many others.
--
Alex Tweedly   http://www.tweedly.net

--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.2 - Release Date: 02/05/2005
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: Writing a file to another computer on the LAN?

2005-05-04 Thread Chipp Walters
Hi Malte,
I would recommend creating a shared folder on the 'networked' drive, 
then trying to 'drag/drop' a file from your computer to it to make sure 
it works. If it does, then you can map it to a drive letter, and simply 
use the put URL form:

put URL file:C:/test.txt into URL file:X:/test.txt
HTH,
Chipp
Malte Brill wrote:
Hi list,
I´m new to all this Networking stuff, so please be patient. ;-)
What I want to do is create a set of folders and files on another 
computer connected to a small LAN.  How do I go about this? I configured 
my router to assign a static IP to one of the computers (running OsX). I 
now can get files from library/webserver by using
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: Writing a file to another computer on the LAN?

2005-05-04 Thread Malte Brill
Hi Chipp, Franz, Alex and all!
Thanks for your replys. Even though the tips for Win are useful they 
don´t really help at the moment, as I need to use a Mac with OsX.
I´ll bookmark them anyway, just in case. ;-)

The suggestion by Alex to set up FTP sounds good, but I have no idea 
how to do it. A quick goole search leads me to nowhere. Anyone an 
idea/link to a tutorial on how to set up an FTP server on Mac Os X?

Thanks,
Malte
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: Writing a file to another computer on the LAN?

2005-05-04 Thread Malte Brill
Ok folks, I´m dumb.
system preferences-Sharing-check ftp
Thanks Björnke!
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: Writing a file to another computer on the LAN?

2005-05-04 Thread Sarah Reichelt
Thanks for your replys. Even though the tips for Win are useful they 
don´t really help at the moment, as I need to use a Mac with OsX.
I´ll bookmark them anyway, just in case. ;-)

The suggestion by Alex to set up FTP sounds good, but I have no idea 
how to do it. A quick goole search leads me to nowhere. Anyone an 
idea/link to a tutorial on how to set up an FTP server on Mac Os X?

Setting up an FTP server on Mac OS X is really complicated...
Go to the sharing system prefs and check FTP Access :-)
Take a note of the address that is then shown at the bottom of the 
window and that's what you can use to log in.

However, I just use personal file sharing, with a Rev script like this 
using AppleScript to connect:
tAddress is the IP address of the remote computer
tUser is the name of a valid user on that remote computer who is 
allowed to log in
tPass is their password

put mount volume   quote  afp://  tAddress  /  tUser  quote 
 \
 on server   quote  tAddress  quote   as user name  \
 quote  tUser  quote   with password   quote  tPass  quote 
into tScript
do tScript as AppleScript

Once you have done this, the remote computer's user folder appears on 
your desktop as an external drive and you can read  write using the 
URL commands.

Cheers,
Sarah
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: Writing a file to another computer on the LAN?

2005-05-04 Thread Malte Brill
Thanks Sarah!
(Did I mention I am dumb before? g)
I like the applescript variant. This will simplify things a lot...
Cheers,
Malte
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: Writing a file to another computer on the LAN?

2005-05-04 Thread sims
At 1:38 AM +0200 5/5/05, Malte Brill wrote:
Anyone an idea/link to a tutorial on how to set up an FTP server on Mac Os X?

Google using setting up ftp server on OS X gave me the following:
http://www.creativemac.com/2002/09_sep/tutorials/ftposx0209242.htm
http://www.atpm.com/8.12/networking.shtml
http://home.earthlink.net/~dgreuel/howto.html
hth
sims
___
use-revolution mailing list
use-revolution@lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution