统信UOS上启用或禁用蓝牙

252 篇文章 3 订阅
252 篇文章 4 订阅

原文链接:统信UOS上启用或禁用蓝牙

hello,大家好啊,今天给大家带来一篇关于在统信UOS上启用/禁用蓝牙的文章,通过systemctl关闭蓝牙服务以及rfkill工具禁用蓝牙的方法实现,接下来一起看看吧。

1、查看系统信息

uos@uos-PC:~/Desktop$ uname -a
Linux uos-PC 4.19.0-arm64-desktop #6030 SMP Tue Jun 27 15:28:10 CST 2023 aarch64 GNU/Linux
uos@uos-PC:~/Desktop$ cat /etc/os-version 
[Version] 
SystemName=UOS Desktop
SystemName[zh_CN]=统信桌面操作系统
ProductType=Desktop
ProductType[zh_CN]=桌面
EditionName=Professional
EditionName[zh_CN]=专业版
MajorVersion=20
MinorVersion=1060
OsBuild=11014.100.100

image-20230711093741116

2、查看蓝牙状态

image-20230711093825226

3、停止蓝牙服务并禁用开机自启

uos@uos-PC:~/Desktop$ sudo systemctl stop bluetooth.service 
请输入密码:
验证成功
uos@uos-PC:~/Desktop$ sudo systemctl disable bluetooth.service 
Synchronizing state of bluetooth.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install disable bluetooth
insserv: warning: current start runlevel(s) (empty) of script `bluetooth' overrides LSB defaults (2 3 4 5).
insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script `bluetooth' overrides LSB defaults (0 1 6).
Removed /etc/systemd/system/dbus-org.bluez.service.
Removed /etc/systemd/system/bluetooth.target.wants/bluetooth.service.
uos@uos-PC:~/Desktop$ 

image-20230711093921834

4、查看蓝牙信息已经不存在

image-20230711093858547

5、启用蓝牙服务并设置开机自启

uos@uos-PC:~/Desktop$ sudo systemctl enable bluetooth.service 
Synchronizing state of bluetooth.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable bluetooth
insserv: warning: current start runlevel(s) (empty) of script `bluetooth' overrides LSB defaults (2 3 4 5).
insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script `bluetooth' overrides LSB defaults (0 1 6).
Created symlink /etc/systemd/system/dbus-org.bluez.service → /lib/systemd/system/bluetooth.service.
Created symlink /etc/systemd/system/bluetooth.target.wants/bluetooth.service → /lib/systemd/system/bluetooth.service.
uos@uos-PC:~/Desktop$ sudo systemctl start bluetooth.service 
uos@uos-PC:~/Desktop$ 

image-20230711094040462

6、蓝牙服务正常

image-20230711094005489

7、使用rfkill禁用蓝牙

rfkill是一个可以启用和禁用Linux内核中无线设备(包括Wi-Fi、蓝牙等)的工具,这是一个临时的方法,如果需要长久禁用,可以搭配由硬件开关或BIOS设置控制。

uos@uos-PC:~/Desktop$ rfkill list 
1: hci0: Bluetooth
        Soft blocked: no
        Hard blocked: no
uos@uos-PC:~/Desktop$ sudo rfkill block 1
uos@uos-PC:~/Desktop$

image-20230711094158056

8、蓝牙信息置灰无法点击开启

image-20230711094625030

9、取消禁用蓝牙

uos@uos-PC:~/Desktop$ sudo rfkill unblock 0
uos@uos-PC:~/Desktop$ rfkill list 
0: hci0: Bluetooth
        Soft blocked: no
        Hard blocked: no
uos@uos-PC:~/Desktop$ 

image-20230711094656629

10、蓝牙信息正常,可以点击开启

image-20230711094719777

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 4
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

鹏大圣运维

编写不易,还请支持

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值