I'm trying to manage the pc in my lab with powershell scripts executed by a "master pc" with administrative rights, now i'm able to boot the pc (via wake on lan) and shut down them but i would like to login them with a specific profile (different by occasion); there is a way with powershell to login a specific profile to a remote pc ? Thanks
Related
We are trying to roll out Windows 365 for our organization, with the only piece missing being our core application.
Currently the core application is launched via a shortcut that runs wscript.exe and calls a VBS script. That VBS script opens a terminal based on the login and then launches the EXE. The EXE requires admin permissions for the first run because it has to configure a bunch of printers and other Windows settings.
There are a ton of users, they are not local admins, and there is a lot of turnover, so it is not feasible for us to login to each workstation every time we have to setup a new user.
Is there any good way this can be done? I do not think I can package it up because it calls the application from one of our servers instead of it being a local install.
Created a scheduled task to run the application on startup and new connection.
I'm trying to automate a task using powershell and I need the computer to restart multiple times. I'm doing this by scheduling a job that runs at startup that executes different scripts, and after that I use Restart-Computer to reboot the pc.
My problem is that I want it to be completely autonomous, but right now I need to input username and password at startup to access my profile. I know that if there is a single user on the machine and if it doesn't have a password it gets logged in automatically, but there are two users on the machine. Is there a way to automatically login after a reboot to a pre-selected windows account with powershell? Thanks
EDIT: I also have to execute programs that have a GUI, so I need authentication anyways.
I have a Windows Server 2012 and want to log in to it remotely.
I know that this possible with the Microsoft Remote Desktop program, but I want to do this with cmd, so that im able to create a script. So far I've build up a ssh connection to my server and I'm able to access the command-line tool but I'm not able to start my desired program. It's telling me that I'm logged in with the "LocalSystem". So my question is, how can I log in to my administrator account with cmd?
Edit:
Basically I want to login with my credentials in my own script.
I m a computer teacher in computer lab. I have approxly 30 pc in lab.
I want to enable remote shutdown in all pc.
I have all pc's admin rights. There are no domain in lab.
So I write all pc ip's in one text file.
I used "shutdown -i" command and copy all the ip's and paste it to windows.
But some pc not showdown and some properly shoutdown.
There are access denied error display for some pc shutdown.
My question is I want to make one universal .reg file, that I want to run in every pc and enable remote shutdown in every pc.
Every pc run Windows xp sp3.
There are no registry settings that you can tweak in order to enable remote shutdown.
You just need to provide the correct set of login credentials with the command. But as there is no possibility to send a username and password with this command, you have to do a little trick:
Connect a network share from the remote computer using an user account from the remote PC (also IPC$ works). By doing so, you have authenticated to this PC for further operations. After that, you can send the shutdown command.
I am using it successfully in the exactly same way as described here in a C# program.
For some reason, after performing a system restore, when I try to execute a certain script while logged on using remote desktop, or by connecting to the computer via WMI, the script starts but then it crashes for an unknown reasons.
When I run the script while logged in to the computer as local user - it works just fine.
I checked the permissions of the script, of the the WMI service, nothing...
Any ideas?