2 # Copyright (c) 2004-2013 Apple Inc.
6 # Collect system & network configuration information.
9 PATH
=/bin
:/usr
/bin
:/sbin
:/usr
/sbin
14 cat <<_END_OF_DISCLAIMER
16 This diagnostic tool generates files that allow Apple to investigate issues
17 with your computer and help Apple to improve its products. The generated files
18 may contain some of your personal information, which may include, but not be
19 limited to, the serial number or similar unique number for your device, your
20 user name, or your computer name. The information is used by Apple in
21 accordance with its privacy policy (www.apple.com/privacy) and is not shared
22 with any third party. By enabling this diagnostic tool and sending a copy of
23 the generated files to Apple, you are consenting to Appleās use of the content
28 /bin
/echo "Press 'Enter' to continue."
35 if [ ${EUID} -ne 0 ]; then
39 if [ -x /usr
/bin
/tail ]; then
40 TAIL_2000
="/usr/bin/tail -n 2000"
41 TAIL_25000
="/usr/bin/tail -n 25000"
47 OUT
="mobility-info-`date +'%m.%d.%Y.%H%M%S'`"
49 if [ -d ~
/Desktop
]; then
51 elif [ "`readlink /tmp`" = "private/var/tmp" ]; then
52 OUTDIR
=/Library
/Logs
/CrashReporter
58 WORKDIR
=`mktemp -d -q "/tmp/${OUT}"`
60 echo "Could not create snapshot directory"
66 if [ -x /usr
/bin
/gzip ]; then
71 ARCHIVE
=`mktemp -q "${OUTDIR}/${OUT}.tar${GZ_EXT}"`
73 echo "Could not create snapshot archive"
81 echo "Please wait, collecting information and statistics"
85 # Execute network reachability/DNS commands early as "mDNSResponder" will block while
86 # logging its "state" info.
88 scutil
-d -v -r www.apple.com
"" no
-server > reachability
-info 2>&1
89 if [ -x /usr
/bin
/dig -a -f /etc
/resolv.conf
]; then
90 /usr
/bin
/dig -t any
-c any www.apple.com
> dig-results 2>/dev
/null
94 # Signal "networkd" and "mDNSResponder" to log their "state" info. This logging will
95 # continue while we execute a few other commands and should be complete by the time
96 # we collect the log content.
98 if [ -x /usr
/bin
/killall
]; then
99 ${PRIV} /usr
/bin
/killall
-INFO networkd
100 ${PRIV} /usr
/bin
/killall
-INFO mDNSResponder
107 if [ -x /bin
/ps
]; then
108 /bin
/ps axlww
> ps
2>&1
112 # network interface configuration
114 if [ -x /sbin
/ifconfig
]; then
115 /sbin
/ifconfig
-a -L -b -m -r -v -v > ifconfig
2>&1
116 if [ $?
-ne 0 ]; then
117 /sbin
/ifconfig
-a > ifconfig
2>&1
122 # network route configuration
124 if [ -x /usr
/sbin
/netstat
]; then
125 /usr
/sbin
/netstat
-n -r -a -l > netstat
2>&1
131 if [ -x /sbin
/ifconfig
]; then
132 for if in `/sbin/ifconfig -l`
136 en
* ) ipconfig getpacket
${if} > ipconfig
-${if} 2>&1
145 if [ -x /System
/Library
/PrivateFrameworks
/Apple80211.framework
/Resources
/airport
]; then
146 /System
/Library
/PrivateFrameworks
/Apple80211.framework
/Resources
/airport
--getinfo \
153 if [ -x /usr
/bin
/wdutil
]; then
154 ${PRIV} /usr
/bin
/wdutil dump
156 /bin
/ls -1 /private
/tmp
/wifi
-* 2>/dev
/null \
159 if [ -f "${log}" ]; then
160 b
="`basename ${log}`"
161 ${PRIV} cat "${log}" > "wifi_dump/${b}" 2>&1
169 if [ -e /System
/Library
/CoreServices
/SystemVersion.plist
]; then
170 cat /System
/Library
/CoreServices
/SystemVersion.plist \
171 > SystemVersion.plist
2>&1
173 if [ -e /System
/Library
/CoreServices
/ServerVersion.plist
]; then
174 cat /System
/Library
/CoreServices
/ServerVersion.plist \
175 > ServerVersion.plist
2>&1
181 if [ -x /usr
/sbin
/ioreg
]; then
182 /usr
/sbin
/ioreg
-i -l -w 0 > ioreg
2>&1
183 /usr
/sbin
/ioreg
-i -l -p IODeviceTree
-w 0 >> ioreg
2>&1
187 # Power Management info
189 if [ -x /usr
/bin
/pmset
]; then
191 echo "# pmset -g everything" >> pmset
193 /usr
/bin
/pmset
-g everything
2>/dev
/null
| ${TAIL_25000} >> pmset
199 if [ -x /bin
/hostname
]; then
200 /bin
/hostname
> hostname
2>&1
206 if [ -x /usr
/bin
/hostinfo
]; then
207 /usr
/bin
/hostinfo
> hostinfo
2>&1
209 if [ -e /etc
/hostconfig
]; then
210 cat /etc
/hostconfig
> etc.hostconfig
2>&1
216 scutil
--dns > dns
-configuration 2>&1
217 if [ -e /etc
/resolv.conf
]; then
218 cat /etc
/resolv.conf
> etc.resolv.conf
2>&1
220 if [ -e /var
/run
/resolv.conf
]; then
221 cat /var
/run
/resolv.conf
> var.run.resolv.conf
2>&1
223 if [ -e /etc
/resolver
]; then
224 tar -c -H /etc
/resolver
> etc.resolver.
tar 2>/dev
/null
228 # Proxy configuration
230 scutil
-d -v --proxy > proxy
-configuration 2>&1
233 # Network information
235 if [ -x /sbin
/ifconfig
]; then
236 echo "#" > network
-information
237 echo "# scutil --nwi" >> network
-information
238 echo "#" >> network
-information
239 scutil
--nwi >> network
-information 2>&1
240 for if in `/sbin/ifconfig -l`
242 echo "" >> network
-information
243 echo "#" >> network
-information
244 echo "# scutil --nwi ${if}" >> network
-information
245 echo "#" >> network
-information
246 scutil
--nwi ${if} >> network
-information 2>&1
251 # System / network preferences
254 /Library
/Preferences
/SystemConfiguration
/NetworkInterfaces.plist \
255 /Library
/Preferences
/SystemConfiguration
/com.apple.PowerManagement.plist \
256 /Library
/Preferences
/SystemConfiguration
/com.apple.airport.preferences.plist \
257 /Library
/Preferences
/SystemConfiguration
/com.apple.nat.plist \
258 /Library
/Preferences
/SystemConfiguration
/com.apple.smb.server.plist \
259 /Library
/Preferences
/SystemConfiguration
/com.apple.wifi.plist \
260 /Library
/Preferences
/SystemConfiguration
/preferences.plist \
261 /Library
/Preferences
/com.apple.alf.plist \
262 /Library
/Preferences
/com.apple.sharing.firewall.plist \
263 /Library
/Preferences
/com.apple.wwand.plist \
266 if [ -e "${f}" ]; then
268 cat "${f}" > "${b}" 2>&1
273 # System / network preferences (from other volumes)
276 | awk 'BEGIN { FS= "[/ \t]+" } /^\/dev\/disk.* on \/Volumes\// { print $6 }' \
279 V_PATH
="/Volumes/${volume}"
281 /Library
/Preferences
/SystemConfiguration
/Networkinterfaces.plist \
282 /Library
/Preferences
/SystemConfiguration
/preferences.plist \
285 if [ -f "${V_PATH}/${f}" ]; then
286 mkdir -p "OtherPreferences/${volume}"
288 cat "${V_PATH}/${f}" > "OtherPreferences/${volume}/${b}" 2>&1
296 if [ -e /etc
/bootpd.plist
]; then
297 cat /etc
/bootpd.plist
> bootpd.plist
2>&1
298 cat /etc
/com.apple.named.proxy.conf
> com.apple.named.proxy.conf
2>/dev
/null
299 elif [ -e /Library
/Preferences
/SystemConfiguration
/bootpd.plist
]; then
300 cat /Library
/Preferences
/SystemConfiguration
/bootpd.plist
> bootpd.plist
2>&1
301 cat /Library
/Preferences
/SystemConfiguration
/com.apple.named.proxy.conf
> com.apple.named.proxy.conf
2>/dev
/null
307 ${PRIV} scutil
-p --snapshot
308 if [ -f /var
/tmp
/configd
-store.plist
]; then
309 cat /var
/tmp
/configd
-store.plist
> configd
-store.plist
2>&1
311 if [ -f /var
/tmp
/configd
-pattern.plist
]; then
312 cat /var
/tmp
/configd
-pattern.plist
> configd
-pattern.plist
2>&1
314 if [ -f /var
/tmp
/configd
-session.plist
]; then
315 cat /var
/tmp
/configd
-session.plist
> configd
-session.plist
2>&1
317 if [ -f /var
/tmp
/configd
-state ]; then
318 cat /var
/tmp
/configd
-state > configd
-state 2>&1
320 if [ -f /var
/tmp
/configd
-reachability ]; then
321 cat /var
/tmp
/configd
-reachability > configd
-reachability 2>&1
325 # mounted filesystems
327 mount
> mounted
-filesystems 2>&1
329 ${PRIV} cat /etc
/hosts
> etc.hosts
2>/dev
/null
332 # kernel extensions statistic
334 if [ -x /usr
/sbin
/kextstat
]; then
335 /usr
/sbin
/kextstat
> kextstat
2>&1
336 elif [ -x /usr
/sbin
/kmodstat
]; then
337 /usr
/sbin
/kmodstat
> kmodstat
2>&1
343 echo -n "" > network
-statistics
345 if [ -x /usr
/sbin
/arp
]; then
346 echo "#" >> network
-statistics
347 echo "# arp -n -a" >> network
-statistics
348 echo "#" >> network
-statistics
349 /usr
/sbin
/arp
-n -a >> network
-statistics 2>&1
352 if [ -x /usr
/sbin
/netstat
]; then
353 echo "#" >> network
-statistics
354 echo "# netstat -n -a -A" >> network
-statistics
355 echo "#" >> network
-statistics
356 /usr
/sbin
/netstat
-n -a -A >> network
-statistics 2>&1
358 echo "#" >> network
-statistics
359 echo "# netstat -s" >> network
-statistics
360 echo "#" >> network
-statistics
361 /usr
/sbin
/netstat
-s >> network
-statistics 2>&1
363 echo "#" >> network
-statistics
364 echo "# netstat -mmm" >> network
-statistics
365 echo "#" >> network
-statistics
366 /usr
/sbin
/netstat
-mmm >> network
-statistics 2>&1
368 echo "#" >> network
-statistics
369 echo "# netstat -i -n -d" >> network
-statistics
370 echo "#" >> network
-statistics
371 /usr
/sbin
/netstat
-i -n -d >> network
-statistics 2>&1
373 echo "#" >> network
-statistics
374 echo "# netstat -g -n -s" >> network
-statistics
375 echo "#" >> network
-statistics
376 /usr
/sbin
/netstat
-g -n -s >> network
-statistics 2>&1
378 echo "#" >> network
-statistics
379 echo "# netstat -i -x R" >> network
-statistics
380 echo "#" >> network
-statistics
381 /usr
/sbin
/netstat
-i -x R
>> network
-statistics 2>&1
382 echo "#" >> network
-statistics
384 echo "# netstat -a -n -p mptcp" >> network
-statistics
385 echo "#" >> network
-statistics
386 /usr
/sbin
/netstat
-a -n -p mptcp
>> network
-statistics 2>/dev
/null
388 echo "#" >> network
-statistics
389 echo "# netstat -s -p mptcp" >> network
-statistics
390 echo "#" >> network
-statistics
391 /usr
/sbin
/netstat
-s -p mptcp
>> network
-statistics 2>/dev
/null
393 if [ -x /sbin
/ifconfig
]; then
394 for if in `/sbin/ifconfig -l`
396 `/sbin/ifconfig -v ${if} | grep -q TXSTART`
397 if [ $?
-eq 0 ]; then
398 echo "#" >> network
-statistics
399 echo "# netstat -qq -I ${if}" >> network
-statistics
400 echo "#" >> network
-statistics
401 /usr
/sbin
/netstat
-qq -I ${if} >> network
-statistics 2>&1
403 `/sbin/ifconfig -v ${if} | grep -q RXPOLL`
404 if [ $?
-eq 0 ]; then
405 echo "#" >> network
-statistics
406 echo "# netstat -Q -I ${if}" >> network
-statistics
407 echo "#" >> network
-statistics
408 /usr
/sbin
/netstat
-Q -I ${if} >> network
-statistics 2>&1
414 if [ -x /usr
/sbin
/ndp
]; then
415 echo "#" >> network
-statistics
416 echo "# ndp -n -a" >> network
-statistics
417 echo "#" >> network
-statistics
418 /usr
/sbin
/ndp
-n -a >> network
-statistics 2>&1
420 echo "#" >> network
-statistics
421 echo "# ndp -n -p" >> network
-statistics
422 echo "#" >> network
-statistics
423 /usr
/sbin
/ndp
-n -p >> network
-statistics 2>&1
425 echo "#" >> network
-statistics
426 echo "# ndp -n -r" >> network
-statistics
427 echo "#" >> network
-statistics
428 /usr
/sbin
/ndp
-n -r >> network
-statistics 2>&1
430 if [ -x /sbin
/ifconfig
]; then
431 for if in `/sbin/ifconfig -l`
433 echo "#" >> network
-statistics
434 echo "# ndp -i ${if}" >> network
-statistics
435 echo "#" >> network
-statistics
436 /usr
/sbin
/ndp
-i ${if} >> network
-statistics 2>&1
441 if [ -x /sbin
/ipfw
]; then
442 echo "#" >> network
-statistics
443 echo "# ipfw -at show" >> network
-statistics
444 echo "#" >> network
-statistics
445 ${PRIV} /sbin
/ipfw
-at show
>> network
-statistics 2>&1
448 if [ -x /sbin
/ip6fw
]; then
449 echo "#" >> network
-statistics
450 echo "# ip6fw -at show" >> network
-statistics
451 echo "#" >> network
-statistics
452 ${PRIV} /sbin
/ip6fw
-at show
>> network
-statistics 2>&1
455 if [ -x /sbin
/pfctl
]; then
457 echo "# pfctl -s all" >> pf
459 ${PRIV} /sbin
/pfctl
-s all
>> pf
2>&1
460 echo "==============================" >> pf
462 echo "# pfctl -s References" >> pf
464 ${PRIV} /sbin
/pfctl
-s References
>> pf
2>&1
465 for ANCHOR
in `${PRIV} pfctl -s Anchors -v 2>/dev/null`
467 echo "==============================" >> pf
469 echo "# pfctl -a ${ANCHOR} -s all" >> pf
471 ${PRIV} /sbin
/pfctl
-a ${ANCHOR} -s all
>> pf
2>&1
475 if [ -x /usr
/sbin
/lsof
]; then
476 echo "#" >> network
-statistics
477 echo "# lsof -i -U -n -P" >> network
-statistics
478 echo "#" >> network
-statistics
479 ${PRIV} /usr
/sbin
/lsof
-i -U -n -P >> network
-statistics 2>&1
483 # DirectoryService info
485 if [ -x /usr
/bin
/odutil
]; then
487 echo "# odutil show all" >> od-info
489 ${PRIV} /usr
/bin
/odutil show all
>> od-info 2>&1
490 elif [ -x /usr
/bin
/dscacheutil
]; then
492 echo "# dscacheutil -configuration" >> ds
-info
494 /usr
/bin
/dscacheutil
-configuration >> ds
-info 2>&1
497 echo "# dscacheutil -statistics" >> ds
-info
499 /usr
/bin
/dscacheutil
-statistics >> ds
-info 2>&1
502 echo "# dscacheutil -cachedump -entries" >> ds
-info
504 /usr
/bin
/dscacheutil
-cachedump -entries >> ds
-info 2>&1
508 # IPsec configuration
510 if [ -x /usr
/sbin
/setkey
-a -x /usr
/bin
/perl
]; then
512 echo "# setkey -D" >> ipsec
514 ${PRIV} /usr
/sbin
/setkey
-D \
515 | /usr
/bin
/perl
-M'Digest::MD5 qw(md5_hex)' -l -n -e '
516 if (/^(\s+[AE]:\s+\S+\s+)"?(.*)"?\s*$/) {
517 printf "%s[MD5:%s]%s\n", $1, md5_hex($2 . "\n"), $3;
525 echo "# setkey -Pp -D" >> ipsec
527 ${PRIV} /usr
/sbin
/setkey
-Pp -D >> ipsec
529 for CF
in /var
/run
/racoon
/*.conf
531 if [ ! -r "${CF}" ]; then
537 echo "# ${CF}" >> ipsec
540 | /usr
/bin
/perl
-M'Digest::MD5 qw(md5_hex)' -l -n -e '
541 if (/^(\s+shared_secret\s+use\s+)"?([^\s;"]+)"?(.*)/) {
542 printf "%s[MD5:%s]%s\n", $1, md5_hex($2 . "\n"), $3;
551 # Kerberos configuration
553 if [ -x /usr
/bin
/klist
]; then
555 echo "# klist --verbose --all-content" >> kerberos
557 klist
--verbose --all-content >> kerberos
2>&1
560 echo "# ktutil list" >> kerberos
562 ${PRIV} /usr
/sbin
/ktutil
--verbose list
>> kerberos
2>&1
565 echo "# gsstool list --verbose" >> kerberos
567 /System
/Library
/PrivateFrameworks
/Heimdal.framework
/Helpers
/gsstool list
--verbose >> kerberos
2>&1
573 if [ -x /usr
/sbin
/system_profiler
]; then
574 system_profiler
-xml SPEthernetDataType \
575 SPFibreChannelDataType \
580 SPThunderboltDataType \
582 SPAirPortDataType
> system_profiler.spx
2>/dev
/null
586 # system usage statistics
588 echo -n "" > system
-statistics
590 if [ -x /usr
/bin
/uptime
]; then
591 echo "#" >> system
-statistics
592 echo "# uptime" >> system
-statistics
593 echo "#" >> system
-statistics
594 /usr
/bin
/uptime
>> system
-statistics 2>&1
597 if [ -x /usr
/sbin
/sysctl
]; then
598 echo "#" >> system
-statistics
599 echo "# sysctl -a" >> system
-statistics
600 echo "#" >> system
-statistics
601 /usr
/sbin
/sysctl
-a >> system
-statistics 2>&1
604 if [ -x /usr
/bin
/zprint
]; then
605 echo "#" >> system
-statistics
606 echo "# zprint" >> system
-statistics
607 echo "#" >> system
-statistics
608 ${PRIV} /usr
/bin
/zprint
>> system
-statistics 2>&1
612 # collect executable and plugin info
616 if [ ! -f ${1} ]; then
621 echo "${VERSION}" >> versions
2>&1
624 echo "\tsum: ${SUM}" >> versions
2>&1
627 echo "\tadditional info: ${LSINFO}" >> versions
2>&1
629 echo "" >> versions
2>&1
635 /usr
/libexec
/bootpd \
636 /usr
/libexec
/configd \
637 /usr
/sbin
/mDNSResponder \
642 /usr
/libexec
/InternetSharing \
643 /System
/Library
/Frameworks
/SystemConfiguration.framework
/SystemConfiguration \
646 report_binary_info
"${BIN}"
649 if [ -x /usr
/bin
/xcodebuild
]; then
650 /usr
/bin
/xcodebuild
-showsdks \
652 | awk '{print $NF}' \
655 SDKPATH
="`xcrun --sdk $IOS --show-sdk-path`"
657 /usr
/libexec
/configd_sim \
658 /System
/Library
/Frameworks
/SystemConfiguration.framework
/SystemConfiguration \
661 report_binary_info
"${SDKPATH}${BIN}"
670 cd ${ROOT}/System
/Library
/SystemConfiguration
671 for PLUGIN
in *.bundle
673 plugins
[$num]=$PLUGIN
679 for PLUGIN
in "${plugins[@]}"
681 PLUGIN_DIR
="${ROOT}/System/Library/SystemConfiguration/${PLUGIN}"
682 PLUGIN_INF
=${PLUGIN_DIR}/Contents
/Info.plist
683 if [ ! -f ${PLUGIN_INF} ]; then
684 PLUGIN_INF
=${PLUGIN_DIR}/Info.plist
685 if [ ! -f ${PLUGIN_INF} ]; then
686 echo "${PLUGIN_INF}: No Info.plist" >> versions
2>&1
690 echo "${PLUGIN}" >> versions
2>&1
693 BOOL
=`scutil --get ${PLUGIN_INF} / Enabled 2>/dev/null`
694 if [ $?
-eq 0 ]; then
695 if [ ${BOOL} = "TRUE" ]; then
701 echo "\t${ENABLED}" >> versions
2>&1
704 BOOL
=`scutil --get ${PLUGIN_INF} / Verbose 2>/dev/null`
705 if [ $?
-eq 0 ]; then
706 if [ ${BOOL} = "TRUE" ]; then
710 if [ -n "${VERBOSE}" ]; then
711 echo "\t${VERBOSE}" >> versions
2>&1
714 VERSION
=`scutil --get ${PLUGIN_INF} / CFBundleVersion 2>/dev/null`
715 if [ $?
-eq 1 ]; then
716 VERSION
=`scutil --get ${PLUGIN_INF} / CFBundleShortVersionString 2>/dev/null`
718 echo "\tVersion: ${VERSION}" >> versions
2>&1
720 if [ -f ${PLUGIN_DIR}/Contents
/MacOS
/${PLUGIN%.*} ]; then
721 SUM
=`sum ${PLUGIN_DIR}/Contents/MacOS/${PLUGIN%.*}`
722 echo "\tsum: ${SUM}" >> versions
2>&1
724 LSINFO
=`ls -lu ${PLUGIN_DIR}/Contents/MacOS/${PLUGIN%.*}`
725 echo "\tadditional info: ${LSINFO}" >> versions
2>&1
726 elif [ -f ${PLUGIN_DIR}/${PLUGIN%.*} ]; then
727 SUM
=`sum ${PLUGIN_DIR}/${PLUGIN%.*}`
728 echo "\tsum: ${SUM}" >> versions
2>&1
730 LSINFO
=`ls -lu ${PLUGIN_DIR}/${PLUGIN%.*}`
731 echo "\tadditional info: ${LSINFO}" >> versions
2>&1
734 echo "" >> versions
2>&1
738 if [ -x /usr
/bin
/what
-a -x /usr
/bin
/sum -a -x /bin
/ls ]; then
744 # Last thing is to collect the logs to give a chance for networkd and mDNSResponder
745 # to finish dumping their state
749 # system log, kernel.log, early boot log messages
751 if [ -x /usr
/bin
/syslog
]; then
752 # save the recent activity
753 ${PRIV} /usr
/bin
/syslog
| ${TAIL_25000} > syslog
755 # save just the "kernel" activity (in case some of the
756 # interesting/relevant message are before the messages
758 ${PRIV} /usr
/bin
/syslog
-k Facility kern
| ${TAIL_25000} > kernel
760 if [ -d /var
/log
/DiagnosticMessages
]; then
761 # save any MessageTracer activity
762 ${PRIV} /usr
/bin
/syslog
-d /var
/log
/DiagnosticMessages \
765 | ${TAIL_25000} > DiagnosticMessages
768 if [ -f /var
/log
/system.log
]; then
769 ${PRIV} ${TAIL_25000} /var
/log
/system.log
> system.log
771 if [ -f /var
/log
/kernel.log
]; then
772 ${PRIV} ${TAIL_25000} /var
/log
/kernel.log
> kernel.log
775 if [ -x /sbin
/dmesg
]; then
776 ${PRIV} /sbin
/dmesg
> dmesg
780 # IPConfiguration log
782 if [ -f /var
/log
/com.apple.IPConfiguration.bootp
]; then
783 ${PRIV} ${TAIL_2000} /var
/log
/com.apple.IPConfiguration.bootp \
784 > com.apple.IPConfiguration.bootp
790 scutil
<<_END_OF_INPUT \
794 if (index($2, "/") == 1) { print $2 } \
795 else { print "/var/log/ppp/" $2 } \
798 print "/tmp/pppotcp.log" \
804 show Setup:/Network/Service/[^/]+/PPP pattern
808 if [ -f "${logFile}" ]; then
809 b
="`basename ${logFile}`"
810 cat "${logFile}" > "${b}" 2>&1
815 # application firewall log
817 if [ -f /var
/log
/appfirewall.log
]; then
818 ${PRIV} ${TAIL_2000} /var
/log
/appfirewall.log
> appfirewall.log
821 if [ -x /bin
/ls ]; then
823 # collect crash reports
830 mDNSResponderHelper \
840 /bin
/ls -1 /Library
/Logs
/DiagnosticReports
/${daemon}_
*.crash \
841 /Library
/Logs
/CrashReporter
/${daemon}_
*.crash \
842 /Library
/Logs
/CrashReporter
/${daemon}_
*.plist \
846 if [ -f "${log}" ]; then
847 b
="`basename ${log}`"
848 ${PRIV} cat "${log}" > "${b}" 2>&1
854 # collect any verbose logging output
856 /bin
/ls -1 /Library
/Logs
/CrashReporter
/com.apple.networking.
*.log
* \
860 if [ -f "${log}" ]; then
861 b
="`basename ${log}`"
862 ${PRIV} cat "${log}" > "${b}" 2>&1
869 # collect everything into a single archive
872 tar -c ${GZ_OPT} -f "${ARCHIVE}" "${OUT}"
875 if [ ${UID} -eq 0 ]; then
876 if [ -n "${SUDO_UID}" -a -n "${SUDO_GID}" ]; then
877 if [ ${UID} -ne ${SUDO_UID} ]; then
878 chown
${SUDO_UID}:${SUDO_GID} "${ARCHIVE}"
883 echo "Network data collected to \"${ARCHIVE}\""