<?xml version="1.0" encoding="UTF-8"?>

<rss version="2.0"
 xmlns:blogChannel="http://backend.userland.com/blogChannelModule"
>

<channel>
<title>Parallels knowledgebase (KB)</title>
<link>http://kb.parallels.com/</link>
<description>Parallels knowledgebase (KB)</description>
<language>en</language>
<copyright>Copyright 2008 Parallels</copyright>
<pubDate>Wed, 10 Sep 2008 00:00:00 +0600</pubDate>
<lastBuildDate>Wed, 10 Sep 2008 00:00:00 +0600</lastBuildDate>
<webMaster>rt-team@parallels.com</webMaster>

<item>
<title><![CDATA[How to deal with out of sync issues]]></title>
<link>http://kb.parallels.com/en/2247</link>
<description><![CDATA[<div id="article">
	




	<div id="kb" class="kb">
		<div class="article-container">
			<h2 class="title">How to deal with out of sync issues</h2>
			<div class="ab-frame"><div class="bl"><div class="br"><div class="tl"><div class="tr"><!-- frame -->
				<div class="articleProperty">
					<div>Article ID: 2247&nbsp;</div>
					<div>Last Review: Jun,8 2009</div>
					<tr>
						<td>Author: </td>
						<td>Vitaly Filatov</td>
					</tr>
					<br/>
					<tr>
						<td>Last updated by: </td>
						<td>Vitaly Filatov</td>
					</tr>
					<strong>APPLIES TO:</strong>
					<div class="articleApplies">
						<ul>
							<li>Parallels Operations Automation</li>
						</ul>
					</div>
				</div><!-- articleProperty -->
			</div></div></div></div></div><!-- frame -->

			<div class="article-internal-flag"></div>

			<div id="article-content">
				<div class="article-part">
					<h2>Symptoms</h2>
					Some items like webspace, domain, mailbox are shown as being not in sync in POA&nbsp;CP. <br />
				</div>
				<div class="article-part">
					<h2>Cause</h2>
					Most probably, some scheduled activity was not completed successfully. POA schedules various tasks almost for any operation (like provisioning, changing configuration, updating statistics and so on), if such task fails - related objects can be out of sync.<br />&nbsp;
				</div>
				<div class="article-part">
					<h2>Resolution</h2>
					Common way to fix such issues is to find a corresponding failed task in the task manager, fix it and re-run. Please see <a href="http://kb.parallels.com../en/2246">http://kb.swsoft.com/en/2246</a> for general info about dealing with POA tasks.<br /><br /><br /><strong>How to find corresponding failed tasks:<br /></strong><u><strong><br />for a webspace</strong>:<br /></u>&nbsp;&nbsp;&nbsp; Webspace is out of sync when some scheduled operations for its domain service are not performed yet, to check if there are any, one may use the following command (should be executed on POA management node):<br /> <div class="commandline"><code>psql -Uplesk -h`hostname` -c &quot;SELECT ds_id, name, (ops_sheduled - ops_performed) as operations FROM domain_services WHERE hd_id = 123456&quot;</code></div> where 123456 is a webspace ID (available in the CCP). <br /><br />For example:<br /> <div class="commandline"><code>[root@core root]# psql -Uplesk -h`hostname` -c &quot;SELECT ds_id, name, (ops_sheduled - ops_performed) as operations FROM domain_services WHERE hd_id = 123456&quot;<br />&nbsp;ds_id&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; name&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | operations<br />--------+---------------------------+------------<br />&nbsp;188791 | www.d1011.pemprovider.com |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 10<br />(1 row)</code></div><br /> This output shows that there are 10 pending operations (tasks) for domain service 188791, to find related tasks in POA one should copy the ds_id and search in background tasks, filtering by queue name domain_service$ds_id (in our example: <em>domain_service188791</em>).<br /><br />Webspace may be also marked as not in sync if exclusive IP&nbsp;could not be assigned to it and that IP&nbsp;was left in state 'configuring' in POA database. In that case it is needed to find out why POA&nbsp;could not assign exclusive IP&nbsp;to webspace, solve the problem and update POA&nbsp;database - set 'configured_ips.state' to 'A' for the IP&nbsp;address in question.<br /><br /><u><strong>for a DNS domain:</strong><br /></u>&nbsp;&nbsp;&nbsp; POA has only one task for handling DNS updates, it is a periodic task 'Update name servers state' which runs every 10 minutes (by default) and it does not need manual rescheduling. However, it makes sense to check if the task was finished successfully the last time or not. Possible out of sync issues can be caused by three things:<br />&nbsp;&nbsp;&nbsp; a) domain has not ready registrar status (article <a title="article #2255" href="http://kb.parallels.com../en/2255">#2255</a>)<br />&nbsp;&nbsp;&nbsp; b) some DNS records keep failing to propagate to one or all DNS servers (article <a title="article #2256" href="http://kb.parallels.com../en/2256">#2256</a>)<br />&nbsp;&nbsp;&nbsp; c) domain's webspace is not in sync<br /><u><br /><strong>for a Qmail mailbox:</strong><br /></u>&nbsp;&nbsp;&nbsp; QMail related tasks are grouped by Qmail hosting ID and can be found in background tasks by the following queue name: qmail_hosting_$id. This $id can be retrieved from the following command (execute it on POA&nbsp;management node):<br /><div class="commandline"><code>psql -Uplesk -h`hostname` -c &quot;SELECT hosting_id, local_part AS name, operations_count AS operations FROM cqmail_mailnames JOIN cqmail_emails USING(email_id) WHERE mailname_id = 12345&quot;</code></div><br /> where 12345 is a mailbox ID from the CCP.<br /><br />For example:<br /><div class="commandline"><code>[root@core root]# psql -Uplesk -h`hostname` -c &quot;SELECT hosting_id, local_part AS name, operations_count AS operations FROM cqmail_mailnames JOIN cqmail_emails USING(email_id) WHERE mailname_id = 12345&quot;<br />&nbsp;hosting_id | name&nbsp; | operations<br />------------+-------+------------<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 42213 | sales |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1<br />(1 row)<br /></code></div><br /><br /> In the example above there is one operation for hosting_id 42213 pending - use <em>qmail_hosting_42213</em> as queue name filter in background tasks.<br /><u><br /><strong>for an Exchange mailbox:</strong><br /></u>&nbsp;&nbsp;&nbsp; Usually, it is possible to look-up an Exchange task by a mailbox name (e.g. enter <em>*sales*</em> in the name field in Task Manager &gt;&nbsp;Background Tasks, where <em>sales</em> is a mailbox name). General way is to select such tasks by a domain service, ID can be retrieved from the following command (should be executed on POA&nbsp;management node):<br /><div class="commandline"><code>psql -Uplesk -h`hostname` -c &quot;SELECT ds_id, name, sync_status FROM exch_mailboxes WHERE mailbox_id = 12345&quot;</code></div><br /> where 12345 is a mailbox id, available in the CCP.<br /><br />For example:<br /> <div class="commandline"><code>[root@core ~]# psql -Uplesk -h`hostname` -c &quot;SELECT ds_id, name, sync_status FROM exch_mailboxes WHERE mailbox_id = 5&quot;<br />&nbsp;ds_id | name | sync_status<br />-------+------+-------------<br />&nbsp;&nbsp;&nbsp;&nbsp; 4 | test |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1<br />(1 row)</code></div><br /> Sync status is positive, that means the mailbox is out of sync, related tasks can be found using the following filter as queue name: <em>DomainService*4</em>.<br /><br /><strong><u>for a VPS:</u></strong><u><br /></u>&nbsp;&nbsp;&nbsp; VPS can stuck in creating/stopping/starting/etc states. To find corresponding task for the VPS, one needs to get VPS host ID on the following screen: <em>Top &gt; Service Director &gt; Virtuozzo Manager &gt; VPSs </em>(refer to the <em>ID</em> column)<em>. </em>And locate tasks with the queue name <em>vps*$ID, </em>for example <em>vps*123 </em>for a VPS with host ID 123.<br /><br /><strong>NOTE:</strong> VPS host ID is not the same as ID of VPS on Virtuozzo server, it is internal POA&nbsp;ID of VPS. To locate a task VPS host ID is needed, not ID of VPS&nbsp;on Virtuozzo server.
				</div>
				<div class="keywords"><strong>Keywords:</strong> tasks, sync, pending</div>
			</div>
		</div><!-- article-container -->


			<br/><br/>

			<div id="SubscriptionLink24Article" class="subscriptionLink2">
<a href="http://kb.parallels.com/subscriptions/index.html?Type=Article&ArticleID=2247&ArticleLanguage=en&Product=&Category="><img src="http://kb.parallels.com/images/mail.png" width="15" height="15" alt="Subscription for changes to this article"></a>
<a href="http://kb.parallels.com/subscriptions/index.html?Type=Article&ArticleID=2247&ArticleLanguage=en&Product=&Category=">Subscription for changes to this article</a>

<script type="text/javascript">

$(document).ready(function() {
	$('#SubscriptionLink24Article a').each(function(){
		$(this).click(function(event) {
			event.preventDefault();
			MainPageContentHide();
			$('#subscription').html('');
			$.get('/Stuff/Subscription', {
													'Type' : 'Article',
													'ArticleID' : '2247',
													'ArticleLanguage' : 'en',
													'Product' : '',
													'Category' : ''
												}, function(data) {
																	$('#subscription').html(data);
																	$('#subscription').show();
																	SUBbuildsubmenus_product();
																});
		});
	});
});

</script>

</div>





	</div><!-- kb -->

</div><!-- article -->


]]></description>
<author>Vitaly Filatov</author>
<guid isPermaLink="false">1885 LastUpdated: 2009-06-08 09:42:34</guid>
<pubDate>2007-10-10 05:42:42</pubDate>
</item>
</channel>
</rss>



