diff options
| author | Simon Rettberg | 2013-04-06 17:22:44 +0200 |
|---|---|---|
| committer | sr | 2013-04-12 19:11:41 +0200 |
| commit | 7a551f66eceda9acd9350481d59270a505a26b8c (patch) | |
| tree | fd60d9680f68c4ef8bbaaede3674b7262a1bfb24 /remote | |
| parent | Xstartup remove initctl line (diff) | |
| download | tm-scripts-7a551f66eceda9acd9350481d59270a505a26b8c.tar.gz tm-scripts-7a551f66eceda9acd9350481d59270a505a26b8c.tar.xz tm-scripts-7a551f66eceda9acd9350481d59270a505a26b8c.zip | |
Create udev rule before switching to stage32 which forces the pxe nic to always be called eth0
Diffstat (limited to 'remote')
| -rwxr-xr-x | remote/rootfs/rootfs-stage31/data/init | 15 | ||||
| -rw-r--r-- | remote/rootfs/rootfs-stage32/rootfs-stage32.conf.zypper | 2 | ||||
| l--------- | remote/targets/stage3.2-opensuse/pam | 1 |
3 files changed, 13 insertions, 5 deletions
diff --git a/remote/rootfs/rootfs-stage31/data/init b/remote/rootfs/rootfs-stage31/data/init index cf89cff0..a9c0435c 100755 --- a/remote/rootfs/rootfs-stage31/data/init +++ b/remote/rootfs/rootfs-stage31/data/init @@ -32,20 +32,24 @@ export KCL for opts in ${KCL}; do case ${opts} in debug*) - DEBUG=1;; + DEBUG=1 ;; splash*) - SPLASH=1;; + SPLASH=1 ;; ip=*) # process IP info - ipinfo=${opts#ip=};; + ipinfo=${opts#ip=} ;; nfs=*) nfs=${opts#nfs=} nfspath=${nfs#*:} nfsserver=${nfs%:/*} - ;; + ;; + BOOTIF=*) + macaddr="$( echo "$opts" | cut -b 11- | tr '-' ':' )" ;; esac done +echo "Mac address is '$macaddr'" + mdev -s & if [ "x$SPLASH" == "x1" -a "x$DEBUG" != "x1" ]; then @@ -124,6 +128,9 @@ mount -n -t aufs -o br:/dev/shm/uniontmp:/rorootfs=ro none /mnt mkdir -p /mnt/uniontmp /mnt/tmp mount -n --move /dev/shm/uniontmp /mnt/uniontmp +# create udev rule for nic we booted from +echo 'SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="'$macaddr'", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"' > "/mnt/etc/udev/rules.d/70-net-boot-nic-name.rules" + for mnt in proc sys run ; do umount -n $mnt done diff --git a/remote/rootfs/rootfs-stage32/rootfs-stage32.conf.zypper b/remote/rootfs/rootfs-stage32/rootfs-stage32.conf.zypper index 03f6f8a2..ec489fd1 100644 --- a/remote/rootfs/rootfs-stage32/rootfs-stage32.conf.zypper +++ b/remote/rootfs/rootfs-stage32/rootfs-stage32.conf.zypper @@ -39,7 +39,7 @@ REQUIRED_LIBRARIES=" libcap libtinfo libresolv libau" -REQUIRED_DIRECTORIES=" "" +REQUIRED_DIRECTORIES="" REQUIRED_FILES=" /etc/environment /etc/issue /etc/inputrc diff --git a/remote/targets/stage3.2-opensuse/pam b/remote/targets/stage3.2-opensuse/pam new file mode 120000 index 00000000..588acdbf --- /dev/null +++ b/remote/targets/stage3.2-opensuse/pam @@ -0,0 +1 @@ +../../modules/pam
\ No newline at end of file |
