Unable to open log device '/dev/log/main': No such file or directory

本文介绍了一种解决GT-N7000设备升级至4.1.2版本后无法显示日志的问题的方法。通过修改特定文件中的删除日志设备指令,可以成功恢复日志显示功能。

GT-N7000升级到4.1.2 后无法显示日志,按照网上说的,如下:

http://liuzhichao.com/p/570.html

已经不能问题。后来发现


http://stackoverflow.com/questions/6941710/unable-to-open-log-device-dev-log-main-no-such-file-or-directory


  1. Open: /system/etc/init.d/××× (not the same file on different ROMs, find the right file)
  2. Find the line that says: rm /dev/log/main
  3. Change the line to: # rm /dev/log/main (comments out the line, rm = remove, in case you were wondering)
  4. Save and reboot
解决问题

10:57:51.766834 35747 main.go:300] Retrieving plugins. W1210 10:57:51.767289 35747 factory.go:47] No valid resources detected, creating a null CDI handler I1210 10:57:51.767375 35747 factory.go:123] Detected non-NVML platform: could not load NVML library: libnvidia-ml.so.1: cannot open shared object file: No such file or directory I1210 10:57:51.767442 35747 factory.go:123] Detected non-Tegra platform: /sys/devices/soc0/family file not found E1210 10:57:51.767463 35747 factory.go:131] Incompatible platform detected E1210 10:57:51.767476 35747 factory.go:132] If this is a GPU node, did you configure the NVIDIA Container Toolkit? E1210 10:57:51.767489 35747 factory.go:133] You can check the prerequisites at: https://github.com/NVIDIA/k8s-device-plugin#prerequisites E1210 10:57:51.767501 35747 factory.go:134] You can learn how to set the runtime at: https://github.com/NVIDIA/k8s-device-plugin#quick-start E1210 10:57:51.767514 35747 factory.go:135] If this is not a GPU node, you should set up a toleration or nodeSelector to only deploy this plugin on GPU nodes E1210 10:57:51.767623 35747 main.go:154] error starting plugins: error creating plugin manager: unable to create plugin manager: platform detection failed root@LAPTOP-21R5QEJ2:~# kubectl logs -n kube-system hami-device-plugin-5hlt9 -c vgpu-monitor I1210 10:58:33.830763 35948 flags.go:27] FLAG: --add_dir_header="false" I1210 10:58:33.830819 35948 flags.go:27] FLAG: --alsologtostderr="false" I1210 10:58:33.830822 35948 flags.go:27] FLAG: --log_backtrace_at=":0" I1210 10:58:33.830825 35948 flags.go:27] FLAG: --log_dir="" I1210 10:58:33.830827 35948 flags.go:27] FLAG: --log_file="" I1210 10:58:33.830829 35948 flags.go:27] FLAG: --log_file_max_size="1800" I1210 10:58:33.830831 35948 flags.go:27] FLAG: --logtostderr="true" I1210 10:58:33.830832 35948 flags.go:27] FLAG: --one_output="false" I1210 10:58:33.830834 35948 flags.go:27] FLAG: --skip_headers="false" I1210 10:58:33.830836 35948 flags.go:27] FLAG: --skip_log_headers="false" I1210 10:58:33.830837 35948 flags.go:27] FLAG: --stderrthreshold="2" I1210 10:58:33.830839 35948 flags.go:27] FLAG: --v="4" I1210 10:58:33.830841 35948 flags.go:27] FLAG: --vmodule="" I1210 10:58:33.830843 35948 flags.go:27] FLAG: --help="false" W1210 10:58:33.830873 35948 client_config.go:659] Neither --kubeconfig nor --master was specified. Using the inClusterConfig. This might not work. I1210 10:58:33.831531 35948 envvar.go:172] "Feature gate default state" feature="WatchListClient" enabled=false I1210 10:58:33.831547 35948 envvar.go:172] "Feature gate default state" feature="InformerResourceVersion" enabled=false I1210 10:58:33.831569 35948 reflector.go:305] Starting reflector *v1.Pod (5m0s) from pkg/mod/k8s.io/client-go@v0.31.10/tools/cache/reflector.go:243 I1210 10:58:33.831588 35948 reflector.go:341] Listing and watching *v1.Pod from pkg/mod/k8s.io/client-go@v0.31.10/tools/cache/reflector.go:243 I1210 10:58:33.839143 35948 reflector.go:368] Caches populated for *v1.Pod from pkg/mod/k8s.io/client-go@v0.31.10/tools/cache/reflector.go:243 I1210 10:58:33.932168 35948 cudevshr.go:317] Pod informer started successfully I1210 10:58:33.932238 35948 lock.go:50] MIG apply lock directory already exists I1210 10:58:33.932407 35948 feedback.go:187] Starting watchAndFeedback I1210 10:58:33.932466 35948 main.go:137] Initializing metrics for vGPUmonitor I1210 10:58:33.932550 35948 reflector.go:305] Starting reflector *v1.Pod (1h0m0s) from pkg/mod/k8s.io/client-go@v0.31.10/tools/cache/reflector.go:243 I1210 10:58:33.932556 35948 reflector.go:341] Listing and watching *v1.Pod from pkg/mod/k8s.io/client-go@v0.31.10/tools/cache/reflector.go:243 E1210 10:58:33.932798 35948 main.go:126] Received error: failed to initialize NVML: ERROR_LIBRARY_NOT_FOUND I1210 10:58:33.932812 35948 main.go:164] Shutting down metrics server
最新发布
12-11
01-01 00:08:12.495 1711 1711 I AEE_AEDV: $** *** *** *** *** *** *** *** Exception *** *** *** *** *** *** *** **$ 01-01 00:08:12.496 1711 1711 D AEE_AEDV: /vendor/bin/aee_dumpstatev_v2: filepath /data/vendor/aee_exp/temp/db.qHk3oU, pid -1360007168, tid -1360007168, exp_class 6, db_opt 0 01-01 00:08:12.498 1717 1717 E AEE_DUMPSTATEV: execute /vendor/bin/aee_dumpstatev_v2 01-01 00:08:12.507 1036 1036 E SpeechMessengerNormal: openCcciDriver(), open(/dev/ccci_aud) fail!! mCcciDeviceHandler: -1, errno: 2 01-01 00:08:12.507 1036 1036 W SpeechMessengerNormal: checkCcciStatusAndRecovery(), #20, sleep 10 ms & retry openCcciDriver 01-01 00:08:12.528 1717 1717 W libc : Access denied finding property "ro.version.confidential" 01-01 00:08:12.528 1717 1717 I AEE_DUMPSTATEV: begin 01-01 00:08:12.528 1717 1717 I AEE_DUMPSTATEV: Built commit 7c708b4421ea60f803088d5c00a634c95909c17c 01-01 00:08:12.529 1717 1717 E AEE_DUMPSTATEV: start set_signal_for_dumpstate 01-01 00:08:12.529 1717 1717 D AEE_DUMPSTATEV: cpu cores:8, online:8 01-01 00:08:12.530 1717 1717 I AEE_DUMPSTATEV: aee_opt=0x0 01-01 00:08:12.531 1717 1717 I AEE_DUMPSTATEV: archive_file_to_db: current dumped file is /data/vendor/aee_exp/temp/db.qHk3oU/__exp_main.txt 01-01 00:08:12.531 1717 1717 D AEE_DUMPSTATEV: archive_file_to_db: Collect file /data/vendor/aee_exp/temp/db.qHk3oU/__exp_main.txt to __exp_main.txt successfully, size 1296 01-01 00:08:12.532 1717 1717 I AEE_DUMPSTATEV: archive_file_to_db: current dumped file is /data/vendor/aee_exp/temp/db.qHk3oU/SYS_PROPERTIES 01-01 00:08:12.533 1046 1046 E sensors-hal-HfManager: try 19 times to wait device ready... 01-01 00:08:12.534 1717 1717 D AEE_DUMPSTATEV: archive_file_to_db: Collect file /data/vendor/aee_exp/temp/db.qHk3oU/SYS_PROPERTIES to SYS_PROPERTIES successfully, size 36992 01-01 00:08:12.534 1717 1717 I AEE_DUMPSTATEV: archive_file_to_db: current dumped file is /data/vendor/aee_exp/temp/db.qHk3oU/_exp_detail.txt 01-01 00:08:12.535 1717 1717 D AEE_DUMPSTATEV: archive_file_to_db: Collect file /data/vendor/aee_exp/temp/db.qHk3oU/_exp_detail.txt to _exp_detail.txt successfully, size 92 01-01 00:08:12.542 1717 1717 E AEE_DUMPSTATEV: archive_file_to_db: Failed to dump SYS_BLOCKIO, can not open file /sys/kernel/debug/blockio, No such file or directory 01-01 00:08:12.543 1717 1717 I AEE_DUMPSTATEV: archive_file_to_db: current dumped file is /proc/blocktag/blockio 01-01 00:08:12.544 1090 1124 I UAH_HAL : (1124)[wait_boot_init_completed] Waiting for 1st Boot 0.1 sec... errno: 0, value: 0 01-01 00:08:12.547 1717 1717 D AEE_DUMPSTATEV: archive_file_to_db: Collect file /proc/blocktag/blockio to SYS_BLOCKIO successfully, size 18709 01-01 00:08:12.547 1717 1717 I AEE_DUMPSTATEV: archive_file_to_db: current dumped file is /proc/ufs_debug 01-01 00:08:12.550 1012 1332 E TetherController: addInterface p2p0->20 succ 01-01 00:08:12.550 1012 1333 E TetherController: addInterface p2p0->20 succ 01-01 00:08:12.552 1717 1717 D AEE_DUMPSTATEV: archive_file_to_db: Collect file /proc/ufs_debug to SYS_STORAGE_DEBUG_UFS successfully, size 50558 01-01 00:08:12.554 1717 1717 E AEE_DUMPSTATEV: archive_file_to_db: Failed to dump SYS_STORAGE_DEBUG_MSDC, can not open file /proc/msdc_debug, No such file or directory 01-01 00:08:12.555 1717 1717 I AEE_DUMPSTATEV: archive_file_to_db: current dumped file is /sys/kernel/debug/mmprofile/buffer 01-01 00:08:12.556 1012 1332 E TetherController: addInterface p2p1->21 succ 01-01 00:08:12.559 1012 1333 E TetherController: addInterface p2p1->21 succ 01-01 00:08:12.571 1720 1720 I AEE_AED : Built commit 1fe4561f177e76c5c927d9204bc9c10c0df47204 01-01 00:08:12.571 1720 1720 D AEE_AED : Rtt command(type:0, string: arg0:1) 01-01 00:08:12.571 1720 1720 E aee_v2 : client connect socket fail: Connection refused 01-01 00:08:12.571 1720 1720 E AEE_AED : aee:rttdRtt command connect socket fail: Connection refused 01-01 00:08:12.572 1720 1720 D AEE_AED : aee:rttd_64Rtt waiting 64_daemon finish the job... 01-01 00:08:12.572 580 580 D AEE_AED : $===AEE===AEE===AEE===$ 01-01 00:08:12.572 580 580 D AEE_AED : p 0 poll events 1 revents 1 01-01 00:08:12.573 580 580 D AEE_AED : requesting from: pid=1720 cmd=23 01-01 00:08:12.581 1720 1720 E AEE_AED : Rtt command read 64_socket fail: Not a data message 01-01 00:08:12.586 1717 1717 D AEE_DUMPSTATEV: archive_file_to_db: Collect file /sys/kernel/debug/mmprofile/buffer to SYS_MMPROFILE successfully, size 3169936 01-01 00:08:12.608 1068 1068 E sensors-hal-HfManager: try 20 times to wait device ready... 01-01 00:08:12.614 1014 1023 D bspFwUpdate: [bspFwUpdate][ufs] ufs fw move succ! 01-01 00:08:12.614 1014 1023 D bspFwUpdate: [bspFwUpdate](null):fw_update success 01-01 00:08:12.614 1014 1023 D bspFwUpdate: [bspFwUpdate]Going to detect /data/oplus/fw_update/ufs 01-01 00:08:12.614 1014 1023 D bspFwUpdate: [bspFwUpdate]Going to create 01-01 00:08:12.614 1014 1023 D bspFwUpdate: [bspFwUpdate](null),monitor read begin
06-26
### 回答1: 这个错误通常是由于权限问题引起的。请确保您正在以root身份运行程序或已将用户添加到gpio组中。您可以使用以下命令将用户添加到gpio组: ``` sudo usermod -aG gpio your_username ``` 如果问题仍然存在,可能需要重新安装wiringPi库或检查您的硬件设置。 ### 回答2: "wiringPiSetup: 无法打开/dev/mem或/dev/gpiomem:没有这个文件或目录。"这个错误通常表示在树莓派上使用wiringPi库时出现了问题。 首先,确保你已经在树莓派上正确地设置了wiringPi库。要正确设置wiringPi库,需要确保在安装了wiringPi库的情况下进行编译和链接。 其次,检查/dev/mem和/dev/gpiomem的存在。这两个文件是树莓派上用于访问硬件的设备文件。如果这两个文件不存在,可能是因为你的系统没有正确配置树莓派的接口。 解决这个问题的一种方法是确保你的树莓派已经启用了GPIO接口。你可以通过在终端中运行"sudo raspi-config"来进入树莓派的配置界面,然后选择"Interfacing Options" -> "GPIO"来启用GPIO接口。 另外,确保你的树莓派系统是最新的。你可以运行"sudo apt-get update && sudo apt-get upgrade"来更新你的系统。 如果你依然遇到这个问题,可以尝试重新安装wiringPi库。可以通过以下步骤来重新安装wiringPi库: 1. 打开终端并输入"sudo apt-get purge wiringpi",这将卸载任何先前安装的wiringPi库。 2. 输入"cd ~"来返回到根目录。 3. 输入"git clone https://github.com/WiringPi/WiringPi.git"来下载wiringPi的最新版本。 4. 输入"cd WiringPi"进入下载的wiringPi文件夹。 5. 输入"./build"来编译和安装wiringPi库。 完成上述步骤后,重新运行你的代码,应该能够成功初始化wiringPi库并避免出现"/dev/mem or /dev/gpiomem: No such file or directory"的错误。 ### 回答3: 该错误通常是由于权限问题或者缺少依赖库导致的。树莓派在使用GPIO接口时需要访问到设备文件/dev/mem或/dev/gpiomem,但出现"No such file or directory"提示是因为系统找不到这两个设备文件。 首先,你需要检查你的权限是否足够访问这些文件。在终端中执行以下命令可以给予当前用户对这两个文件的读写权限: ``` $ sudo chmod 666 /dev/mem $ sudo chmod 666 /dev/gpiomem ``` 然后,你还需要确保你已经安装了wiringPi库及其依赖。运行以下命令以安装wiringPi: ``` $ git clone https://github.com/WiringPi/WiringPi.git $ cd WiringPi $ ./build ``` 编译完成后,检查是否已经成功加载wiringPi库。在终端中输入以下命令: ``` $ gpio -v ``` 如果输出了wiringPi的版本信息则说明安装成功。 如果上述步骤仍然不能解决问题,可能是因为缺少了BCM2835库或BCM2835配置错误。你可以尝试以下命令修复: ``` $ sudo apt-get update $ sudo apt-get install libbcm2835-dev ``` 如果还是没有解决问题,可能是因为系统存在其他错误。你可以参考官方文档或在相关的开发者社区寻求解决方案。 希望以上回答能对你有所帮助,祝你成功解决问题!
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值