Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: "Bad command or file name" during system restore  (Read 19165 times)

0 Members and 1 Guest are viewing this topic.

BC_Programmer


    Mastermind
  • Typing is no substitute for thinking.
  • Thanked: 1140
    • Yes
    • Yes
    • BC-Programming.com
  • Certifications: List
  • Computer: Specs
  • Experience: Beginner
  • OS: Windows 11
Re: "Bad command or file name" during system restore
« Reply #15 on: March 11, 2010, 10:03:39 AM »
Quote
ghost -clone,mode=load,src=R:\T2542.gho,dst=1 -sure -ntil

if you want to restore, run that command.


I was trying to dereference Null Pointers before it was cool.

Veltas



    Intermediate

    Thanked: 7
    • Yes
  • Certifications: List
  • Computer: Specs
  • Experience: Beginner
  • OS: Linux variant
Re: "Bad command or file name" during system restore
« Reply #16 on: March 11, 2010, 11:06:20 AM »
What problem are you actually having that is causing you to use recovery?

If your OS doesn't load and you just get a flashing line, then you can remedy this with the A:\> thing you have, type 'FDISK /CMBR C' (without apostrophes)

(if that fails try 'FDISK /CMBR C:')
(if even that fails try 'C:' and then 'FDISK /MBR')

BC_Programmer


    Mastermind
  • Typing is no substitute for thinking.
  • Thanked: 1140
    • Yes
    • Yes
    • BC-Programming.com
  • Certifications: List
  • Computer: Specs
  • Experience: Beginner
  • OS: Windows 11
Re: "Bad command or file name" during system restore
« Reply #17 on: March 11, 2010, 12:31:12 PM »
What problem are you actually having that is causing you to use recovery?

If your OS doesn't load and you just get a flashing line, then you can remedy this with the A:\> thing you have, type 'FDISK /CMBR C' (without apostrophes)

(if that fails try 'FDISK /CMBR C:')
(if even that fails try 'C:' and then 'FDISK /MBR')

It's FDISK /MBR C:

And unless you want to clobber the Windows XP MBR code with a windows 9x/DOS version it's probably not a good idea.
I was trying to dereference Null Pointers before it was cool.

tom97531

    Topic Starter


    Rookie

    Re: "Bad command or file name" during system restore
    « Reply #18 on: March 11, 2010, 04:43:34 PM »
    What problem are you actually having that is causing you to use recovery?

    My computer has a 40 GB hard drive. I did a restore a while back, now it shows the only drive as:

    2.57 GB USED
    3.19 GB FREE
    5.77 GB TOTAL CAPACITY

    I get a low memory warning very quickly.

    This has happened to me once before when it was under warranty and tech support helped me increase my drive capacity by doing another restore, but I don't remember exactly what he did. I am trying to do another restore hoping it will fix the problem.


                     --UPDATE--

    BC_Programmer 's suggestion (ghost -clone,mode=load,src=R:\T2542.gho,dst=1 -sure -ntil) did the trick. Unfortunately, it's still showing the hard drive as 5.77 GB. I'm going to consider this topic resloved since I was able to complete my restore and will now repost my new problem (low capacity hard drive) under another topic.

    Thanks to all!

    Veltas



      Intermediate

      Thanked: 7
      • Yes
    • Certifications: List
    • Computer: Specs
    • Experience: Beginner
    • OS: Linux variant
    Re: "Bad command or file name" during system restore
    « Reply #19 on: March 12, 2010, 01:17:28 AM »
    It's FDISK /MBR C:

    And unless you want to clobber the Windows XP MBR code with a windows 9x/DOS version it's probably not a good idea.

    You sure about that?  I thought an XP recovery disc allowed an XP MBR to be made, oh well; best not to try it!

    :Restore
    @echo off
    ghost -clone,mode=load,src=R:\T2542.gho,dst=1 -sure -ntil


    Nice one BC_Programmer, didn't spot that (although the 'XP RESTORE COMPLETE' afterwards probably should have rung bells in my head.

    Also, what on earth is this bit for:
    goto exit

    :exit

    Looks like space wasn't an issue, eh?

    BC_Programmer


      Mastermind
    • Typing is no substitute for thinking.
    • Thanked: 1140
      • Yes
      • Yes
      • BC-Programming.com
    • Certifications: List
    • Computer: Specs
    • Experience: Beginner
    • OS: Windows 11
    Re: "Bad command or file name" during system restore
    « Reply #20 on: March 12, 2010, 07:09:59 AM »
    You sure about that?  I thought an XP recovery disc allowed an XP MBR to be made, oh well; best not to try it!

    The only thing that would even remotely possibly make a XP MBR would be the recovery console. And that doesn't have a FDISK command; the proper way is FIXMBR.

    In this case, it looks more like a DOS installation booting to run ghost, in which case FDISK (if present) would write a DOS MBR.

    basically, for windows and DOS from windows 9x/ME and earlier, you would use FDISK /MBR; for Windows NT (including XP) you use FIXMBR. Except for Vista and Windows 7, since I've never had to run a recovery of any sort on those systems (it's probably part of the "repair" on the discs, though).

    Of course, this little "recovery" disc is a bit strange- It's really just a shell around ghost. I was going to say I was surprised but then I saw this was an eMachines - (which also explains why they didn't create the menu properly, heh)

    Another thing that half-confirms that this is a rather standard MS-DOS OS, rather then some sort of recovery console thingamajig, was the seemingly peculiar operation of "MORE". with Pre-NT "command.com" the pipe redirection character would be performed via the creation of some temporary files. Normally, these are created in the "TEMP" directory (that is, using the environment variable). However, when no TEMP variable is set, it just uses the current directory. In this case, since the installation is really running off of a read-only media, it can't.


    Quote

    Also, what on earth is this bit for:

    My guess is the batch wasn't written by a human but by a program or something, which might explain that.





    I was trying to dereference Null Pointers before it was cool.

    Geek-9pm


      Mastermind
    • Geek After Dark
    • Thanked: 1026
      • Gekk9pm bnlog
    • Certifications: List
    • Computer: Specs
    • Experience: Expert
    • OS: Windows 10
    Re: "Bad command or file name" during system restore
    « Reply #21 on: March 12, 2010, 11:02:21 AM »
    Quote
    My guess is the batch wasn't written by a human but by a program programmerr or something, which might explain that.
    Yes, not written by a human!
    But maybe a programmer!