<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.technet.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>HPC, Virtualization and Random Thoughts : Linux</title><link>http://blogs.technet.com/gmarchetti/archive/tags/Linux/default.aspx</link><description>Tags: Linux</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>A Hybrid OS Cluster Solution</title><link>http://blogs.technet.com/gmarchetti/archive/2008/06/03/a-hybrid-os-cluster-solution.aspx</link><pubDate>Tue, 03 Jun 2008 22:28:09 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:3065571</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.technet.com/gmarchetti/comments/3065571.aspx</comments><wfw:commentRss>http://blogs.technet.com/gmarchetti/commentrss.aspx?PostID=3065571</wfw:commentRss><description>&lt;p&gt;Thomas Varlet, of Microsoft France, and Dr. Patrice Calegari, of BULL SAS, have written an excellent paper on how to build hybrid clusters, i.e. clusters where 2 or more operating systems can be run at the same time. It is recommended reading, in my opinion, for those of us who use both Linux and Windows HPC solutions. You'll find the paper &lt;a href="https://windowshpc.net/Resources/Documents/Hybrid_OS_Cluster_Solution_HPCS_XBAS.pdf"&gt;here.&lt;/a&gt;&lt;/p&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3065571" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/gmarchetti/archive/tags/HPC/default.aspx">HPC</category><category domain="http://blogs.technet.com/gmarchetti/archive/tags/Virtualization/default.aspx">Virtualization</category><category domain="http://blogs.technet.com/gmarchetti/archive/tags/Windows+Server+2008/default.aspx">Windows Server 2008</category><category domain="http://blogs.technet.com/gmarchetti/archive/tags/Linux/default.aspx">Linux</category></item><item><title>Dual-boot Linux and HPC Server 2008</title><link>http://blogs.technet.com/gmarchetti/archive/2007/12/11/dual-boot-linux-and-hpc-server-2008.aspx</link><pubDate>Wed, 12 Dec 2007 09:20:00 GMT</pubDate><guid isPermaLink="false">d5e57398-b9ef-4490-9955-07cbb4e4a80d:2637835</guid><dc:creator>gmarchetti</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.technet.com/gmarchetti/comments/2637835.aspx</comments><wfw:commentRss>http://blogs.technet.com/gmarchetti/commentrss.aspx?PostID=2637835</wfw:commentRss><description>&lt;p&gt;In the past few weeks I had the pleasure of working with UGS, a division of Siemens that develops engineering product lifecycle management solutions. They were looking for a way to dual-boot an existing Linux cluster into Windows. The process we came up with is summarized here. It is work in progress, so if you find it useful and/or improvable, please let me know.&lt;/p&gt;&lt;p&gt;&lt;b&gt;1. Verify the existing disk layout&lt;/b&gt;&lt;br&gt;Let us suppose that we have a Linux cluster, where all the compute nodes have a typical configuration on the boot disk, i.e. they have a root file system partition and a swap partition. We want to add a partition with server 2008 and boot into either o/s.&lt;br&gt;First, let’s verify the disk layout on Linux. Assuming that /dev/sda is the boot disk, from a “root” prompt, type:&lt;br&gt;&lt;/p&gt;&lt;p&gt;&lt;i&gt;&lt;a href="http://tldp.org/HOWTO/Partition/fdisk_partitioning.html" title="Partitioning with fdisk" mce_href="http://tldp.org/HOWTO/Partition/fdisk_partitioning.html"&gt;fdisk /dev/sda &lt;/a&gt;&lt;br&gt;p&lt;/i&gt;&lt;br&gt;&lt;br&gt;The output lists the partitions on the disk, their starting and ending point, size and type, for instance&lt;br&gt;&lt;/p&gt;&lt;p&gt;&lt;font&gt;&lt;font color="#000000"&gt;&lt;pre class="programlisting"&gt;Device 		Boot    Start   End    Blocks       Id  System&lt;br&gt;/dev/sda1   	*       1	   5034  40435573+ 83  Linux&lt;br&gt;/dev/sda2	        5035     5221    1502046   82  Linux swap / Solaris&lt;/pre&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;b&gt;2. Modify the existing disk layout&lt;/b&gt;&lt;br&gt;At least 20 GB of free disk space are necessary to install Server 2008. If that is not available and the Linux file system has space to spare, the Linux utility parted can be used to resize the Linux partitions. Alas, to resize the boot partition you will need to boot off a “live” Linux cd. If that was necessary on several nodes, it might be quicker just to re-deploy Linux so that it does not take up all the space.&lt;br&gt;If using parted, proceed with caution and remember that the risk of data loss is high. The following example illustrates how to resize a boot partition starting at 32.3kB to 15 GB:&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.gnu.org/software/parted/index.shtml" title="Parted" mce_href="http://www.gnu.org/software/parted/index.shtml"&gt;&lt;i&gt;parted /dev/sda resize 1 32.3kB 15GB&lt;/i&gt;&lt;/a&gt;&lt;br&gt;￼&lt;br&gt;The Linux boot loader, grub, must also be installed on the first sector of the /boot partition itself and not on the master boot record of the disk. The MBR will be overwritten during server 2008 installation. To achieve that, at the Linux root prompt type: &lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;i&gt;&lt;a href="http://www.gnu.org/software/grub/" title="Grub" mce_href="http://www.gnu.org/software/grub/"&gt;grub-install&lt;/a&gt; /dev/sda1&lt;/i&gt;&lt;/p&gt;&lt;p&gt;&lt;i&gt;&lt;/i&gt;&lt;br&gt;&lt;b&gt;3. Install Windows&lt;/b&gt;&lt;br&gt;We assume that the default Windows HPC Server 2008 deployment techniques will be used from its administration console. For more information on those, please refer to the Windows HPC Server 2008 overview video on Technet Edge.&lt;br&gt;When preparing a deployment template with an o/s image in the HPC Server 2008 console, a number of tasks are added automatically. One of those tasks partitions the boot disk, destroying everything in the process. This is achieved by running diskpart /s diskpart.txt where the latter is a script that is copied to the installation environment. It is sufficient to remove the “clean” instruction from such script to avoid the destruction of the Linux partitions.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;i&gt;c:\program files\Microsoft Compute cluster Pack\Data\Installshare\config\diskpart.txt&lt;br&gt;&lt;br&gt;select disk 0&lt;br&gt;-&amp;gt; clean &amp;lt;- REMOVE THIS LINE&lt;br&gt;create partition primary&lt;br&gt;assign letter=c&lt;br&gt;format FS=NTFS label=”Node” QUICK OVERRIDE&lt;br&gt;active&lt;br&gt;exit&lt;/i&gt;&lt;br&gt;&amp;nbsp; &lt;br&gt;Thus, when diskpart is run during the installation of the compute node, a new partition will be created, taking all the available space on the boot disk. The partition will be assigned the drive letter C, formatted and made active for booting. &lt;br&gt;Later during the installation process an unattended setup of server 2008 will be launched, guided by a file called unattend.xml. If the default paths were chosen during installation, this file will be in: &lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;i&gt;c:\program files\Microsoft Compute Cluster Pack\Data\Installshare\unattend.xml&lt;/i&gt;&lt;/p&gt;&lt;p&gt;&lt;i&gt;&lt;/i&gt;&lt;br&gt;Unattend.xml must be edited before starting the HPC Server deployment so that it points to the correct new Windows partition. For instance, if there are two existing Linux partitions, it must point to partition three, which will be created during installation. For that to happen, in the file find the entry: &lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;i&gt;&amp;lt;PartitionID&amp;gt;1&amp;lt;/PartitionID&amp;gt;&lt;/i&gt;&lt;br&gt;&amp;nbsp;and replace it with &lt;br&gt;&lt;i&gt;&amp;lt;PartitionID&amp;gt;3&amp;lt;/PartitionID&amp;gt;&lt;/i&gt;&lt;br&gt;&lt;br&gt;The compute node deployment can then proceed normally and the machine will finally boot under Windows 2008.&lt;br&gt;&lt;br&gt;&lt;b&gt;4. Set the active boot partition&lt;/b&gt;&lt;br&gt;When switching back to Linux from Windows, use diskpart.exe and make the Linux boot partition active. Assuming that it is the first partition on the disk, enter the following commands:&lt;br&gt;&lt;br&gt;&lt;i&gt;diskpart&lt;br&gt;Select disk 0&lt;br&gt;Select partition 1&lt;br&gt;Active&lt;/i&gt;&lt;br&gt;&lt;br&gt;These can be saved into a file and executed via &lt;i&gt;diskpart /s &amp;lt;filename&amp;gt;&lt;/i&gt;&lt;br&gt;Linux will be loaded at the next reboot.&lt;br&gt;&lt;br&gt;Similarly, when switching to Windows, make the Windows boot partition active. Assuming that it is n. 3, at the Linux root prompt type:&lt;br&gt;&lt;br&gt;&lt;i&gt;fdisk /dev/sda&lt;br&gt;a&lt;br&gt;3&lt;br&gt;w&lt;br&gt;&lt;/i&gt;&lt;br&gt;These answers can be stored in a file and passed to fdisk with &lt;i&gt;fdisk /dev/sda &amp;lt; answerfile. &lt;/i&gt;&lt;br&gt;Windows will start at the next reboot&lt;br&gt;&lt;br&gt;In order to execute these commands on a number of nodes remotely, on Windows cluster type:&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;i&gt;Clusrun /nodes:&amp;lt;node1, node2, ...&amp;gt; &amp;lt;command line&amp;gt;&lt;br&gt;&lt;br&gt;&lt;/i&gt;On Linux, a variety of tools are available, e.g. Webmin or simply rsh. &lt;br&gt;&lt;/p&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=2637835" width="1" height="1"&gt;</description><category domain="http://blogs.technet.com/gmarchetti/archive/tags/HPC/default.aspx">HPC</category><category domain="http://blogs.technet.com/gmarchetti/archive/tags/Server+2008/default.aspx">Server 2008</category><category domain="http://blogs.technet.com/gmarchetti/archive/tags/Linux/default.aspx">Linux</category></item></channel></rss>