There are two ways to start the Telnetd service:
- Start with inetd service hosting
- Start independently
Hosting through inetd seems to require many files to be configured, so select the independent startup method here.
1. Check the Kernel configuration. Select "Device Drivers-> character devices-> unix98 Pty support"
2. Re-compile the busybox in uClinux-Dist and select the following items:
- Busybox-> busybox settings-> general configuration-> use the devpts filesystem for unix98 ptys
- Busybox-> login/password management utilities-> Login
- Busybox-> networking utilities-> telnetd
- Busybox-> networking utilities-> support standalone telnetd (not inetd only)
- If you are using a nommu Board (ARM7), set the value of the "busybox-> busybox settings-> general configuration-> path to busybox executable" option to "/bin/busybox"
3. Add the group and passwd files to the etc directory under romfs.
- $ Cat romfs/etc/group
- Root: 0: Root
- $ Cat romfs/etc/passwd
- Root: 0: 0: Root:/bin/sh
CopyCode
4. Create a device node and Directory
- $ CD romfs/dev/
- $ Touch @ ptmx, C, 5, 2
- $ Mkdir PTS
Copy code
5. Modify romfs/etc/rc and add the following content:
- Mount-T devpts/dev/PTS
Copy code
6. re-create romfs. IMG and run the following command after entering the system:
- # Telnetd
Copy code
Start the Telnetd service.
You do not need to add "&" at startup because it is a daemon.
Note:
- the tested uClinux-Dist version is 20080808
- busybox is a uClinux v1.10.2-uc0.
- the Telnet logon username is root and the password is blank
- according to the online documentation, When configuring the kernel, you also need to select/dev/PTS File System for unix98 ptys in file systems; but my kernel does not find this option (2.6.25)
- reference 1: http://hi.baidu.com/qwetiop/blog... 4abc2cd4074238.html
- reference 2: http://www.linuxforum.net/forum/showflat.php? Cat = & board = embedded & number = 524059 & page = & view = & SB = & O = & Vc = 1