[置顶] 【总结】嵌入式Linux学习中遇到的问题及解决方法
2017-06-01 19:34
525 查看
持续更新。。。
(1)uboot中执行nfs 32000000 192.168.1.101:/work/nfs_root/uImage_new
下载新内核时出现:TTT***ERROR:Cannot
umount。如下图:
解决方法:
在linux虚拟机下输入:sudo vi /etc/hosts。在里面加上一行:
192.168.1.17 /work/nfs_root/
192.168.1.17 是单板uboot设置的IP
(2)Freeing init memory: 164K Kernel
panic - not syncing: No init found. Try passing init= option to kernel. See Linux Documentation/init.txt for guidance.
解决方法:
如果你刚移植了内核,设置了分区,制作了文件系统,那么八成是:文件系统烧错地方,或者分区不对,内核根本没找到文件系统。请检查uboot分区和内核中的分区是否一致。
(3)warning
implicit declaration of function 'exit'
Add:
(4)ubuntu 14 中安装arm-linux-gcc-4.4.3,装好后设置环境变量,然后arm-linux-gcc -v是出现:
/opt/FriendlyARM/toolschain/4.4.3/bin/arm-linux-gcc: 15: exec: /opt/FriendlyARM/toolschain/4.4.3/bin/.arm-none-linux-gnueabi-gcc: not found
解决方法:
执行:apt-get install lsb-core
(5)git commit -m "first_base_root"的时候出现:
*** Please tell me who you are.
Run
git config --global user.email "you@example.com"
git config --global user.name "Your Name"
to set your account's default identity.
Omit --global to set the identity only in this repository.
fatal: unable to auto-detect email address (got 'root@yangfei-virtual-machine.(none)')
解决方法:
vi .git/config
在下面加上:
[user]
email=your email
name=your name
(6)ubuntu 编译内核出现
recipe for target 'menuconfig' failed
No command 'recipe' found, did you mean:
Command 'recite' from package 'recite' (universe)
recipe: command not found
解决方法:
sudo apt-get install libncurses5-dev
(7)ubuntu出现:
error while loading shared libraries: libstdc++.so.6: cannot open shared obj
解决方法:
apt-get install lib32stdc++6
(8)内核启动过程中,打印: can't run '/etc/init.d/rcS': Permission denied
是制作文件系统的时候,没有加上缺陷,导致脚本文件无法被正常执行。
解决方法:
chomd +x /etc/init.d/rcS。。。
(9)ls /dev 目录下只有console 和 null
正常情况下,单板内核启动并加载文件系统后,在/dev下会看到一些设备节点。
原因是mdev没有正常被文件系统加载,文件系统脚本文件没有正常执行,或者busybox中没有配置mdex(默认是配置了的)
解决方法:
chomd +x /etc/init.d/rcS。
(10)Can't use 'defined(@array)' (Maybe you should just omit the defined()?) at kernel/timeconst.pl line 373
解决方法:
打开 kernel/timeconst.pl
@val = @{$canned_values{$hz}};
if (!defined(@val)) {
@val = compute_values($hz);
}
output($hz, @val);
将if (defined(@val)) 改为if (!@val),再次编译就可以通过了。
(11)安装ssl时:POD document had syntax errors at /usr/bin/pod2man line 68.
解决方法:执行
sudo rm /usr/bin/pod2man
(12)单板 passwd root时出现
unknown uid 0
解决方法:
13、makefile中的反斜杠\
反斜杠\:换行符的意思,不用写到一行了,这样增加makefile可读性。
OBJS := main.o \
display/disp_manager.o \
display/fb.o \
encoding/ascii.o \
encoding/utf-16be.o
(1)uboot中执行nfs 32000000 192.168.1.101:/work/nfs_root/uImage_new
下载新内核时出现:TTT***ERROR:Cannot
umount。如下图:
解决方法:
在linux虚拟机下输入:sudo vi /etc/hosts。在里面加上一行:
192.168.1.17 /work/nfs_root/
192.168.1.17 是单板uboot设置的IP
(2)Freeing init memory: 164K Kernel
panic - not syncing: No init found. Try passing init= option to kernel. See Linux Documentation/init.txt for guidance.
解决方法:
如果你刚移植了内核,设置了分区,制作了文件系统,那么八成是:文件系统烧错地方,或者分区不对,内核根本没找到文件系统。请检查uboot分区和内核中的分区是否一致。
(3)warning
implicit declaration of function 'exit'
Add:
#include <stdlib.h>
(4)ubuntu 14 中安装arm-linux-gcc-4.4.3,装好后设置环境变量,然后arm-linux-gcc -v是出现:
/opt/FriendlyARM/toolschain/4.4.3/bin/arm-linux-gcc: 15: exec: /opt/FriendlyARM/toolschain/4.4.3/bin/.arm-none-linux-gnueabi-gcc: not found
解决方法:
执行:apt-get install lsb-core
(5)git commit -m "first_base_root"的时候出现:
*** Please tell me who you are.
Run
git config --global user.email "you@example.com"
git config --global user.name "Your Name"
to set your account's default identity.
Omit --global to set the identity only in this repository.
fatal: unable to auto-detect email address (got 'root@yangfei-virtual-machine.(none)')
解决方法:
vi .git/config
在下面加上:
[user]
email=your email
name=your name
(6)ubuntu 编译内核出现
recipe for target 'menuconfig' failed
No command 'recipe' found, did you mean:
Command 'recite' from package 'recite' (universe)
recipe: command not found
解决方法:
sudo apt-get install libncurses5-dev
(7)ubuntu出现:
error while loading shared libraries: libstdc++.so.6: cannot open shared obj
解决方法:
apt-get install lib32stdc++6
(8)内核启动过程中,打印: can't run '/etc/init.d/rcS': Permission denied
是制作文件系统的时候,没有加上缺陷,导致脚本文件无法被正常执行。
解决方法:
chomd +x /etc/init.d/rcS。。。
(9)ls /dev 目录下只有console 和 null
正常情况下,单板内核启动并加载文件系统后,在/dev下会看到一些设备节点。
原因是mdev没有正常被文件系统加载,文件系统脚本文件没有正常执行,或者busybox中没有配置mdex(默认是配置了的)
解决方法:
chomd +x /etc/init.d/rcS。
(10)Can't use 'defined(@array)' (Maybe you should just omit the defined()?) at kernel/timeconst.pl line 373
解决方法:
打开 kernel/timeconst.pl
@val = @{$canned_values{$hz}};
if (!defined(@val)) {
@val = compute_values($hz);
}
output($hz, @val);
将if (defined(@val)) 改为if (!@val),再次编译就可以通过了。
(11)安装ssl时:POD document had syntax errors at /usr/bin/pod2man line 68.
解决方法:执行
sudo rm /usr/bin/pod2man
(12)单板 passwd root时出现
unknown uid 0
解决方法:
13、makefile中的反斜杠\
反斜杠\:换行符的意思,不用写到一行了,这样增加makefile可读性。
OBJS := main.o \
display/disp_manager.o \
display/fb.o \
encoding/ascii.o \
encoding/utf-16be.o
相关文章推荐
- 嵌入式Linux开发实验中遇到的问题及解决方法
- 最近在ArcGIS Engine开发中关于调用gp工具过程出现COM 组件的调用返回了错误 HRESULT E_FAIL 错误的解决方法 和 学习oracle中遇到的一些问题总结
- 常见的嵌入式Linux内核启动问题总结及解决方法
- 部分Linux学习遇到的问题及解决方法汇总
- 嵌入式linux(内核为linux 2.6.30.4)开发中遇到的一些问题解决方法
- android可能遇到问题,以及找到的解决方法小总结!
- 【Linux】U盘安装Centos6.3遇到的两个重要问题及其解决方法
- Linux下搭建SVN服务器遇到的问题及解决方法
- VUE学习遇到的问题及解决方法(一)
- Git学习 -- 远程操作遇到error: failed to push some refs to问题解决方法
- linux系统用遇到Another app is currently holding the yum lock问题的解决方法
- linux ---------驱动开发遇到的问题及解决方法
- 回顾总结64位CentOs下安装QT遇到的问题和解决方法
- ios 开发中遇到的问题总结以及解决方法
- DSP学习-遇到的问题及解决方法1
- 学习Hadoop时遇到的问题以及解决方法
- js学习总结之DOM2兼容处理this问题的解决方法
- 将 Windows 的 thinkPHP 项目上传至 Linux 服务器遇到的问题及解决方法
- Linux中gedit遇到如下问题时解决方法No protocol specified (gedit:9143): Gtk-WARNING **: cannot open display: :0.
- 自写聊天室_LinuxC实现(1)——项目部署遇到问题及解决方法