Windows Server 2012 Zip File Command Line

0 views
Skip to first unread message
Message has been deleted

Melva Simons

unread,
Jul 13, 2024, 1:34:20 AM7/13/24
to deomaresert

All supported versions of Windows and Windows Server have a set of Win32 console commands built in. This set of documentation describes the Windows Commands you can use to automate tasks by using scripts or scripting tools.

Windows has two command-line shells: the Command shell and PowerShell. Each shell is a software program that provides direct communication between you and the operating system or application, providing an environment to automate IT operations.

windows server 2012 zip file command line


Descargar https://tinurli.com/2yOV8C



The Command shell was the first shell built into Windows to automate routine tasks, like user account management or nightly backups, with batch (.bat) files. With Windows Script Host, you could run more sophisticated scripts in the Command shell. For more information, see cscript or wscript. You can perform operations more efficiently by using scripts than you can by using the user interface. Scripts accept all commands that are available at the command line.

PowerShell was designed to extend the capabilities of the Command shell to run PowerShell commands called cmdlets. Cmdlets are similar to Windows Commands but provide a more extensible scripting language. You can run both Windows Commands and PowerShell cmdlets in PowerShell, but the Command shell can only run Windows Commands and not PowerShell cmdlets.

A reference of exit and error codes for Windows Commands can be found in the Debug system error codes articles that may be helpful to understanding errors produced. Windows Commands also include command redirection operators. To learn more of their use, see Using command redirection operators.

You can configure the Command shell to automatically complete file and directory names on a computer or user session when a specified control character is pressed. By default this control character is configured to be the tab key for both file and directory names, although they can be different. To change this control character, run regedit.exe and navigate to either of the following registry keys and entries, depending on whether you wish to change the value for the current user only, or for all users of the computer.

Set these values to that of the control character you wish to use. See virtual key codes for a complete list. To disable a particular completion character in the registry, use the value for space (0x20) as it isn't a valid control character. The type of value for this registry entry is REG_DWORD, and can also be specified by hexadecimal or decimal value.

You can also enable or disable file and directory name completion per instance of a Command shell by running cmd.exe with the parameter and switch /F:ON or /F:OFF. If name completion is enabled with the /F:ON parameter and switch, the two control characters used are Ctrl-D for directory name completion and Ctrl-F for file name completion. User-specified settings take precedence over computer settings, and command-line options take precedence over registry settings.

Use this topic to find the documentation resources and other technical information that you need to learn about the command shell, and to automate command-line tasks by using scripts or scripting tools.

To read introductory information about the command shell and command-line tools, see Feature description. To see a listing of new and deprecated command-line tools see New and deprecated functionality.

The command shell is a software program that provides direct communication between the user and the operating system. The non-graphical, command shell user interface provides the environment in which you run character-based applications and utilities. The command shell executes programs and displays their output on the screen by using individual characters similar to the MS-DOS command interpreter, Command.com. The command shell in the Windows Server operating system uses the command interpreter, Cmd.exe. Cmd.exe loads applications, directs the flow of information between applications, and translates user input into a form that the operating system understands.

You can use the command shell to create and edit scripts to automate routine tasks. For example, you can create simple scripts in batch (.bat) files to automate the management of user accounts or nightly backups. You can also use the command-line version of Windows Script Host to run more sophisticated scripts in the command shell. For more information, see Cscript or Wscript. You can perform operations more efficiently by using scripts than you can by using the user interface. Scripts accept all commands that are available at the command line.

In Command History, type or select 999 in Buffer Size, and then type or select 5 in Number of Buffers. By increasing the screen buffer size to 999, you enable scrolling through the Command Prompt window. By increasing the number of buffers to five, you increase the number of lines in the Command Prompt window to 5000.

To enable or disable file and directory name completion on a computer or user logon session, run Regedit.exe and set the following REG_DWORD value:HKEY_LOCAL_MACHINE\Software\Microsoft\Command Processor\CompletionChar\REG_DWORDTo set the REG_DWORD value, use the hexadecimal value of a control character for a particular function (for example, 09 is Tab and 008 is Backspace). User-specified settings take precedence over computer settings, and command-line options take precedence over registry settings.

I have been using Plastic as a client for some time now and like it a lot. Last year I set up a server on an OSX machine and, after a few hiccups with connections across multiple versions of the software, there was no problem setting up a server.

However, I've tried to set up a server on two Windows machines now, a Windows 7 machine and an 8.1 machine, and both machines are causing me problems that I can't seem to solve with a simple Google search (or twelve).

After configuring the server with the desired settings, I try to check plasticd status, and get "Cannot start service from the command line or a debugger. A Windows Service must first be installed (using installutil.exe) and then started with the ServerExplorer, Windows Services Administratice tool of the NET START command."

Command line reads a whole lot of "log4net : ERROR [FileAppender] Unable to acquire lock on file *.log.txt. Access to the path is denied." so I'm not getting any log info either.

I tried using installutil but that won't work either.

As I write this it occurs to me that this feels reminiscent of issues I've experienced with installing stuff in Program Files... but if that's the problem, I don't believe I changed the default install directory, and it chose to put itself in Program Files.

I'll attempt to install the whole shebang in root C: later but until then, acting under the assumption that this alone won't be the solution, maybe someone has some insight?

Thanks!

Can you check the user that is trying to run the server? You can check it from the services windows opening the "Plastic server 5" properties. It should be a user with read/write permissions on ProgramFiles.

Googling about this, I saw some people asking the same thing. But the answers looked like a manual page of netstat or netsh commands focusing on how to monitor the ports. I don't want answers on how to monitor them (I already do this). I want to close/kill them.

EDIT, for clarification: Let's say that my server listens TCP port 80. A client makes a connection and port 56789 is allocated for it. Then, I discover that this connection is undesired (e.g. this user is doing bad things, we asked them to stop but the connection didn't get dropped somewhere along the way). Normally, I would add a firewall to do the job, but this would take some time, and I was in an emergency situation. Killing the process that owns the connection is really a bad idea here because this would take down the server (all users would lose functionality when we just want to selectively and temporally drop this one connection).

Yes, this is possible. You don't have to be the current process owning the socket to close it. Consider for a moment that the remote machine, the network card, the network cable, and your OS can all cause the socket to close.

So all you really need is either for Windows to provide an API that allows this directly, or for someone to have written a program that operates somewhat like a VPN or Fiddler and gives you a way to close sockets that pass through it.

There is at least one program (CurrPorts) that does exactly this and I used it today for the purpose of closing specific sockets on a process that was started before CurrPorts was started. To do this you must run it as administrator, of course.

Note that it is probably not easily possible to cause a program to not listen on a port (well, it is possible but that capability is referred to as a firewall...), but I don't think that was being asked here. I believe the question is "how do I selectively close one active connection (socket) to the port my program is listening on?". The wording of the question is a bit off because a port number for the undesired inbound client connection is given and it was referred to as "port" but it's pretty clear that it was a reference to that one socket and not the listening port.

Alternatively, if you don't want to use EXTERNAL SOFTWARE (these tools don't require an installation by the way), you can simply FIRST run the netstat command (preferably netstat -b ) & then setup Local Security Policy to block the IP address of the user's machine in question, that's what I have been doing with unwanted or even unknown connections - that allows you doing everything WITHOUT ANY EXTERNAL SOFTWARE (everything comes with Windows)...

You can't close sockets without shutting down the process that owns those sockets. Sockets are owned by the process that opened them. So to find out the process ID (PID) for Unix/Linux. Use netstat like so:

d3342ee215
Reply all
Reply to author
Forward
0 new messages