<html><body><div style="font-family: trebuchet ms,sans-serif; font-size: 10pt; color: #000000"><div>There should be DNS scripts in the contextualization packages that provide some assignment of DNS.  You should be able to slightly modify a script to pick up that variable you define, i.e.<br></div><div><br></div><div>echo search $searchdomain >> /etc/resolv.conf</div><div><br></div><div>And define the $searchdomain variable in your network template.</div><div><br></div><div><br></div><div>Be advised, I only see this script on the Ubuntu context packages (not RHEL/Cent, but could be added either way)</div><hr id="zwchr"><div style="color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;"><b>From: </b>"jerry steele" <Jerry.Steele@CGG.com><br><b>To: </b>users@lists.opennebula.org<br><b>Sent: </b>Thursday, September 26, 2013 6:42:23 AM<br><b>Subject: </b>[one-users] DNS search domains and rc.local not being read in VMs<br><div><br></div>


<style>
<!--
@font-face
        {font-family:Calibri}
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif"}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline}
span.EmailStyle17
        {font-family:"Calibri","sans-serif";
        color:windowtext}
.MsoChpDefault
        {font-family:"Calibri","sans-serif"}
@page WordSection1
        {margin:72.0pt 72.0pt 72.0pt 72.0pt}
div.WordSection1
        {}
-->
</style>


<div class="WordSection1">
<p class="MsoNormal">Hello,</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">I posted a few days ago about network configuration seemingly not being picked up properly – I think that was mainly due to my contextualisation packages being for the wrong version, and so the context CDROM device wasn’t being mounted.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">So now I have a separate,, but related issue.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">I need to be able to have DNS search domains in my /etc/resolv.conf. I tried to achieve this by adding a SEARCH attribute to the virtual network template, but it doesn’t seem to be picked up (looking in the context scripts, there’s nothing
 there to pick it up, so that’s kind of expected). I then tried to add it in /etc/rc.local, along with some lines to correctly set the hostname based on IP,  but this doesn’t appear to be being picked up either.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Could anyone tell me what might be going wrong here? Could it be the case that rc.local is not being run for some reason at boot? When I test the VM outside ONE, rc.local runs fine…</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Any help greatly appreciated.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Thanks</p>
<p class="MsoNormal"><b><span style="font-size:18.5pt; font-family:"Arial","sans-serif"; color:#0093D0">______</span></b><b><span style="font-size:18.5pt; font-family:"Arial","sans-serif"; color:#6A737B">
</span></b><b><span style="font-size:18.5pt; font-family:"Arial","sans-serif"; color:#8CC63F">______</span></b><b><span style="font-size:18.5pt; font-family:"Arial","sans-serif"; color:#6A737B">
</span></b><b><span style="font-size:18.5pt; font-family:"Arial","sans-serif"; color:#FCB034">______</span></b><b><span style="font-size:18.5pt; font-family:"Arial","sans-serif"; color:#6A737B"></span></b></p>
<p class="MsoNormal"><b><span style="font-family:"Arial","sans-serif"; color:#6A737B"> </span></b></p>
<p class="MsoNormal"><b><span style="font-family:"Arial","sans-serif"; color:#6A737B"> </span></b></p>
<p class="MsoNormal"><b><span style="font-family:"Arial","sans-serif"; color:#6A737B">Jerry Steele</span></b></p>
<p class="MsoNormal"><span style="font-family:"Arial","sans-serif"; color:#6A737B">IT Support Specialist</span></p>
<p class="MsoNormal"><span style="font-family:"Arial","sans-serif"; color:#6A737B">Subsurface Imaging</span></p>
<p class="MsoNormal"><span style="font-size:12.0pt; font-family:"Arial","sans-serif"; color:#6A737B"> </span></p>
<p class="MsoNormal"><span style="font-family:"Arial","sans-serif"; color:#6A737B">CGGVeritas Services (UK) Ltd</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">Crompton Way</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">Crawley</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">W Sussex</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">RH10 9QN</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B"> </span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">T              +44 (0)1293 683264 (Internal: 233264)</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">M             +44 (0)7920 237105</span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B"> </span></p>
<p class="MsoNormal"><span style=""><a href="http://www.cgg.com/" target="_blank"><span style="font-family:"Arial","sans-serif"; color:blue">www.cgg.com</span></a></span><span style="font-family:"Arial","sans-serif"; color:#6A737B"></span></p>
<p class="MsoNormal"><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B"> </span></p>
<p class="MsoNormal"><i><span style="font-size:9.0pt; font-family:"Arial","sans-serif"; color:#6A737B">This email and any accompanying attachments are confidential. The information<br>
is intended solely for the use of the individual to whom it is addressed. Any review,<br>
disclosure, copying, distribution, or use of the email by others is strictly prohibited.</span></i></p>
<p class="MsoNormal"> </p>
</div>
<p class="MsoNormal"><i><span lang="EN-GB" style="font-size:7.0pt; font-family:"Arial","sans-serif"; color:#6A737B">This email and any accompanying attachments are confidential. If you received this email by mistake, please delete<br>
it from your system. Any review, disclosure, copying, distribution, or use of the email by others is strictly prohibited.</span></i></p>


<br>_______________________________________________<br>Users mailing list<br>Users@lists.opennebula.org<br>http://lists.opennebula.org/listinfo.cgi/users-opennebula.org<br></div><div><br></div></div>
<br><html><body><b>NOTICE: Protect the information in this message in accordance with the company's security policies. If you received this message in error, immediately notify the sender and destroy all copies.</b></body></html>

<br></body></html>