summarylogtreecommitdiffstats
path: root/initcpio-hook-aoe
blob: 2e1cc884057c9169ac1fc7dea0fb84fc084b6fa9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# vim: set ft=sh:
run_hook() {
    for i in $(ls /sys/class/net); do
        echo Bringing up interface $i for AoE
        ifconfig $i up
    done

    # Make sure udev has processed all events from adding the NIC
    # modules before loading aoe
    udevadm settle --timeout=30
    echo Loading AoE module
    modprobe aoe
    # Wait until aoe device files have been generated.
    udevadm settle --timeout=30
    echo Issuing AoE discover
    aoe-discover
}

# vim: set ft=sh ts=4 sw=4 et: