Solved

DSCommands

Posted on 2014-01-15
2
118 Views
Last Modified: 2014-01-28
I will like to use dsquery or dsget command to find a DN for user.  I know I find this information from a machine using the current logon  %username% command.  But I like to use this command for a user who machine I am not login into.

This is command I know about  

dsquery * domainroot -filter "(samaccountname%username%)"


This command only works with the current logon users.    I will like to specify a different user and receive his DN.
0
Comment
Question by:JCJohnson76
2 Comments
 
LVL 5

Assisted Solution

by:alicain
alicain earned 250 total points
ID: 39783870
Hi,

We need to first find the user with a dsquery, then pipe that into a dsget command :
   dsquery user -name the_users_account_name_here | dsget user -dn

Regards,
Alastair
0
 
LVL 40

Accepted Solution

by:
footech earned 250 total points
ID: 39783893
It works even without piping to dsget.
dsquery user -samid someusername
0

Featured Post

Backup Solution for AWS

Read about how CloudBerry Backup fully integrates your backups with Amazon S3 and Amazon Glacier to provide military-grade encryption and dramatically cut storage costs on any platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Hibernate on windows 10 18 173
Group policy not applying 5 104
Server 2008 Not services listed 23 49
Problem to Citrix 2 15
Welcome to my series of short tips on migrations. Whilst based on Microsoft migrations the same principles can be applied to any type of migration. My first tip Migration Tip #1 – Source Server Health can be found here: http://www.experts-exchang…
Remote Apps is a feature in server 2008 which allows users to run applications off Remote Desktop Servers without having to log into them to run the applications.  The user can either have a desktop shortcut installed or go through the web portal to…
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

749 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