Last active
November 30, 2020 15:02
-
-
Save godspeed1989/5590281 to your computer and use it in GitHub Desktop.
/etc/init.d/rcS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo "Starting rcS..." | |
echo "++ Mounting filesystem" | |
mount tmpfs /dev -t tmpfs | |
mount proc /proc -t proc | |
mount sysfs /sys -t sysfs | |
mkdir -p /dev/pts | |
mkdir -p /dev/i2c | |
echo "++ Setting up mdev" | |
echo /sbin/mdev > /proc/sys/kernel/hotplug | |
mdev -s | |
mount -a | |
echo "++ Starting syslogd" | |
syslogd | |
echo "++ Starting klogd" | |
klogd | |
echo "++ Starting telnet daemon" | |
telnetd -l /bin/sh | |
echo "++ Starting http daemon" | |
httpd -h /var/www | |
echo "++ Starting ftp daemon" | |
tcpsvd 0:21 ftpd ftpd -w /& | |
echo "++ Starting ssh daemon" | |
chmod 600 /etc/ssh_host_* | |
/usr/sbin/sshd | |
if [ -f /mnt/init.sh ] | |
then | |
echo "++ Running user script init.sh from SD Card" | |
source /mnt/init.sh | |
fi | |
echo "rcS Complete" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment