lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 30 Oct 2019 22:27:19 -0700
From:   Randy Dunlap <rdunlap@...radead.org>
To:     Bhaskar Chowdhury <unixbhaskar@...il.com>
Cc:     bfields@...ldses.org, yamada.masahiro@...ionext.com,
        michal.lkml@...kovi.net, linux-kbuild@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] scripts: prune-kernel:remove old kernels and modules dir
 from system

On 10/30/19 9:52 PM, Bhaskar Chowdhury wrote:
>>>> That 'rm' doesn't remove any files.  Compare what remove_old_kernel() does.
>>> No,it is not using that function rather take the parameter from the
>>> commandline and get into boot dir match with it and remove it.
>>
>> But it doesn't do that.  I tested it.  It should be more like what
>> rmeove_old_kernel() does:
>>
>>         rm -If vmlinuz-$kernel_ver System.map-$kernel_ver config-$kernel_ver
>>
>> and if not, please explain why not.
> Okay, again some uniformity missing in the code, I would like to your
> suggested method,i.e call remove_old_kernel to do the job instead of depending on individual kernel.

The simplest thing to do is set kernel_version=$kernel_ver
and then call remove_old_kernel().
And set modules_version=$modules_dir_name and call remove_old_modules_dir().

But it would be cleaner to pass a parameter (kernel_version) to the
remove_old_kernel() function and to pass a parameter (modules_dir) to the
remove_old_modules_dir() function.


-- 
~Randy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ