diff options
Diffstat (limited to 'conf/tcos-run-functions.sh')
-rw-r--r-- | conf/tcos-run-functions.sh | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/conf/tcos-run-functions.sh b/conf/tcos-run-functions.sh index 7bcd8a7..4e79180 100644 --- a/conf/tcos-run-functions.sh +++ b/conf/tcos-run-functions.sh @@ -103,6 +103,17 @@ _log () { /bin/logger -t "$(echo $1| awk '{print $1}')" "$@" >> /tmp/initramfs.debug 2>&1 } +tcos_find_module() { + mod=$(find /lib/modules/${version} -name ${1}.ko | tail -1) + if [ "$mod" = "" ] ; then + return 1 + fi + if [ "$(basename $mod .ko)" = "$1" ]; then + return 0 + fi + return 1 +} + read_server() { # $1 is server hostname nSERVER=$(grep "$1" /etc/hosts | awk '{print $1}' | head -1) |