On Wed, 21 Aug 2013 21:09:41 +0100, thegeezer wrote:

> > I posted a script fragment that compares the contents of the kernel's
> > initramfs config file with the live filesystem. Dracut users could use
> > the same method by parsing the output from lsinitrd.

> the script you posted referenced /usr/src/init.cfg -- not sure if this
> is a dracut thing but i don't have that.

It's the kernel's initramfs config file, or at least the location I use
(the location is set in the kernel config)

> i was actually thinking something like the following (warning needs
> work)
> 
> #!/bin/bash
> # get contents of lsinitrd | awk for month,day,time, /filename | list
> the awked filename

There's no need to get the timestamps from the initramfs, just the list
of files. Then you compare the timestamp of the ones in your root
filesystem with the timestamp of the file containing the initramfs. it
saves parsing and comparing all those dates, just use the shell's -nt
test. The only difference between using it with Dracut or the kernel's
initramfs is how you generate the file list.


-- 
Neil Bothwick

Press every key to continue.

Attachment: signature.asc
Description: PGP signature

Reply via email to