Moxa V2616A-C8 Руководство по программной части (Linux) онлайн [15/111] 171047

Moxa V2616A-C8-CT-LX Руководство по программной части (Linux) онлайн [15/111] 171050
V2616A Linux Software Configuration
2-8
To run a private daemon, you can edit the file rc.local, as shown below:
1. Because the root file system is mounted in Read-only mode, you need to re-mount it with write permission.
MOXA:~# mount -o remount,rw /
2. Type cd /etc/ to change directories.
MOXA:~# cd /etc/
3. Type vi rc.local to edit the configuration file with vi editor.
MOXA:/etc/# vi rc.local
4. Next, add the application daemon that you want to run. We use the example program tcps2-release,
which you can find on the CD, to illustrate, and configure it to run in the background.
# !/bin/sh
# Add you want to run daemon
/home/your program &
5. After you finish writing or modifying the code, remember to execute umount / to change the root directory
back to Read-only mode.
MOXA:~# umount /
6. The enabled daemon should be running and displayed in yoru process list after you reboot the system:
MOXA:~# ps -ef
PID Uid VmSize Stat Command
1 root 1296 S init
2 root S [keventd]
3 root S [ksoftirqd_CPU0]
4 root S [kswapd]
5 root S [bdflush]
6 root S [kupdated]
7 root S [mtdblockd]
8 root S [khubd]
10 root S [jffs2_gcd_mtd3]
32 root D [ixp425_csr]
38 root 1256 S stdef
47 root 1368 S /usr/sbin/inetd
53 root 4464 S /usr/sbin/httpd
63 nobody 4480 S /usr/sbin/httpd
64 nobody 4480 S /usr/sbin/httpd
65 nobody 4480 S /usr/sbin/httpd
66 nobody 4480 S /usr/sbin/httpd
67 nobody 4480 S /usr/sbin/httpd
92 bin 1460 S /sbin/portmap
97 root 1264 S /root/tcps2-release
105 root 1556 S /usr/sbin/rpc.statd
109 root 4044 S /usr/sbin/snmpd –s –l /dev/null
111 root 2832 S /usr/sbin/snmptrapd -s
140 root 1364 S /sbin/cardmgr
144 root 1756 S /usr/sbin/rpc.nfsd
146 root 1780 S /usr/sbin/rpc.mountd
153 root 2960 S /usr/sbin/sshd
161 root 1272 S /bin/reportip
162 root 3464 S /bin/massupfirm
163 root 1532 S /sbin/getty 115200 ttyM0
164 root 1532 S /sbin/getty 115200 ttyM1
166 root 3464 S /bin/massupfirm
168 root 3464 S /bin/massupfirm
171 root 3652 S /usr/sbin/sshd
172 root 2200 S -bash
174 root 1592 S ps -ef
MOXA:~#

Содержание

Похожие устройства

Скачать