Wednesday 30 November 2016

Storage drive appearing as RAW in Windows Server 2008 R2

I faced an issue that a storage drive assigned from DS 3400 was appearing in RAW format.
i was unable to open it, initialize it and it asking every time to format it. as it was not in NTFS format and Windows was unable to open it, RAW format was unknown for it.

Actually the was that, the server was restarted and the IQN was changed of the server due to some issue.
after putting the IQN again in Storage issue was resolved.

The IQN of a server you can find as below.
Open ISCSI initiator and then go to Favorite Targets and there you will see the IQN.

The IQN you will put in below path on the DS3400 storage.
Open DS3400 storage console (i have IBM DS storage Manager 10)--> here you have to open the required storage, -->Host Mappings Tab-->select the required host group--->right click on Drive and select-->select Manage host port Identifiers-->Add Host port identifier information (This value and the value on server should be the same)


P.S: possibility of this is

if you rename the server.
if you change the IP.
if there is network device between SAN and Server which malfunction.


 

Thursday 24 November 2016

The operation couldn't be performed because object 'd7f5dfd8676fd' couldn't be found on 6fd87ere8fy7.prod.outlook.com

The operation couldn't be performed because object 'd7f5dfd8676fd' couldn't be found on 6fd87ere8fy7.prod.outlook.com

Few days back i moved a user from its OU (OU1) which was synchronizing with Office 365 to another OU (OU2) which was not synchronizing with Office 365.
after that i faced few issues with this user, the issue was below.
(1) was unable to receive email but can sent emails, mails for this user were stuck in Queue
(2) in Office 365 admin Center getting errors when checking its properties, which was as below.
The operation couldn't be performed because object 'd7f5dfd8676fd' couldn't be found on 6fd87ere8fy7.prod.outlook.com
(3) in portal.office.com also getting some errors

This issue was resolved in this way

  1. Move this user to another OU (OU2) which was not synching with office 365
  2. Then start ADsync syncing and when it complete
  3. Then move again the user to the old OU (OU1) in which this user was in start.
  4. Then start again the syncing manually
  5. And the issue was resolved.
 

Thursday 17 November 2016

The UMMailboxPolicy policy assigned to the mailbox in the source forest couldn‎'t be mapped to the policy in the target forest

I have hybrid environment with Exchange server 2013 and office 365. i was trying to migrate a mailbox from on premises to office 365. but was getting the following error and migration was failing.
the reason was that the user was enabled for UM and a UM policy was applying on it, which was not exist in office 365. so as a work around i just went to exchange control panel, search this user mailbox and disable the Unified Messaging in Phone and Voice Features, in mailbox feature of this user.
then tried to migrate again and was able to migrate this time.
Unified Messaging: Disabled

Error: MigrationPermanentException: Mailbox ‎'username@domain.com‎‎' in the source forest is currently enabled for Unified Messaging but it can‎'t be enabled for Unified Messaging in the target forest for the following reason: The UMMailboxPolicy policy assigned to the mailbox in the source forest couldn‎'t be mapped to the policy in the target forest. Wasn‎'t able to find a UMMailboxPolicy policy using ‎'‎(SourceForestPolicyNames Equal Dial_Plan Default Policy)‎‎' as a filter in target forest. Please fix the problem or disable the mailbox for Unified Messaging before you try the operation again. --> Mailbox ‎'username@domain.com‎' in the source forest is currently enabled for Unified Messaging but it can‎'t be enabled for Unified Messaging in the target forest for the following reason: The UMMailboxPolicy policy assigned to the mailbox in the source forest couldn‎'t be mapped to the policy in the target forest. Wasn‎'t able to find a UMMailboxPolicy policy using ‎'‎(SourceForestPolicyNames Equal Dial_Plan Default Policy)‎‎' as a filter in target forest. Please fix the problem or disable the mailbox for Unified Messaging before you try the operation again. --> The UMMailboxPolicy policy assigned to the mailbox in the source forest couldn‎'t be mapped to the policy in the target forest. Wasn‎'t able to find a UMMailboxPolicy policy using ‎'‎(SourceForestPolicyNames Equal Dial_Plan Default Policy)‎‎' as a filter in target forest.
Report:
user@domain.com Download the report for this user

Sunday 30 October 2016

how to find system restart time through command in windows operating system

how to find system restart time through command in windows operating system
you can use the following command in command prompt.
systeminfo | find "System Boot Time

Thursday 13 October 2016

how to find drives space on remote machines

you can use the following command in windows power shell, but you need admin rights otherwise you will get access denied error.


get-WmiObject win32_logicaldisk -Computername machinename01

Saturday 6 August 2016

WSUS service stoping again and again after each few minutes and administration console not connecting

I had WSUS server installed on the same server as SCCM primary server.
My issues
  1. WSUS was not stable, it crashed again after few minutes
  2. WSUS administration console did not connect
  3.  In SCCM console the status of Software update point was not healthy

After searching enough i got the following link (https://blogs.technet.microsoft.com/wsus/2016/05/05/the-long-term-fix-for-kb3148812-issues/)
which is relevant to this issue but in my case KB3148812 was not installed and the KB3159706 was installed.
Now to resolve this issue i took the following steps

  1. Deleting the wsus file from (C:\user\username\AppData\Roaming\Microsoft\MMC)
  2. Uninstalling KB3159706
  3. Restarting the server

 my issue was resolved.


In event viewer the following errors found

Log Name:      Application
Source:        Windows Server Update Services
Date:          8/6/2016 7:52:08 PM
Event ID:      7053
Task Category: None
Level:         Error
Keywords:      Classic
User:          N/A
Computer:      SCCMPRSRV.pt.com
Description:
The WSUS administration console has encountered an unexpected error. This may be a transient error; try restarting the administration console. If this error persists,
Try removing the persisted preferences for the console by deleting the wsus file under %appdata%\Microsoft\MMC\.

System.IndexOutOfRangeException -- Index was outside the bounds of the array.
Source
Microsoft.UpdateServices.BaseApi
Stack Trace:
   at Microsoft.UpdateServices.Internal.BaseApi.SoapExceptionProcessor.DeserializeAndThrow(SoapException soapException)
   at Microsoft.UpdateServices.Internal.DatabaseAccess.AdminDataAccessProxy.ExecuteSPGetConfiguration()
   at Microsoft.UpdateServices.Internal.BaseApi.UpdateServerConfiguration.Load()
   at Microsoft.UpdateServices.Internal.ClassFactory.CreateWellKnownType(Type type, Object[] args)
   at Microsoft.UpdateServices.Internal.ClassFactory.CreateInstance(Type type, Object[] args)
   at Microsoft.UpdateServices.Internal.BaseApi.UpdateServer.set_UserSelectedCulture(String value)
   at Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools.TrySetServerCulture(String culture)
   at Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools.SetServerCulture()
   at Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools..ctor(CultureInfo culture, IUpdateServer updateServer)
   at Microsoft.UpdateServices.UI.SnapIn.Common.ServerTools..ctor(ServerSummaryScopeNode serverSummaryScopeNode, SnapInTools snapInTools, IUpdateServer updateServer)
   at Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.ConnectToServer()
   at Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.get_ServerTools()
Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
  <System>
    <Provider Name="Windows Server Update Services" />
    <EventID Qualifiers="0">7053</EventID>
    <Level>2</Level>
    <Task>0</Task>
    <Keywords>0x80000000000000</Keywords>
    <TimeCreated SystemTime="2016-08-06T14:52:08.000000000Z" />
    <EventRecordID>55280</EventRecordID>
    <Channel>Application</Channel>
    <Computer>SCCMPRSRV.pt.com</Computer>
    <Security />
  </System>
  <EventData>
    <Data>The WSUS administration console has encountered an unexpected error. This may be a transient error; try restarting the administration console. If this error persists,
Try removing the persisted preferences for the console by deleting the wsus file under %appdata%\Microsoft\MMC\.

System.IndexOutOfRangeException -- Index was outside the bounds of the array.
Source
Microsoft.UpdateServices.BaseApi
Stack Trace:
   at Microsoft.UpdateServices.Internal.BaseApi.SoapExceptionProcessor.DeserializeAndThrow(SoapException soapException)
   at Microsoft.UpdateServices.Internal.DatabaseAccess.AdminDataAccessProxy.ExecuteSPGetConfiguration()
   at Microsoft.UpdateServices.Internal.BaseApi.UpdateServerConfiguration.Load()
   at Microsoft.UpdateServices.Internal.ClassFactory.CreateWellKnownType(Type type, Object[] args)
   at Microsoft.UpdateServices.Internal.ClassFactory.CreateInstance(Type type, Object[] args)
   at Microsoft.UpdateServices.Internal.BaseApi.UpdateServer.set_UserSelectedCulture(String value)
   at Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools.TrySetServerCulture(String culture)
   at Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools.SetServerCulture()
   at Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools..ctor(CultureInfo culture, IUpdateServer updateServer)
   at Microsoft.UpdateServices.UI.SnapIn.Common.ServerTools..ctor(ServerSummaryScopeNode serverSummaryScopeNode, SnapInTools snapInTools, IUpdateServer updateServer)
   at Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.ConnectToServer()
   at Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.get_ServerTools()</Data>
  </EventData>
</Event>

Wednesday 13 July 2016

Lync Server Front-End service not starting

Today I faced an issue, my Lync server 2010 internal certificate got expired then I have to renew it.
My environment is
I have two FE servers, one Archiving/Monitoring server and one LyncEdge server.
The expired certificate was default certificate of  Lync Front end fool.

Now to renew it I generate CSR on first FE server, I added all the required subject alternate name but lost one (second FE server FQDN),  and get SSL against this CSR from my internal CA.
I download the SSL form CA and copy to first FE server, import it and assign to the service according.
after that I start the "Lync Server Front-End" and it was started without any issue.

Now for second FE server I export form first FE server and import in second FE server and assign as well with out any issue. Then I went to services on this server and tried to start the "Lync Server Front-End" service but was unable to start and was getting the following error in event viewer as well.

Event ID: 14587
Lync Server machine FQDN cannot be located in the default certificate.
Machine FQDN: 'FE02.mydomain.com
Cause: This is a configuration problem.
Resolution:
Make sure the default certificate matches the machine FQDN.


Now start thinking on error description and I decide, lets check FQDN of both servers in the subject alternative names of this renewed SSL.
after checking, it was found that the name of the second FE server was not included as Subject alternative name.
For it I started to renew again the SSL with the above mentioned method but just add the FQDN of the second FE server as well as Subject alternative name in CSR.

Now after adding the FQDN and assigning the new SSL to services on both FE servers I was able to start the "Lync Server Front-End" service without any issue on second FE server as wll.

and in this way my issue was resolved

Saturday 25 June 2016

SCCM

(1)
To find all windows 7 machines in your environment you can use the following query.

select SMS_R_System.NetbiosName,
SMS_R_System.OperatingSystemNameandVersion from 
SMS_R_System where
SMS_R_System.OperatingSystemNameandVersion like "%Workstation 6.1%"
(2)
To find all windows 10 machines in your environment you can use the following query.

select SMS_R_System.NetbiosName,
SMS_R_System.OperatingSystemNameandVersion from 
SMS_R_System where
SMS_R_System.OperatingSystemNameandVersion like "%Workstation 10%"
(3)
To restart a remote computer Remotely

shutdown /m \\computername /s
(4)
Clients are unable to get updates from SCCM 2012,
getting error: "Job error (0x87d00692) received for assignment"
To resolve this issue check the assigned WSUS server, in my case a GPO was applied in which another WSUS was mentioned. after disabling that GPO on client machines, machines were able to get updates.

you can check the assigned WSUS by checking in the following registry key.

HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate

(5)
To check the status of Update deployment you should check the log file "UpdateDeployment " at location "C:\windows\CCM\Logs" on client.
(6)
To show list of installed updates with power shell command:
Get-HotFix | Sort-Object InstalledOn -Descending
7)
To install SCCM client on workgroup computers
ccmsetup.exe smssitecode=abc smsmp=mp.domain.com
To check the current assigned WSUS server to your client machine. go to the following location on client Machine. Start-->run-->gpedit.msc-->local computer policy-->computer configuration-->Administrative templates-->Windows Compunents-->Widows update. then look into "specify intranet Microsoft update service location" here you will see the server and port like "http://SCCM.domain.com:8530"

Wednesday 22 June 2016

How to restore a deleted object in active directory 2008 R2 and Activie Directory 2016 and Exchange Server

If you have deleted any AD object unexpectedly and want to restore it. If you have already enabled the ADRecycleBin then you can do it with the following steps.

First let's check if your recycle bin is enabled or not.
you can check with the following command
Get-ADOptionalFeature -Identity 'Recycle Bin Feature'

The above command will show the complete detail of recycle bin.

Let's it was enabled then you can use the following command to first find the deleted object.
you can use the following to display the deleted object first.
Get-ADObject -Filter {displayName -eq "DisplayNameOfUser"} -IncludeDeletedObjects
or
Get-ADObject -Filter {samaccountname -eq "nawaz.nawaz"} -IncludeDeletedObjects

Now it should show the deleted object to you.
let's you have found the deleted object and now want to restore.

you can use the following command to restore that ID.

Get-ADObject -Filter {displayName -eq "DisplayNameOfUser"} -IncludeDeletedObjects | Restore-ADObject


Note: you may need to add the target path as well in AD 2016, so you may use the following command.

Get-ADObject -Filter {UserPrincipalName -eq "nawaz@domain.com"} -IncludeDeletedObjects | Restore-ADObject -TargetPath "OU=Users,OU=HR,OU=Managementname,DC=domain,DC=com"

Note: if this AD Object/ID have any mailbox then that will be automatically recovered with out any issue. just wait for few minutes.
P.S: Will be better if just copy/past the displayname of the user object to be restored. As it is case sensitive. and the result would not display if you typed lower character instead of upper character. 

Sunday 31 January 2016

UNable to submit CSR and get SSL Certificate from internal CA on windows server 2008 R2

Today i faced an issue, i tried to get certificate against my CSR which i had generated from my Exchange servers 2013 mailbox/cas server.
Now my steps was as below.
first i logged in to mailbox/cas server and from here i generate a CSR and copied that CSR to my CA server. i opened the CA's console and
right click on CA name select All task-->submit new request and select the CSR file.
but i got the below error.

The Request contains no certificate template information. 0x80094801 (-2146875391) Denied by policy Module 0x80094801, the request does not contain a certificate template extension or the certificate template request attribute.

Now i tried few times but no luck. then i tried to submit the request with command prompt.
so i went to the location where my CSR file was placed (C:\SSL).


C:\SSL>Certreq -submit -attrib "certificateTemplate:webserver" certreq.req

and here i was able to submit request and got the required certificate.