upgraded busybox, activated ntpd, activated mdev, added hotplug scripts for USB storage - /media, added sbin paths to dropbear

This commit is contained in:
Jaroslav Kysela
2015-04-08 13:54:26 +02:00
parent 2838c945b5
commit 0d9040988d
10 changed files with 110 additions and 7 deletions

View File

@@ -1,3 +1,9 @@
#
# SATIP AXE firmware configuration
#
HOSTNAME="satip-axe"
#
# IPV4 config
#
@@ -8,6 +14,11 @@ IPV4="dhcp"
#IPV4_BROADCAST="192.168.1.255"
#IPV4_GATEWAY="192.168.1.1"
#
# ntpd
#
NTPD_OPTS="-p 0.pool.ntp.org"
#
# telnetd
#

7
fs-add/etc/init.d/ntpd Executable file
View File

@@ -0,0 +1,7 @@
#!/bin/sh
test -r /etc/sysconfig/config && . /etc/sysconfig/config
test -z "$NTPD_OPTS" && NTPD_OPTS="-p 0.pool.ntp.org"
exec /usr/sbin/ntpd -I eth0 $NTPD_OPTS

View File

@@ -6,7 +6,10 @@ busybox mount -t proc proc /proc
# remount root filesystem in rw mode
busybox mount -o remount,rw /
# Create all symbolic links.
/bin/busybox --install -s
/bin/busybox --install -s
# Date
date 010112002015 >/dev/null
# mount /dev and devpts to allow logging in
mount -t tmpfs -o size=64k,mode=0755 tmpfs /dev
@@ -15,12 +18,18 @@ mount -t devpts none /dev/pts -ogid=5,mode=620
# use mdev/sysfs
mount -t sysfs sysfs /sys
touch /dev/mdev.seq
mkdir -p /media
echo /sbin/mdev > /proc/sys/kernel/hotplug
echo /sbin/hotplug > /proc/sys/kernel/hotplug
mdev -s
# make /tmp as tmpfs
mount -t tmpfs -o size=1M tmpfs /tmp
mv /var /var.2
mkdir /tmp/var
ln -s /tmp/var /var
rm -rf /var.2
mkdir -p /tmp/var/run /tmp/var/log /tmp/var/spool
# start syslogd
syslogd -C256
@@ -41,8 +50,12 @@ if test -r /etc/sysconfig/passwd ; then
cp /etc/sysconfig/passwd /etc/passwd
fi
# hostname
test -r /etc/sysconfig/config && . /etc/sysconfig/config
test -n "$HOSTNAME" && hostname "$HOSTNAME"
test -z "$HOSTNAME" && hostname satip-axe
# basic network
hostname satip-axe
ifconfig lo 127.0.0.1 netmask 255.255.255.0
ifconfig eth0 up
route add -net 224.0.0.0 netmask 240.0.0.0 dev eth0

View File

@@ -1,9 +1,11 @@
# Boot
::sysinit:/etc/init.d/rcSBB
::sysinit:/etc/init.d/rcS
# Console
ttyAS0::askfirst:/bin/bash --init-file /etc/bashrc
ttyAS0::askfirst:/bin/sh
# Network
::once:/etc/init.d/network
# Time Network Protocol
::once:/etc/init.d/ntpd
# telnetd
::once:/etc/init.d/telnetd
# dropbear

2
fs-add/etc/mdev.conf Normal file
View File

@@ -0,0 +1,2 @@
-sd[a-h][0-9]{1,2} 0:0 660 @/sbin/sd-hotplug.sh
-sd[a-h][0-9]{1,2} 0:0 660 $/sbin/sd-hotunplug.sh

View File

@@ -1,2 +1,3 @@
Welcome to SATIP-AXE server @VERSION@
Welcome to SATIP-AXE server @VERSION@