2

Is it possible to run MS-DOS applications via telnet on a Windows 7 system? Some applications we still use here were never ported to newer systems. Now the company wants to move the workstations towards Linux and have the old applications run on a Windows Server.

3 Answers 3

2

Yes. As long as the programs will run on the command prompt in the first place (don't do crazy stuff like TSRs or tap the serial port directly).

Also, FYI - if they are really simple you can probably just run them in Linux: DOSemu http://www.n0nb.us/ham-linux/linux/dosemuold.html http://www.dosemu.org/

9
  • 1
    Note that 16 bit (e.g. DOS) applications do not work on win7 x64.
    – Hennes
    Sep 27, 2012 at 21:36
  • glad to know @hennes
    – Holy Sheet
    Sep 27, 2012 at 21:36
  • Even menu-driven programs?
    – Holy Sheet
    Sep 27, 2012 at 21:37
  • yes. that's terminal control. and should be handled by a BIOS emulation layer.
    – EdH
    Sep 27, 2012 at 21:39
  • Note the X64. They work on X86. Not that win7 would make a server OS, you might want to use server 2003 (server 2008 and 2012 are x64 only). --- All 16 bit programs. Even windows 2.01 or 3.x. Simply no native 16 bit support in those versions.
    – Hennes
    Sep 27, 2012 at 21:39
1

try this http://www.bttr-software.de/products/jhoffmann/#rmenu ... a telnet server for DOS. Of course it cannot turn (MS-)DOS into a multiuser system, therefore only one connection is accepted at any time, but it can be used to remotely control a computer runnig DOS via telnet....

1
  • You should provide more detail than just the link.. Try to say in your own words what they are saying in the link. That way if the link ever changes or disappears, SU still has the answer here
    – Eric F
    Apr 7, 2016 at 12:02
1

Here is one solution that can work in some cases, which is rarely mentioned in a Google search, and that is using MS-DOS's own CTTY command. I've found uses for this on MS-DOS 6.22. CTTY has been available since MS-DOS 2.x, so the setup below can possibly also work with MS-DOS 5 or earlier. This setup does not appear to use any additional conventional memory.

This command forwards the terminal input (keyboard) and output (screen) to another computer, via serial cable. A null modem cable (7 pin connection) works for this. For a Windows client accessing the MS-DOS terminal server, PuTTY works well. As the OP might be running Linux workstations by now, screen probably is the most reliable terminal client for this, though there are several other terminal clients out there that can probably do the same job (I did have problems getting this to work with picocom). I've had no issues using a serial-to-USB adapter for the connection, on both Windows and Linux.

By default, MS-DOS sets the COM ports to 2400bps. We can up this speed to 19200bps and use the common serial settings of nowadays, by doing MODE COMx: 19,N,8,1, (replacing x with the actual COM port number being used; yes, nothing after the 4th comma).

With the serial cable connected to a Linux computer, one can run screen /dev/ttyUSB1 19200,cs8 (replacing the actual serial port path to use, accordingly). With PuTTY on Windows, choose Serial as Connection type, choose the COM port linked to the serial cable and set the speed. I also set Window -> Translation to CP437. Of course, this can be a different codepage, if the target DOS's locale is different than United States.

With the modern computer ready and connected to the serial terminal, you should just see a blank screen. Now, on MS-DOS, type CTTY COMx, and you should now see your MS-DOS prompt showing on screen/PuTTY.

Now, whether this setup would work for the OP, this depends on how the target utilities or applications were programmed. There are more than one way for a program to display and receive text on MS-DOS, and what I have found from my experiences are various different outcomes.

When launching some utilities, such as most of MS-DOS's built-in ones, everything shows up in the terminal screen and all basic keys being typed on the modern computer gets accepted as input. On the other hand, if launching an application that accesses the graphics card directly, such as EDIT.COM, the application shows up on MS-DOS's own monitor and MS-DOS's own keyboard could be required.

I have seen other utilities with very poor compatibility to CTTY, displaying half the text through the terminal with the rest showing on the DOS monitor. I have seen a couple of others show text on the DOS monitor, but input could only be accepted from the terminal. Due to these experiences, it is recommended to try your target utilities/applications/TSRs first, to determine whether this setup would work out in your particular company environment.

If you find that your company's uses for MS-DOS can work with this setup, then staff members should be able to access the terminal computer remotely over SSH or RDP to get to MS-DOS, as a bonus. You also get scrollback and clipboard with your modern computer. ASCII escape sequences (prompt colors, etc.) display properly on the terminal client as well, as long as ANSI.SYS or equivalent is installed. The DOS side of this setup can be initialized automatically at startup with AUTOEXEC.BAT.

For more information on CTTY and MODE, type help ctty or help mode in an MS-DOS prompt.

Note: I did also try using CTTY and MODE on MS-DOS 7 for Windows 98SE and I was unsuccessful. After ending up on this article, I decided not to try further.

Note 2: This answer is rather long because I really found no webpages depicting any experiences about using this method, and this answer possibly could be of use for any other reader that stumbles into this question.

1
  • 1
    That's an amazing answer!
    – pbies
    Sep 2, 2023 at 17:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .