3/31/2012

Restoring a deleted Active Directory object using Ldp.exe (Active Directory Recycle Bin) - Windows Server 2008 R2

How to restore objects from AD ind Windows 2008 R2. Things in Windows 2008 Server R2 are different. In Windows 2008 R2 AD there is a new feature called „Active Directory Recycle Bin“.
 
When enabled (see
Enabling Active Directory Recycle Bin - Windows Server 2008 R2), Active Directory Recycle Bin, all link-valued and non-link-valued attributes of the deleted Active Directory objects are preserved and the objects are restored in their entirety to the same consistent logical state that they were in immediately before deletion. For example, restored user accounts automatically regain all group memberships and corresponding access rights that they had immediately before deletion, within and across domains, which, compared with restoring of user account in Windows Server 2003 (previous article), is not the case.

Note:
By default, Active Directory Recycle Bin in Windows Server 2008 R2 is disabled. To enable it, functional level the forest of your AD DS or AD LDS environment must be set to Windows Server 2008 R2, which in turn requires all forest domain controllers or all servers that host instances of AD LDS configuration sets to be running Windows Server 2008 R2.

In a next few steps, I will explain how to restore deleted user account. For restoring I will use LDP.EXE tool (Objects can also be restored using Get-ADObjects and Restore-ADObjects cmdlets of Windows PowerShell).

Let's see how it's done.
Note: You should replace CONTOSO.LOCAL with your own domain and user TEST USER with your own user.

1. In AD DS, we have a user named Test User. The user gets deleted (accidentally or on purpose). In this case, we'll delete the user manually. 

3/27/2012

Add Ribbon features to sharepoin

Download the feature from
http://spribbonvisibility.codeplex.com/

Project Description
This SharePoint 2010 solution allow site administrator to define who can or cannot see the SharePoint ribbon.

In few words
With this solution you can on each site define if the ribbon is display or not for :
*     Everyone
*     Anonymous user
*     for one or many specific SharePoint groups

Screenshots
*  stsadm -o addsolution -filename PATH\ConsultPoint.SharePoint.RibbonVisibility.wsp
*  stsadm -o deploysolution -name ConsultPoint.SharePoint.RibbonVisibility.wsp -allowgacdeployment -immediate
*  Activate the feature named ConsultPoint.SharePoint.RibbonVisibility on your site collection

http://spribbonvisibility.codeplex.com/

Add features to sharepoin

How to deploy a feature On sharepoin
Installation
*  stsadm -o addsolution -filename PATH\the feature name.wsp
*  stsadm -o deploysolution -name the feature name.wsp -allowgacdeployment -immediate
*  Activate the feature named the fuature name on your site collection

3/25/2012

query computers in Active directory

##Make Sure to the following commands on AD and Run as administrator
##How to query inactive computers in AD And increase the View limit
open CMD then
dsquery computer -inactive 8 -limit 400"

### How to disable the inactive computers
OPen CMD then
"dsquery computer -inactive 8 -limit 400| dsmod computer -disabled yes"
###If you need to target a specific OU, simply place DN of the OU after the computer:
"dsquery computer "OU=Build,DC=Domain,DC=com" -inactive 8 | dsmod computer -disabled yes"
dsmove "cn=computer
**************************

To find out detailed information about a user account: net user username 
C:\>net user etbain

********************
###To find out where (which OU) a user account resides in ADS:
dsquery user -samid username


*******************************
##to get the list of users who hasnt been active for the last 16 week
dsquery user -inactive 16 | dsget user -dn
****************************************************
## how to know on whcih DC the users has been authenticated
From Command prompt
ECHO %LOGONSERVER%

restore Deleted Objects from active rdirectory 2008

get-adobject -Filter{Deleted -eq $true -and ObjectClass -eq "user"} -IncludeDeletedObjects | dsquery user -name "*any name"

How to delete auto cashed Auto complete from outlook 2010

How to delete auto cashed Auto complete  from outlook 2010
Go to file -------> options
Go to mail then under send messages empty Auto-complete List ro remove the check box

3/22/2012

Developer dashboard sharepoint 2010

Developer dashboard
Make sure to copy the stsadm to under the c:\
C:\>stsadm -o getproperty -pn developer-dashboard
C:\>Stsadm –o setproperty –pn developer-dashboard –pv ondemand





The you will find a new icon beside the logon name in central admin
To disable the option or enable it
Stsadm –o setproperty –pn developer-dashboard –pv Off
 To display the additional diagnostic information all the time, you use the same com­mands, but instead of specifying ondemand as the developer dashboard type, you provide a command to create an on/off icon that enables and disables the dashboard as needed.
You use the icon to toggle between displaying and hiding additional detailed diag­nostics.
 

3/20/2012

Adobe PDF IFilter Indexing with SharePoint 2010


This note explains how to enable PDF indexing using the Adobe IFilter version 9.0 in Microsoft SharePoint 2010. This note is adapted from the Adobe note explaining how to configure the 64 bit IFilter for SharePoint 2007 (see: http://www.adobe.com/special/acrobat/configuring_pdf_ifilter_for_ms_sharepoint_2007.pdf ).
Now add PDF as a file type:
  • Run Central Administration.
  • Click Manage service applications under “Application Management”:
  • Click the Search Service Application link in the list of applications.
  • Click File Types  under “Crawling” in the left navigation area:
  • Click New File Type.
  • Enter pdf for the “File Name Extension” and click OK.
  • Using Regedit on the server, navigate to
\\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office Server\14.0\Search\Setup\Filters
  •  Right-click the Filters  folder and select New Key. Enter “.pdf” for the key value.
  • Add the following values to this key:
<REG_SZ> Default = <value not set>
<REG_SZ> Extension = pdf
<REG_DWORD> FileTypeBucket = 1
<REG_SZ> MimeTypes = application/pdf

 The key should look like:



  • Navigate to: \\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office Server\14.0\Search\Setup\ContentIndexCommon\Filters\Extension
  •  Right-click the Filters  folder and select New Key. Enter “.pdf” for the key value.
  • Set the “default” value to {E8978DA6-047F-4E3D-9C78-CDBE46041603}
 The key should look like:
You can now add an image to be used for the icon for PDF documents:
  • Add an image (typically gif or png, use Google images to find an example) for the PDF icon to the folder:
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\IMAGES
  •  Open the file docicon.xml from the location:
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\XML
  •  Add a link to map the pdf extension to the image by adding a link like the following to the ByExtension element:
                 <Mapping Key=”pdf” Value=”pdf_icon.gif” OpenControl=”"/>
  •  Finally, issue an IISReset and restart the Windows services “SharePoint Foundation Search V4” and “SharePoint Server Search 1”.









3/13/2012

SMTP error, Mails aren’t received and there are mails in the badmail folder


SMTP error


Mails aren’t received and there are mails in the badmail folder

Download smtpdiag tool;

SMTPDIAG "sender address" "recipient address" [-d external DNS] [/v]

how to remove service application from sharepoint



How to delete service application
------------------------------------
#To retrieve the service application that you want to delete, type the following command:
$spapp = Get-SPServiceApplication -Name "<Service application display name>"

#delete the selected service application
Remove-SPServiceApplication $spapp
#
To delete the selected service application and also delete the service application database
Remove-SPServiceApplication $spapp –RemoveData

How to convert hexa to decimal


The error code does indeed confirm that at least from the CSE's point of view the driver can't be downloaded. If you take the last four hexadecimal digits (the first four are just indicating the provider), convert that to decimal, then punch it into the following command, you can see as much:

Conversion: 0x0BCB = 3019
Command: net helpmsg 3019
Output: The specified printer driver was not found on the system and needs to be downloaded.

I know that's not offering a massive insight into why it's happening, but I figured it still may be worth clarifying which track to pursue.

Cheers,
Lain

In addition, you may also enable the policy processing under the path [Computer Configuration | Policies | Administrative Templates | System | Group Policy | Printers preference extension policy procesing] for client computers.

Enable Audit on SharePoint 2010

You can turn auditing several different ways, if you have SharePoint Server in my opinion I would audit at the document level.  This would require using content types and place auditing on them.  This will give you the freedom to place different auditing on different types of documents.  You set auditing when you create the content type.
This is done from Site Actions... Site Settings... Under Galleries click Site Content Types...
Once here click create...
Name your content type
Set your content types parent, in this clase in the "select parent content type from" drop down click "document content types"
In the parent content type box for this example select document, select a group if you want... click OK
If you have now you should see a link under settings which are for Information Management Policy settings... click this link.
Now you will see a check box for Auditing... select this and the page will reload with you auditing settings.  You would make use of this by now using the content type in a doc lib or which ever type you want.
Another way of setting auditing is to set it at a site collection.
You need to be on the root of your site collection to be able to do this, click on Site Actions... Site settings...
Under Site COllection Administration click Site COllection Audit settings. This will set auditing for the entire site collection.
Good luck,

Event ID: 10016 Source: DistributedCOM, how to know the APPID corresponds to


Event ID: 10016
Source: DistributedCOM
Description:
The application-specific permission settings do not grant Local Launch permission for the COM Server application with CLSID
{24FF4FDC-1D9F-4195-8C79-0DA39248FF48}
 and APPID
{B292921D-AF50-400C-9B75-0C57A7F29BA1}
 to the user NT AUTHORITY\SYSTEM SID (S-1-5-18) from address LocalHost (Using LRPC). This security permission can be modified using the Component Services administrative tool.

APPID {B292921D-AF50-400C-9B75-0C57A7F29BA1} corresponds to the DCOM NAP Agent Service, which in turn is part of the Network Access Protection Agent service.

Search the Registry for the CLSID to determine what product is calling the NAP Agent Service APPID.  In this case the CLSID is the Quarantine Private SHA Binding class, which is a Kaspersky Anti-virus product.
By default the service Network Access Protection Agent is stopped and the Start Type is set to Manual.

Cause:
The DCOM error is being generated because the application’s SHA encryption module is trying to register with the NAP Agent even when NAP is not enabled.  Several applications are known not to verify the NAP Agent is running before attempting to register themselves.

Solution:
Method 1
This DCOM error can be ignored if you don’t use NAP in your current environment. 

Method 2
Enable the Network Access Protection Agent

Method 3
Contact the vendor of the software trying to register with the NAP Agent to see if they have released a fix for this issue

Application Pool error


Application Pool error

Get-SPServiceApplicationPoolRun
Add-SPShellAdmin
Add-SPShellAdmin [-UserName]
Then
Get-SPVisioServiceApplication

For adding access web DB
Enable-SPSessionStateService

Title Missing server side dependencies


Title Missing server side dependencies. 

Explanation
 [MissingWebPart] WebPart class [8d6034c4-a416-e535-281a-6b714894e1aa] is referenced [1] times in the database [WSS_Content_Intranet], but is not installed on the current farm. Please install any feature/solution which contains this web part. One or more web parts are referenced in the database [WSS_Content_Intranet], but are not installed on the current farm. Please install any feature or solution which contains these

Databases running in compatibility range, upgrade recommended



Explanation: The following databases have versions that are older than the current SharePoint software, but are within the backwards compatible range:
User Profile Service Application_SocialDB_cdd2f43ca1c9467abdd0e58c5e3751e5,
Search_Service_CrawlStoreDB_b2dbbbdfbf514a4e96868cec02583d1f,
Search_Service_PropertyStoreDB_daf09cfc46fe4e1cb79b403c44d3ff19,
SearchAppPropertyDB1,
WSS_Content,
WSS_Content_Intranet,
WSS_Content_MYSITE-2011,
Search_Service_Application_DB_fd3133ce2e6f4e46b158a15ce06cada3,
Search_Service_DB_aeaf5a1c95db46e1a73f8f8cd9f0221d,
Managed Metadata Service_c81e807f1ee3477193467cf2d05c2d9d,
User Profile Service Application_ProfileDB_fa386a74a1754112b9baa69d50c816e3,
WSS_Logging.
This cooures when you run new bathces to the Spoint or to the Microsoft Project server
You can find the following
In the status field 

How to solve it
First, try to run this command
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\BIN\psconfigui.exe
This is the product configuration wizard if it succeed then you are done if not then go to the following
Open the Sp powershell

Powershell commands that are useful during SharePoint 2010 Upgrade



3/06/2012

AD 2008 Delegation tricks

AD 2008

Delegation

Go to active directory users and computers
Right click the OU or the Domain the delegate

Add the user or group to be delegated



The create custom delegate


Choose the scope of the task


The choose General and property specific make sure to choose the send as and receive as check box this is new in Window server 2008 then choose the property you want

Finish