Solved

Adding a contact to a group using the "Net Group" command

Posted on 2008-10-07
3
281 Views
Last Modified: 2008-10-14
I have a script we use to add users to our DL's.
Net Group groupname Username /Add /Domain

I need to have an external person added to a DL. I thought I could create a "Contact" in AD and then use the "Net Group" command to add that contact to the DL. Is this possible? Has anyone done it successfully?
0
Comment
Question by:ubsoc
  • 2
3 Comments
 
LVL 8

Expert Comment

by:Shmoid
ID: 22663081
Unfortunately, NET GROUP does not recognize an e-mail address, contact display name, nor contact alias. As you know the NET GROUP command expects a username. Because of this I dont think you can use NET GROUP the way you want to with just a contact.

The only way I know of to make it work (but I dont recommend it) is to create a user, but do not create an Exchange mailbox. Once the user is created you can mail enable it, putting in the external e-mail address.

Now you have an actual username to use with NET GROUP but you also have a user account in your AD that really shouldnt be there. You can give the user no rights, make sure the password is strong, you can even disable the account but youd still wind up with a lot of user accounts that are really just contacts. No one is using them no one is monitoring them and it seems like an unnecessary risk. I'm not sure why I say that, it just "feels bad". There are probably plenty of other reasons, besides security, not to create user accounts that are not really users but Ill leave that to somebody else to expand on.

Im guessing that since you are wanting to use a script to add contacts to a distribution list that you are also automating the creation of user/contacts. Otherwise you would simply click the member of tab while creating the external contact and add the appropriate DL. Is that correct?  Perhaps a little more detail about your current method and what you are trying to accomplish will yield a different solution.
0
 
LVL 5

Author Comment

by:ubsoc
ID: 22663180
Your answer is pretty much what I thought. I was just looking for someone to confirm what I thought. We use scripts to repopulate our "Big" DL's everynight from system extracts. Sometimes we need to override the extracts and add people that don't normally get into these extracts.
We use the Net Group method in our scripts and it works perfectly for what we do.
0
 
LVL 8

Accepted Solution

by:
Shmoid earned 500 total points
ID: 22663223
Sorry I couldn't give you the, "Oh sure, just do this" answer.    :-)

I looked around a bit and couldn't find anything else on NET GROUP for external addresses. If you find anything I'd be interested as well.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

TOMORROW TOMORROW.BAT is inspired by a question I get asked over and over again; that is, "How can I use batch file commands to obtain tomorrow's date?" The crux of this batch file revolves around the XCOPY command - a technique I discovered w…
Setting up a Microsoft WSUS update system is free relatively speaking if you have hard disk space and processor capacity.   However, WSUS can be a blessing and a curse. For example, there is nothing worse than approving updates and they just have…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

757 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

21 Experts available now in Live!

Get 1:1 Help Now