]>
git.ipfire.org Git - ipfire-2.x.git/blob - src/hwinfo/getsysinfo
6 Collect some system data that are useful for debugging
7 hardware detection bugs.
12 # collect some system data
14 dir
=`mktemp -d /tmp/getsysinfo.XXXXXXXXXX`
16 [ -d "$dir" ] ||
exit 1
19 [ "$host" ] ||
host=xxx
41 /proc
/sys
/dev
/cdrom
/info \
42 /proc
/sys
/dev
/parport \
50 cp -a --parents "$i" "$dir/$host" 2>/dev
/null
51 chmod -R u
+w
,a
+r
,a
+X
"$dir/$host"
56 cp --parents /proc
/mounts
"$dir/$host"
58 echo -e "\n------ dmesg start ------\n" >>"$dir/$host/var/log/boot.msg"
59 dmesg
>>"$dir/$host/var/log/boot.msg"
62 tar -C "$dir" -zcf "$dir/$file" "$host"
66 if [ -e "/tmp/$file" ] ; then
67 echo "Warning: /tmp/$file exists, no info written"\
!
72 ln -nf "$dir/$file" "/tmp/$file"
76 echo -e "\nSystem data written to: /tmp/$file"