Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

header-navigation
keyboard_arrow_up
close
keyboard_arrow_left
Junos CLI Reference
Table of Contents Expand all
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

request vmhost local-file-copy

date_range 03-Jul-24

Syntax

content_copy zoom_out_map
 
     request vmhost local-file-copy source source_path destination destination_path;             

Description

Copy a file or a directory present under /var/public/ directory structure on the hypervisor to a different name under /var/public/ directory structure.

Options

  • source source-path—Name of the source path from which the file is to be copied.

  • destinationdestination-path—Name of the destination path to which the file is copied.

Additional Information

Consider the following guidelines while creating a local path.

  • Both paths should be under /var/public/ directory

  • Avoid special characters. You can include alphanumeric characters, hyphen, underscore, dot, and asterisk.

  • Avoid relative path components .. and /./

  • Avoid ending the path with /.

Following are the examples of a path:

  • /var/public/sanity_packages

  • /var/public/sanity_packages/readme.txt

  • /var/public/12-hours.data

Required Privilege Level

Maintenance

Sample Output

request vmhost local-file-copy (To copy a directory)

content_copy zoom_out_map
user@host> request vmhost local-file-copy source /var/public/sanity_packages destination /var/public/new_sanity_packages
'/var/public/sanity_packages' -> '/var/public/new_sanity_packages'
'/var/public/sanity_packages/centos-linux-1.img.gz' -> '/var/public/new_sanity_packages/centos-linux-1.img.gz'
'/var/public/sanity_packages/vnf_test_pkg.tar.gz' -> '/var/public/new_sanity_packages/vnf_test_pkg.tar.gz'
'/var/public/sanity_packages/readme.txt' -> '/var/public/new_sanity_packages/readme.txt'
                                                                                                                                 
         

request vmhost local-file-copy (To copy a file specifying the destination file name)

content_copy zoom_out_map
user@host> request vmhost local-file-copy source
/var/public/sanity_packages/readme.txt destination 
/var/public/new_sanity_packages/new_readme.txt
'/var/public/sanity_packages/readme.txt' ->
'/var/public/new_sanity_packages/new_readme.txt'

request vmhost local-file-copy (To copy a file specifying the destination directory)

content_copy zoom_out_map
user@host> request vmhost local-file-copy source 
 /var/public/sanity_packages/readme.txt destination 
/var/public/new_sanity_packages/
'/var/public/sanity_packages/readme.txt' ->
'/var/public/new_sanity_packages/readme.txt'

Release Information

Command introduced in Junos OS Release 24.2R1 for NFX150, NFX250, and NFX350 devices.

footer-navigation