summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Endres2006-03-21 17:33:01 +0100
committerFelix Endres2006-03-21 17:33:01 +0100
commit33ea007ab9c9a6630d817644959cb1ca7ce1e1dd (patch)
treec050fa8b8dd4d055fb9bd3005e8b537ad2892a7f
parentAdded 'sync' to runvmware (ensure that data is really written to loop (diff)
downloadcore-33ea007ab9c9a6630d817644959cb1ca7ce1e1dd.tar.gz
core-33ea007ab9c9a6630d817644959cb1ca7ce1e1dd.tar.xz
core-33ea007ab9c9a6630d817644959cb1ca7ce1e1dd.zip
Fix: dhclientuser für Ubuntu
Neue Basepasswd Screenresolutionermittlung git-svn-id: http://svn.openslx.org/svn/openslx/ld4@109 95ad53e4-c205-0410-b2fa-d234c58c8868
-rw-r--r--initrd/distro-specs/ubuntu/functions-5.106
-rwxr-xr-xinitrd/initrd-stuff/bin/hwautocfg11
-rw-r--r--initrd/initrd-stuff/etc/functions10
-rwxr-xr-xinitrd/initrd-stuff/init1
-rwxr-xr-xinitrd/mkdxsinitrd7
5 files changed, 23 insertions, 12 deletions
diff --git a/initrd/distro-specs/ubuntu/functions-5.10 b/initrd/distro-specs/ubuntu/functions-5.10
index d26dbea7..957ea475 100644
--- a/initrd/distro-specs/ubuntu/functions-5.10
+++ b/initrd/distro-specs/ubuntu/functions-5.10
@@ -12,6 +12,7 @@
# distro specific stuff to initialize
preinit () {
+ echo "Creating dhcp user"
echo "dhcp:x:101:">>/etc/group
echo "dhcp:x:101:101::/nonexistent:/bin/false">>/etc/passwd
@@ -19,8 +20,9 @@ preinit () {
modprobe ${MODPRV} unix || error " Failed to load the \"unix\" module. \
Problems with Hardware detection will probably arise"
}
-preinit () {
-:
+
+postinit () {
+ # Nothing to do yet
}
# AUS SuSE-9.3
diff --git a/initrd/initrd-stuff/bin/hwautocfg b/initrd/initrd-stuff/bin/hwautocfg
index 9ce5cd75..835124a0 100755
--- a/initrd/initrd-stuff/bin/hwautocfg
+++ b/initrd/initrd-stuff/bin/hwautocfg
@@ -149,11 +149,12 @@ fi
monmanual=yes
-# compute max resolution
-for res in 640x400 640x480 800x600 1024x768 1280x1024 1400x1050 1600x1200
- do MODES="\"$res\" \"lcd$res\" $MODES"
- [ "$res" = "$MR" ] && break
-done
+## compute max resolution
+#for res in 640x400 640x480 800x600 1024x768 1280x1024 1400x1050 1600x1200
+# do MODES="\"$res\" \"lcd$res\" $MODES"
+# [ "$res" = "$MR" ] && break
+#done
+MODES=`screenres | sed -n '/Recommended Screen Modes:/s/[^"]*\(.*\)/\1/p'`
# finally write config file
echo -e "#\n# autogenerated X hardware configuration by $0\n# \
diff --git a/initrd/initrd-stuff/etc/functions b/initrd/initrd-stuff/etc/functions
index 90ded7fd..825eff17 100644
--- a/initrd/initrd-stuff/etc/functions
+++ b/initrd/initrd-stuff/etc/functions
@@ -365,8 +365,14 @@ echo "not implemented" > /tmp/ldap-done
# base passwd/shadow, the standard user present in every system. All
# other system users should be generated within the service function
basepasswd () {
-echo -e "root:x:0:0:System Administrator:/root:/bin/bash" \
- > /mnt/etc/passwd
+# strip every line with userid between 500 and 99999 from the passwd-file
+# FIXME: "nobody" will be deleted too
+cat /mnt/etc/passwd | sed '/^[a-zA-Z0-9]*:[a-zA-Z0-9]*:[1-9][0-9]\{3,4\}:/d;/^[a-zA-Z0-9]*:[a-zA-Z0-9]*:[5-9][0-9]\{2\}:/d' > /mnt/etc/newpasswd
+mv /mnt/etc/newpasswd /mnt/etc/passwd
+
+
+#echo -e "root:x:0:0:System Administrator:/root:/bin/bash" \
+# > /mnt/etc/passwd
echo -e "root:"$root_pw":12958:0:10000::::" > /mnt/etc/shadow
}
diff --git a/initrd/initrd-stuff/init b/initrd/initrd-stuff/init
index 39280a4d..40e6ea3b 100755
--- a/initrd/initrd-stuff/init
+++ b/initrd/initrd-stuff/init
@@ -365,6 +365,7 @@ That\n might indicate some severe error."
# run distribution independent and dependent configuration of files and
# services
+bash
servconfig &
for path in @@@COMDIRINDXS@@@ ${D_DIRINDXS} ${D_DIRINBINDMNT} ; do
diff --git a/initrd/mkdxsinitrd b/initrd/mkdxsinitrd
index 42964d4d..a09c5097 100755
--- a/initrd/mkdxsinitrd
+++ b/initrd/mkdxsinitrd
@@ -342,7 +342,7 @@ done
# needed standard binaries
for bbins in \
cat chmod chown chroot cp expr fdisk killall ln mkdir mkfs.ext2 \
- modprobe mount portmap rmmod sed tar umount
+ modprobe mount portmap rmmod sed sort tar umount uniq
do
cobi ${bbins} bin || echo "Program ${bbins} not found"
done
@@ -428,7 +428,7 @@ if [ -z "$KERNVER" ] ; then
fi
if [ -z "$NWMODULES" ] ; then
- NWMODULES="e100 tg3 via-rhine r8169 pcnet32"
+ NWMODULES="forcedeth e1000 e100 tg3 via-rhine r8169 pcnet32"
fi
if [ -z "$FSMODULES" ] ; then
FSMODULES="nbd nfs"
@@ -480,7 +480,8 @@ for dirs in `find initrd-stuff/* ! -regex ".*/\..*"` ; do
repco ${dirs##initrd-stuff/}
done
chmod 755 ${INSTDIR}/init ${INSTDIR}/bin/servconfig \
- ${INSTDIR}/bin/hwautocfg ${INSTDIR}/bin/dhcpmkconfig
+ ${INSTDIR}/bin/hwautocfg ${INSTDIR}/bin/dhcpmkconfig \
+ ${INSTDIR}/bin/screenres
#########################################################################
# End of file copy procedures