<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.define-technology.com/mediawiki-1.35.0/index.php?action=history&amp;feed=atom&amp;title=BLCR_Integration</id>
	<title>BLCR Integration - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.define-technology.com/mediawiki-1.35.0/index.php?action=history&amp;feed=atom&amp;title=BLCR_Integration"/>
	<link rel="alternate" type="text/html" href="http://wiki.define-technology.com/mediawiki-1.35.0/index.php?title=BLCR_Integration&amp;action=history"/>
	<updated>2026-05-04T20:14:37Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.0</generator>
	<entry>
		<id>http://wiki.define-technology.com/mediawiki-1.35.0/index.php?title=BLCR_Integration&amp;diff=1428&amp;oldid=prev</id>
		<title>Michael: Created page with &quot;PDD Link to Files: &lt;file&gt;\\srv-vfs2\PDD_DATA\Product Development\High Performance Computing\HPC Software Information\Platform\BLCR Integration|BLCR Integration&lt;/file&gt;  ===== B...&quot;</title>
		<link rel="alternate" type="text/html" href="http://wiki.define-technology.com/mediawiki-1.35.0/index.php?title=BLCR_Integration&amp;diff=1428&amp;oldid=prev"/>
		<updated>2012-12-07T11:53:44Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;PDD Link to Files: &amp;lt;file&amp;gt;\\srv-vfs2\PDD_DATA\Product Development\High Performance Computing\HPC Software Information\Platform\BLCR Integration|BLCR Integration&amp;lt;/file&amp;gt;  ===== B...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;PDD Link to Files: &amp;lt;file&amp;gt;\\srv-vfs2\PDD_DATA\Product Development\High Performance Computing\HPC Software Information\Platform\BLCR Integration|BLCR Integration&amp;lt;/file&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== BLCR 0.8.2 patch for 2.6.18.238.el5 Kernels =====&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Ref: https://upc-bugs.lbl.gov/bugzilla/show_bug.cgi?id=2990&lt;br /&gt;
* Compilation error for BLCR 0.8.2 on 2.6.18-238.el5 kernel (CentOS 5.6):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  .&lt;br /&gt;
  CC [M]  /usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.o&lt;br /&gt;
/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.c:44: warning: type defaults to ￢int￢ in declaration of ￢DECLARE_DELAYED_WORK￢&lt;br /&gt;
/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.c:44: warning: parameter names (without types) in function declaration&lt;br /&gt;
/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.c: In function ￢cr_wd_run￢:&lt;br /&gt;
/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.c:60: error: ￢cr_wd_work￢ undeclared (first use in this function)&lt;br /&gt;
.&lt;br /&gt;
.&lt;br /&gt;
/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.c:93: error: ￢cr_wd_work￢ undeclared (first use in this function)&lt;br /&gt;
gmake[5]: *** [/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild/cr_watchdog.o] Error 1&lt;br /&gt;
gmake[4]: *** [_module_/usr/src/redhat/BUILD/blcr-0.8.2/builddir/cr_module/kbuild] Error 2^&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The folowing patch/changes is needed for BLCR 0.8.2 to compile with 2.6.18-238.el5 kernel&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
File: cr_watchdog.c (line 35):&lt;br /&gt;
&lt;br /&gt;
--- cr_module/cr_watchdog.c     21 Aug 2008 05:22:49 -0000      1.7&lt;br /&gt;
+++ cr_module/cr_watchdog.c     17 Feb 2011 19:42:05 -0000&lt;br /&gt;
@@ -32,7 +32,7 @@&lt;br /&gt;
 // Interval for the watchdog to wakeup HZ = 1s&lt;br /&gt;
 #define CR_WD_INTERVAL (HZ)&lt;br /&gt;
&lt;br /&gt;
-#if HAVE_STRUCT_DELAYED_WORK&lt;br /&gt;
+#if HAVE_STRUCT_DELAYED_WORK &amp;amp;&amp;amp; defined(DECLARE_DELAYED_WORK)&lt;br /&gt;
   typedef struct work_struct * cr_work_arg_t;&lt;br /&gt;
   #define CR_DECLARE_DELAYED_WORK DECLARE_DELAYED_WORK&lt;br /&gt;
 #else /* struct work_struct */&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Install kernel source on Compilation Nodes ===== &lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
kusu-ngedit&lt;br /&gt;
(added kernel-devel and kernel-headers)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Install BLCR from source =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
tar zxvf blcr-0.8.2.tar.gz&lt;br /&gt;
make --enable-test &amp;lt;== should it be ./configure --enable-test ??&lt;br /&gt;
make insmod&lt;br /&gt;
make check&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Install BLCR from SRC RPM =====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;NOTE&amp;lt;/b&amp;gt; I had to edit the .spec file to remove all mentions of multilib, libdir32 etc&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
rpm -Uvh blcr-0.8.2-1.src.rpm&lt;br /&gt;
cd /usr/src/redhat/SPECS&lt;br /&gt;
# edit spec file to remove mentions of whatever, see diff below&lt;br /&gt;
# remove all references to: libdir32&lt;br /&gt;
rpmbuild -bb blcr-0.8.2.spec&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Add RPMs to Platform Repo =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
# Copy the RPMs to the contrib dir&lt;br /&gt;
cp /usr/src/redhat/RPMS/x86_64/blcr* /depot/contrib/1000&lt;br /&gt;
# Update the repo DB&lt;br /&gt;
kusu-repoman -u -r centos-5.4-x86_64&lt;br /&gt;
# Add BLCR packages to the installer group and centos group&lt;br /&gt;
kusu-ngedit&lt;br /&gt;
&lt;br /&gt;
# if you dont automatically update the node, then run:&lt;br /&gt;
kusu-cfmsync -n &amp;#039;installer-centos-5.4-x86_64&amp;#039; -p -f&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Adding BLCR echkpnt files to the PCM LSF directory =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
chmod 755 *.blcr&lt;br /&gt;
cp echkpnt.blcr $LSF_SERVERDIR&lt;br /&gt;
cp erestart.blcr $LSF_SERVERDIR&lt;br /&gt;
&lt;br /&gt;
# copy to the node image CFM directory&lt;br /&gt;
mkdir /etc/cfm/compute-centos-5.4-x86_64/$LSF_SERVERDIR -p&lt;br /&gt;
# not needed if you RPM install on the headnode: mkdir /etc/cfm/installer-centos-5.4-x86_64/$LSF_SERVERDIR -p&lt;br /&gt;
&lt;br /&gt;
# sync the files&lt;br /&gt;
kusu-cfmsync -f&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Disable Prelinking on Nodes =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
set the following in file: /etc/sysconfig/prelink&lt;br /&gt;
PRELINKING=no&lt;br /&gt;
&lt;br /&gt;
mkdir /etc/cfm/[node_group]/etc/sysconfig -p&lt;br /&gt;
&lt;br /&gt;
ln -s /etc/sysconfig/prelink /etc/cfm/compute-centos-5.4-x86_64/etc/sysconfig/prelink &lt;br /&gt;
ln -s /etc/sysconfig/prelink /etc/cfm/[any_other_node_groups]/etc/sysconfig/prelink &lt;br /&gt;
&lt;br /&gt;
kusu-cfmsync -f&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Using LSF with BLCR =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
# submit a job then with:&lt;br /&gt;
bsub -k &amp;quot;/home/viglen/job/mychkpntdir method=blcr 60&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# checkpoint the job&lt;br /&gt;
bchkpnt JOBID (as per lsf/bjobs output)&lt;br /&gt;
bchkpnt -k JOBID (kill the job upon successful checkpointing&lt;br /&gt;
&lt;br /&gt;
# restart the job&lt;br /&gt;
brestart /home/viglen/job/mychkpntdir JOBID&lt;br /&gt;
or if that gives you jip, -f it&lt;br /&gt;
brestart -f /home/viglen/job/mychkpntdir JOBID&lt;br /&gt;
&lt;br /&gt;
# migrate a job&lt;br /&gt;
bmig -m node_to_move_job_to JOBID&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===== Debugging it =====&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
Test blcr on individual nodes:&lt;br /&gt;
cr_run app&lt;br /&gt;
cr_checkpoint [--kill] [app_ps_id]&lt;br /&gt;
cr_restart context.ps_id&lt;br /&gt;
&lt;br /&gt;
export OMP_NUM_THREADS=1 (blcr didnt work on multi-threaded apps)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
# ###################################&lt;br /&gt;
# spec diff on the multilib spec file&lt;br /&gt;
# ###################################&lt;br /&gt;
[root@master SPECS]# diff blcr-0.8.2.orig blcr-0.8.2.spec&lt;br /&gt;
55,65d54&lt;br /&gt;
&amp;lt; # Are we building both 32- and 64-bit libcr?&lt;br /&gt;
&amp;lt; %define build_libdir32 0&lt;br /&gt;
&amp;lt; %ifarch x86_64 ppc64&lt;br /&gt;
&amp;lt;   %define build_libdir32 %{is_enabled 1 multilib}&lt;br /&gt;
&amp;lt; %endif&lt;br /&gt;
&amp;lt;&lt;br /&gt;
&amp;lt; # Where to put 32-bit libs on a 64-bit platform&lt;br /&gt;
&amp;lt; %if %{build_libdir32}&lt;br /&gt;
&amp;lt;   %define libdir32 %(echo %{_libdir} | sed -e s/lib64/lib/)&lt;br /&gt;
&amp;lt; %endif&lt;br /&gt;
&amp;lt;&lt;br /&gt;
125d113&lt;br /&gt;
&amp;lt;       %{?libdir32:--enable-multilib} \&lt;br /&gt;
224,231d211&lt;br /&gt;
&amp;lt; %if %{build_shared} &amp;amp;&amp;amp; %{build_libdir32}&lt;br /&gt;
&amp;lt; %{libdir32}/libcr.so.0&lt;br /&gt;
&amp;lt; %{libdir32}/libcr.so.0.5.2&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_run.so.0&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_run.so.0.5.2&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_omit.so.0&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_omit.so.0.5.2&lt;br /&gt;
&amp;lt; %endif&lt;br /&gt;
262,266d241&lt;br /&gt;
&amp;lt; %if %{build_libdir32}&lt;br /&gt;
&amp;lt; %{libdir32}/libcr.la&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_run.la&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_omit.la&lt;br /&gt;
&amp;lt; %endif&lt;br /&gt;
273,277d247&lt;br /&gt;
&amp;lt; %if %{build_shared} &amp;amp;&amp;amp; %{build_libdir32}&lt;br /&gt;
&amp;lt; %{libdir32}/libcr.so&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_run.so&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_omit.so&lt;br /&gt;
&amp;lt; %endif&lt;br /&gt;
284,288d253&lt;br /&gt;
&amp;lt; %if %{build_static} &amp;amp;&amp;amp; %{build_libdir32}&lt;br /&gt;
&amp;lt; %{libdir32}/libcr.a&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_run.a&lt;br /&gt;
&amp;lt; %{libdir32}/libcr_omit.a&lt;br /&gt;
&amp;lt; %endif&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Michael</name></author>
	</entry>
</feed>