#18724 closed defect (fixed)
VBox 5.2.x: VBoxManage copyto --target-directory now requires an ending slash for guests => fixed in 5.2.x x>32
Reported by: | kboortz | Owned by: | paulson |
---|---|---|---|
Component: | other | Version: | VirtualBox 5.2.30 |
Keywords: | VBoxManage copyto target-directory | Cc: | |
Guest type: | Windows | Host type: | Solaris |
Description
The "VBoxManage copyto" destination directory given to "--target-directory" for a Windows guest now requires an ending slash. I assume this is not an intentional change.
The error message when leaving out the ending slash in the destination "C:/tmp" is
VBoxManage: error: File copy failed VBoxManage: error: Copying file "/tmp/foo" to guest failed: VERR_ACCESS_DENIED VBoxManage: error: Details: code VBOX_E_IPRT_ERROR (0x80bb0005), component GuestSessionWrap, interface IGuestSession VBoxManage: error: Context: "int gctlCopyFileToDest(COPYCONTEXT*, const char*, const char*, gctlCopyFlags)" at line 2176 of file VBoxManageGuestCtrl.cpp VBoxManage: error: Copying file "/tmp/foo" to guest failed: VERR_ACCESS_DENIED. VBoxManage: error: Error processing "/tmp/foo", rc=VERR_GENERAL_FAILURE
Change History (7)
comment:1 by , 5 years ago
Owner: | set to |
---|---|
Status: | new → assigned |
Summary: | VBoxManage copyto --target-directory now requires an ending slash for Windows guest → VBox 5.2.x: VBoxManage copyto --target-directory now requires an ending slash for guests |
comment:2 by , 5 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Summary: | VBox 5.2.x: VBoxManage copyto --target-directory now requires an ending slash for guests → VBox 5.2.x: VBoxManage copyto --target-directory now requires an ending slash for guests => fixed in 5.2.x x>32 |
This has been fixed in 5.2.x (x > 32) and the fix will be part of any 5.2.x Testbuilds with a revision >= r133443. As mentioned previously this doesn't apply to VirtualBox 6.0.x.
follow-up: 5 comment:3 by , 5 years ago
This fix seems to break copyfrom --target-directory. This command fails on Windows 7 host with Windows XP/Windows 7 guests in VirtualBox 5.2.34.
>"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" guestcontrol vm_win7 copyfrom -v --username User --password 123 --target-directory D:\log C:\Users\User\Desktop\1.txt Creating guest session as user 'User'... Waiting for guest session to start... Successfully started guest session (ID 1) Copying from guest to host ... Directory "D:\log\" already exists Source: C:\Users\User\Desktop\1.txt Copying "C:\Users\User\Desktop\1.txt" to "D:\log\" ... 0%... Progress state: VBOX_E_IPRT_ERROR VBoxManage.exe: error: Opening/creating destination file on host "D:\log\" failed: VERR_PATH_NOT_FOUND. VBoxManage.exe: error: Error processing "C:\Users\User\Desktop\1.txt", rc=VERR_GENERAL_FAILURE Closing guest session ...
When I try without --target-directory,
copyfrom [common-options] [--dryrun] [--follow] [-R|--recursive] <guest-src0> [guest-src1 [...]] <host-dst>
<host-dst> is written from start but not replaced. This corrupts <host-dst> if a smaller file is copied.
comment:4 by , 5 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
follow-up: 7 comment:5 by , 5 years ago
Replying to robpats:
This fix seems to break copyfrom --target-directory.
Then a new bug should be filed against the currently used release.
Re-opening this old one which had a source code change is not the right action.
comment:6 by , 5 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
This is a regression introduced in VirtualBox 5.2.8 and applies to any type of guest, not just Windows guests. A variety of subsequent changesets reworked this code in VirtualBox 6.0.0 so only 5.2.x is affected.
Here is the output from a MacOS host running VBox 5.2.32 attempting to copy a file to a Linux guest using '--target-directory':