$ sudo service --status-all | grep -q oijawpawuouzmaomwaoiwadlknasdlknascsc &>/dev/null
[ ? ] hwclock.sh
[ ? ] kmod
[ ? ] plymouth
[ ? ] plymouth-log
$ sudo service --status-all
[ + ] apache-htcacheclean
[ + ] apache2
[ - ] apparmor
[ + ] awslogs
[ - ] console-setup.sh
[ - ] cron
[ - ] dbus
[ ? ] hwclock.sh
[ + ] irqbalance
[ - ] keyboard-setup.sh
[ ? ] kmod
[ + ] php7.2-fpm
[ ? ] plymouth
[ ? ] plymouth-log
[ - ] procps
[ - ] rsync
[ - ] rsyslog
[ + ] udev
[ - ] ufw
[ - ] unattended-upgrades
[ - ] uuidd
[ - ] x11-common
想知道为什么出现带有安静标志的grep输出,将输出发送到dev null还是失败。
对于混乱的东西为何与任何东西匹配我也感到困惑。