Solved

Exchange management shell parameter not found error

Posted on 2007-11-15
6
2,259 Views
Last Modified: 2008-02-21
I have been trying to bulk load users into Exchange 2007.
Environment is a single 2003 server and a single exchange 2007 domain member server.

In the shell command I can run the following

get-user                     - correctly returns all users with and without mailboxs
get-user -organizationalunit users   - correctly returns all users
BUT
get-user - organizationalunit users where-object{$_.RecipientType -eq "User"}
gives error message
A parameter cannot be found that matches parameter name $_.RecipientType -eq "User"

I have been following instructs from exchangepedia.com/blog/2006/12/id-written-about-how-to-bulk-create.html

Any pointers greatfully appreciated. I have also noticed that one of the services I would expect to see is not present in the services list - microsoft exchange management

Thanks

Willy
0
Comment
Question by:wsmyth
  • 4
  • 2
6 Comments
 
LVL 22

Expert Comment

by:ATIG
Comment Utility
what is your over all goal...... if you already doing a get user why add the where-object?

also you can read in from a csv file if you have one.......

you want to read user from an  OU and do what?
0
 

Author Comment

by:wsmyth
Comment Utility
The overall goal is to bulk add the non-mailbox enabled users.
I only posted the first part of the command as this was the part generating the message. The full command
get-user –organizationalUnit users | where-object{$_.RecipientType –eq “User”  Enable-Mailbox –Database “MAILSRV1\Mailbox Database” get-mailbox select name,windowsemailaddress,database

I appreciate there may be other ways of obtaining the same result ie load from CSV but I am concerned that the fact the $_.RecipientType parameter cannot be found is a pointer to something more fundamental being wrong
0
 
LVL 22

Expert Comment

by:ATIG
Comment Utility
use a CSV file to create users.  This command can be used in the same function to create users on one database or distribute them across databases.  An example of the CSV is below the command.  There is two parts to this command.  The first line sets the password for all creations.

$Password=Read-Host "Enter Password" -AsSecureString

Import-Csv csvtest.csv | foreach { New-Mailbox –alias $_.Alias –name $_.Name –UserPrincipalName $_.UPN  â€“Database “ent-labexmb01\mailbox database” –OrganizationalUnit "XXXX" –Password $Password –ResetPasswordOnNextLogon:$true }

This would create them all on one database but with the addition of $.Database after the –database and an additional column in the CSV file you can distribute them.  The CSV file would look like this

Alias,Name,UPN
User1,User 1,user1@dell.com
User2,User 2,user2@dell.com
0
Wish Marketing would stop bothering you?

Is your marketing department constantly asking for new email signature updates? Are they requesting a different design for every department? Do they need yet another banner added? Don’t let it get you down! There is an easy way to manage all of these requests...

 

Author Comment

by:wsmyth
Comment Utility
Try installing sp1
0
 

Author Comment

by:wsmyth
Comment Utility
I have installed SP1 and resolved the error myself.
Thanks
0
 

Accepted Solution

by:
wsmyth earned 0 total points
Comment Utility
As  previously posted I installed SP1 and resolved the issue myself. Can this now be closed?
Thanks
0

Featured Post

Do email signature updates give you a headache?

Constantly trying to correctly format email signatures? Spending all of your time at every user’s desk to make updates? Want high-quality HTML signatures on all devices, including on mobiles and Macs? Then, let Exclaimer solve all your email signature problems today!

Join & Write a Comment

Disabling the Directory Sync Service Account in Office 365 will stop directory synchronization from working.
Follow this checklist to learn more about the 15 things you should never include in an email signature from personal quotes, animated gifs and out-of-date marketing content.
In this video we show how to create a Distribution Group in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >>…
In this video we show how to create a Shared Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Sha…

728 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

11 Experts available now in Live!

Get 1:1 Help Now