restore -rf user@host:file

Matthias Apitz guru at unixarea.de
Tue Nov 24 11:22:22 UTC 2009


El día Tuesday, November 24, 2009 a las 11:44:52AM +0100, n dhert escribió:

> To use the restore command (dump/restore) with a dump file on a remote
> machine, the man restore tells you can use the syntax restore -rf
> user at host:file, this uses rcmd(3)
> If from the target machine (on same subnet as remotemachine),
> logged in as root, I enter
> targetmachine# cd /home/testrestore
> targetmachine# tar -rf root@ IP_of_remote_machine:/home/file.dmp

Why you are talking here about tar(1) if you need restore(1M)?

> I get
> IP_of_remote_machine: Connection refused
> login to IP_of_remote_machine as root failed
> There needs some more setup for this in order to work, (hosts.equiv,
> .rhosts  or something ??).
> How exactly ?
> (I just need this for the restore, certainly not to be a permanent way of
> transferring files)

just use another normal user and not 'root'; you only need read access
to the file on the remote server;

> 
>  <root@%20machine.domain:/dir1/dir2/file.dmp>

I'm usingt for restore:

# newfs /dev/daXXXXX
# mount /dev/daXXXXX /mnt
# cd /mnt

# ssh guru at albatros cat dumpsRebelion-20080825/usr.dmp.gz | gzip -dc | restore -r -f -

(my dumps are compressed there);

HIH

	matthias

-- 
Matthias Apitz
t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211
e <guru at unixarea.de> - w http://www.unixarea.de/
Vote NO to EU The Lisbon Treaty: http://www.no-means-no.eu


More information about the freebsd-questions mailing list