Questions tagged [windows-command-prompt]

Refers to the default CLI that ships with all versions of Windows, often shortened to just "command prompt" or cmd (after the file name of the executable).

Refers to the default CLI that ships with all versions of Windows, often shortened to just "command prompt" or cmd (after the file name of the executable).

383 questions
0
votes
1 answer

Delete all .bak files from folder with CMD

I want automate the delete files with .bak extension in my backup folder I have a little CMD who ZIP all my BD .back and after this i want delete this bak but not ZIP file I use this but dont work, the bak files are in F:\bckup del /s /q /f…
0
votes
1 answer

Fast File Copy script in Windows

I have a process that is run every month or so. Such process identifies a set of files and constructs a proper source and destination path from several fields of different tables in DB to then copy all of these files, so I end up with potentially…
0
votes
1 answer

ICACLS escape asterisk character

Let's say I have managed to create a file named '*' (via MSYS or whatever) Is there a way to properly escape this such that I can call ICACLS and only list that single file? icacls * lists everything in the directory The file itself shows up as and…
LordAro
  • 111
  • 1
  • 5
0
votes
2 answers

"net user XXX /expires:never" does not work in Active Directory mode

I'm trying to make a user's password never expire, so I executed the following command in the domain controller: net user admin /expires:never And it succeed. But months later, the password still gets expired, what should I do in command line?
daisy
  • 747
  • 4
  • 14
  • 30
0
votes
2 answers

Powershell / Command prompt cannot switch to mapped drive when running as another use

in my powershell prompt, logged into a Windows 10 PC as Domain\UserA i can run the net use command to see my shared drives net use lists +--------+-------+----------------+---------------------------+ | Status | local | Remote | …
0
votes
0 answers

Create user - map network drive CMD

I have a pipeline which I want to do automatically (probably with a bat file) without the need to do all steps manually on my windows 10 machine. Pipeline steps: Create a normal user account e.g userA. I know this can be done using this net user…
0
votes
3 answers

Windows Server DHCP server reservation list

In Windows Server acting as a DHCP server, how can I get a list of the DHCP reservations from the CMD? I need to know the MAC address and the IP address reserved to that MAC address inside the DHCP server. Right now I have to right click every…
Malkavian
  • 125
  • 2
  • 12
0
votes
3 answers

I'm getting Permission Denied when redirecting output from CMD to a text file using the logitech_dfu tool

I've gotten this output using this command you see here from the Logitech instructions, and using the ">" operator before the file names in said command. It errors, and does not place anything in the output and error files. first it lists the…
0
votes
0 answers

Makefile CMD long path limit

When when I have long paths in my project (250+ characters), when I trigger my makefile it can't find the include files. Is there a way to fix this instead of renaming folders to decrease path length? Also if my long directory is…
Kerdany
  • 1
  • 1
0
votes
1 answer

How to run command tail -f error_log|fgrep '[rewrite:' in Windows Server

I'm currently performing website redirection from non-www to www+https, but unfortunately, my redirection does not work and I've tried to create rewrite log but it ends up my website down. After further check, I found here with below command: tail…
0
votes
2 answers

CMD file just flashes by when running as administrator

When running a simple batch file (.cmd) as administrator (Rightclick --> Run as administrator), it just flashes by in the taskbar and nothing more is happening. Running the file by just doubleclicking on it works fine. Total content of the .cmd…
Andreas
  • 309
  • 1
  • 5
  • 17
0
votes
0 answers

Run cmd command as admin through the pipe

I find myself in a bit of a weird situation and I'm hoping someone would be able to advise for me. I have a tool, RMM datto, which allows myself to run commands to all machines on the domain. I'm looking to run an uninstaller on the device, this…
0
votes
1 answer

Task Scheduler failed ... Error Value 2147942402

I tried to schedule a task by schtasks /create /tn Test /sc minute /mo 1 /tr "del /f \"%UserProfile%\path\file\"" ...however the Scheduler always ends up with the following type of error: Task Scheduler failed to launch action "del" in instance …
0
votes
1 answer

How to discover if Microsoft Project 2016 is installed on a remote machine

I've been trying to find a way to learn if Microsoft Project 2016 is installed on a remote machine. The main problem I'm running into is that Microsoft has, at some point in the past, concealed or encapsulated the components of its installation…
Matt
  • 3
  • 3
-1
votes
3 answers

Is it possible to know who hosts a website using cmd only?

I read similar questions but I didn't find something similar to what I'm asking. Suppose that we want to know who hosts a particular website knowing the domain name using the cmd only. I found many web interfaces to do it, so for example I put the…