Project

General

Profile

Download (974 Bytes) Statistics
| Branch: | Tag: | Revision:
1 c613b74f Scott Ullrich
#!/bin/sh
2
#
3
# rc.embedded - embedded system specific startup information
4
# For pfSense
5
6
# Size of memory file system /conf partition
7
partsize="3m"
8
9 ebe6a739 Scott Ullrich
echo -n "Setting up embedded specific environment..."
10 c613b74f Scott Ullrich
# Run some initialization routines
11 deb0fc81 Scott Ullrich
[ -f /etc/rc.d/uzip ] && /etc/rc.d/uzip start
12 e9f2dd08 Scott Ullrich
13 4f1842be Scott Ullrich
if [ -f /nanobuild ]; then
14
# Init /etc and /var, /tmp to point towards /var/tmp
15
# All these to be done by rc.initdiskless
16
    sh /etc/rc.initdiskless
17 e9f2dd08 Scott Ullrich
else
18 4f1842be Scott Ullrich
# Initialize MFS for /tmp. Partly taken from /etc/rc.d/var
19
    if (/bin/mkdir -p /tmp/.diskless 2> /dev/null); then
20
	rmdir /tmp/.diskless
21
    else
22 e9f2dd08 Scott Ullrich
        varsize="40m"
23 4f1842be Scott Ullrich
	mdmfs -S -M -s ${varsize} md /tmp
24
    fi
25 c613b74f Scott Ullrich
26
# Initialize MFS for /var. Partly taken from /etc/rc.d/var
27 4f1842be Scott Ullrich
    if (/bin/mkdir -p /var/.diskless 2> /dev/null); then
28
	rmdir /var/.diskless
29
    else
30 8692fc2d Scott Ullrich
        varsize="20m"
31 4f1842be Scott Ullrich
	mdmfs -S -M -s ${varsize} md /var
32
    fi
33 c613b74f Scott Ullrich
fi
34
35
# Create some needed directories
36
/bin/mkdir -p /var/db/pkg/
37
/bin/mkdir -p /var/tmp/vi.recover/
38 ebe6a739 Scott Ullrich
echo " done."