Reputation: 101
I'm developing an embedded linux program. Now, I have an target board which has a embedded linux kernel running on it, and I want to mount a NFS file via the minicom. But when I excute the mount -t nfs IP:/path/to/nfs /tmp
, it happens an error like
mount: wrong fs type, bad option, bad superblock on
192.168.1.221:/home/shihaoliu/nfs
, missing codepage or helper program, or other error(for several filesystems(e.g. nfs, cifs) you might need a/sbin/mount.<type>
helper program)
In some cases useful info is found in syslog - trydmesg | tail
or so
Ok, I try another method to transfer file from host machine to target board.
I run the minicom on my host machine, and use the zmodem to transfer the file, but I got the error like this:
0000000000-bash: 0000000000: command not found.
Upvotes: 0
Views: 2729
Reputation: 101
Ok, I think I found the solution to using the minicom to transfer file.
Firstly, you need install the minicom and lrzsz on your host machine. You can use the command:
>> apt-get install minicom
>> apt-get install lrzsz
Secondly, you need install the lrzsz on your target board. You can get the lrzsz source code at the http://www.filewatcher.com/m/lrzsz-0.12.20.tar.gz.280938.0.0.html
Now, you need to cross-compile the lrzsz source code.
At the root directory of the lrzsz, you'll find the INSTALL file which describes the procedure.
Now, execute the command configure.
>> ./configure
After configure, you'll get the Makefile. Now you have to change the Makefile at the root
, /lib
, /src
directories. Like following:
CC = arm-lnone-linux-gnueabi-gcc
CPP = arm-lnone-linux-gnueabi-gcc -E
And you also need to change the Makefile at the /intl
directory. Like following:
AR = arm-none-linux-gnueabi-ar
CC = arm-none-linux-gnueabi-gcc
RANLIB = arm-none-linux-gnueabi-ranlib
At this time, you can make the program use command make and after that you'll get lsz, lrz files. Copy these two files to you target board and place both them at the /bin
dirctory.
After all, you have install the minicom successfully. Now, you can turn into the /tmp
directory and enter the command:
>> lrz
Type the keyboard Ctrl+A S and select the zmodem, now you can transfer a file to the target board from the host machine.
When the transmission is completed, you can find the file at /tmp
directory.
Ok, that's all I knew. Hope that's helpful for someone.
Upvotes: 2