Bug 5776 - AMDeviceTransferApplication returned: 0x0 (kAMDSuccess).
Summary: AMDeviceTransferApplication returned: 0x0 (kAMDSuccess).
Status: RESOLVED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: Tools ()
Version: 5.3.x
Hardware: PC Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-06-20 09:42 UTC by Sebastien Pouliot
Modified: 2012-08-27 21:29 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Sebastien Pouliot 2012-06-20 09:42:09 UTC
/Developer/MonoTouch/usr/bin/mtouch -sdkroot
"/Applications/Xcode.app/Contents/Developer" -installdev
"/Users/joe/Projects/Mono/ACR/SalesTALK/SalesTALK/SalesTALK/bin/iPhone/Debug/ACRSalesTALK.app"
Please ensure your device is connected...
Connected to: Joseph’s iPhone 4S
Initializing file service...
Installation failed: AMDeviceStartService returned: 0x0 (kAMDSuccess)
error MT1006: Could not install the application
'/Users/joe/Projects/Mono/ACR/SalesTALK/SalesTALK/SalesTALK/bin/iPhone/Debug/ACRSalesTALK.app'
on the device '': AMDeviceStartService returned: 0x0 (kAMDSuccess).
The application was terminated by a signal: SIGHUP

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

If I unplug iPad3 and plug it back in, it uploads straight away ("Run" =>
"Upload to Device").  If I try to do it again straight away, I get this:-

/Developer/MonoTouch/usr/bin/mtouch -sdkroot
"/Applications/Xcode.app/Contents/Developer" -installdev
"/Users/joe/Projects/Mono/ACR/SalesTALK/SalesTALK/SalesTALK/bin/iPhone/Debug/ACRSalesTALK.app"
Please ensure your device is connected...
Connected to: Joseph’s iPad 3
Initializing file service...
Uploading application
Finalizing file service...
Installation failed: AMDeviceTransferApplication returned: 0x0 (kAMDSuccess)
error MT1006: Could not install the application
'/Users/joe/Projects/Mono/ACR/SalesTALK/SalesTALK/SalesTALK/bin/iPhone/Debug/ACRSalesTALK.app'
on the device '': AMDeviceTransferApplication returned: 0x0 (kAMDSuccess).
The application was terminated by a signal: SIGHUP

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

If I unplug it and plug it straight back in, it works fine. Looks like I only
get one go before having to unplug it and plug it back in again.
Comment 1 Sebastien Pouliot 2012-06-20 11:08:38 UTC
This happens in the new (faster) install code but I'm not able to reproduce it. Is it random or do you have some steps that always ends up like this ?

Now in some case the error code is not propagated properly (fixed in master) and some other fixes were made after the 5.3.4 release. So this may be the reason I can't duplicate it.

If this occurs again you can create a 'old-install-mode' (empty) file inside your MonoTouch directory, by default /Developer/MonoTouch , to switch back to the older (and slower) installation code. The file can be later removed when 5.3.5+ is installed.

E.g.

    echo x > /Developer/MonoTouch/old-install-mode
Comment 2 Joseph Hanna 2012-06-20 18:27:46 UTC
I get permission denied, even when using "sudo".
Comment 3 Sebastien Pouliot 2012-06-20 21:25:03 UTC
sudo should work. what does the three following command returns ?

$ ls -ld /Developer/MonoTouch

$ whoami

$ sudo whoami
Comment 4 Greg Munn 2012-07-21 08:43:10 UTC
I have started getting this issue regularly (MT 5.3.4) and adding the old-install-mode file has made an immediate difference - I can now upload to the device.

Greg
Comment 5 Sebastien Pouliot 2012-08-27 21:29:29 UTC
The code for 5.3.6 is quite different (more sharing between the old and new deployment code) so you won't see the 0x0 (kAMDSuccess) anymore. You should also try to remove the `/Developer/MonoTouch/old-install-mode` file to make sure things are fixed* and to get the much faster deployment to devices.

* if not please open a new bug report including the specific error code