Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>PsExec.exe + PsLoggedOn.exe + batch file.</p> <p>Step 1. Download PsExec.exe and put it in a folder.</p> <p>Step 2. Put PsExec.exer and PsLoggedOn.exe in a folder together.</p> <p>Step 3. Determine a network share.</p> <p>Step 4. Create a text file called pc_list.txt with the results of NET VIEW pasted in it (minus the "\" - should be one computer name per line). Basically should be a text with the following:</p> <pre><code>computer1 computer2 computer3 computer4 10.1.1.1 10.2.1.3 10.3.1.4 </code></pre> <p>etc.</p> <p>You can use IP's or Computer names.</p> <p>Step 5. Create a Batch file called PsExec.bat with the following code:</p> <pre><code>"location_of_PsExec.exe"\PsExec.exe @"location_of_text_file"\pc_list.txt -u domain\Admin_username -p password -n 60 -c -f "location_of_runPsLoggedOn.bat"\runPsLoggedOn.bat </code></pre> <p>Step 6. Create another batch file called runPsLoggedOn.bat with the following code:</p> <pre><code>@echo off echo.%computername%&gt;&gt;"location_of_network_share"\userlist.txt PsLoggedOn.exe -x&gt;&gt;"location_of_network_share"\userlist.txt echo.&gt;&gt;"location_of_network_share"\userlist.txt </code></pre> <p>Step 7. Run the PsExec.bat</p> <p>This is really probably not going to be the EXACT answer you're looking for, but this should at least get you pointed in the right direction... I didn't test this out, but I use something similar to get other things done using PsExec.exe. You would want to just write in the code to only output the domain\username to the file on your network share, (from PsLoggedOn.exe -x>>"location_of_network_share"\userlist.txt) because the output is like this: Users logged on locally: domain\user</p> <p>No one is logged on via resource shares.</p> <p>You also might want to find, as far as formatting goes, a way to output that username to a variable so that you could do the following:</p> <pre><code>echo.%computername% %variable_username_from_PsLoggedOn%&gt;&gt;"location_of_network_share"\userlist.txt </code></pre> <p>Anyhow, this should get you started on your way to getting this solved...</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload