VirtualBox

Ticket #14336 (reopened defect)

Opened 2 years ago

Last modified 5 weeks ago

Error with copyfrom

Reported by: littlebuck144 Owned by: pentagonik
Priority: major Component: other
Version: VirtualBox 5.0.0 Keywords:
Cc: Guest type: other
Host type: other

Description (last modified by frank) (diff)

I just recently, upgraded to the latest version of virtual box version 5.0.0 r101573 and I cannot get the copyfrom command to work.

Here is the command I'm trying to run and the resultant error I get:

C:\Program Files\Oracle\VirtualBox>VBoxManage.exe guestcontrol
    "Windows Server 2008 x64" copyfrom
    --target-directory "C:\BuildLogs\Install Log - Win 7.txt"
    "C:\ProgramData\MyApp\Installer.txt"
    --username "TestUser" --password "111111" --recursive --verbose

VBoxManage.exe: error: File copy failed
VBoxManage.exe: error: Unable to write "C:\ProgramData\MyApp\Installer.txt" to "C:\BuildLogs/Install Log - Win 7.txt
": Access denied
VBoxManage.exe: error: Details: code VBOX_E_IPRT_ERROR (0x80bb0005), component G
uestSessionWrap, interface IGuestSession
VBoxManage.exe: error: Context: "int __cdecl gctlCopyFileToDest(struct COPYCONTE
XT *,const char *,const char *,enum gctlCopyFlags)" at line 2162 of file VBoxMan
ageGuestCtrl.cpp
VBoxManage.exe: error: Unable to write "C:\ProgramData\MyApp\Installer.txt" to "C:\BuildLogs/Install Log - Win 7.txt
": Access denied.
VBoxManage.exe: error: Error processing "C:\ProgramData\MyApp\Installer.txt", rc=VERR_GENERAL_FAILURE

Attachments

vbox.log Download (43.0 KB) - added by Magnus Madsen 2 years ago.
Log file from running VboxService verbosely when trying to copy a file to the guest
vbox-1-admin.log Download (11.4 KB) - added by Magnus Madsen 2 years ago.
Process log file from running VboxService verbosely when trying to copy a file to the guest
VBox.log Download (102.6 KB) - added by kjonca 20 months ago.
VBox.2.log Download (70.6 KB) - added by xpavlice 20 months ago.
Guest_W7x64-host_Ubuntu14

Change History

comment:1 Changed 2 years ago by frank

  • Description modified (diff)
  • Summary changed from Error with the virtual box 4.0 copyfrom command to Error with copyfrom

comment:2 Changed 2 years ago by Magnus Madsen

I can confirm this error occurs, it does not seem to be affected by the version of the Guest Additions. I tested with both 4.27, 5.0.2 and 5.0.3.102322 without success.

This error occurs in both 5.0.0, 5.0.2 and 5.0.3.102322 and also affects copying files to the VM.

comment:3 Changed 2 years ago by Magnus Madsen

The problem is still present in 5.0.6.

comment:4 Changed 2 years ago by Magnus Madsen

The problem affects both copyto and copyfrom, but does not seem to affect any other guestcontrol actions that I tried.

Host: Windows 7 x64
Guest: Windows 7 x64, Windows 7 x86, Windows XP x86.
Guest additions: 4.27, 5.0.2, 5.0.6

Running the following command:

C:\Program Files\Oracle\VirtualBox>vboxmanage guestcontrol "Win7 SP1 x64" copyto "C:\host_path_to_file.test" --use
rname {USERNAME} --password {PASSWORD} --target-directory C:\ --verbose

Returns no output at all - no error message appears. Interestingly, changing the guest target directory to a non-existing path gives no error message either.

comment:5 Changed 2 years ago by Magnus Madsen

The problem also occurs when using the COM interface to attempt to copy a file to a VM. No error is thrown, but the operation does not complete.

comment:6 Changed 2 years ago by Magnus Madsen

The problem is still present in 5.0.8. I have attached some verbose log files from VboxService in the guest when running additions 5.0.8. The command I attempted to run against the VM while the logging was going on was:

vboxmanage guestcontrol "Win7 SP1 x64" 
    copyto C:\path_to_file.test --target-directory C:\ 
    --username admin --password {password}

The attached files are vbox.log and vbox-1-admin.log.

Changed 2 years ago by Magnus Madsen

Log file from running VboxService verbosely when trying to copy a file to the guest

Changed 2 years ago by Magnus Madsen

Process log file from running VboxService verbosely when trying to copy a file to the guest

comment:7 Changed 2 years ago by Magnus Madsen

I think this line in the log could be telling - it looks like the filename argument does not make it to the guest.

Contrast the line from a working copy in 4.3.32:

00:00:00.031250 main     Request to start process szCmd=vbox_cat, uFlags=0x4, 
                         szArgs=--output=C:/temp.txt, szEnv=<None>, uTimeout=30000

with that from 5.0.8:

00:00:00.000000 main     Request to start process szCmd=vbox_cat, uFlags=0x4, 
                         szArgs=, szEnv=<None>, uTimeout=30000

comment:8 Changed 2 years ago by rogierschouten

Have the same problem in v5.0.8 r103449 copying from Host Windows 7 to Guest Windows Server 2012R2

Also the documentation for copyfrom is not correct and does not match the command-line help.

I'm really stuck now because in v4 the run command doesn't work and now in v5 the copyfrom command doesn't work. I need to do both. If you need help reproducing just ask and I'll try to help.

comment:9 Changed 2 years ago by Magnus Madsen

Problem is still present in v5.0.10.

comment:10 Changed 2 years ago by Magnus Madsen

Problem does not look to be fixed in v5.0.12- r104815 either.

comment:11 Changed 2 years ago by cmaier

Is anyone from Oracle interested in fixing this issue? Really strange that there is not a single reaction from them.

comment:12 Changed 2 years ago by frank

Regarding expectations and possible ETAs for a fix: Please read the 2nd paragraph from here. We are aware of several problems which still exist in the guest control code.

comment:13 Changed 22 months ago by jpsider

Are there other tickets we can follow? I am specifically interested in problems with "copyto". I am not able to complete the copy and I am not getting any feedback from the cmdline. Not sure if this is the same bug, related bug, or completely different bug. thanks!

FYI - running the latest build I could find Version 5.0.14 r105127 (updated guest additions as well).

Last edited 22 months ago by jpsider (previous) (diff)

comment:14 Changed 22 months ago by PayloadSecurity

We can confirm copyto/copyfrom issues as well.

comment:15 Changed 22 months ago by danielgindi

Yes, this is a real PITA.

comment:16 Changed 21 months ago by LionFat

5.0.14 r105127 -- copyto does not work

this command do nothing:

VBoxManage guestcontrol "IE11 - Win10" copyto C:\Users\user\gc.txt --target-directory C:\Users\IEUser\Downloads --username IEUser --password Passw0rd!

C:\Users\user\gc.txt - just a small txt file on the host OS C:\Users\IEUser\Downloads - destination on the guest OS

OVA setup guest OS image was taken from modern.ie

comment:17 Changed 20 months ago by samuel3

5.0.16 doesn't work)))) Are you guys going to do anything with that?..

comment:18 Changed 20 months ago by pentagonik

Thanks for noticing (again). We'll have a look at this shortly.

comment:19 Changed 20 months ago by pentagonik

  • Owner set to pentagonik
  • Status changed from new to assigned

comment:20 Changed 20 months ago by pentagonik

Found and fixed the issue. The bugfix will be available in the next upcoming maintenance version.

comment:21 Changed 20 months ago by pentagonik

  • Status changed from assigned to closed
  • Resolution set to fixed

comment:22 Changed 20 months ago by xpavlice

  • Status changed from closed to reopened
  • Resolution fixed deleted

This bug is still not fixed. I upgrade to 5.0.18r106667

host: Ubuntu 14.04.1 (4.2.0-27-generic)

guest: windows7x64

command: vboxmanage guestcontrol "clone2" --username Administrator --password PassW0rd copyto /home/xpavlice/WinShare/ISO/ubuntu-15.10-desktop-amd64.iso --target-directory "C:/temp"

response: VBoxManage: error: File copy failed

VBoxManage: error: Copying file "/home/xpavlice/WinShare/ISO/ubuntu-15.10-desktop-amd64.iso" failed (131072/1178386432 bytes transfered)

VBoxManage: error: Details: code VBOX_E_IPRT_ERROR (0x80bb0005), component GuestSessionWrap, interface IGuestSession

VBoxManage: error: Context: "int gctlCopyFileToDest(PCOPYCONTEXT, const char*, const char*, gctlCopyFlags)" at line 2164 of file VBoxManageGuestCtrl.cpp

VBoxManage: error: Copying file "/home/xpavlice/WinShare/ISO/ubuntu-15.10-desktop-amd64.iso" failed (131072/1178386432 bytes transfered).

VBoxManage: error: Error processing "/home/xpavlice/WinShare/ISO/ubuntu-15.10-desktop-amd64.iso", rc=VERR_GENERAL_FAILURE SO/ubuntu-15.10-desktop-amd64.iso --target-directory "C:/temp"

comment:23 Changed 20 months ago by pentagonik

Which Guest Additions are installed? Please attach the VBox.log file. Thanks.

Changed 20 months ago by kjonca

comment:24 Changed 20 months ago by kjonca

VBoxManage guestcontrol lit copyto --verbose --username kjonca --password Virtualbox1 --target-directory "C:/Users/kjonca/" ~/test.txt
Creating guest session as user 'kjonca'...
Waiting for guest session to start...
Successfully started guest session (ID 1)
Copying from host to guest ...
Directory "C:/Users/kjonca/" already exists
Source: /home/kjonca/test.txt
Copying "/home/kjonca/test.txt" to "C:/Users/kjonca/" ...
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...
Progress state: VBOX_E_IPRT_ERROR
VBoxManage: error: Copying file "/home/kjonca/test.txt" failed with status 500, exit code 1.
VBoxManage: error: Error processing "/home/kjonca/test.txt", rc=VERR_GENERAL_FAILURE

vbox.log attached

Last edited 20 months ago by kjonca (previous) (diff)

Changed 20 months ago by xpavlice

Guest_W7x64-host_Ubuntu14

comment:25 Changed 20 months ago by pentagonik

Thanks for the new report. Another fix will be in the next upcoming maintenance release.

comment:26 Changed 20 months ago by frank

The latest 5.0 test builds contain the fixes which will be part of the next maintenance release. Could you re-test?

comment:27 Changed 20 months ago by frank

  • Status changed from reopened to closed
  • Resolution set to fixed

Fixed in 5.0.20.

comment:28 Changed 19 months ago by kjonca

In my case is partially fixed (copyto)

VBoxManage guestcontrol lit copyto --verbose --username kjonca --password Virtualbox1 --target-directory "C:/Users/kjonca/" ~/test.txt    
Creating guest session as user 'kjonca'...
Waiting for guest session to start...
Successfully started guest session (ID 1)
Copying from host to guest ...
Directory "C:/Users/kjonca/" already exists
Source: /home/kjonca/test.txt
Copying "/home/kjonca/test.txt" to "C:/Users/kjonca/" ...
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%

but

VBoxManage guestcontrol lit copyto --verbose --username kjonca --password Virtualbox1 test.txt 'c:/xxx.bat' 
Oracle VM VirtualBox Command Line Management Interface Version 5.0.20_Debian
(C) 2005-2016 Oracle Corporation
All rights reserved.

Usage:

VBoxManage guestcontrol     <uuid|vmname> [--verbose|-v] [--quiet|-q]
                              [--username <name>] [--domain <domain>]
                              [--passwordfile <file> | --password <password>]
                              copyto [common-options]
                              [--dryrun] [--follow] [-R|--recursive]
                              <host-src0> [host-src1 [...]] <guest-dst>

                              copyto [common-options]
                              [--dryrun] [--follow] [-R|--recursive]
                              [--target-directory <guest-dst>]
                              <host-src0> [host-src1 [...]]


Syntax error: No destination specified!

I tried to specify destination multiple different ways

comment:29 Changed 16 months ago by klockren

  • Status changed from closed to reopened
  • Resolution fixed deleted

In the VirtualBox 5.1 branch, copyto does not work again.

Tested with 5.1.2 and 5.1.4 with both Ubuntu Linux and Windows Server 2008R2 as guests.

Creating guest session as user 'administrator'...
Waiting for guest session to start...
Successfully started guest session (ID 1)
Copying from host to guest ...
Directory "c:/temp" already exists
Source: /tmp/test.txt
Copying "/tmp/test.txt" to "c:/temp/test.txt" ...
0%...
Progress state: VBOX_E_IPRT_ERROR
VBoxManage: error: VERR_GENERAL_FAILURE.
VBoxManage: error: Error processing "/tmp/test.txt", rc=VERR_GENERAL_FAILURE

comment:30 Changed 16 months ago by kjonca

to be honest:

VBoxManage guestcontrol lit copyto --verbose --username kjonca --password yyyy test.txt --target-directory "C:/tmp/xxxx.txt"

Works as expected (but "target-directory" is misleading :) )

Last edited 16 months ago by kjonca (previous) (diff)

comment:31 Changed 9 months ago by kjonca

Again with 5.1.8 copyto does not work :(

Last edited 9 months ago by kjonca (previous) (diff)

comment:32 Changed 9 months ago by haimn

I can confirm it's not working again on 5.1.8. I reverted back to 5.0.30 and it's working fine there.

comment:33 Changed 5 weeks ago by kjonca

With 5.2.0 version stiill docopyto does not work.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use