hidden hit counter
Welcome to WindowsForumz.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

LDAP Query

 
   Win 2000/NT/98/ME (Home) -> Active Directory RSS
Next:  OE Stationary - How To ??? Having trouble  
Author Message
Anzelem

External


Since: Feb 07, 2008
Posts: 2



(Msg. 1) Posted: Thu Feb 07, 2008 1:40 am
Post subject: LDAP Query
Archived from groups: microsoft>public>win2000>active_directory (more info?)

I want to make a LDAP Query in Windows 2000 based Active Directory to get a
list of people who logs to a certain workstation an dthe total number. How do
i do this?
--
Ansy

 >> Stay informed about: LDAP Query 
Back to top
Login to vote
Richard Mueller [MVP]

External


Since: Dec 04, 2007
Posts: 17



(Msg. 2) Posted: Thu Feb 07, 2008 6:59 am
Post subject: Re: LDAP Query [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Ansy wrote:

>I want to make a LDAP Query in Windows 2000 based Active Directory to get a
> list of people who logs to a certain workstation an dthe total number. How
> do
> i do this?
> --
> Ansy

Active Directory does not keep track of which users log into which
workstations. Active Directory does not even know who currently is logged
into which workstation.

I believe there is no way to determine (after the fact) how many times a
user has logged into a workstation. You might be able to tell which users
have logged into a particular computer using WMI to retrieve information on
the profiles saved on the machine.

You could use logon scripts to log the user and computer name to a shared
log file. This would allow you to tell which users logged into any
workstation, and the number of times. I have an example VBScript logon
script linked here:

http://www.rlmueller.net/Logon5.htm

--
Richard Mueller
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
--

 >> Stay informed about: LDAP Query 
Back to top
Login to vote
Anzelem

External


Since: Feb 07, 2008
Posts: 2



(Msg. 3) Posted: Thu Feb 07, 2008 6:59 am
Post subject: Re: LDAP Query [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

--
Ansy


"Richard Mueller [MVP]" wrote:

> Ansy wrote:
>
> >I want to make a LDAP Query in Windows 2000 based Active Directory to get a
> > list of people who logs to a certain workstation an dthe total number. How
> > do
> > i do this?
> > --
> > Ansy
>
> Active Directory does not keep track of which users log into which
> workstations. Active Directory does not even know who currently is logged
> into which workstation.
>
> I believe there is no way to determine (after the fact) how many times a
> user has logged into a workstation. You might be able to tell which users
> have logged into a particular computer using WMI to retrieve information on
> the profiles saved on the machine.
>
> You could use logon scripts to log the user and computer name to a shared
> log file. This would allow you to tell which users logged into any
> workstation, and the number of times. I have an example VBScript logon
> script linked here:
>
> http://www.rlmueller.net/Logon5.htm
>
> --
> Richard Mueller
> Microsoft MVP Scripting and ADSI
> Hilltop Lab - http://www.rlmueller.net
> --
>
>
>

Oops, I think you missed me here, you can assign which workstation/computer
to log on to in the AD. On a User Profile>Properties>Account tab>LOG
ON TO button>you can specify which computer to log onto this Domain from.
In my case i did this for several users specifying certain TERMINAL SERVERS.

I now need an LDAP query to give me a list of users who logs to a certain
computer (e.g SERVER1)???
 >> Stay informed about: LDAP Query 
Back to top
Login to vote
Richard Mueller [MVP]

External


Since: Dec 04, 2007
Posts: 17



(Msg. 4) Posted: Thu Feb 07, 2008 10:53 am
Post subject: Re: LDAP Query [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

"Anzelem" <Anzelem.TakeThisOut@discussions.microsoft.com> wrote in message
news:408C4EC3-34FC-4067-BD3F-BFE67F92ADA9@microsoft.com...
>
> --
> Ansy
>
>
> "Richard Mueller [MVP]" wrote:
>
>> Ansy wrote:
>>
>> >I want to make a LDAP Query in Windows 2000 based Active Directory to
>> >get a
>> > list of people who logs to a certain workstation an dthe total number.
>> > How
>> > do
>> > i do this?
>> > --
>> > Ansy
>>
>> Active Directory does not keep track of which users log into which
>> workstations. Active Directory does not even know who currently is logged
>> into which workstation.
>>
>> I believe there is no way to determine (after the fact) how many times a
>> user has logged into a workstation. You might be able to tell which users
>> have logged into a particular computer using WMI to retrieve information
>> on
>> the profiles saved on the machine.
>>
>> You could use logon scripts to log the user and computer name to a shared
>> log file. This would allow you to tell which users logged into any
>> workstation, and the number of times. I have an example VBScript logon
>> script linked here:
>>
>> http://www.rlmueller.net/Logon5.htm
>>
>> --
>> Richard Mueller
>> Microsoft MVP Scripting and ADSI
>> Hilltop Lab - http://www.rlmueller.net
>> --
>>
>>
>>
>
> Oops, I think you missed me here, you can assign which
> workstation/computer
> to log on to in the AD. On a User Profile>Properties>Account tab>LOG
> ON TO button>you can specify which computer to log onto this Domain from.
> In my case i did this for several users specifying certain TERMINAL
> SERVERS.
>
> I now need an LDAP query to give me a list of users who logs to a certain
> computer (e.g SERVER1)???

Oops, sorry. The attribute is userWorkstations. The value is a comma
delimited list of workstation NetBIOS names. A query for all users that have
a specified workstation ("TestComputer" in this example) specified in their
userWorkstations attribute would be:

(userWorkstations=*TestComputer*)

You need the * wildcard character on both ends. The query may be slow, but
should work. You should be able to use this query in ADUC, View, Filter
Options..., Create custom filter, Customize..., Advanced, and enter the
above LDAP filter. Otherwise, the filter can be used with command line
utilities like adfind or dsquery. To use the filter with ADO in a VBScript
program, see this link:

http://www.rlmueller.net/ADOSearchTips.htm

--
Richard Mueller
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
--
 >> Stay informed about: LDAP Query 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
query regarding ldap - i want sugestion for "how to search the attributes using ldap api"

AD LDAP query (Member of) - I need to get an LDAP query that will display all the users of a particular group (Domain Admins to be exact). I have searched and found several solutions, but most seem to be web or VB based. I need one that I can use in the "Custom Search"...

LDAP Query logs? - Do AD server keep a log of LDAP queries? Can they? I am having an issue with a CF web app that works from an internal dev server but when I test it on a live public webserver it fails. I just would like to see what the queries look like that are coming t...

novice LDAP query help - Wondering if anyone can help me write a pretty basic LDAP query for an LDAP novice. Wanted to return all computers whose cn begins with either NARM or EUUK This is what I have so far and it isn't working (|(cn=euuk*) (cn=narm*)) Thanks, JM -- ..

custom LDAP query - I have ADModify.NET and I am trying to use it to dynamically select all users of a certain group. From my understanding, you should be able to do it through a Custom LDAP Query, but I have been looking on and off all day for an LDAP language reference o...
   Win 2000/NT/98/ME (Home) -> Active Directory All times are: Eastern Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You can edit your posts in this forum
You can delete your posts in this forum
You can vote in polls in this forum

Categories:
 Windows XP
  Win 2000/NT/98/ME
 Windows Vista!


[ Contact us | Terms of Service/Privacy Policy ]