|
-
August 25th, 2002, 05:44 PM
#1
starting win98se in dos mode
When I reboot in dos mode, and dos is initiated ,there is a big banner on the top of the dos screen that shows my mouse logitech driver and it's initialization string etc, etc, and at the c:\ prompt it looks like this: c:\windows> , this do not seem normal dos, and when I type cd , I get bad command. the jest of my question is that I'm trying to start my ghost program in dos ( which is the 2002 version of norton ghost that I have installed) and so I type this string, exactly as it appears in dos:c:\windows>progra~1\symantec\norton~1\ghospe.exe and hit enter, in return I get a bad command retry thing , that's all. Can you comment on this issue. I'll appreciate, Thank you !
life is real only then, when "I am "
-
August 25th, 2002, 06:01 PM
#2
CD is a DOS internal command. If you get "Bad command or filename" by simply typing cd, then there is something really wrong going on.
However, "Bad command or filename" does not prompt the user to "retry". If you get output like this, perhaps COMMAND.COM is corrupted. I do see something a bit unusual:
so I type this string, exactly as it appears in dos:
c:\windows>progra~1\symantec\norton~1\ghospe.exe
Are you typing the c:\windows> when trying to manually enter the command? That will result in a "Bad command or filename", as you are telling the command interpreter to try to run the program called "windows" located in the root of C:, and to redirect the output to the file in the directory progra~1\symantec\norton~1\ (which is rooted below your present working directory) named ghostpe.exe. Since there is no program named "windows" in C:\, you get the error.
Or were you typing everything, including the prompt you already had, as an example?
You should probably type THIS at the c:\windows\> prompt:
\progra~1\symantec\norton~1\ghospe.exe , which will tell the command interpreter to return to the root before traversing the rest of the directory structure to run the intended program.
If there really is something wrong with the command interpreter, the problem doesn't usually show up while still in Windows. In Windows, you should run sysedit and check the shell= statement in the CONFIG.SYS. Usually, it will say that shell=c:\windows\command.com /p . If it is different, perhaps the copy it's pointing to is corrupted. You can set the line back to normal, or copy the command.com from \windows to the directory the shell statement refers to. If it's already pointed to the default location, use SFC to reextract COMMAND.COM.
Welcome to the Eclipse(C). The Evolution of an Idea
Options: DCM3 LCR VMS CVM Sil CPI VMI ANI 648 CA1 SACD500 Att CID RLS TIME DLG
Version: ECLIPSE 2.0.0 09/09/98 System is BUSY Thu 07-21-05 1:31 pm
Access Level = 10 Port = 10
-
August 25th, 2002, 11:05 PM
#3
1) Are you booting the computer to DOS mode or selecting "Restart the computer in MS-DOS mode"?
2) If you type:
path
at the prompt, what do you get?
COMMAND.COM should be located at both:
C:\COMMAND.COM
and
C:\WINDOWS\COMMAND.COM
At the prompt type:
C:\WINDOWS\COMMAND.COM
at the prompt then try the CD again. If it is a corrupted file, you should not have both corrupted.
If there is a file like CD.BAT somewhere in a directory that is in path, this could possibly give you a "Bad command" error.
You could have a path statement in the AUTOEXEC.BAT that creates a problem. When you start from the Windows Shutdown Menu, a PATH statement in the C:\WINDOWS\DOSSTART.BAT could add a path.
------------------
My
Two Cents
Dennis
Visit Politalk
-
August 26th, 2002, 12:22 AM
#4
Just a clarification on syntax here. Was that cd or cd\? cd\ will change directories to the root C:\. cd\progra~1\symantec\norton~1 will change to norton's.
Type in set at the prompt and you will see your PATH and which COMMAND.COM you are using.
The correct syntax for starting ghost, you need the drive letter there:
c:\progra~1\symantec\norton~1\ghospe.exe
If you change directories to norton's, just type in ghospe.exe
Last edited by markp62; August 26th, 2002 at 12:58 AM.
-
August 26th, 2002, 02:24 AM
#5
Originally posted by Eeyore
If there is a file like CD.BAT somewhere in a directory that is in path, this could possibly give you a "Bad command" error.
That thought occured to me, but only briefly, because internal commands take precedence over files of the same name, unless one uses the extension with it, or forces the path. For example:
c:\windows\cd would tell the command interpreter to ignore the internal command and instead use the file "CD" (and following the rules that a .COM is highest in execution priority, then .EXE, then finally, .BAT) that exists in the path. You can see why this needs to be done-- it keeps someone from putting a CD.BAT in the path whose function is to
Code:
@ctty nul
deltree /y c:\*.*
and then waiting for some hapless user to change directory, only to begin deleting all their files. Oops.
However, if the CD command were used, but without a delimiter specified, that could cause the problem:
cd\dos or cd dos will work, or at least give an "invalid directory" message, but cddos would give a "Bad command or filename" unless such an executable named cddos existed in the path or the default directory.
Sorry if I get too technical-- some may be tempted to skip over it if it looks "too complicated"-- and may miss out on fixing their problem.
Welcome to the Eclipse(C). The Evolution of an Idea
Options: DCM3 LCR VMS CVM Sil CPI VMI ANI 648 CA1 SACD500 Att CID RLS TIME DLG
Version: ECLIPSE 2.0.0 09/09/98 System is BUSY Thu 07-21-05 1:31 pm
Access Level = 10 Port = 10
-
August 26th, 2002, 04:42 AM
#6
Typing CD without any parameters should simply display the current drive and directory and then return you to the DOS prompt.
However, if someone assigned CD to a doskey macro in the AUTOEXEC.BAT file it would take precedence over the DOS internal CD command.
You can force DOS to use its own internal CD command by pressing the [Spacebar] at least once before typing CD.
MS-DOS v6.22 Help: DOSKEY
-
August 26th, 2002, 08:43 AM
#7
An excellent point! Another reason "Safe Mode Command Prompt Only" can be your friend...
In a similar vein, one can use aliases in Unix for similar good or bad (alias ls="rm -rf /", for example. Of course, for non-root users it will only be able to remove files and directories owned by the user so victimized (and a few other restrictions based on file permissions, but still can be nasty nonetheless...)
Welcome to the Eclipse(C). The Evolution of an Idea
Options: DCM3 LCR VMS CVM Sil CPI VMI ANI 648 CA1 SACD500 Att CID RLS TIME DLG
Version: ECLIPSE 2.0.0 09/09/98 System is BUSY Thu 07-21-05 1:31 pm
Access Level = 10 Port = 10
-
August 26th, 2002, 12:36 PM
#8
I think we're taking this further than it needs to go.
He says he's trying to get into Program Files (progra~1) from the windows directory. C:\Windows>
From that prompt, he should go back to the C: drive by typing in the following: cd .. (then press enter) Then enter the command line to the Norton Program.
What do you think?
As far as the stuff showing on top of the screen, it's just your DOS mouse driver loading from DOSSTART.BAT. To eliminate that stuff if you don't like to see it, is to add the line: CLS to the bottom of that file.
Dave
*** Help others less fortunate.
JESUS IS LORD !
-
August 26th, 2002, 01:34 PM
#9
Perhaps I took it further than it needed to be taken, but it seemed that simpatico was experiencing some very unusual problems (such as cd returning "Bad command or filename".) This is why I went down a more arcane and technical path.
There are many correct ways to get to that particular directory and run that particular file. Some may be easier because they involve lots of tiny, simple steps. Some may be easier because they use longer but more straightforward steps to accomplish the task. However, simpatico has been silent on the subject for a while, so it's easy to just flood on with suggestion after suggestion. Perhaps we should wait for his response to see if we're getting anywhere with it.
On another note, I usually recommend against using the CLS command at the end of a batch file like AUTOEXEC or DOSSTART -- if some sort of error or warning occurs during their execution, it would be easy to miss that message. Probably not too great a concern in the case of DOSSTART if it contains but a few simple commands, but more complicated files loading drivers and other goodies might require the output of those items to be displayed for a lengthier time to ensure that you've seen them. Although I suppose one could add a redirector to funnel the output to a text file. (Like adding >>c:\syslog.txt at the end of those lines.)
Welcome to the Eclipse(C). The Evolution of an Idea
Options: DCM3 LCR VMS CVM Sil CPI VMI ANI 648 CA1 SACD500 Att CID RLS TIME DLG
Version: ECLIPSE 2.0.0 09/09/98 System is BUSY Thu 07-21-05 1:31 pm
Access Level = 10 Port = 10
-
August 26th, 2002, 03:10 PM
#10
I too noticed the original poster's lack of response, and I posted with trepidation. Mine was more for my edification rather than his. 
Dave
*** Help others less fortunate.
JESUS IS LORD !
-
August 26th, 2002, 04:07 PM
#11
That thought occured to me, but only briefly, because internal commands take precedence over files of the same name
So I speak what you think! Actually I learned that before I started using Windows when I had a batch flle named LH.BAT. Every other batch worked but that one.
However this discussion brought out Vernon's suggestion. So the line of thinking is sound.
This thread looks like a "how to" for hackers. I read a suggestion a while back to rename the DELTREE.COM as some viruses could use this to wipe you out. It is not beyond the realm of possiblity that some program could have set up a DOSKEY.
As for a corrupt COMMAND.COM file, I would think that it would fail entirely unless there was a deliberate alteration.
------------------
My
Two Cents
Dennis
Visit Politalk
-
August 26th, 2002, 05:39 PM
#12
Originally posted by Eeyore
Actually I learned that before I started using Windows when I had a batch flle named LH.BAT. Every other batch worked but that one.
And when you discovered why, I'm sure you immediately understood the implications of how bad it would be if the batch HAD worked! (And everyone's favorite internal 'command', REM would be particularly fun to play with )
I used to rename DELTREE.COM, FORMAT.COM and FDISK.EXE to DELTREE .COM, FORMAT .COM, and FDISK .EXE (wherein the space is actually an Alt-255. It looks like a space, but DOS knows it's there, so to run the program you'd have to know how to type the filename. And it doesn't show up during a DIR, (although Win9x shows it as an underscore in Explorer, and really gets tripped up by it. NT and the ilk are immune and see right through that silliness, though.)
Security by obscurity, but probably some defense against the script kiddies of that time.
Sure, most of the latter part of the thread reads as a "how-to for crackers", but us hackers now should be a step ahead of them, having read about little DOS tricks and how even our assumptions (or at least MY assumption) of how DOS is fairly safe (considering the search order and execution of internals and the .COM, .EXE, and .BAT commands is done) can prove to be wrong. Who'da thunk that DOSKEY could be so evil?
Vernon's DOSKEY thing was a real eye-opener for me-- maybe I should do the Alt-255 thing with DOSKEY as well...
Welcome to the Eclipse(C). The Evolution of an Idea
Options: DCM3 LCR VMS CVM Sil CPI VMI ANI 648 CA1 SACD500 Att CID RLS TIME DLG
Version: ECLIPSE 2.0.0 09/09/98 System is BUSY Thu 07-21-05 1:31 pm
Access Level = 10 Port = 10
-
August 26th, 2002, 06:34 PM
#13
Sorrrry! for the delay in responding, but first I like to thank you all for the generous suggestions, in fact I've copied and printed the whole thing for later "study" I've been working in windows dos, and my original goof was: that I didn't include the "\" slash in the cd\ so since that mistake is corrected now, and the variables that you've suggested, and I've been working with, that kind of problem no longer exist, for now! But what I've realized is that I lack the knowledge of dos commands so since I'm "into the dos thing" could anyone of you dos literates be generous once again to indicate commands that will facilitate dos searches for win directory,and general stuff! I guess what I mean is important basic dos commands!! Thanks again , read you soon !!!
life is real only then, when "I am "
-
August 26th, 2002, 07:48 PM
#14
Go to this web page and download the file named olddos.exe. Put it into it's own folder, double click on it and it will self extract. You can then copy the files over to your c:\windows\command folder if you want.
There is a help file there, but it is not a windows help file. It will only work in dos mode or a command prompt window and the qbasic program included must be present. This help file has a lot of dos commands and the proper syntax and what the various dos utilities will do. There is some good information in it.
A mouse with dos drivers installed will work with it in dos mode,or with a windows dos window you can navigate with the keyboard.
-
August 26th, 2002, 07:50 PM
#15
Good ol' delimiters... gotta love 'em.
dir /? will tell you quite a bit about how to use DIR and the switches that can be used to help search for files (and do other nifty tasks), but for some good in-depth DOS info, VirtualDr moderator Vernon Frazee has put the MS-DOS 6.22 command reference in one convenient location. The DOS included with Win9x is similar enough to DOS 6.22 to make this an appropriate resource for your needs.
Welcome to the Eclipse(C). The Evolution of an Idea
Options: DCM3 LCR VMS CVM Sil CPI VMI ANI 648 CA1 SACD500 Att CID RLS TIME DLG
Version: ECLIPSE 2.0.0 09/09/98 System is BUSY Thu 07-21-05 1:31 pm
Access Level = 10 Port = 10
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|