Operating System - HP-UX
1751798 Members
4791 Online
108781 Solutions
New Discussion юеВ

Re: Compress a file before ftp

 
Christian Tremblay
Trusted Contributor

Re: Compress a file before ftp

PS: I'm not sure, but I think in redhat remsh is called rsh

You may try that....
MacMcDonald
Advisor

Re: Compress a file before ftp

got the rsh part - but for some reason it falls over on the login, doesnt want to use the details included in the .netrc.
Christian Tremblay
Trusted Contributor

Re: Compress a file before ftp

I don't have access to a Redhat box to check the rsh use of .netrc, try man rsh on your Redhat box for more info.

You really should try to implement ssh in your environment. .netrc files are considered a security risk and will not survive a SOX audit. In fact their use is prohibited at most security conscious sites.
Peter Nikitka
Honored Contributor

Re: Compress a file before ftp

Hi,

.netrc is used for ftp only - rsh uses a .rhosts or /etc/hosts.equiv file on the remote host to check for logins without the need of an interactive login.

Even for ssh connections (which I recommend) you will have to add data to all involved clients you want to connect to.
If you setup sftp, you could reuse your script(s) nearly unchanged.

mfG Peter

mfG Peter
The Universe is a pretty big place, it's bigger than anything anyone has ever dreamed of before. So if it's just us, seems like an awful waste of space, right? Jodie Foster in "Contact"
MacMcDonald
Advisor

Re: Compress a file before ftp

it seems that rexec uses the .netrc file as well, could i use that to initiate the gzip command?
Volker Borowski
Honored Contributor

Re: Compress a file before ftp

Hi,

you could set up your ftp server to allow the execution of some commands, i.E. compression via script or likewise.

Get manpage of ftp and dig into the
"site exec"
section

i.E. here: http://docs.hp.com/en/B2355-60105/ftpd.1M.html

Watch it, there are scurity issues with this setup !

Volker
Arturo Galbiati
Esteemed Contributor

Re: Compress a file before ftp

Hi Mac,
you can use the rexec command:
rexec host [-l username] [-n] command

HTH,
Art