Microsoft DOS ren and rename
About ren and rename
Availability
Syntax
Examples
About ren and rename
Used to rename files and directories from the original name to a new name.
In earlier releases of MS-DOS instead of using ren or rename you need to use the move command to rename your MS-DOS directories or files.
Availability
The ren and rename commands are internal commands that are available in the below Microsoft operating systems.
All Versions of MS-DOS
Windows 95
Windows 98
Windows ME
Windows NT
Windows 2000
Windows XP
Windows Vista
Windows 7
Syntax
Renames a file/directory or files/directories.
Note that you cannot specify a new drive or path for your destination.
Examples
rename c:chope hope
Rename the directory chope to hope.
rename *.txt *.bak
Rename all text files to files with .bak extension.
rename * 1_*
Rename all files to begin with 1_. The asterisk (*) in this example is an example of a wild character; because nothing was placed before or after the first asterisk, this means all files in the current directory will be renamed with a 1_ in front of the file. For example, if there was a file named hope.txt it would be renamed to 1_pe.txt.
rename “computer hope.txt” “example file.txt”
Rename the file “computer hope.txt” to “example file.txt”.
Whenever dealing with a file or directory with a space, it must be surrounded
with quotes. Otherwise you’ll get the “The
syntax of the command is incorrect.” error.
Create a new directory by copying all contents of the existing directory, including any files or subdirectories having the hidden or system attributes and empty directories.
xcopy e:existing e:
ewcopy /e /i /h
If the pathnames include spaces, they must be enclosed in quotation marks.
xcopy /D/E/C/Y
Copy entire drive in to a mapped network drive while ignoring any errors in network restartable mode.
xcopy *.* z:Netmirror /E /V /C /F /H /Y /Z out.txt err.txt
Copy a single file without prompt if it is a file or a directory
XCOPY does not support the Windows Volume Shadow Copy service which effectively allows processes to have access to open files, so it is not useful for backing up live operating system volumes.
XCOPY deployment or xcopy installation is a software application’s installation into a Microsoft Windows system simply by copying files. The name is derived from the XCOPY command line facility provided by Microsoft operating systems.
In contrast, the installation of a typical Windows application will require a significant number of additional steps before the application is ready to be used. Most of this additional work involves, directly or indirectly, adding or modifying entries in the Windows Registry. Even when an application uses ordinary files for its own data, many common facilities provided by Windows require some type of registration step before they are available to programs. Usually, one or more specialized tools (such as Windows Installer, InnoSetup, or NSIS) are used to help coordinate these relatively complex operations.
- “JaTomes Help – OS/2 Commands”. www.jatomes.com. Archived from the original on 2019-04-14.
- “Reactos/Base/Applications/Cmdutils/Xcopy at master · reactos/Reactos”. GitHub.
- Pietrek, Matt (2007-01-16). “Robocopy built into Vista”. Under The Hood (an MSDN blog).
- “FreeDOS 1.2 Updates Package – XCopy (FreeDOS Base)”. Ibiblio.org. 2007-09-22. Retrieved .
- Smith, Russell (27 November 2020). “SMB Compression Lowers Bandwidth and Improves Copy Times in Windows Server and Azure”. Petri.
- Output from xcopy /? in Windows 10 includes “/COMPRESS – Request network compression during file transfer where applicable”.
- Maciak, Luke (2007-02-05). “Xcopy: Insufficient Memory”.
Да, вы можете быть активным пользователем MS-DOS и думаете, что знаете все сочетания клавиш возможно, что можно использовать для ускорения работы. Однако весьма вероятно, что у вас нет полного списка, поскольку некоторые из них поставляются с Windows 10, поэтому из Softzone мы хотим помочь вам лучше ориентироваться в командной строкеВот 34 сочетания клавиш, которые использует каждый эксперт MS-DOS.
Как известно самый быстрый способ открыть окно MS-DOS в Windows это нажать клавишу Windows + R и введите cmd, хотя, если вы делали это раньше, вы уже знаете эту часть наизусть. Однако также можно открыть командную строку с помощью:
- Win + X и нажмите B
- Win + X и нажмите A (с правами администратора)
Чтобы закрыть его, все, что вам нужно сделать, это:
- Alt + F4
- Alt + ENTER (переключение между полноэкранным и оконным режимами).
- : Переместить точку вставки в начало или конец текущей строки.
- Ctrl + стрелка влево / вправо : Перемещает точку вставки в начало предыдущего или следующего слова в текущей строке.
- Ctrl + стрелка вверх / вниз : прокрутка страницы вверх или вниз, не перемещая точку вставки.
- Ctrl + H
- : Выделить весь текст в текущей строке. Снова нажмите Ctrl + A, чтобы выделить весь текст в буфере CMD.
- Shift + стрелка влево / стрелка вправо : Расширяет текущий выбор на один символ влево или вправо.
- Shift + Ctrl + стрелка влево / стрелка вправо : Расширяет текущий выбор на одно слово влево или вправо.
- Shift + стрелка вверх / стрелка вниз : Расширяет текущий выбор на одну строку вверх или вниз. Выделение распространяется на ту же позицию в предыдущей или следующей строке.
- Shift + Home : расширяет текущий выбор до начала команды. Снова нажмите Shift + Home, чтобы включить путь (например, C: Windows system32) в выделенный фрагмент.
- Shift + Конец : расширяет текущий выбор до конца строки.
- Ctrl + Shift + : Расширяет текущий выбор до начала или до конца экранного буфера.
- Shift + Предыдущая страница / Следующая страница : Расширяет текущий выбор на одну страницу вверх или вниз.
- Ctrl + C (или Ctrl + Insert) : копирует текущий выделенный текст.
- F2 затем буква : Скопируйте текст справа от точки вставки до написанного вами письма.
- Ctrl + V (или Shift + Insert) : вставить текст из буфера обмена.
- : удалить символ слева от точки вставки.
- Ctrl + Backspace : удаляет слово слева от точки вставки.
- : автоматически введите имя папки.
- : удаляет текущую текстовую строку.
- : Активировать режим вставки. Когда включен режим вставки, все, что вы вводите, вставляется в текущее место. При отключении все, что вы пишете, перезаписывает то, что уже существует.
- : Удаляет текст из точки вставки в начале или в конце текущей строки.
- Ctrl + Z : отмечает конец строки. Текст, который вы напишете позже, будет учитывать этот момент в этой строке.
Ярлык для истории заказов
Если мы не хотим повторять команды, благодаря этим ярлыкам мы можем повторять их без повторного ввода:
- : Повторить предыдущую команду.
- Стрелка вверх / вниз : Пролистайте предыдущие команды, которые вы ввели в текущем сеансе. Вы также можете нажать F5 вместо стрелки вверх для прокрутки истории команд.
- Стрелка вправо (или F1) : воссоздать персонажа из предыдущей команды.
- : отображает историю предыдущих команд. Вы можете использовать клавиши со стрелками вверх / вниз, чтобы выбрать любую команду, а затем нажмите клавишу Enter, чтобы выполнить команду.
- Alt + F7 : очищает историю команд.
- : Пролистайте историю команд до команд, соответствующих текущей команде. Это полезно, если вы хотите ввести часть команды, которую вы использовали несколько раз, а затем прокрутить историю, чтобы найти именно ту команду, которую вы хотите повторить.
- Ctrl + C : прекращает ввод строки или выполняемой команды.
Вы знали все элементы управления? Вы часто используете MS-DOS в Windows?
Команда XCOPY
Копирует каталоги, их подкаталоги и файлы (кроме скрытых и
системных).
Параметр “источник” задает расположение и имена файлов, которые вы хотите скопировать, и может включать в себя диск или маршрут. “Приемник” задает место, куда копируются файлы, и может включать в себя буквенную метку диска, маршрут, имя файла или их комбинацию.
Параметр /A копирует все файлы с установленном атрибутом архивизации (атрибут не модифицируется). См. также команду ATTRIB. /M выполняет те же действия, но сбрасывает атрибут архивизации у файлов, заданных в качестве источника. /D:дата копирует только файлы, модифицированные после заданной даты (формат даты зависит от установки COUNTRY). /P выводит при создании каждого целевого файла запрос на подтверждение. /S копирует каталоги и подкаталоги, если они не пусты. /E копирует все подкаталоги, даже если они пусты (используется с параметром /S). /V проверяет каждый файл-копию на идентичность исходному файлу. /W выводит перед началом копирования сообщение:
Press any key to begin copying file(s)
(Для начала копирования файлов нажмите любую клавишу)
Параметр /Y указывает, что вы хотите заменить существующий файл (файлы) без запроса на подтверждение. По умолчанию, когда вы задает в качестве целевого файла существующий файл, XCOPY будет запрашивать, хотите ли вы затереть его. (В предыдущих версиях MS-DOS такой файл перезаписывался без запроса.) Если команда XCOPY используется в командном файле, то запрос в любом случае не выводится. Задание этого параметра переопределяет установку переменной операционной среды COPYCMD.
/-Y указывает, что вы при замене существующего файла вы хотите выводить в XCOPY запрос на подтверждение. Задание этого параметра переопределяет установку переменной операционной среды COPYCMD.
О копировании отдельных файлов рассказывается в описании команды COPY, а о копировании дисков – в описании DISKCOPY.
Если вы не указываете приемник, XCOPY копирует файлы в текущий каталог. Если приемник не содержит существующий каталог и не заканчивается , XCOPY выводит подсказку вида:
Does destination specify a file name
or directory name on the target
(F = file, D = directory)?
(Приемник задает имя файла или каталога?
F = файл, D = каталог)
В старых версиях MS-DOS, XCOPY копирует скрытые и системные файлы. MS-DOS 6 это не так. Для копирования этих файлов измените их атрибуты с помощью команды ATTRIB.
Независимо от установки атрибута архивизации в исходном файле, XCOPY создает файлы с установленным атрибутом архивизации.
В отличие от команды DISKCOPY, которая копирует диски по дорожкам и требует, чтобы исходный и целевой диски имели один формат, XCOPY не имеет такого ограничения.
Чтобы задать, хотите ли вы выводить в командах COPY, MOVE и XCOPY запрос на подтверждение перед затиранием файла, когда команда дается из командной строки или командного файла, можно установить переменную операционной среды COPYCMD. Чтобы команды COPY, MOVE и XCOPY во всех случаях выводили запрос, установите переменную COPYCMD в /-Y. Для отмены запроса задайте в COPYCMD /Y. Указание /Y или /-Y в командной строке переопределяет значение переменной COPYCMD.
В предыдущих версиях MS-DOS XCOPY копировала скрытые и системные файлы. В MS-DOS 6.2 это не так. Для переопределения атрибута файла используйте команду ATTRIB.
Коды выхода команды XCOPY перечислены в следующей таблице:
Например, команда xcopy a: b: /s /e /w копирует все файлы и подкаталоги (включая пустые) с диска A на диск B, а перед началом копирования выводится запрос.
На данной странице вы найдете весь список актуальных комманд для MS-DOS 6.22+
Информация взята с сайта: www.helpset.ru
Узнать о некоторых дополнительных коммандах можно тут: Управление MS-DOS
Смена текущей директории
Примеры:cd — переход в корневую директорию текущего диска;cd exe — переход в директорию exe в корневой директории;cd .. — переход в наддиректорию;cd — сообщает текущий диск и директорию.
Просмотр содержимого директории
Сортировки:/on — по имени;/oe — по расширению;/od — по времени;/og — сначала выводить сведения о директориях;
Создание директории
Удаление пустой директории
Удаление директории со всем содержимым
Команда deltree может удалять как директории, так и файлы. В имени файла-или-директории можно использовать символы * и ?.
Примеры:deltree temp — удалить директорию или файл с именем temp из текущей директории;deltree /y d* — удалить из текущей директории все директории и файлы, имя которых начинается на d, не запрашивая подтверждение.
Переименование директории
Примеры:move a: emp tmp — переименовать директорию temp корневой директории диска а: в tmp.
Установка списка директорий для поиска выполняемых программ
Примеры:path ; — поиск программ должен вестись только в текущей директорииpath — имена директорий, в которых производится поиск программpath c:exe; c:exeprogram; d:msdos — поиск программ производить в директориях exe, program, msdos.
Команды MS-DOS для работы с файлами
Формат команды:copy con имя-файла
Ctrl+Z, F6 — признак конца файла.Enter — признак конца строки.
Примеры:copy con work.txt — создать в текущей директории текстовый файл work.txt.
Удаление файлов
Примеры:del *.txt — удалить все файлы с расширением .txt из текущей директории;del name.doc — удалить из текущей директории файл с именем name.doc.
Переименование файлов
Формат команды:ren имя-файла1 имя-файла2
В параметре имя-файла1 можно указывать дисковод и путь, в имя-файла2 — нет.Команда ren не обрабатывает скрытые файлы.
Примеры:ren xxx.doc xxx.txt — переименовать файл xxx.doc текущей директории в xxx.txt;ren a:*.txt *.doc — переименовать все файлы текущей директории на диске а: с расширением .txt в файлы с такими же именами и расширениями .doc.
Копирование файлов
В именах файлов можно употреблять символы * и ?, а также указывать имя диска и путь.Команда copy не копирует скрытые файлы и файлы нулевой длины.Если файл с таким же именем, как у копии, создаваемой командой уже существует, то он замещается.
Примеры:copy x.txt z.txt — скопировать файл x.txt в текущую директорию с именем z.txt;copy a:*.* — cкопировать все файлы из корневой директории диска а: в текущую директорию текущего диска;copy ext*.txt a:*.doc — скопировать из поддиректории text текущей директории все файлы с расширением txt в текущую директорию диска а:. Файлы получат расширения doc.
Использование устройств:copy t1.txt prn — копирование файла t1.txt на принтер;copy t1.txt con — копирование файла t1.txt на экран монитора.
Соединение (конкатенация) файлов
Если имя исходного файла (или одного из файлов) совпадает с именем создаваемого командой copy файла, то существующий файл замещается. Например, если файл all.doc уже существует, то команда copy *.doc all.doc будет ошибочной, т.к. файл all.doc будет уничтожена в начале копирования.
Примеры:copy .lst+*.ref *.prn — к каждому файлу текущей директории с расширением lst добавить файл с тем же именем и расширением ref, результат записывается в файл с тем же именем и расширением prn;copy f1.doc+f2.doc — объединить файлы f1.doc и f2.doc, содержимое объединенного файла записывается в файл f1.doc;copy *.txt all.prn — содержимое всех файлов с расширением txt записывается в файл all.prn.
Перемещение файлов в другую директорию
С параметром /y при существовании в директории-приемнике файлов с теми же именами, что и пересылаемые, выполняется замещение этих файлов без запроса. Задание нового имени возможно только при пересылке одного файла. Например, команда move *.bac a:*.old ошибочна.
Примеры:move *.doc d: — переместить файлы с расширением doc из текущей директории в корневую директорию диска d:;move f1.txt tmp2.txt — переместить файл f1.txt в директорию tmp с переименованием в f2.txt.
Сравнение файлов
Если имя файла-протокола не задано, сведения о сравнении выводятся на экран.
Параметры:/l — построчное сравнение. Если программа обнаруживает различия в файлах, она пытается найти после точки рассогласования места, начиная с которых файлы снова становятся одинаковыми. На выходе — различающиеся строки;/b — побайтовое сравнение. После обнаружения различия файлов сравнение прекращается.
По умолчанию режим сравнения выбирается по расширению:/b — .exe, .com, .sys, .obj, .lib, .bin,/l — остальные.
Параметры построчного сравнения:/c — игнорировать различия между строчными и прописными буквами;/n — вывод номеров строк;/число — сколько строк файлов должно совпадать, чтобы файлы считались снова согласованными. По умолчанию 2 строки;/lbчисло — размер внутреннего буфера для нахождения соответствий в файлах после рассогласования. По умолчанию 100 строк.
Вывод файла на экран
Примеры:type t1.doc — вывод на экран файла type t1.doc из текущей директории.
Команда копирования xcopy
Преимущества команды xcopy:
Get to a Command Prompt in Windows 10
- Click Start button in windows or press windows Key.
- Type cmd and press Enter.
Renaming a file
rename test.txt hope.txt
rename c:computer est.txt hope.txt
Renaming a file with a space
To rename multiple files at once, you must utilize some form of wild character. Below are examples of how this could be done.
rename *.rtf *.txt
rename h?pe.txt hope.txt
Renaming a directory
Renaming a directory in MS-DOS is much like renaming a file. Use the ren or rename command to rename the directory. Because you cannot have a file and directory of the same name, you don’t need to worry about mistakenly renaming a file instead of a directory. The only exception is if you’re using wild characters.
Renaming a directory containing files may cause problems if that directory contains files required by a program. For example, if the program is looking for a directory named “data” and you rename it to “other,” the program would no longer know where data files are located.
rename computer hope
Rename the directory “computer hope” to “example directory”. Whenever dealing with a file or directory with a space, it must be surrounded with quotes. Otherwise, you get the “The syntax of the command is incorrect” error.
rename “computer hope” “example directory”
Sets the path to be searched for data files or displays the current search path.
The APPEND command is similar to the PATH command that tells DOS where to search for program files (files with a .COM, . EXE, or .BAT file name extension).
The command redirects requests for disk operations on one drive to a different drive. It can also display drive assignments or reset all drive letters to their original assignments.
Lists connections and addresses seen by Windows ATM call manager.
Attrib changes or views the attributes of one or more files. It defaults to display the attributes of all files in the current directory. The file attributes available include read-only, archive, system, and hidden attributes. The command has the capability to process whole folders and subfolders of files and also process all files.
BACKUP and RESTORE
An implementation of the BASIC programming language for PCs. Implementing BASIC in this way was very common in operating systems on 8- and 16-bit machines made in the 1980s.
IBM computers had BASIC 1.1 in ROM, and IBM’s versions of BASIC used code in this ROM-BASIC, which allowed for extra memory in the code area. BASICA last appeared in IBM PC DOS 5.02, and in OS/2 (2.0 and later), the version had ROM-BASIC moved into the program code.
Microsoft released GW-BASIC for machines with no ROM-BASIC. Some OEM releases had basic.com and basica.com as loaders for GW-BASIC.EXE.
BASIC was dropped after MS-DOS 4, and PC DOS 5.02. OS/2 (which uses PC DOS 5), has it, while MS-DOS 5 does not.
This command is used to instruct DOS to check whether the Ctrl and Break keys have been pressed before carrying out a program request.
Starts a batch file from within another batch file and returns when that one ends.
CD and CHDIR
The CHDIR (or the alternative name CD) command either displays or changes the current working directory.
The command either displays or changes the active code page used to display character glyphs in a console window. Similar functionality can be achieved with MODE CON: CP SELECT=yyy.
CHKDSK verifies a storage volume (for example, a hard disk, disk partition or floppy disk) for file system integrity. The command has the ability to fix errors on a volume and recover information from defective disk sectors of a volume.
The CLS or CLRSCR command clears the terminal screen.
Start a new instance of the command interpreter.
Show differences between any two files, or any two sets of files.
Makes copies of existing files.
This section needs expansion. You can help by adding to it.
A very primitive assembler and disassembler.
The command has the ability to analyze the file fragmentation on a disk drive or to defragment a drive. This command is called DEFRAG in MS-DOS/PC DOS and diskopt in DR-DOS.
DEL and ERASE
DEL (or the alternative form ERASE) is used to delete one or more files.
Deletes a directory along with all of the files and subdirectories that it contains. Normally, it will ask for confirmation of the potentially dangerous action. Since the RD (RMDIR) command can not delete a directory if the directory is not empty (except in Windows NT & 10), the DELTREE command can be used to delete the whole directory.
A command for comparing the complete contents of a floppy disk to another one.
A command for copying the complete contents of a diskette to another diskette.
A command that adds command history, macro functionality, and improved editing features to the command-line interpreter.
DOS line-editor. It can be used with a script file, like debug, this makes it of some use even today. The absence of a console editor in MS-DOS/PC DOS 1–4 created an after-market for third-party editors.
The EMM386 command enables or disables EMM386 expanded-memory support on a computer with an 80386 or higher processor.
See: DEL and ERASE
Converts an executable (.exe) file into a binary file with the extension .com, which is a memory image of the program.
The size of the resident code and data sections combined in the input .exe file must be less than 64 KB. The file must also have no stack segment.
Provides information for MS-DOS commands.
A command that provides accelerated access to frequently-used files and directories.
The FDISK command manipulates hard disk partition tables. The name derives from IBM’s habit of calling hard drives fixed disks. FDISK has the ability to display information about, create, and delete DOS partitions or logical DOS drive. It can also install a standard master boot record on the hard drive.
The FIND command is a filter to find lines in the input data stream that contain or don’t contain a specified string and send these to the output data stream. It may also be used as a pipe.
The FINDSTR command is a GREP-oriented FIND-like utility. Among its uses is the logical-OR lacking in FIND.
FINDSTR “YES NO MAYBE” *.txt
would find all TXT files with one or more of the above-listed words YES, NO, MAYBE.
Iteration: repeats a command for each out of a specified set of files.
The FOR loop can be used to parse a file or the output of a command.
Deletes the FAT entries and the root directory of the drive/partition, and reformats it for MS-DOS. In most cases, this should only be used on floppy drives or other removable media. This command can potentially erase everything on a computer’s drive.
Main article: Goto
The Goto command transfers execution to a specified label. Labels are specified at the beginning of a line, with a colon (:likethis).
Used in Batch files.
Gives help about DOS commands.
IF is a conditional statement, that allows branching of the program execution. It evaluates the specified condition, and only if it is true, then it executes the remainder of the command line. Otherwise, it skips the remainder of the line and continues with next command line.
INTERSVR and INTERLNK
In MS-DOS; filelink in DR-DOS.
Network PCs using a null modem cable or LapLink cable. The server-side version of InterLnk, it also immobilizes the machine it’s running on as it is an active app (As opposed to a terminate-and-stay-resident program) which must be running for any transfer to take place. DR-DOS’ filelink is executed on both the client and server.
The KEYB command is used to select a keyboard layout.
From DOS 3.0 through 3.21, there are instead per-country commands, namely KEYBFR, KEYBGR, KEYBIT, KEYBSP and KEYBUK.
Changes the label on a logical drive, such as a hard disk partition or a floppy disk.
LOADHIGH and LH
A command that loads a program into the upper memory area.
It is called hiload in DR-DOS.
MD or MKDIR
Makes a new directory. The parent of the directory specified will be created if it does not already exist.
Displays memory usage. It is capable of displaying program size and status, memory in use, and internal drivers. It is an external command.
On earlier DOS versions the memory usage could be shown by running CHKDSK. In DR DOS the parameter /A could be used to only show the memory usage.
MEMMAKER.EXE and SIZER.EXE were developed for Microsoft by Helix Software Company and were eliminated starting in MS-DOS 7 (Windows 95); however, they could be obtained from Microsoft’s FTP server as part of the OLDDOS.EXE package, alongside other tools.
PC DOS uses another program called RamBoost to optimize memory, working either with PC DOS’s HIMEM/EMM386 or a third-party memory manager. RamBoost was licensed to IBM by Central Point Software.
The MIRROR command saves disk storage information that can be used to recover accidentally erased files.
The MORE command paginates text, so that one can view files containing more than one screen of text. More may also be used as a filter. While viewing MORE text, the return key displays the next line, the space bar displays the next page.
Moves files or renames directories.
DR-DOS used a separate command for renaming directories, rendir.
Main article: MSAV
The MSBACKUP command is used to backup or restore one or more files from one disk to another.
MSCDEX is a driver executable which allows DOS programs to recognize, read, and control CD-ROMs.
Displays or sets a search path for executable files.
Suspends processing of a batch program and displays the message Press any key to continue. . ., if not given other text to display.
It is not included in many DOS versions; typically ones with network stacks will have it as a diagnostic tool.
An integrated development environment and BASIC interpreter.
RD or RMDIR
Remove a directory (delete a directory); by default the directories must be empty of files for the command to succeed.
The deltree command in some versions of MS-DOS and all versions of Windows 9x removes non-empty directories.
A primitive filesystem error recovery utility included in MS-DOS / IBM PC DOS.
Remark (comment) command, normally used within a batch file, and for DR-DOS, PC/MS-DOS 6 and above, in CONFIG.SYS. This command is processed by the command processor. Thus, its output can be redirected to create a zero-byte file. REM is useful in logged sessions or screen-captures. One might add comments by way of labels, usually starting with double-colon (::). These are not processed by the command processor.
A command that is used to replace one or more existing computer files or add new files to a target directory.
See: BACKUP and RESTORE
The SELECT command formats a disk and installs country-specific information and keyboard codes.
It was initially only available with IBM PC DOS. The version included with PC DOS 3.0 and 3.1 is hard-coded to transfer the operating system from A: to B:, while from PC DOS 3.2 onward you can specify the source and destination, and can be used to install DOS to the harddisk.
The version included with MS-DOS 4 and PC DOS 4 is no longer a simple command-line utility, but a full-fledged installer.
This command is no longer included in DOS Version 5 and later, where it has been replaced by SETUP.
Sets environment variables.
SetVer is a TSR program designed to return a different value to the version of DOS that is running. This allows programs that look for a specific version of DOS to run under a different DOS.
Installs support for file sharing and locking capabilities.
The SHIFT command increases number of replaceable parameters to more than the standard ten for use in batch files.
This is done by changing the position of replaceable parameters. It replaces each of the replacement parameters with the subsequent one (e.g. %0 with %1, %1 with %2, etc.).
The external command SIZER.EXE is not intended to be started directly from the command prompt. Is used by MemMaker during the memory-optimization process.
A utility to make a volume bootable. Sys rewrites the Volume Boot Code (the first sector of the partition that SYS is acting on) so that the code, when executed, will look for IO.SYS. SYS also copies the core DOS system files, IO.SYS, MSDOS.SYS, and COMMAND.COM, to the volume. SYS does not rewrite the Master Boot Record, contrary to widely held belief.
It is an external command, graphically displays the path of each directory and sub-directories on the specified drive.
Internal command that expands the name of a file, directory, or drive, and display its absolute pathname as the result. It will expand relative pathnames, SUBST drives, and JOIN directories, to find the actual directory.
For example, in DOS 7.1, if the current directory is C:WINDOWSSYSTEM, then
The argument does not need to refer to an existing file or directory: TRUENAME will output the absolute pathname as if it did. Also TRUENAME does not search in the PATH.
For example, in DOS 5, if the current directory is C:TEMP, then TRUENAME command.com will display C:TEMPCOMMAND.COM (which does not exist), not C:DOSCOMMAND.COM (which does and is in the PATH).
This command displays the UNC pathnames of mapped network or local CD drives. This command is an undocumented DOS command. The help switch “/?” defines it as a “Reserved command name”. It is available in MS-DOS version 5.00 and later, including the DOS 7 and 8 in Windows 95/98/ME. The C library function realpath performs this function. The Microsoft Windows NT command processors do not support this command, including the versions of command.com for NT.
Restores file previously deleted with del. By default all recoverable files in the working directory are restored; options are used to change this behavior. If the MS-DOS mirror TSR program is used, then deletion tracking files are created and can be used by undelete.
An internal DOS command, that reports the DOS version presently running, and since MS-DOS 5, whether DOS is loaded high.
An internal command that displays the disk volume label and serial number.
A TSR program that continuously monitors the computer for viruses.
Copy entire directory trees. Xcopy is a version of the copy command that can move files and directories from one location to another.
XCOPY usage and attributes can be obtained by typing XCOPY /? in the DOS Command line.
Microsoft DOS ipconfig command
About ipconfig
Availability
Windows 95, 98, ME syntax
Windows 2000 and XP syntax
Examples
About ipconfig
Ipconfig is a DOS utility that can be used from MS-DOS and a MS-DOS shell to display the network settings currently assigned and given by a network. This command can be utilized to verify a network connection as well as to verify your network settings.
The ipconfig.exe command is an external command and is available in the below Microsoft operating systems.
Windows 95
Windows 98
Windows ME
Windows 2000
Windows XP
Windows Vista
Windows 7
Windows 95, 98, and ME syntax
/All
Display detailed information.
/renew_all
Renew all adapters.
/release_all
Release all adapters.
/renew N
Renew adapter N.
/release N
Release adapter N.
Windows 2000 and XP syntax
The default is to display only the IP address, subnet mask and default gateway for each adapter bound to TCP/IP.
For Release and Renew, if no adapter name is specified, then the IP address leases for all adapters bound to TCP/IP will be released or renewed.
For SetClassID, if no class id is specified, then the classid is removed.
To get your computers local network IP address, subnet mask, and default gateway typing ipconfig alone will display this information as shown below. Keep in mind this is only your local network information. If you’re trying to determine your IP address used on the Internet we suggest viewing our system information page.
Ethernet adapter Local Area Connection:
Connection-specific DNS Suffix . : hsd1.ut.comcast.net.
IP Address. . . . . . . . . . . . : 192.168.201.245
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.201.1
Windows IP Configuration
Host Name . . . . . . . . . : COMPUTERH1
DNS Servers . . . . . . . . : 123.45.67.8
111.111.111.1
111.111.111.1
Node Type . . . . . . . . . : Broadcast
NetBIOS Scope ID. . . . . . :
IP Routing Enabled. . . . . : No
WINS Proxy Enabled. . . . . : No
NetBIOS Resolution Uses DNS : No
0 Ethernet adapter :
Description . . . . . . . . : PPP Adapter.
Physical Address. . . . . . : 44-44-44-54-00-00
DHCP Enabled. . . . . . . . : Yes
IP Address. . . . . . . . . : 123.45.67.802
Subnet Mask . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . : 123.45.67.801
DHCP Server . . . . . . . . : 255.255.255.255
Primary WINS Server . . . . :
Secondary WINS Server . . . :
Lease Obtained. . . . . . . : 01 01 80 12:00:00 AM
Lease Expires . . . . . . . : 01 01 80 12:00:00 AM
1 Ethernet adapter :
Description . . . . . . . . : 3Com 3C90x Ethernet Adapter
Physical Address. . . . . . : 00-50-04-62-F7-23
DHCP Enabled. . . . . . . . : Yes
IP Address. . . . . . . . . : 111.111.111.108
Subnet Mask . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . : 111.111.111.1
DHCP Server . . . . . . . . : 111.111.111.1
Primary WINS Server . . . . :
Secondary WINS Server . . . :
Lease Obtained. . . . . . . : 11 16 00 12:12:44 AM
Lease Expires . . . . . . . :
Running the above command would display all the DNS information.
Delete all DNS entries.
Вызов и использование
DOS-команды все еще можно встретить даже во времена пестрых окон и анимированных программ. Вспоминать об этом вы начинаете, например, если возникают проблемы с Windows и вам нужно создать резервную копию данных без помощи графического интерфейса. DOS-окно (в Windows это называется «Командная строка») можно открыть двумя способами:
- Вызвать из меню «Пуск» в разделе «Все программы» — «Стандартные» (Windows 7) или «Пуск» — «Windows-система» — «Командная строка» (Windows 10).
- Вызвать из поиска Windows, введя команду «cmd».
Навигация по файловой системе
Навигация по файловой системе в DOS осуществляется с помощью команды cd. Она означает «change directory» (сменить директорию) и может использоваться несколькими способами:
- Прямой вызов папки, например, с «cd Documents». С помощью этой команды вы перейдете непосредственно в папку «Documents».
- Вызов «cd». Эта команда вернет вас непосредственно в корневой каталог вашего жесткого диска.
- Команда «cd» может использоваться в сочетании с командой «dir», которая позволяет просматривать каталоги на жестком диске. С помощью этих двух команд у вас есть возможность перемещаться по всему жесткому диску.
- Кроме того, «dir» может применяться с параметрами, например «dir /w» и «dir /p», для постраничного просмотра содержимого ваших каталогов. Это рекомендуется для удобства просмотра очень больших каталогов.