<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
h1
        {mso-style-priority:9;
        mso-style-link:"Überschrift 1 Zchn";
        margin-top:24.0pt;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:0cm;
        margin-bottom:.0001pt;
        page-break-after:avoid;
        font-size:14.0pt;
        font-family:"Arial","sans-serif";
        color:black;}
h2
        {mso-style-priority:9;
        mso-style-link:"Überschrift 2 Zchn";
        margin-top:10.0pt;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:0cm;
        margin-bottom:.0001pt;
        page-break-after:avoid;
        font-size:13.0pt;
        font-family:"Arial","sans-serif";
        color:black;}
p.MsoTitle, li.MsoTitle, div.MsoTitle
        {mso-style-priority:10;
        mso-style-link:"Titel Zchn";
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:15.0pt;
        margin-left:0cm;
        mso-add-space:auto;
        border:none;
        padding:0cm;
        font-size:26.0pt;
        font-family:"Arial","sans-serif";
        color:#4A4A48;
        letter-spacing:.25pt;}
p.MsoTitleCxSpFirst, li.MsoTitleCxSpFirst, div.MsoTitleCxSpFirst
        {mso-style-priority:10;
        mso-style-link:"Titel Zchn";
        mso-style-type:export-only;
        margin:0cm;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        border:none;
        padding:0cm;
        font-size:26.0pt;
        font-family:"Arial","sans-serif";
        color:#4A4A48;
        letter-spacing:.25pt;}
p.MsoTitleCxSpMiddle, li.MsoTitleCxSpMiddle, div.MsoTitleCxSpMiddle
        {mso-style-priority:10;
        mso-style-link:"Titel Zchn";
        mso-style-type:export-only;
        margin:0cm;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        border:none;
        padding:0cm;
        font-size:26.0pt;
        font-family:"Arial","sans-serif";
        color:#4A4A48;
        letter-spacing:.25pt;}
p.MsoTitleCxSpLast, li.MsoTitleCxSpLast, div.MsoTitleCxSpLast
        {mso-style-priority:10;
        mso-style-link:"Titel Zchn";
        mso-style-type:export-only;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:15.0pt;
        margin-left:0cm;
        mso-add-space:auto;
        border:none;
        padding:0cm;
        font-size:26.0pt;
        font-family:"Arial","sans-serif";
        color:#4A4A48;
        letter-spacing:.25pt;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoNoSpacing, li.MsoNoSpacing, div.MsoNoSpacing
        {mso-style-priority:39;
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Arial","sans-serif";
        mso-fareast-language:EN-US;}
span.MsoIntenseEmphasis
        {mso-style-priority:21;
        color:#CE1126;
        font-weight:bold;
        font-style:italic;}
span.berschrift1Zchn
        {mso-style-name:"Überschrift 1 Zchn";
        mso-style-priority:9;
        mso-style-link:"Überschrift 1";
        font-family:"Arial","sans-serif";
        color:black;
        font-weight:bold;}
span.berschrift2Zchn
        {mso-style-name:"Überschrift 2 Zchn";
        mso-style-priority:9;
        mso-style-link:"Überschrift 2";
        font-family:"Arial","sans-serif";
        color:black;
        font-weight:bold;}
span.TitelZchn
        {mso-style-name:"Titel Zchn";
        mso-style-priority:10;
        mso-style-link:Titel;
        font-family:"Arial","sans-serif";
        color:#4A4A48;
        letter-spacing:.25pt;}
span.E-MailFormatvorlage23
        {mso-style-type:personal-reply;
        font-family:"Arial","sans-serif";
        color:#646460;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Arial","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=DE link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>Hi Vincenzo<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>Add hacluster to the sudoers file with<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'># visudo<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>And add <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>hacluster    ALL=(ALL) NOPASSWD: ALL<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>at the very end.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>And of course use <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'># sudo ifconfig…<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>Regards<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#646460'>Andreas<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>Von:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Vincenzo Pii [mailto:piiv@zhaw.ch] <br><b>Gesendet:</b> Donnerstag, 23. Oktober 2014 17:51<br><b>An:</b> pacemaker@oss.clusterlabs.org<br><b>Betreff:</b> [Pacemaker] IPaddr resource agent on Illumos<o:p></o:p></span></p><p class=MsoNormal><o:p> </o:p></p><div><p class=MsoNormal>I am trying to run the IPaddr resource agent on an active/passive cluster on Illumos nodes (pacemaker, corosync, crm... built from updated sources).<br clear=all><o:p></o:p></p><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>By reading the example from Saso here <a href="http://zfs-create.blogspot.ch/2013/06/building-zfs-storage-appliance-part-1.html">http://zfs-create.blogspot.ch/2013/06/building-zfs-storage-appliance-part-1.html</a>, this would seem straightforward and this makes me think that I am doing something wrong :)!<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>I patched the IPaddr script to use /usr/bin/gnu/sh and to avoid finding a free interface with \" grep "^$NIC:[0-9]" \" as that is just not the case, but now I am stuck at trying to configure the ip address.<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>This, in the script, is done with ifconfig (something like <o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>    ifconfig e1000g2 inet 10.0.100.4 && ifconfig e1000g2 netmask 255.255.255.0 && ifconfig e1000g2 up<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>).<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>However, the script is run by the hacluster user, which cannot write network configuration settings.<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>To solve this problem, I am now looking at profiles, roles and authorizations, which seems to be a very "user friendly" way to handle permissions in Solaris.<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>My question is: there is no mention of this in Saso's post, or other discussions (even thought old ones) that I've come across today; am I missing something obvious, or this is just the way it has to be?<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>This is how I configure the IPaddr prmitive:<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal># ipadm create-if e1000g2<o:p></o:p></p></div><div><p class=MsoNormal># crm configure primitive frontend_IP ocf:heartbeat:IPaddr params ip="10.0.100.4" cidr_netmask="255.255.255.0" nic="e1000g2"<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>Many thanks,<o:p></o:p></p></div><div><p class=MsoNormal>Vincenzo.<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><p class=MsoNormal>-- <o:p></o:p></p><div><div><p class=MsoNormal>Vincenzo Pii<o:p></o:p></p></div><p class=MsoNormal>Researcher, InIT Cloud Computing Lab<br>Zurich University of Applied Sciences (ZHAW)<br><a href="http://blog.zhaw.ch/icclab" target="_blank"><span style='color:#1155CC'>blog.zhaw.ch/icclab</span></a><o:p></o:p></p></div></div></div></body></html>