Solved

Sharepoint farm secret phrase reset

Posted on 2013-01-11
11
2,040 Views
Last Modified: 2013-01-14
Hello Experts,

I need to connect to a SP farm which was created by default on the SBS 2011 Standard installation and I do not know the secret phrase...

I found a way with SP Management Shell to reset that secret Phrase when adding a second server to that farm but I need to be already connected to that farm.

Here is the result :
$passphrase = ConvertTo-SecureString -asPlainText -Force
*****************************
Set-SPPassPhrase -PassPhrase $passphrase -Confirm
cmdlet Set-SPPassPhrase at command pipeline position 1
Supply values for the following parameters:
ConfirmPassPhrase: *****************************
Set-SPPassPhrase : Cannot access the local farm. Verify that the local farm is
properly configured, currently available, and that you have the appropriate per
missions to access the database before trying again.
At line:1 char:17
+ Set-SPPassPhrase <<<<  -PassPhrase $passphrase -Confirm
    + CategoryInfo          : InvalidData: (Microsoft.Share...etSetPassPhrase:
   SPCmdletSetPassPhrase) [Set-SPPassPhrase], SPCmdletException
    + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletSetPassP
   hrase

I have the permissions to access the database in SQL Management Studio.

Is there any way to reset that secret phrase before to connect to the farm with the SP Wizard ?

Thank you in advance for your help !
0
Comment
Question by:jet-info
  • 4
  • 4
  • 3
11 Comments
 
LVL 30

Expert Comment

by:Brad Howe
ID: 38766886
It is a permissions issue for sure.

1. Make sure you are logged in as the FarmAdministrator account
2. Starting Powershell in elevated admin rights "Run As Administrator"
3. Open Sharepoint 2010 Management Shell and execute the following :
         Get-SPShellAdmin
    The account you are execute from should be listed. If not this is why.

Let us know,
Hades666
0
 
LVL 38

Expert Comment

by:Justin Smith
ID: 38766915
Are you running this from the new server, or from a server in the existing SBS farm?  If the new server, that would explain the error...you can't connect to a farm that doesn't exist.

The permission that Hades posted is also a possibility.  You must have certain db roles on the config database (and any content db you want to run against) in order to execute PowerShell commands against it.  If you see that your account doesn't have it you can run Add-SPShellAdmin -UserName domain\user   - which will add the account to the config db.
0
 

Author Comment

by:jet-info
ID: 38767038
I think there is a lack of information from me.

I had a working SP Foundation 2010 farm installed by default by SBS 2011 Std and somebody uninstalled SPF... We don't have a valid backup before that incident ! I know, I know...
Now I re-installed SPF and I want to connect to the previous farm but I do not know the secret phrase because I didn't installed it, it was installed by default on SBS 2011 std.
I can connect to the Sharepoint DB with my admin credentials (in SQL management Studio and with the SP wizard) but I am blocked by the secret phrase.

In that scenario, do you know a way to go forward ?
0
 
LVL 38

Expert Comment

by:Justin Smith
ID: 38767054
In that case, there is no way to recover the passphrase.  You'll need to create a new farm and reconnect all your content and svc app databases.

http://mikessharepoint.wordpress.com/2012/02/22/forgot-farm-passphrase-to-the-only-sharepoint-server-recreate-farm-walkthrough/


______________________________________________________
Follow me on Twitter!  @justinsmith317
0
 
LVL 30

Expert Comment

by:Brad Howe
ID: 38767073
That is correct. Start fresh and attach content DBs.  with a valid backup of your config DBs you are lost.

Sorry ;/
Hades666
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:jet-info
ID: 38767152
I don't need previous Config DB, I was at the start point of my work.
The problem is that I can't even create a new farm :

1. Start the SharePoint Products Configuration Wizard as administrator. (Click Yes to reset services warning)
2. Create a new server farm -> Next
3. Specify all same settings, except input a new SharePoint Config database name. Instead of ‘SharePoint_Config’, I input ‘SharePoint_Config2'.
4. Write down a passphrase and remember it.
5. Specify port number (I leave this unchecked) and Choose NTLM or Negotiate (NTLM is most common).
6. Review the settings and Click Next to confirm.
7. Click Finish if the Configuration is successful. If not, check your logs.

An error occurs at 3/10 but the log is so big that I do not know where or what to find...
0
 
LVL 38

Expert Comment

by:Justin Smith
ID: 38767175
Do you have proper permissions on the SQL instance?  Must have at least dbcreator and securityadmon permissions.
0
 
LVL 30

Expert Comment

by:Brad Howe
ID: 38767199
Search your log for "ERR " and paste the results here.

Thanks,
Hade666
0
 

Author Comment

by:jet-info
ID: 38767462
I can log in SP DB but can't add dbcreator and securityadmon permissions with my two admin accounts...
I can see a login named "sa" with SQL credentials, it must had make by SBS install...?

I give you the log errors in a moment, my VM has just crashed with very stranged display... like graphics card failure...
0
 
LVL 38

Accepted Solution

by:
Justin Smith earned 500 total points
ID: 38767497
Uh oh.  If you have no current sysadmin accounts, it's a pain.  I've had to use this before:

http://sqlserver-help.com/2012/02/08/help-i-lost-sa-password-and-no-one-has-system-administrator-sysadmin-permission-what-should-i-do/
0
 

Author Closing Comment

by:jet-info
ID: 38773765
Thank you so much for you very useful link !

I followed it and it works perfectly now !
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now