Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Deployment] failed to run compiled magefile: signal: killed. #2636

Closed
lxxsoap opened this issue Sep 20, 2024 · 7 comments
Closed

[Deployment] failed to run compiled magefile: signal: killed. #2636

lxxsoap opened this issue Sep 20, 2024 · 7 comments

Comments

@lxxsoap
Copy link

lxxsoap commented Sep 20, 2024

OpenIM Server Version

3.8.0

Operating System and CPU Architecture

macOS (ARM)

Deployment Method

Source Code Deployment

Issue Description and Steps to Reproduce

mage start
error message: failed to run compiled magefile: signal: killed.

Analysis of the Crash Log
This is a crash report for a macOS application. Here are the main findings and analysis:

Crash Time and Environment:

Occurrence: September 20, 2024, 10:16:41
Operating System: macOS 15.0 (24A335)
Hardware Model: MacBookPro18,3

Crashed Application:

Process Name: 4b321c6aefc97053b5d0457049f070e4b6b70e66
Parent Process: mage
Responsible Process: goland (suggesting it might be a program run within the GoLand IDE)

Crash Type:

Exception Type: EXC_BAD_ACCESS (SIGKILL (Code Signature Invalid))
Termination Reason: CODESIGNING 2 Invalid Page

Crashed Thread:

Thread 0 crashed, involving operations in dyld (dynamic linker)

Key Issues:

Invalid Code Signature: The report shows "Code Signature Invalid" and "CODESIGNING 2 Invalid Page", indicating issues with the program's code signature.
Memory Access Error: EXC_BAD_ACCESS suggests the program attempted to access a memory address it wasn't allowed to.

Crash Stack:

The crash occurred within internal functions of dyld, specifically while processing load commands of a Mach-O file (macOS executable format).

Possible Causes:

Code Signing Issue: The program's code signature might be invalid or corrupted.
Dynamic Linker Problem: dyld encountered issues while loading or validating the program.
Potential Security Measure: The system may have forcibly terminated the program due to detected code signing issues.

Suggested Resolution Steps:

Check and re-sign the application.
Ensure all dependent libraries are correctly signed and compatible with the current macOS version.
If this is a development application, review compilation and linking settings to ensure compatibility with the target macOS version.

Screenshots Link

image
image

@OpenIM-Robot
Copy link

Hello! Thank you for filing an issue.

If this is a bug report, please include relevant logs to help us debug the problem.

Join slack 🤖 to connect and communicate with our developers.

@FGadvancer
Copy link
Member

You should execute bootstrap.sh to ensure that mage is installed correctly.

@lcztt
Copy link

lcztt commented Sep 26, 2024

已经执行了 bootstrap.sh 脚本,也遇到类似问题。

macOS 15 (ARM)

@OpenIM-Robot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


I have executed the bootstrap.sh script and encountered similar problems.

macOS 15 (ARM)

@skiffer-git
Copy link
Member

Could you provide a complete description of the entire process?

@lxxsoap
Copy link
Author

lxxsoap commented Sep 27, 2024

Operating System: macOS 15.0 (24A335)

step1: clone from the github
step2: execute bootstrap.sh
step3: execute mage
then errorMsg: failed to run compiled magefile: signal: killed
image
Meanwhile I go to check the crash report,here is the details:


Translated Report (Full Report Below)

Incident Identifier: 8084A33B-5197-4364-AC29-26F4E36ED4F0
CrashReporter Key: 45622615-04B6-DA48-5A2D-60885AEF312D
Hardware Model: MacBookPro18,3
Process: 4b321c6aefc97053b5d0457049f070e4b6b70e66 [72441]
Path: /Users/USER/*/4b321c6aefc97053b5d0457049f070e4b6b70e66
Identifier: 4b321c6aefc97053b5d0457049f070e4b6b70e66
Version: ???
Code Type: ARM-64 (Native)
Role: Unspecified
Parent Process: Exited process [72419]
Coalition: com.todesktop.230313mzl4w4u92 [24923]
Responsible Process: Cursor [6950]

Date/Time: 2024-09-27 20:17:18.0619 +0800
Launch Time: 2024-09-27 20:17:18.0609 +0800
OS Version: macOS 15.0 (24A335)
Release Type: User
Report Version: 104

Exception Type: EXC_BAD_ACCESS (SIGKILL (Code Signature Invalid))
Exception Subtype: UNKNOWN_0x32 at 0x0000000104cfc000
Exception Codes: 0x0000000000000032, 0x0000000104cfc000
VM Region Info: 0x104cfc000 is in 0x104cfc000-0x104edc000; bytes after start: 0 bytes before end: 1966079
REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL
UNUSED SPACE AT START
---> __TEXT 104cfc000-104edc000 [ 1920K] r-x/r-x SM=COW /main_executable_path_missing
__DATA_CONST 104edc000-105030000 [ 1360K] rw-/rw- SM=COW /main_executable_path_missing
Termination Reason: CODESIGNING 2 Invalid Page

Triggered by Thread: 0

Thread 0 Crashed:
0 dyld_path_missing 0x1051421e4 dyld3::MachOFile::forEachLoadCommand(Diagnostics&, void (load_command const*, bool&) block_pointer) const + 52
1 dyld_path_missing 0x10514426c dyld3::MachOFile::forEachSupportedPlatform(void (dyld3::Platform, unsigned int, unsigned int) block_pointer) const + 160
2 dyld_path_missing 0x10518e6fc dyld3::MachOFile::isBuiltForSimulator() const + 124
3 dyld_path_missing 0x105145e3c start + 1760

Thread 0 crashed with ARM Thread State (64-bit):
x0: 0x0000000104cfc000 x1: 0x000000016b1035d8 x2: 0x000000016b103580 x3: 0x0000000105141e23
x4: 0x0000000000000001 x5: 0x0000000000000073 x6: 0x0000000000000000 x7: 0x0000000000000e60
x8: 0x000000016b1035b8 x9: 0x00000001051c7458 x10: 0x00000001051b1000 x11: 0x00000001051bea56
x12: 0x0000000000000065 x13: 0x0000000000000073 x14: 0x000000000004bca0 x15: 0x0000000000000000
x16: 0x000000010514430c x17: 0x6ae100016b103580 x18: 0x0000000000000000 x19: 0x000000016b1035d8
x20: 0x0000000104cfc000 x21: 0x000000016b103580 x22: 0x000000016b1038c0 x23: 0x0000000000000000
x24: 0x0000000000000000 x25: 0x0000000000000000 x26: 0x0000000000000000 x27: 0x0000000000000000
x28: 0x0000000000000000 fp: 0x000000016b103570 lr: 0x000000010514426c
sp: 0x000000016b1034e0 pc: 0x00000001051421e4 cpsr: 0x80001000
far: 0x0000000104cfc000 esr: 0x92000007 (Data Abort) byte read Translation fault

Binary Images:
0x105140000 - 0x1051c3fff dyld_path_missing () <02e3ca05-e849-31c8-a4f2-c7292420dfad> /dyld_path_missing
0x104cfc000 - 0x104edbfff main_executable_path_missing (
) <9ac33179-6377-32ef-a049-342b1f24390d> /main_executable_path_missing
0x0 - 0xffffffffffffffff ??? (*) <00000000-0000-0000-0000-000000000000> ???

Error Formulating Crash Report:
dyld_process_snapshot_get_shared_cache failed

EOF


Full Report

{"app_name":"4b321c6aefc97053b5d0457049f070e4b6b70e66","timestamp":"2024-09-27 20:17:18.00 +0800","app_version":"","slice_uuid":"9ac33179-6377-32ef-a049-342b1f24390d","build_version":"","platform":0,"share_with_app_devs":1,"is_first_party":1,"bug_type":"309","os_version":"macOS 15.0 (24A335)","roots_installed":0,"incident_id":"8084A33B-5197-4364-AC29-26F4E36ED4F0","name":"4b321c6aefc97053b5d0457049f070e4b6b70e66"}
{
"uptime" : 610000,
"procRole" : "Unspecified",
"version" : 2,
"userID" : 0,
"deployVersion" : 210,
"modelCode" : "MacBookPro18,3",
"coalitionID" : 24923,
"osVersion" : {
"train" : "macOS 15.0",
"build" : "24A335",
"releaseType" : "User"
},
"captureTime" : "2024-09-27 20:17:18.0619 +0800",
"codeSigningMonitor" : 1,
"incident" : "8084A33B-5197-4364-AC29-26F4E36ED4F0",
"pid" : 72441,
"translated" : false,
"cpuType" : "ARM-64",
"roots_installed" : 0,
"bug_type" : "309",
"procLaunch" : "2024-09-27 20:17:18.0609 +0800",
"procStartAbsTime" : 14680600243834,
"procExitAbsTime" : 14680600261890,
"procName" : "4b321c6aefc97053b5d0457049f070e4b6b70e66",
"procPath" : "/Users/USER//4b321c6aefc97053b5d0457049f070e4b6b70e66",
"parentProc" : "Exited process",
"parentPid" : 72419,
"coalitionName" : "com.todesktop.230313mzl4w4u92",
"crashReporterKey" : "45622615-04B6-DA48-5A2D-60885AEF312D",
"responsiblePid" : 6950,
"responsibleProc" : "Cursor",
"codeSigningID" : "a.out",
"codeSigningTeamID" : "",
"codeSigningFlags" : 587334144,
"codeSigningValidationCategory" : 0,
"codeSigningTrustLevel" : 4294967295,
"instructionByteStream" : {"beforePC":"+mcFqfhfBqn2Vwep9E8Iqf17Can9QwKR9QMCqvMDAar0AwCq//8AOQ==","atPC":"CABAuelZn1Kp3b9yHwEJa+AAAFTJWZ9Sqd2/ch8BCWthAQBUiQOAUg=="},
"bootSessionUUID" : "C9AF7BD7-070F-4C9C-874E-81FEBDB4777B",
"wakeTime" : 452297,
"sleepWakeUUID" : "A333E808-A15E-42D5-BAE8-0B3D886677D1",
"sip" : "enabled",
"vmRegionInfo" : "0x104cfc000 is in 0x104cfc000-0x104edc000; bytes after start: 0 bytes before end: 1966079\n REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL\n UNUSED SPACE AT START\n---> __TEXT 104cfc000-104edc000 [ 1920K] r-x/r-x SM=COW /main_executable_path_missing\n __DATA_CONST 104edc000-105030000 [ 1360K] rw-/rw- SM=COW /main_executable_path_missing",
"exception" : {"codes":"0x0000000000000032, 0x0000000104cfc000","rawCodes":[50,4375691264],"type":"EXC_BAD_ACCESS","signal":"SIGKILL (Code Signature Invalid)","subtype":"UNKNOWN_0x32 at 0x0000000104cfc000"},
"termination" : {"flags":0,"code":2,"namespace":"CODESIGNING","indicator":"Invalid Page"},
"vmregioninfo" : "0x104cfc000 is in 0x104cfc000-0x104edc000; bytes after start: 0 bytes before end: 1966079\n REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL\n UNUSED SPACE AT START\n---> __TEXT 104cfc000-104edc000 [ 1920K] r-x/r-x SM=COW /main_executable_path_missing\n __DATA_CONST 104edc000-105030000 [ 1360K] rw-/rw- SM=COW /main_executable_path_missing",
"extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"warnings":0},
"faultingThread" : 0,
"threads" : [{"triggered":true,"id":6708124,"threadState":{"x":[{"value":4375691264},{"value":6091191768},{"value":6091191680},{"value":4380171811},{"value":1},{"value":115},{"value":0},{"value":3680},{"value":6091191736},{"value":4380718168,"symbolLocation":0,"symbol":"__block_descriptor_tmp.70"},{"value":4380626944,"symbolLocation":36,"symbol":"lsl::BTree<lsl::UniquePtrdyld4::Atlas::Image, std::__1::less<lsl::UniquePtrdyld4::Atlas::Image>, false>::NodeCore<31u, 15u>::merge(lsl::Allocator
, unsigned char) (.cold.1)"},{"value":4380682838},{"value":101},{"value":115},{"value":310432},{"value":0},{"value":4380181260,"symbolLocation":0,"symbol":"invocation function for block in dyld3::MachOFile::forEachSupportedPlatform(void (dyld3::Platform, unsigned int, unsigned int) block_pointer) const"},{"value":7701436843871450496},{"value":0},{"value":6091191768},{"value":4375691264},{"value":6091191680},{"value":6091192512},{"value":0},{"value":0},{"value":0},{"value":0},{"value":0},{"value":0}],"flavor":"ARM_THREAD_STATE64","lr":{"value":4380181100},"cpsr":{"value":2147487744},"fp":{"value":6091191664},"sp":{"value":6091191520},"esr":{"value":2449473543,"description":"(Data Abort) byte read Translation fault"},"pc":{"value":4380172772,"matchesCrashFrame":1},"far":{"value":4375691264}},"frames":[{"imageOffset":8676,"symbol":"dyld3::MachOFile::forEachLoadCommand(Diagnostics&, void (load_command const*, bool&) block_pointer) const","symbolLocation":52,"imageIndex":0},{"imageOffset":17004,"symbol":"dyld3::MachOFile::forEachSupportedPlatform(void (dyld3::Platform, unsigned int, unsigned int) block_pointer) const","symbolLocation":160,"imageIndex":0},{"imageOffset":321276,"symbol":"dyld3::MachOFile::isBuiltForSimulator() const","symbolLocation":124,"imageIndex":0},{"imageOffset":24124,"symbol":"start","symbolLocation":1760,"imageIndex":0}]}],
"usedImages" : [
{
"source" : "P",
"arch" : "arm64e",
"base" : 4380164096,
"size" : 540672,
"uuid" : "02e3ca05-e849-31c8-a4f2-c7292420dfad",
"path" : "/dyld_path_missing",
"name" : "dyld_path_missing"
},
{
"source" : "P",
"arch" : "arm64",
"base" : 4375691264,
"size" : 1966080,
"uuid" : "9ac33179-6377-32ef-a049-342b1f24390d",
"path" : "/main_executable_path_missing",
"name" : "main_executable_path_missing"
},
{
"size" : 0,
"source" : "A",
"base" : 0,
"uuid" : "00000000-0000-0000-0000-000000000000"
}
],
"vmSummary" : "ReadOnly portion of Libraries: Total=3072K resident=0K(0%) swapped_out_or_unallocated=3072K(100%)\nWritable regions: Total=8672K written=64K(1%) resident=64K(1%) swapped_out=0K(0%) unallocated=8608K(99%)\n\n VIRTUAL REGION \nREGION TYPE SIZE COUNT (non-coalesced) \n=========== ======= ======= \nSTACK GUARD 56.0M 1 \nStack 8176K 1 \nVM_ALLOCATE 16K 1 \n__DATA 672K 3 \n__DATA_CONST 1392K 2 \n__DATA_DIRTY 16K 1 \n__LINKEDIT 624K 2 \n__TEXT 2448K 2 \n__TPRO_CONST 288K 1 \nmapped file 4.3G 13 \npage table in kernel 64K 1 \n=========== ======= ======= \nTOTAL 4.3G 28 \n",
"legacyInfo" : {
"threadTriggered" : {

}
},
"logWritingSignature" : "900c9589cf37bbec0896e2b99c99a872754920f4",
"trialInfo" : {
"rollouts" : [
{
"rolloutId" : "632c763c58740028737bfdd2",
"factorPackIds" : {
"SIRI_DIALOG_ASSETS" : "64a57d23fa6fd41b2353e2ae"
},
"deploymentId" : 240000034
},
{
"rolloutId" : "652eff3d1bce5442b8d753c9",
"factorPackIds" : {

  },
  "deploymentId" : 240000009
}

],
"experiments" : [
{
"treatmentId" : "c47ab4cc-c9c3-4b5d-a87c-e2433ce02597",
"experimentId" : "6639bc6ba73d460582162323",
"deploymentId" : 400000006
},
{
"treatmentId" : "45f4e2a5-551b-4bc2-a2dc-19c244dda8f8",
"experimentId" : "6643969b3099cf28e049862f",
"deploymentId" : 400000007
}
]
},
"reportNotes" : [
"dyld_process_snapshot_get_shared_cache failed"
]
}

@lcztt
Copy link

lcztt commented Sep 27, 2024

I updated Go to the latest version (1.23.1 for my M1 Mac) and now mage is working as expected.

I was previously using Go 1.22.1, and I recently upgraded my macOS to the latest version.

I'm not positive if updating my Mac caused the mage command to break, but it's working again now.

@lxxsoap lxxsoap closed this as completed Sep 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants