<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://t2bwiki.iihe.ac.be/index.php?action=history&amp;feed=atom&amp;title=NewMethodUpdateKernelWorkernodes</id>
	<title>NewMethodUpdateKernelWorkernodes - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://t2bwiki.iihe.ac.be/index.php?action=history&amp;feed=atom&amp;title=NewMethodUpdateKernelWorkernodes"/>
	<link rel="alternate" type="text/html" href="https://t2bwiki.iihe.ac.be/index.php?title=NewMethodUpdateKernelWorkernodes&amp;action=history"/>
	<updated>2026-04-20T09:32:42Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://t2bwiki.iihe.ac.be/index.php?title=NewMethodUpdateKernelWorkernodes&amp;diff=193&amp;oldid=prev</id>
		<title>Maintenance script: Created page with &quot; === Short description of the reboot script === Now, on the workernodes, there is a cron script, written in Perl, that checks if a reboot is needed and if if all the conditio...&quot;</title>
		<link rel="alternate" type="text/html" href="https://t2bwiki.iihe.ac.be/index.php?title=NewMethodUpdateKernelWorkernodes&amp;diff=193&amp;oldid=prev"/>
		<updated>2015-08-26T12:28:51Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot; === Short description of the reboot script === Now, on the workernodes, there is a cron script, written in Perl, that checks if a reboot is needed and if if all the conditio...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&lt;br /&gt;
=== Short description of the reboot script ===&lt;br /&gt;
Now, on the workernodes, there is a cron script, written in Perl, that checks if a reboot is needed and if if all the conditions are met in order to reboot safely. Here is the checklist done by the script :&lt;br /&gt;
*node must be offline;&lt;br /&gt;
*kernel release in &amp;quot;uname -r&amp;quot; is different from default kernel in /etc/grub.conf;&lt;br /&gt;
*node must be drained.&lt;br /&gt;
If all these conditions are fullfilled, then a &amp;quot;reboot&amp;quot; command is issued.&lt;br /&gt;
=== The new recipe to update kernel on the workernodes ===&lt;br /&gt;
Normally, in CB9, the kernel update should be done automatically by SPMA-YUM through the usual method of update of repositories. And so, it should not be necessary to specify explicitly a kernel release in the templates. However, due to a bug in the component ncm-grub (versions 14.2 to 14.5), we are in fact obliged to do so, by setting the variable KERNEL_VERSION_NUM in site/global_variables. (Note that it is in fact a nasty trick : it only works because all the machines in CB9 are in SL63.)&lt;br /&gt;
&lt;br /&gt;
In brief, here is the recipe :&lt;br /&gt;
#Update the errata repository for SL.&lt;br /&gt;
 2. Check in the updated repo what is the new kernel release and report the value in KERNEL_VERSION_NUM.&lt;br /&gt;
 3. Adapt the nlist REPO_YUM_SNAPSHOT_DATE in site/global_variables.&lt;br /&gt;
 4. Commit and runcheck.&lt;br /&gt;
 5. Put offline the nodes you want to update.&lt;br /&gt;
 6. Wait...&lt;br /&gt;
&lt;br /&gt;
=== Software environment of the reboot script ===&lt;br /&gt;
The reboot script is deployed through Quattor, thanks to the template :&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
config/reboot_wn&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
For the script to work, the cream server must publish a list of offline workernodes on a webserver. This is done through the template :&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
config/cream_clusterinfo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
If you look at the code of this template, you will see that the list of offine workernodes is copied to the webserver like this :&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp offline_wns.txt quatcli:/var/www/html/clusterinfo/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
So, make sure that the public ssh key of cream is in the .ssh/authorized_keys of quatcli, and do at least on ssh from cream server to the webserver to add the webserver the know_hosts file.&lt;br /&gt;
&lt;br /&gt;
As you don&amp;#039;t want the whole web to access your webserver, you may want to secure it a bit by adding something like this at the end of the httpd.conf :&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;Location /clusterinfo/&amp;gt;&lt;br /&gt;
    Order deny,allow&lt;br /&gt;
    Deny from all&lt;br /&gt;
    Allow from wn.iihe.ac.be&lt;br /&gt;
    Allow from iihe.ac.be&lt;br /&gt;
&amp;lt;/Location&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{TracNotice|{{PAGENAME}}}}&lt;/div&gt;</summary>
		<author><name>Maintenance script</name></author>
	</entry>
</feed>