Giter VIP home page Giter VIP logo

Comments (9)

danielpaulus avatar danielpaulus commented on May 21, 2024

Hey there, please run it with the -v option and post logs

from go-ios.

tzcurtain avatar tzcurtain commented on May 21, 2024
./ios --udid d950b7ba58dd8aba00eff574fd62a30ae8a8af43 launch -v com.apple.Preferences
{"level":"info","msg":"Set Debug mode","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"map[--basedir:\u003cnil\u003e --binary:false --bundleid:\u003cnil\u003e --details:false --help:false --nojson:false --output:\u003cnil\u003e --path:\u003cnil\u003e --pid:\u003cnil\u003e --process:\u003cnil\u003e --setlang:\u003cnil\u003e --setlocale:\u003cnil\u003e --stop-at-entry:false --system:false --testrunnerbundleid:\u003cnil\u003e --trace:false --udid:d950b7ba58dd8aba00eff574fd62a30ae8a8af43 --verbose:true --version:false --xctestconfig:\u003cnil\u003e \u003capp_path\u003e:\u003cnil\u003e \u003cbundleID\u003e:com.apple.Preferences \u003chostPort\u003e:\u003cnil\u003e \u003cprofileId\u003e:\u003cnil\u003e \u003cprofileTypeId\u003e:\u003cnil\u003e \u003ctargetPort\u003e:\u003cnil\u003e apps:false auto:false ax:false date:false debug:false devicename:false devicestate:false diagnostics:false dproxy:false enable:false forward:false image:false info:false install:false kill:false lang:false launch:true list:false listen:false mount:false pair:false pcap:false ps:false readpair:false reboot:false runtest:false runwda:false screenshot:false syslog:false version:false]","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Looking for device 'd950b7ba58dd8aba00eff574fd62a30ae8a8af43'","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Opening connection:0xc0002d1e00","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.ReadDevicesType on 0xc0000a8830","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc0000a8878","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Opening connection:0xc0002eea50","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.ReadPair on 0xc000306098","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc0003060e0","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.connectMessage on 0xc000306098","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc000306830","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Lockdown sendios.startSessionRequest","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"enable session ssl on0xc0003081c0 and wrap with tlsConn0xc0002c8f20","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Lockdown sendios.startServiceRequest","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Lockdown sendios.stopSessionRequest","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Closing connection:0xc0003081c0","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Failed connecting to com.apple.instruments.remoteserver, trying com.apple.instruments.remoteserver.DVTSecureSocketProxy","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Opening connection:0xc0002ef7e0","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.ReadPair on 0xc000307370","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc0003073a0","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.connectMessage on 0xc000307370","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc00000e710","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Lockdown sendios.startSessionRequest","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"enable session ssl on0xc000309880 and wrap with tlsConn0xc000010010","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Lockdown sendios.startServiceRequest","time":"2021-08-21T03:20:45-04:00"}
{"EnableServiceSSL":true,"Port":52753,"Request":"StartService","Service":"com.apple.instruments.remoteserver.DVTSecureSocketProxy","level":"debug","msg":"Service started on device","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Lockdown sendios.stopSessionRequest","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Closing connection:0xc000309880","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Opening connection:0xc00005a9c0","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.ReadPair on 0xc00000f208","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc00000f238","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"Opening connection:0xc0002ee0d0","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux sendios.connectMessage on 0xc000306740","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"UsbMux Receive on 0xc000306770","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"enable session ssl on0xc000308720 and wrap with tlsConn0xc0002c8008","time":"2021-08-21T03:20:45-04:00"}
{"channel_id":"com.apple.instruments.server.services.processcontrol","level":"debug","msg":"Requesting channel","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"DTX Connection with EOF","time":"2021-08-21T03:20:45-04:00"}
{"level":"debug","msg":"i0.0 c0 t:Ack mlen:0 aux_len0 paylen0","time":"2021-08-21T03:20:50-04:00"}
{"channel_id":"com.apple.instruments.server.services.processcontrol","error":"Timed out waiting for response for message:5 channel:0","level":"error","msg":"failed requesting channel","time":"2021-08-21T03:20:50-04:00"}
{"channel_id":"com.apple.instruments.server.services.processcontrol","level":"debug","msg":"Channel open","time":"2021-08-21T03:20:50-04:00"}
{"bundleID":"com.apple.Preferences","channel_id":"com.apple.instruments.server.services.processcontrol","level":"info","msg":"Launching process","time":"2021-08-21T03:20:50-04:00"}
{"level":"error","msg":"DeviceConnection failed writing 1383 bytes, only 0 sent","time":"2021-08-21T03:20:50-04:00"}
{"level":"error","msg":"Failed sending: write unix @-\u003e/var/run/usbmuxd: write: broken pipe","time":"2021-08-21T03:20:50-04:00"}
{"level":"debug","msg":"Closing connection:0xc000308720","time":"2021-08-21T03:20:50-04:00"}
{"channel_id":"com.apple.instruments.server.services.processcontrol","error":"write unix @-\u003e/var/run/usbmuxd: write: broken pipe","level":"info","methodselector":"launchSuspendedProcessWithDevicePath:bundleIdentifier:environment:arguments:options:","msg":"failed starting invoking method","time":"2021-08-21T03:20:50-04:00"}
panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/danielpaulus/go-ios/ios/instruments.ProcessControl.StartProcess(0xc000532840, 0xc000620040, 0x7ffc614c875e, 0x15, 0xc000528bd0, 0xb8d588, 0x0, 0x0, 0xc000528ba0, 0x0, ...)
        /home/runner/work/go-ios/go-ios/ios/instruments/processcontrol.go:65 +0x9f1
github.com/danielpaulus/go-ios/ios/instruments.(*ProcessControl).LaunchApp(0xc00051a910, 0x7ffc614c875e, 0x15, 0x0, 0xc0002d3b70, 0x3)
        /home/runner/work/go-ios/go-ios/ios/instruments/processcontrol.go:23 +0xe5
main.Main()
        /home/runner/work/go-ios/go-ios/main.go:335 +0x267d
main.main()
        /home/runner/work/go-ios/go-ios/main.go:41 +0x25

from go-ios.

danielpaulus avatar danielpaulus commented on May 21, 2024

Can you maybe:

  • stop Xcode and all other Mac tools using iOS devices
  • run ./ios dproxy in a separate window
  • then try to launch the app again
  • zip the dproxy "dump" directory and upload it?

from go-ios.

tzcurtain avatar tzcurtain commented on May 21, 2024

dump-2021.08.25-09.27.45.229.zip

from go-ios.

tzcurtain avatar tzcurtain commented on May 21, 2024

btw i has to use sudo to run dproxy and launch, or terminal will say

INFO[0000] Successfully retrieved pairrecord: 20265234-378D-41F5-8277-EBA43D14980A for device d950b7ba58dd8aba00eff574fd62a30ae8a8af43 
INFO[0000] Moving socket /var/run/usbmuxd to /var/run/usbmuxd.96e1a21f-9373-46be-bf50-616fdc406f74.real_socket 
ERRO[0000] Unable to move, lacking permissions?          error="rename /var/run/usbmuxd /var/run/usbmuxd.96e1a21f-9373-46be-bf50-616fdc406f74.real_socket: permission denied" socket=/var/run/usbmuxd
INFO[0000] DebugProxy Terminated abnormally              error="rename /var/run/usbmuxd /var/run/usbmuxd.96e1a21f-9373-46be-bf50-616fdc406f74.real_socket: permission denied" 

hope it dosen't matter,
and this phone i'm using now is iphone8 with ios14.0.1 running on macos 10.15.7

from go-ios.

danielpaulus avatar danielpaulus commented on May 21, 2024

yeah you can also temporarily chmod /var/run so your user has access. I should add that to the error message

from go-ios.

danielpaulus avatar danielpaulus commented on May 21, 2024

Is your cable broken or something? :-D

from go-ios.

vdelendik avatar vdelendik commented on May 21, 2024

I was able to repro the issue using ios ps as part of healthcheck script. It works in the beginning but in 5-10 minutes couldn't send messages due to the broken pipe. Moreover, other commands might work correctly.
Among problematic based on mine observation: launch/kill app and ps. As a workaroung going to organize retries on my end with pause in between retries.

from go-ios.

briankrznarich avatar briankrznarich commented on May 21, 2024

My current estimation is that this occurs when the device itself is, to use a technical term, "borked". (Perhaps some phone-internal service has crashed/hung).

I have this occurring on an iPhone 8 running 15.0.1. Host is Ubuntu LTS, so this isn't an Xcode interaction. 20 other devices are connected concurrently on the same machine, and are stable and respond to go-ios commands, so it's not inherently usbmuxd related (unless usbmuxd can leak per-device resources?). tidevice commands for "ps" and "launch" also fail on this device, so it's not go-ios implementation specific.

Device started off working and launching processes, and communication continues to the device over existing go-ios tunnels in spite of the inability to launch new processes via go-ios. Appear to be able to launch new tunnels, and other functionality works. Agreeing with comments above, impacted commands are minimally "ps", "kill", and "launch", leaving me to suspect that a reboot is probably the only recourse for recovery.

from go-ios.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.