valmikroy
3/15/2018 - 5:55 PM

try backing up /proc or /sys fs files

try backing up /proc or /sys fs files

# credits 
# https://stackoverflow.com/a/21801893/4817100


find /proc/irq/ -type f -name smp_affinity | while read F ; do
   D=tmp/$(dirname $F)
   test -d $D || mkdir -p $D
   test -f tmp/$F || sudo cat $F > tmp/$F
done

sudo cat /proc/interrupts  > tmp/proc/interrupts


find  /sys/devices/system/cpu/cpu*/topology -type f | while read F ; do
   D=tmp/$(dirname $F)
   test -d $D || mkdir -p $D
   test -f tmp/$F || sudo cat $F > tmp/$F
done