嵌入式linux下的USB自动挂载问题
现在在做嵌入式linux下的USB自动挂载。
在系统启动的时候,首先加载USB驱动。加载过程中出现如下错误:
usb 1-2: new full speed USB device using hisilicon-ohci and address 2
usb 1-2: device descriptor read/64, error -110
usb 1-2: device descriptor read/64, error -110
usb 1-2: new full speed USB device using hisilicon-ohci and address 3
usb 1-2: device descriptor read/64, error -110
usb 1-2: device descriptor read/64, error -110
usb 1-2: new full speed USB device using hisilicon-ohci and address 4
usb 1-2: device not accepting address 4, error -110
usb 1-2: new full speed USB device using hisilicon-ohci and address 5
usb 1-2: device not accepting address 5, error -110
这是怎么回事?
虽然出现上述错误。但是当系统起来以后在控制台下还是能发现USB设备。我现在用的是U盘
能在/dev/scsi/host0/bus0/target0/lun0/目录下发现disc和part1
然后可以手动挂载。
现在我想让U盘自动挂载。写了个脚本。在加载完驱动以后马上执行挂载U盘脚本。但是挂载的时候提示
mount: Mounting /dev/scsi/host0/bus0/target0/lun0/part1 on /mnt/usb failed: No such file or directory
下面是脚本的内容:
load_usb_drv
sleep 10
if[ -r /dev/scsi/host0/bus0/target0/lun0/part1 ]
then
mount /dev/scsi/host0/bus0/target0/lun0/part1 /mnt/usb
fi
相关文档:
TFTP是用来下载远程文件的最简单网络协议,它基于UDP协议而实现。嵌入式linux的tftp开发环境包括两个方面:一是嵌入式linux宿主机的 tftp-server支持,二是嵌入式linux目标机的tftp-client支持。因为u-boot本身内置支持tftp-client,所以嵌入式目标机就不用配置了。下面就详细介绍一下linux宿主机tftp-server的安装配置。
......
linux下几种服务器的配置使用之一:nfs tftp
安装nfs需要在服务器端关闭iptables防火墙,关闭方法如下
查看防火墙状态:
/etc/init.d/iptables status
暂时关闭防火墙:
/etc/init.d/iptables stop
禁止防火墙在系统启动时启动
/sbin/chkconfig --level 2345 iptables off
重启iptables:
/etc/init.d/iptabl ......
在程序不寻常退出时,内核会在当前工作目录下生成一个core文件(是一个内存映像,同时加上调试信息)。使用gdb来查看core文件,可以指示出导致程序出错的代码所在文件和行数。
1.core文件的生成开关和大小限制
1)使用ulimit -c命令可查看core文件的生成开关。若结果为0,则表示关闭了此功能,不会生成core文件。
......
1.编译安装libevent
2.编译安装Memcached
在我写这篇文章的时候,libevent已经有1.4.8稳定版
,Memcached Server已经有1.3.0版本
。本文就以这两个版本为例,我的gcc是gcc version 3.3.4 (Debian 1:3.3.4-7)。
首先安装libevent
wget http://www.monkey.org/~provos/libevent-1.4.8-stable.tar.gz
tar zxvf libeven ......
top命令是Linux下常用的性能分析工具,能够实时显示系统中各个进程的资源占用状况,类似于Windows的任务管理器。下面详细介绍它的使用方法。 top - 01:06:48 up 1:22, 1 user, load average: 0.06, 0.60, 0.48
Tasks: 29 total, 1 running, 28 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.3% us, 1.0% sy, 0.0% ni, ......