Module Name:    src
Committed By:   jmcneill
Date:           Sun Oct 11 14:24:31 UTC 2020

Modified Files:
        src/distrib/evbarm/instkernel/ramdisk: dot.profile

Log Message:
Sync with amd64


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/distrib/evbarm/instkernel/ramdisk/dot.profile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/distrib/evbarm/instkernel/ramdisk/dot.profile
diff -u src/distrib/evbarm/instkernel/ramdisk/dot.profile:1.3 src/distrib/evbarm/instkernel/ramdisk/dot.profile:1.4
--- src/distrib/evbarm/instkernel/ramdisk/dot.profile:1.3	Thu Jan  9 19:17:41 2020
+++ src/distrib/evbarm/instkernel/ramdisk/dot.profile	Sun Oct 11 14:24:31 2020
@@ -1,4 +1,4 @@
-# $NetBSD: dot.profile,v 1.3 2020/01/09 19:17:41 martin Exp $
+#	$NetBSD: dot.profile,v 1.4 2020/10/11 14:24:31 jmcneill Exp $
 #
 # Copyright (c) 1997 Perry E. Metzger
 # Copyright (c) 1994 Christopher G. Demetriou
@@ -35,10 +35,14 @@
 
 PATH=/sbin:/bin:/usr/bin:/usr/sbin:/
 export PATH
-TERM=vt100
+TERM=wsvt25
 export TERM
 HOME=/
 export HOME
+BLOCKSIZE=1k
+export BLOCKSIZE
+EDITOR=ed
+export EDITOR
 
 umask 022
 
@@ -51,14 +55,22 @@ if [ "X${DONEPROFILE}" = "X" ]; then
 	# set up some sane defaults
 	echo 'erase ^?, werase ^W, kill ^U, intr ^C'
 	stty newcrt werase ^W intr ^C kill ^U erase ^?
-	echo ''
+	mount -t tmpfs tmpfs /tmp
+	mount -t tmpfs tmpfs /var
+	mount -t tmpfs -o union tmpfs /etc
+
+	mkdir -p /var/run /var/db
 
 	# mount the ramdisk read write
 	mount -u $ROOTDEV /
 
-	# mount the kern_fs so that we can examine the dmesg state
-	mount -t kernfs /kern /kern
+	grep() sed -n "/$1/p"
 
-	# run the installation or upgrade script.
-	sysinst || stty sane
+	if [ -x /sysinst ]; then
+		# run the installation or upgrade script.
+		sysinst || stty sane
+	else
+		echo "This image contains utilities which may be needed"
+		echo "to get you out of a pinch."
+	fi
 fi

Reply via email to