"New-MailboxRestoreRequest" issue with hard deleted O365 hybrid account

In hybrid mode with users still managed by on-prem AD with some mailboxes migrated to O365. A users synced O365 account was hard delted by mistake and the user was resync'd  with a new O365 mailbox which has been in use.

"Get-Mailbox -SoftDeletedMailbox" returns the deleted mailbox but running the recover option returns the below error as expected

This mailbox cannot be restored with the Undo-SoftDeletedMailbox cmdlet since the user that was associated with the mailbox has been permanently deleted. You can however recover the contents of this mailbox using the New-MailboxRestoreRequest cmdlet.

Ran the New-MailboxRestoreRequest but I get a source database error as per below, which is a parameter I thought I didn't need as the users O365 account/mailbox was deleted, not one located on the on prem Exchange.

New-MailboxRestoreRequest -sourcestoremailbox "Jaxxx Maxxxxxx_68eeaca40f" -TargetMailbox "James Maxxxxxx"
Cannot process command because of one or more missing mandatory parameters: SourceDatabase.


Did the below to get the Mailbox database

Get-Mailbox -SoftDeletedMailbox | FL Name,Database
Name     : Jxxxx Maxxxxxx_68eeaca40f
Database : EURPR02DG041-db079


and tried a "New-MailboxRestoreRequest" again but get an error telling me the database parameter is wrong

New-MailboxRestoreRequest -sourcedatabase "EURPR02DG041-db079" -sourcestoremailbox "Jxxxx Maxxxxxx_68eeaca40f" -TargetMailbox "James Maxxxxxx"
A parameter cannot be found that matches parameter name 'sourcedatabase'.
    + CategoryInfo          : InvalidArgument: (:) [New-MailboxRestoreRequest], ParameterBindingException
    + FullyQualifiedErrorId : NamedParameterNotFound,New-MailboxRestoreRequest
    + PSComputerName        : outlook.office365.com


Am in a bit of a loop now as, use the parameter and it is wrong, take it out and it says I need it. Would appreciate some advice please.
LVL 1
nchtIT Operations ManagerAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

MaheshArchitectCommented:
Before running restoration cmdlet, obtain deleted mailbox guid with exchange online and then run the restore cmdlet

https://blogs.technet.microsoft.com/jbecks/2018/03/11/o365-exo-restore-and-recover-soft-deleted-mailboxes/

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
nchtIT Operations ManagerAuthor Commented:
Thanks Mahesh. The link gave me the right pointers although I had to substitute -InactiveMailboxOnly for -SoftDeletedMailbox in the command below, as nothing shows for inactive command.  Also had to use the ExchangeGuid for the -TargetMailbox as the Mailbox Name returned errors of multiple entries.

PS C:\> $InactiveMailbox = Get-Mailbox -InactiveMailboxOnly -Identity 44d9503c-8b4d-43c6-b60b-951312dd4535
PS C:\> $InactiveMailbox
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ExchangeOnline

From novice to tech pro — start learning today.