Bug 1271913 - [devexp_public_681]oc rsync cannot work when the rsync command not installed locally
Summary: [devexp_public_681]oc rsync cannot work when the rsync command not installed ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OKD
Classification: Red Hat
Component: oc
Version: 3.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Cesar Wong
QA Contact: Wei Sun
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-10-15 06:11 UTC by Wang Haoran
Modified: 2019-10-08 18:33 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-23 21:17:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Wang Haoran 2015-10-15 06:11:25 UTC
Description of problem:

when remove the rsync command locally , cannot sync file to the pod using oc rsync
Version-Release number of selected component (if applicable):
openshift v1.0.6-610-g1bc373b
kubernetes v1.1.0-alpha.1-653-g86b4e77
AMI:qe_devenv-rhel7_2465

How reproducible:

always
Steps to Reproduce:
1.create a project
2.new app
 $oc new-app registry.access.redhat.com/openshift3/ruby-20-rhel7~https://github.com/openshift/ruby-hello-world.git
3.remove rsync locally
 yum remove rsync
4.sync files after the deploy success
  $oc rsync testfile <pod>:/tmp

Actual results:
get message : rsync not found in local computer

Expected results:
could sync file successfully.


Additional info:

Comment 1 Cesar Wong 2015-10-28 02:32:48 UTC
https://github.com/openshift/origin/pull/5351

Comment 2 Wang Haoran 2015-10-28 06:16:27 UTC
test again using AMI:devenv-rhel7_2576
1. it works with absolute path . 
2. and have problem with relative path, after rsync , the directory name changed.see the log:
[root@ip-172-18-2-7 ~]# mkdir test
[root@ip-172-18-2-7 ~]# echo "tet" >> test/testfile
[root@ip-172-18-2-7 ~]# oc rsync ./test ruby-hello-world-2-udfux:/tmp
W1028 02:05:32.654473    7498 rsync.go:106] rsync command not found in path. Please use your package manager to install it.
st/testfile
[root@ip-172-18-2-7 ~]# oc rsh ruby-hello-world-2-udfux
bash-4.2$ ls -rlt /tmp
total 20
-rw-------. 1 root       root       0 Aug 26 11:54 yum.log
-rwx------. 1 root       root     663 Aug 26 11:56 ks-script-R4xZy7
-rw-r--r--. 1 root       root    1879 Aug 26 11:56 anaconda-post.log
drwxr-xr-x. 6 default    default 4096 Oct 28 01:59 src
-rw-r--r--. 1 1000030000 root       1 Oct 28 02:00 rack.pid
drwxr-xr-x. 2 1000030000 root    4096 Oct 28 02:05 st
bash-4.2$ ls -rlt /tmp/st
total 4
-rw-r--r--. 1 1000030000 root 4 Oct 28 02:05 testfile

Comment 3 Cesar Wong 2015-10-28 17:57:35 UTC
The problem with relative directory name truncation has been fixed in 
https://github.com/openshift/origin/pull/5445

Comment 4 Wang Haoran 2015-10-29 07:40:32 UTC
test again using AMI :devenv-rhel7_2589
1. can sync file using relative path
2. when the cannot sync to a not exited directory will track with this bug :
   https://bugzilla.redhat.com/show_bug.cgi?id=1276008


Note You need to log in before you can comment on or make changes to this bug.