blob: 366b617b4f300cc03a36930f79ca054c6ad1bb86 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
#!/bin/sh
die() {
echo >&2 E: $2 returned error code $1
echo >&2 N: Could not set up the loopback interface.
exit 1
}
if test -x /sbin/ifconfig; then
/sbin/ifconfig lo up || die $? ifconfig
elif test -x /sbin/ip; then
/sbin/ip link set lo up || die $? ip
elif test -x /bin/ip; then
/bin/ip link set lo up || die $? ip
else
echo >&2 E: Neither ifconfig nor ip found.
echo >&2 N: Could not set up the loopback interface.
exit 1
fi
exec "$@"
|