Why is rsync not found?

Clash Royale CLAN TAG#URR8PPP
rsync -avP /home/user/.profile hpux3:/home/user/.profile
bash: rsync: command not found
If I did ssh to hpux3 machine
rsync
version 3.1.1 protocol version 31
Copyright (C) 1996-2014 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
output truncated
I have set PATH in $HOME/.profile and $HOME/.bashrc. Should I set it in the /etc/profile file?
rsync path
add a comment |
rsync -avP /home/user/.profile hpux3:/home/user/.profile
bash: rsync: command not found
If I did ssh to hpux3 machine
rsync
version 3.1.1 protocol version 31
Copyright (C) 1996-2014 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
output truncated
I have set PATH in $HOME/.profile and $HOME/.bashrc. Should I set it in the /etc/profile file?
rsync path
Thersynccommand must be present on your local machine.
– ott--
Apr 26 '15 at 21:44
1
Of course is present in both machines
– elbarna
Apr 27 '15 at 0:56
add a comment |
rsync -avP /home/user/.profile hpux3:/home/user/.profile
bash: rsync: command not found
If I did ssh to hpux3 machine
rsync
version 3.1.1 protocol version 31
Copyright (C) 1996-2014 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
output truncated
I have set PATH in $HOME/.profile and $HOME/.bashrc. Should I set it in the /etc/profile file?
rsync path
rsync -avP /home/user/.profile hpux3:/home/user/.profile
bash: rsync: command not found
If I did ssh to hpux3 machine
rsync
version 3.1.1 protocol version 31
Copyright (C) 1996-2014 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
output truncated
I have set PATH in $HOME/.profile and $HOME/.bashrc. Should I set it in the /etc/profile file?
rsync path
rsync path
edited Apr 26 '15 at 22:19
Braiam
23.7k2077141
23.7k2077141
asked Apr 26 '15 at 21:35
elbarnaelbarna
4,165123785
4,165123785
Thersynccommand must be present on your local machine.
– ott--
Apr 26 '15 at 21:44
1
Of course is present in both machines
– elbarna
Apr 27 '15 at 0:56
add a comment |
Thersynccommand must be present on your local machine.
– ott--
Apr 26 '15 at 21:44
1
Of course is present in both machines
– elbarna
Apr 27 '15 at 0:56
The
rsync command must be present on your local machine.– ott--
Apr 26 '15 at 21:44
The
rsync command must be present on your local machine.– ott--
Apr 26 '15 at 21:44
1
1
Of course is present in both machines
– elbarna
Apr 27 '15 at 0:56
Of course is present in both machines
– elbarna
Apr 27 '15 at 0:56
add a comment |
1 Answer
1
active
oldest
votes
Your .profile is only read when you log in interactively. When rsync connects to another machine to execute a command, /etc/profile and ~/.profile are not read.
If your login shell is bash, then ~/.bashrc may be read (this is a quirk of bash — ~/.bashrc is read by non-login interactive shells, and in some circumstances by login non-interactive shells). This doesn't apply to all versions of bash though.
The easiest way to make rsync work is probably to pass the --rsync-path option, e.g.
rsync --rsync-path=/home/elbarna/bin/rsync -avP /home/user/.profile hpux3:/home/user/.profile
If you log in over SSH with key-based authentication, you can set the PATH environment variable via your ~/.ssh/authorized_keys. See sh startup files over ssh for explanations of how to arrange to load .profile when logging in over SSH with a key.
6
Note:--rsync-pathis used to set the path ofrsyncon the remote computer. (at first sight I was wondering how was it possible to specify the path torsyncwhile lauchingrsyncon the same machine)
– A.L
Apr 27 '15 at 8:56
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f198756%2fwhy-is-rsync-not-found%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Your .profile is only read when you log in interactively. When rsync connects to another machine to execute a command, /etc/profile and ~/.profile are not read.
If your login shell is bash, then ~/.bashrc may be read (this is a quirk of bash — ~/.bashrc is read by non-login interactive shells, and in some circumstances by login non-interactive shells). This doesn't apply to all versions of bash though.
The easiest way to make rsync work is probably to pass the --rsync-path option, e.g.
rsync --rsync-path=/home/elbarna/bin/rsync -avP /home/user/.profile hpux3:/home/user/.profile
If you log in over SSH with key-based authentication, you can set the PATH environment variable via your ~/.ssh/authorized_keys. See sh startup files over ssh for explanations of how to arrange to load .profile when logging in over SSH with a key.
6
Note:--rsync-pathis used to set the path ofrsyncon the remote computer. (at first sight I was wondering how was it possible to specify the path torsyncwhile lauchingrsyncon the same machine)
– A.L
Apr 27 '15 at 8:56
add a comment |
Your .profile is only read when you log in interactively. When rsync connects to another machine to execute a command, /etc/profile and ~/.profile are not read.
If your login shell is bash, then ~/.bashrc may be read (this is a quirk of bash — ~/.bashrc is read by non-login interactive shells, and in some circumstances by login non-interactive shells). This doesn't apply to all versions of bash though.
The easiest way to make rsync work is probably to pass the --rsync-path option, e.g.
rsync --rsync-path=/home/elbarna/bin/rsync -avP /home/user/.profile hpux3:/home/user/.profile
If you log in over SSH with key-based authentication, you can set the PATH environment variable via your ~/.ssh/authorized_keys. See sh startup files over ssh for explanations of how to arrange to load .profile when logging in over SSH with a key.
6
Note:--rsync-pathis used to set the path ofrsyncon the remote computer. (at first sight I was wondering how was it possible to specify the path torsyncwhile lauchingrsyncon the same machine)
– A.L
Apr 27 '15 at 8:56
add a comment |
Your .profile is only read when you log in interactively. When rsync connects to another machine to execute a command, /etc/profile and ~/.profile are not read.
If your login shell is bash, then ~/.bashrc may be read (this is a quirk of bash — ~/.bashrc is read by non-login interactive shells, and in some circumstances by login non-interactive shells). This doesn't apply to all versions of bash though.
The easiest way to make rsync work is probably to pass the --rsync-path option, e.g.
rsync --rsync-path=/home/elbarna/bin/rsync -avP /home/user/.profile hpux3:/home/user/.profile
If you log in over SSH with key-based authentication, you can set the PATH environment variable via your ~/.ssh/authorized_keys. See sh startup files over ssh for explanations of how to arrange to load .profile when logging in over SSH with a key.
Your .profile is only read when you log in interactively. When rsync connects to another machine to execute a command, /etc/profile and ~/.profile are not read.
If your login shell is bash, then ~/.bashrc may be read (this is a quirk of bash — ~/.bashrc is read by non-login interactive shells, and in some circumstances by login non-interactive shells). This doesn't apply to all versions of bash though.
The easiest way to make rsync work is probably to pass the --rsync-path option, e.g.
rsync --rsync-path=/home/elbarna/bin/rsync -avP /home/user/.profile hpux3:/home/user/.profile
If you log in over SSH with key-based authentication, you can set the PATH environment variable via your ~/.ssh/authorized_keys. See sh startup files over ssh for explanations of how to arrange to load .profile when logging in over SSH with a key.
edited Apr 13 '17 at 12:36
Community♦
1
1
answered Apr 26 '15 at 21:44
GillesGilles
542k12810991616
542k12810991616
6
Note:--rsync-pathis used to set the path ofrsyncon the remote computer. (at first sight I was wondering how was it possible to specify the path torsyncwhile lauchingrsyncon the same machine)
– A.L
Apr 27 '15 at 8:56
add a comment |
6
Note:--rsync-pathis used to set the path ofrsyncon the remote computer. (at first sight I was wondering how was it possible to specify the path torsyncwhile lauchingrsyncon the same machine)
– A.L
Apr 27 '15 at 8:56
6
6
Note:
--rsync-path is used to set the path of rsync on the remote computer. (at first sight I was wondering how was it possible to specify the path to rsync while lauching rsync on the same machine)– A.L
Apr 27 '15 at 8:56
Note:
--rsync-path is used to set the path of rsync on the remote computer. (at first sight I was wondering how was it possible to specify the path to rsync while lauching rsync on the same machine)– A.L
Apr 27 '15 at 8:56
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f198756%2fwhy-is-rsync-not-found%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
The
rsynccommand must be present on your local machine.– ott--
Apr 26 '15 at 21:44
1
Of course is present in both machines
– elbarna
Apr 27 '15 at 0:56