Re: [opensuse-factory] SuSEconfig clearance: "CLASS-A" scripts
Christoph Thiel
09/04/06 2:04 PM >>> Hi there,
I was just thinking for all these SuSEconfig scripts, as the problem is their runtime: Couldn't we remember the 'las-run' of such a script and only run it if the timestamp of the file in /etc/sysconfig is newer than the 'last-run'? This test is imho quiet fast and we could leave most of the scripts. And still remove the one's we don't need anymore. Dominique --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-factory+help@opensuse.org
On Mon, 4 Sep 2006, Dominique Leuenberger wrote:
Christoph Thiel
09/04/06 2:04 PM >>> Hi there, I was just thinking for all these SuSEconfig scripts, as the problem is their runtime:
Couldn't we remember the 'las-run' of such a script and only run it if the timestamp of the file in /etc/sysconfig is newer than the 'last-run'? This test is imho quiet fast and we could leave most of the scripts. And still remove the one's we don't need anymore.
That's an optimization that should be implemented in any case. I don't think we will need to keep a "last-run" file, but rather compare the mtime of the sysconfig files with the resulting config files to figure out if we need to run SuSEconfig. Regards Christoph --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-factory+help@opensuse.org
Christoph Thiel wrote:
On Mon, 4 Sep 2006, Dominique Leuenberger wrote:
Christoph Thiel
09/04/06 2:04 PM >>> Hi there, I was just thinking for all these SuSEconfig scripts, as the problem is their runtime:
Couldn't we remember the 'las-run' of such a script and only run it if the timestamp of the file in /etc/sysconfig is newer than the 'last-run'? This test is imho quite fast and we could leave most of the scripts. And still remove the one's we don't need anymore.
That's an optimization that should be implemented in any case. I don't think we will need to keep a "last-run" file, but rather compare the mtime of the sysconfig files with the resulting config files to figure out if we need to run SuSEconfig.
Now, when you are working on it, you can use every chance to speed up the process. The question is what is faster to check, one file "last-run" or mtime on few of them. To write/update "last-run" file we have to use time, too, so where is the optimum. -- Regards, Rajko. --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-factory+help@opensuse.org
Hello, Am Montag, 4. September 2006 13:33 schrieb Christoph Thiel: [...]
That's an optimization that should be implemented in any case. I don't think we will need to keep a "last-run" file, but rather compare the mtime of the sysconfig files with the resulting config files to figure out if we need to run SuSEconfig.
Comparing the mtime of sysconfig and the resulting file won't work reliable. Think about the following scenario: A user first edits a sysconfig file (say "sysconfig/postfix"), then edits the resulting file (main.cf) by hand and runs SuSEconfig afterwards. When comparing timestamps of main.cf and sysconfig/postfix, SuSEconfig will see that main.cf is newer and will not update it. (I expect "touch sysconfig/postfix" advice in the mailinglists ;-) - but this can't be the solution.) While I usually don't like timestamp files and alike, they can prevent some trouble here ;-) Regards, Christian Boltz PS: The above files are only examples and apply to all other generated config files too. --
He Mann, isse krasse, erste Wort: "Kyptographie", isse schon falsch. Was machst du? Uuuhhh. Ist in der Listenkasse noch genug Geld für ein Wörterbuch? [> Ratti und Thorsten Haude in sl-etikette]
To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-factory+help@opensuse.org
participants (4)
-
Christian Boltz
-
Christoph Thiel
-
Dominique Leuenberger
-
Rajko M