Bug 89870 - [patch] [request] make netif verbose rc.conf toggle
Summary: [patch] [request] make netif verbose rc.conf toggle
Status: Closed Overcome By Events
Alias: None
Product: Base System
Classification: Unclassified
Component: conf (show other bugs)
Version: 6.0-RELEASE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-12-03 01:50 UTC by L. Jason Godsey
Modified: 2024-01-16 06:13 UTC (History)
1 user (show)

See Also:


Attachments
file.diff (170 bytes, patch)
2005-12-03 01:50 UTC, L. Jason Godsey
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description L. Jason Godsey 2005-12-03 01:50:02 UTC
I'm using start_if.fxp0 to add alot of aliases.  I'm not sure why, but
all this output when /etc/rc.d/netif displays verbose ifconfig fxp0 wipes
dmesg, to the extent that only 1 line is present in /var/run/dmesg.boot.

This change makes the verbose output more easily tuned via rc.conf:
netif_verbose="NO"

I believe this behavior is more like /etc/rc.d/ip6addrctl behavior.

Thank you for taking time to consider my request.

Fix: +netif_verbose="YES" # Set to YES to enable verbose configuration messages
+
+
 ##############################################################
 ###  System console options  #################################
 ##############################################################


# Configure the interface(s).
-       network_common ifn_start verbose
+       network_common ifn_start

        if [ -f /etc/rc.d/ipfilter ] ; then
                # Resync ipfilter
@@ -86,12 +86,12 @@
        echo '.'
 }

-# network_common routine verbose
+# network_common routine
 #      Common configuration subroutine for network interfaces. This
 #      routine takes all the preparatory steps needed for configuriing
-#      an interface and then calls $routine. If $verbose is specified,
+#      an interface and then calls $routine. If netif_verbose is specified,
 #      it will call ifconfig(8) to show, in long format, the configured
-#      interfaces. If $verbose is not given, it will simply output the
+#      interfaces. If netif_verbose is not given, it will simply output the
 #      configured interface(s).
 network_common()
 {
@@ -103,7 +103,7 @@
        else
                _func="$1"
        fi
-       [ -n "$2" ] && _verbose=yes
+       checkyesno netif_verbose && _verbose=yes

        # Set the scope of the command (all interfaces or just one).
        #--zNiQfqsBqtiaEryiskUWRhfENuWGpBAr21ePwyzknbnICWNM
Content-Type: text/plain; name="file.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="file.diff"

diff -ur etc.orig/defaults/rc.conf etc/defaults/rc.conf
--- etc.orig/defaults/rc.conf   Fri Dec  2 20:33:17 2005
+++ etc/defaults/rc.conf        Fri Dec  2 20:30:48 2005
@@ -379,6 +379,9 @@
 ip6addrctl_enable="NO" # Set to YES to enable default address selection
 ip6addrctl_verbose="NO"        # Set to YES to enable verbose configuration messages
Comment 1 Doug Barton freebsd_committer freebsd_triage 2006-02-22 02:25:21 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-rc


Bring to the attention of the list
Comment 2 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 07:59:57 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped
Comment 3 Warner Losh freebsd_committer freebsd_triage 2024-01-16 06:13:08 UTC
Thank you for submitting this suggestion. Please accept my apologies for this taking so long to get back to.

However, this patch will no longer apply.
And there's no _verbose anymore in netif and it looks tricky to add it back.

So, if you can rework this with the newer code, please resubmit this.