aarch64_Ubuntu (Linux)连不上adb解决方法

1、已经安装了adb tools

sudo apt install -y android-tools-adb android-tools-fastboot

bash 复制代码
root@ubuntu://# sudo adb kill-server
root@ubuntu://# adb start-server
error: device offline
root@ubuntu://# adb devices -l
List of devices attached
error: device offline
root@ubuntu://# sudo adb kill-server && adb start-server
error: device offline
root@ubuntu://# adb devices -l
List of devices attached
error: device offline

这种情况也不是udev规则的问题也不是驱动问题。

2、验证 USB 链路

手机连arm ubuntu主机,开启开发者模式

bash 复制代码
root@ubuntu://# lsusb
Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 005 Device 002: ID 18d1:4e11 Google Inc. Nexus One
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 003: ID 046d:c542 Logitech, Inc.
Bus 001 Device 002: ID 1a40:0101 Terminus Technology Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 004: ID 2207:1005 Fuzhou Rockchip Electronics Company rk3xxx
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@ubuntu://#

lsusb查到的检测到了手机 Bus 005 Device 002: ID 18d1:4e11 Google Inc. Nexus One

说明usb线没问题,adb调试也开启的,主机也识到了,物理层面没任何问题,那么就是软件的问题。

3、查看USB 设备详细信息

bash 复制代码
root@ubuntu://# lsusb -v -s 005:002

Bus 005 Device 002: ID 18d1:4e11 Google Inc. Nexus One
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.10
  bDeviceClass            0
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0        64
  idVendor           0x18d1 Google Inc.
  idProduct          0x4e11 Nexus One
  bcdDevice            5.15
  iManufacturer           1 Xiaomi
  iProduct                2 Xiaomi 13
  iSerial                 3 a26a26b9
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength       0x0020
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          4 mtp
    bmAttributes         0x80
      (Bus Powered)
    MaxPower              500mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     66
      bInterfaceProtocol      1
      iInterface              5 ADB Interface
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
Binary Object Store Descriptor:
  bLength                 5
  bDescriptorType        15
  wTotalLength       0x002a
  bNumDeviceCaps          3
  USB 2.0 Extension Device Capability:
    bLength                 7
    bDescriptorType        16
    bDevCapabilityType      2
    bmAttributes   0x0000211e
      BESL Link Power Management (LPM) Supported
    BESL value      256 us
    Deep BESL value     8192 us
  SuperSpeed USB Device Capability:
    bLength                10
    bDescriptorType        16
    bDevCapabilityType      3
    bmAttributes         0x00
    wSpeedsSupported   0x000f
      Device can operate at Low Speed (1Mbps)
      Device can operate at Full Speed (12Mbps)
      Device can operate at High Speed (480Mbps)
      Device can operate at SuperSpeed (5Gbps)
    bFunctionalitySupport   1
      Lowest fully-functional device speed is Full Speed (12Mbps)
    bU1DevExitLat           0 micro seconds
    bU2DevExitLat           0 micro seconds
  SuperSpeedPlus USB Device Capability:
    bLength                20
    bDescriptorType        16
    bDevCapabilityType     10
    bmAttributes         0x00000001
      Sublink Speed Attribute count 1
      Sublink Speed ID count 0
    wFunctionalitySupport   0x1100
    bmSublinkSpeedAttr[0]   0x000a4030
      Speed Attribute ID: 0 10Gb/s Symmetric RX SuperSpeedPlus
    bmSublinkSpeedAttr[1]   0x000a40b0
      Speed Attribute ID: 0 10Gb/s Symmetric TX SuperSpeedPlus
can't get debug descriptor: Resource temporarily unavailable
Device Status:     0x0000
  (Bus Powered)
root@ubuntu://#

lsusb -v -s 005:002

输出的信息表明硬件层面完全识别到安卓设备xiaomi 13,且ADB 接口正常注册,现在error: device offline是纯软件层面的授权 / ADB 通信问题;和硬件、驱动、USB 线 / 接口完全无关。

4、kill掉ADB进程 sudo pkill -9 adb

删除root和用户的ADB密钥目录 sudo rm -rf /root/.android /home/wang/.android

检查一下是否删除 ls /root/.android 2>/dev/null || echo "已删除"

5、以root权限启动ADB服务 sudo adb start-server

手机端点击信任设备就可以了。

bash 复制代码
root@ubuntu://# adb shell
fuxi:/ $ getprop ro.product.model
2211133C
fuxi:/ $ getprop ro.build.version.release
16
fuxi:/ $ uname -a
Linux localhost 5.15.178-android13-8-00021-g6f2f96be86b9-ab13729987 #1 SMP PREEMPT Wed Jul 2 02:41:59 UTC 2025 aarch64 Toybox
fuxi:/ $
相关推荐
Coder个人博客1 天前
Linux6.19-ARM64 mm mmu子模块深入分析
大数据·linux·车载系统·系统架构·系统安全·鸿蒙系统
Doro再努力1 天前
Vim 快速上手实操手册:从入门到生产环境实战
linux·编辑器·vim
wypywyp1 天前
8. ubuntu 虚拟机 linux 服务器 TCP/IP 概念辨析
linux·服务器·ubuntu
阿蒙Amon1 天前
TypeScript学习-第10章:模块与命名空间
学习·ubuntu·typescript
Doro再努力1 天前
【Linux操作系统10】Makefile深度解析:从依赖推导到有效编译
android·linux·运维·服务器·编辑器·vim
senijusene1 天前
Linux软件编程:IO编程,标准IO(1)
linux·运维·服务器
忧郁的橙子.1 天前
02-本地部署Ollama、Python
linux·运维·服务器
醇氧1 天前
【linux】查看发行版信息
linux·运维·服务器
No8g攻城狮1 天前
【Linux】Windows11 安装 WSL2 并运行 Ubuntu 22.04 详细操作步骤
linux·运维·ubuntu
XiaoFan0121 天前
免密批量抓取日志并集中输出
java·linux·服务器