Advertisement
Guest User

Untitled

a guest
Oct 5th, 2017
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.00 KB | None | 0 0
  1. RSYNC_PASSWORD
  2. Setting RSYNC_PASSWORD to the required password allows you to
  3. run authenticated rsync connections to an rsync daemon without
  4. user intervention. Note that this does not supply a password to
  5. a shell transport such as ssh.
  6.  
  7. USER or LOGNAME
  8. The USER or LOGNAME environment variables are used to determine
  9. the default username sent to an rsync daemon. If neither is
  10. set, the username defaults to 'nobody'
  11.  
  12. #!/bin/bash
  13. USER=name
  14. RSYNC_PASSWORD=pass
  15. DEST="myhost::mymodule"
  16.  
  17. /usr/bin/rsync -rltvvv . $DEST
  18.  
  19. /usr/bin/rsync -rltvvv . myuser@myhost::mymodule
  20.  
  21. opening tcp connection to myhost port 873
  22. opening connection using --server -vvvltr . mymodule
  23. @ERROR: auth failed on module mymodule
  24. rsync error: error starting client-server protocol (code 5) at main.c(1383) [sender=2.6.9]
  25. _exit_cleanup(code=5, file=main.c, line=1383): about to call exit(5)
  26.  
  27. rsync -rltvvv --password-file=/root/secret . user@host::dest
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement