source: debwrt/trunk/debian/rootfs/files/etc/init.d/rcS.firstboot @ 252

Last change on this file since 252 was 252, checked in by stappers, 9 years ago

addition on r251, to fix / to avoid

insserv: Script rcS.firstboot is broken: incomplete LSB comment.
insserv: missing valid name for `Provides:' please add.

message

  • Property svn:executable set to *
File size: 1.8 KB
Line 
1#! /bin/sh
2
3### BEGIN INIT INFO
4# Provides:             rcS
5# Required-Start:       
6# Required-Stop:       
7# Default-Start:       
8# Default-Stop:         
9# Short-Description:    first boot run control start for Debwrt
10### END INIT INFO
11
12# Mount root read-write
13/bin/mount -n -o remount,rw /dev/root /
14
15# Mount proc - why not? :-)
16/bin/mount -t proc none /proc
17
18# Setup the network
19/sbin/ifconfig eth0 192.168.1.1 netmask 255.255.255.0 up
20/sbin/ifconfig eth0:1 192.168.1.20 netmask 255.255.255.0 up
21
22# Mount devpts to allow telnet and ssh logins
23/bin/mkdir -p /dev/pts/
24/bin/mount -t devpts none /dev/pts/
25
26# Run telnetd in background
27while true; do /usr/sbin/in.telnetd -debug 23; /bin/sleep 1; done&
28
29# Run SSHd in background - nice scp-ing
30/usr/sbin/sshd -D &
31
32# Setting hostnams
33/bin/hostname `cat /etc/hostname`
34
35# Run bash instead of normal boot procedure
36/bin/echo
37/bin/echo "Welcome to the DebWrt post installation!"
38/bin/echo
39/bin/echo "Press ctrl-d for normal boot. Use vim.tiny to edit files."
40/bin/echo
41/bin/echo "Note that both telnetd and sshd are running on: 192.168.1.1 and on 192.168.1.20."
42/bin/echo
43/bin/echo "Second stage install instructions:"
44/bin/echo
45/bin/echo "  /debootstrap/debootstrap --second-stage  ;"
46/bin/echo "  rm -rf /var/cache/apt/archives  ;"
47/bin/echo "  mkdir -p /var/cache/apt/archives/partial  ;"
48/bin/echo "  echo \"deb http://ftp.debian.org/debian squeeze main\" >>/etc/apt/sources.list"
49/bin/echo "# OR"
50/bin/echo "- echo \"deb http://ftp.debian.org/debian sid main\" >>/etc/apt/sources.list"
51/bin/echo "- for Lenny: dpkg-reconfigure dash"
52/bin/echo
53/bin/echo " Don't execute these lines, these are a reminder for myself(amain) when preparing an DebWrt release:"
54/bin/echo "- rm -rf /lib/modules/*"
55/bin/echo "- rm -rf /lib/firmware/*"
56/bin/echo
57/bin/bash
58
59# Normal boot procedure
60exec /etc/init.d/rc S
Note: See TracBrowser for help on using the repository browser.