Wind River Support Network

HomeDefectsLIN1018-4275
Fixed

LIN1018-4275 : inetutils: rcp directory copy is not working

Created: Jun 14, 2019    Updated: Jul 4, 2019
Resolved Date: Jun 20, 2019
Previous ID: LIN9-8635
Found In Version: 10.18.44.7
Fix Version: 10.18.44.8
Severity: Severe
Applicable for: Wind River Linux LTS 18
Component/s: Userspace

Description

The rcp command in WRL9 can't copy directory.

Replace with the WRL6's rcp.inetutils, it works fine.

 

See my below test log:

------------

root@intel-x86-64:~# rcp -r root@192.168.122.211:/root /test/
root@intel-x86-64:~# ls -l root/
total 0
root@intel-x86-64:~#

root@intel-x86-64:~# rcp -V
rcp (GNU inetutils) 1.9.4
Copyright (C) 2015 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by many authors.
root@intel-x86-64:~# ls
root
root@intel-x86-64:~# tree root/
-sh: tree: command not found
root@intel-x86-64:~# ls -l root/
total 0
root@intel-x86-64:~# cp ../rcp.inetutils /usr/bin/rcp.inetutils
root@intel-x86-64:~# rcp -r root@192.168.122.211:/root /test/
root@intel-x86-64:~# ls -l root/
total 4
drwxr-xr-x 2 root root 4096 May 16 2019 test-dir
root@intel-x86-64:~# rcp -V
rcp (GNU inetutils) 1.9.1
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by many authors.

------------

 




 

Steps to Reproduce

project configuration:

wrlinux-9/setup.sh --dl-layers --distros wrlinux-ovp --machines intel-x86-64 --templates feature/initramfs,feature/kdump,feature/kexec,feature/kernel-ovp-kvm,feature/sysklogd,feature/dpdk,feature/package-management --layers wr-kernel wr-ovp

 

Start VM using a Freebsd qcow2 image, which can be download from:

[https://download.freebsd.org/ftp/releases/VM-IMAGES/11.2-RELEASE/amd64/Latest/]

 

Use the attached xml, change the qcow2 image path as your test environment.

#virsh create  x86-64-kvm-guest-local-qcow2.xml

 

To access the guest, you can use vncviewer on another host.

The command "virsh vncdisplay $domain_name " will show the vncdisplay id, by default it's 0.

vncviewer $WRL9_host_ipaddress:0

 

If you want to use the "virsh console $domain_name" to access the serial console on the WRL9 host shell, you may need to change the Freebsd default setting to use the serial console.

/boot/defaults/loader.conf:

console="comconsole"

 

/etc/ttys:

dcons   "/usr/libexec/getty std.9600"   vt100   on secure

 

Then you can use:

#virsh console $domain_name 

to access the guest console, to exit the guest console, use Ctrl+] .

 

In the freebsd guest, enable rshd by:

create /root/.rhosts:

192.168.122.1 root

 

edit /etc/hosts.equive:

+@192.168.122.1

 

edit /etc/pam.d/rsh:

auth required pam_rhosts.so no_warn allow_root

 

/etc/inetd.conf:

shell stream tcp nowait root /usr/libexec/rshd rshd
login stream tcp nowait root /usr/libexec/rlogind rlogind

 

/etc/rc.d/inetd restart

 

mkdir /root/test

echo "test" > /root/test/test1

 

From the WRL9 host shell, run the following command:

mkdir -p /root/gyang

rcp -r root@192.168.122.211:/root /root/gyang/

 

After complete, check if the root directory, it's empty.

 

replace rcp.inetutils with the WRL6's binary, it works fine.
Live chat
Online