| Author | Messages | |
jeromelcruz
Posts:120
 | | 05/19/2010 6:50 PM |
| Michael,
The noted DS* commands are NOT PowerShell commands. Those commands can be run at any CMD prompt if you have installed the Active Directory mgmt tools on your PC/Server. So you should be able to use them (you original note stated you don't have PoSH, but these commands you 'should be able to use...)..
DSQUERY, DSMOD, DSGET, etc.
Jerry Cruz | Group Policies Product Manager | Windows Server and Infrastructure Architecture | Boeing IT
From: xxxxxxxxxxxxxxxx [mailto:xxxxxxxxxxxxxxxx] On Behalf Of Robert Mariani Sent: Tuesday, May 18, 2010 3:13 PM To: xxxxxxxxxxxxxxxx Subject: RE: [gptalk] Script - Anyone have a working script to copy members of an existing group to another group
Alternatively a powershell command I use is:
dsquery group "cn=Source Group, ou=Source OU, dc=contoso ,DC=com" | dsget group -members | dsmod group "cn=Destination Group, ou=Destination OU, dc=contoso, dc=com" -addmbr
Regards,
Robert
From: xxxxxxxxxxxxxxxx [mailto:xxxxxxxxxxxxxxxx] On Behalf Of Craig Buonora Sent: Wednesday, 19 May 2010 6:51 AM To: xxxxxxxxxxxxxxxx Subject: Re: [gptalk] Script - Anyone have a working script to copy members of an existing group to another group
Const ADS_GROUP_TYPE_GLOBAL_GROUP = &H2
Set objOU = GetObject("LDAP://OU=Finance, dc=fabrikam, dc=com")
Set objOldGroup = GetObject("LDAP://CN=Finance Managers, ou=Finance, dc=fabrikam, dc=com")
Set objNewGroup = objOU.Create("Group", "Finance Department")
objNewGroup.sAMAccountName = "financedept"
objNewGroup.groupType = ADS_GROUP_TYPE_GLOBAL_GROUP
objNewGroup.Set Info
For Each objUser in objOldGroup.Member
objNewGroup.Add "LDAP://" & objUser
Next
On Tue, May 18, 2010 at 3:15 PM, Dzikowski, Michael <xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx>> wrote: One AD group to another, yeah.
From: xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx> [mailto:xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx>] On Behalf Of David Radford Sent: Tuesday, May 18, 2010 12:16 PM
To: xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx> Subject: RE: [gptalk] Script - Anyone have a working script to copy members of an existing group to another group
Please clarify, Are you copying members from one for example distribution group in to another?
From: xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx> [mailto:xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx>] On Behalf Of Dzikowski, Michael Sent: 18 May 2010 15:49 To: xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx> Subject: [gptalk] Script - Anyone have a working script to copy members of an exisiting group to another group
Script - Anyone have a working script to copy members of an existing group to another group in AD?
I can't find a working script...anyone got one?
I don't have powershell. Just vbs.
==============================================================================
CONFIDENTIALITY NOTICE: This email contains information from the sender that
may be CONFIDENTIAL, LEGALLY PRIVILEGED, PROPRIETARY or otherwise protected
from disclosure. This email is intended for use only by the person or entity
to whom it is addressed. If you are not the intended recipient, any use,
disclosure, copying, distribution, printing, or any action taken in reliance
on the contents of this email, is strictly prohibited. If you received this
email in error, please contact the sending party by reply email, delete the
email from your computer system and shred any paper copies.
Note to Patients: There are a number of risks you should consider before using
e-mail to communicate with us. See our Privacy Policy and Henry Ford My Health
at www.henryford.com<http://www.henryford.com/> for more detailed information. If you do not believe that
our policy gives you the privacy and security protection you need, do not send
e-mail or Internet communications to us.
==============================================================================
**********************************************************************
This communication is confidential and is intended only for the use of the addressee(s) designated above. If you are not an addressee, you are hereby expressly forbidden to copy, disseminate, distribute or in any other way use this communication.
If you have received this communication in error please email us at xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx> or telephone +44 (0) 0207 486 3661.
We reserve any and all possible rights to privilege in respect of this communication.
We do not accept service by email nor can this or any email from us act as acceptance of an offer to this Company or any member of its group of companies. Pell Frischmann does not authorise any contract to be made using email.
We accept no liability for communications that are either personal in nature or do not relate to the business of Pell Frischmann.
Any file attachments to this communication will have been virus checked prior to transmission, however you should carry out your own virus check before opening.
Accordingly we do not accept liability for any damage or loss that may occur from software viruses that may be attached to this communication.
Pell Frischmann Registered Office: 5 Manchester Square London W1U 3PD
"Pell Frischmann" is the trading name of companies registered in England:
Pell Frischmann Consulting Engineers No. 4403030
Pell Frischmann Consultants No 1777946
**********************************************************************
==============================================================================
CONFIDENTIALITY NOTICE: This email contains information from the sender that
may be CONFIDENTIAL, LEGALLY PRIVILEGED, PROPRIETARY or otherwise protected
from disclosure. This email is intended for use only by the person or entity
to whom it is addressed. If you are not the intended recipient, any use,
disclosure, copying, distribution, printing, or any action taken in reliance
on the contents of this email, is strictly prohibited. If you received this
email in error, please contact the sending party by reply email, delete the
email from your computer system and shred any paper copies.
Note to Patients: There are a number of risks you should consider before using
e-mail to communicate with us. See our Privacy Policy and Henry Ford My Health
at www.henryford.com<http://www.henryford.com/> for more detailed information. If you do not believe that
our policy gives you the privacy and security protection you need, do not send
e-mail or Internet communications to us.
==============================================================================
-- Regards,
Craig M. Buonora SABIC Innovative Plastics CompuCom Systems, Inc. Senior Networking Specialist Operational Leader - Datacenter Team
1 Plastics Avenue Building 59 Pittsfield, MA 01201
T 413.448.6902 D *838-6902 E xxxxxxxxxxxxxxxx<mailto:xxxxxxxxxxxxxxxx>
www.sabic-ip.com<http://www.sabic-ip.com>
| | | |
|
|