From: Kamalesh B. <kam...@li...> - 2015-05-14 08:17:40
|
Teach snap to ignore deprecated sysctl network files, while gathering information from /proc. Reading deprecated file, throws warnings in /var/log/message like: kernel: process `snap' is using deprecated sysctl (syscall) net.ipv6.neigh.default.retrans_time; Use net.ipv6.neigh.default.retrans_time_ms instead.` Signed-off-by: Kamalesh Babulal <kam...@li...> Cc: Vasant Hegde <heg...@li...> Cc: Nathan Fontenot <nf...@li...> --- scripts/snap | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/scripts/snap b/scripts/snap index dc8abe1..74d2bfb 100755 --- a/scripts/snap +++ b/scripts/snap @@ -142,6 +142,12 @@ my @snap_command_rsxx = ( "rs_cardreport -d 'all'", ); +# Files, which are to be ignored as they are deprecated +my @snap_deprecated_files = ( + "retrans_time", + "base_reachable_time", +); + sub recurse_dir($); # function prototype sub error { @@ -258,6 +264,7 @@ sub recurse_dir ($) { recurse_dir "$dir/$file"; } else { + next if (grep { /$file/ } @snap_deprecated_files); copy "$dir/$file", $outdir."$dir/$file"; } } -- 2.1.2 |
From: Naveen N. R. <nav...@li...> - 2015-05-14 11:00:49
|
On 2015/05/14 01:46PM, Kamalesh Babulal wrote: > Teach snap to ignore deprecated sysctl network files, while > gathering information from /proc. Reading deprecated file, > throws warnings in /var/log/message like: > kernel: process `snap' is using deprecated sysctl (syscall) > net.ipv6.neigh.default.retrans_time; Use net.ipv6.neigh.default.retrans_time_ms instead.` Are you sure you want to ignore these just to prevent those warnings? Those could still be used by older applications and kernel will still effect changes based on these. - Naveen |
From: Kamalesh B. <kam...@li...> - 2015-05-14 15:47:52
|
On 05/14/2015 04:29 PM, Naveen N. Rao wrote: >> Teach snap to ignore deprecated sysctl network files, while >> >gathering information from /proc. Reading deprecated file, >> >throws warnings in /var/log/message like: >> >kernel: process `snap' is using deprecated sysctl (syscall) >> >net.ipv6.neigh.default.retrans_time; Use net.ipv6.neigh.default.retrans_time_ms instead.` > Are you sure you want to ignore these just to prevent those warnings? > Those could still be used by older applications and kernel will still > effect changes based on these. Both retrans_time and retrans_time_ms behave synonymously. i.e., if you modify one file the value gets reflected in another. We can avoid the warning from snap, by copying the non deprecated version and still we could have the required debugging information. Thanks,, Kamalesh. |
From: Naveen N. R. <nav...@li...> - 2015-05-15 05:32:25
|
On 2015/05/14 09:16PM, Kamalesh Babulal wrote: > > > On 05/14/2015 04:29 PM, Naveen N. Rao wrote: > >>Teach snap to ignore deprecated sysctl network files, while > >>>gathering information from /proc. Reading deprecated file, > >>>throws warnings in /var/log/message like: > >>>kernel: process `snap' is using deprecated sysctl (syscall) > >>>net.ipv6.neigh.default.retrans_time; Use net.ipv6.neigh.default.retrans_time_ms instead.` > >Are you sure you want to ignore these just to prevent those warnings? > >Those could still be used by older applications and kernel will still > >effect changes based on these. > > Both retrans_time and retrans_time_ms behave synonymously. i.e., if you > modify one file the value gets reflected in another. > We can avoid the warning from snap, by copying the non deprecated version > and still we could have the required debugging > information. Ah, nice. Assuming we're only skipping these files under /proc/sys and/or chances of similarly named files in paths we care about is none: Acked-by: Naveen N. Rao <nav...@li...> Thanks, Naveen |
From: Kamalesh B. <kam...@li...> - 2015-05-15 06:38:13
|
On 05/15/2015 11:01 AM, Naveen N. Rao wrote: >> >Both retrans_time and retrans_time_ms behave synonymously. i.e., if you >> >modify one file the value gets reflected in another. >> >We can avoid the warning from snap, by copying the non deprecated version >> >and still we could have the required debugging >> >information. > Ah, nice. > Assuming we're only skipping these files under /proc/sys and/or chances > of similarly named files in paths we care about is none: > Acked-by: Naveen N. Rao<nav...@li...> Thanks for the review. AFAIK, both retrans_time and base_reachable_time are network tunable, living under /proc. We might not end up accidentally losing any other diagnostic data, while safely ignoring both of the deprecated files. Thanks, Kamalesh. |