diff options
Diffstat (limited to 'templates/system/console/network/node.def')
-rw-r--r-- | templates/system/console/network/node.def | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/templates/system/console/network/node.def b/templates/system/console/network/node.def deleted file mode 100644 index d8184461..00000000 --- a/templates/system/console/network/node.def +++ /dev/null @@ -1,33 +0,0 @@ -tag: -type: txt -help: Network based console logging -priority: 400 # After network interface -val_help: <netconXX>; Network console device name - -syntax:expression: pattern $VAR(@) "^netcon[0-9]+$" \ - ; "network console $VAR(@): not a valid name" - -begin: # Make configfs if not present - if [ ! -d /dev/config ] ; then - sudo mkdir /dev/config - sudo mount -t configfs none /dev/config - fi - # Add netconsole module if not already present - [ -d /dev/config/netconsole ] || sudo modprobe netconsole - # create network console object - NETCONS=/dev/config/netconsole/$VAR(@) - [ -d $NETCONS ] || sudo mkdir $NETCONS - # leave disabled until end of transaction - if [ $(cat $NETCONS/enabled) -ne 0 ]; then - sudo sh -c "echo 0 > $NETCONS/enabled" - fi - -commit:expression: $VAR(interface) != "" ; "interface must be specified" - -delete: sudo rmdir /dev/config/netconsole/$VAR(@) - -end: NETCONS=/dev/config/netconsole/$VAR(@) - # enable console if not deleted - if [ -d $NETCONS ]; then - sudo sh -c "echo 1 > $NETCONS/enabled" - fi |