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

Author Topic: Need help for my Autoexec.bat file for a HDD boot partition  (Read 7873 times)

0 Members and 1 Guest are viewing this topic.

the_importer

    Topic Starter


    Greenhorn

    Need help for my Autoexec.bat file for a HDD boot partition
    « on: February 12, 2009, 06:42:32 PM »
    Hi there,

    It's been age since I worked in good old DOS days, so I'm sort of out of touch.

    So anyway, I bought a Netbook with no optical drive. I made a small partition and transferred the Windows XP CD files from my USB key to it. I made a bigger partition to act as the C drive for Windows XP to install on.

    My only problem is how to make that main partition boot in DOS mode as a C drive. I formatted the partition with the format "x: /s command" and copied the files from my 2nd USB key that I used as a boot disk on to it. Everything is there (command.com, autoexec.bat, etc...) but the partition is still not bootable.

    I think the problem is my autoexec.bat file. Can anyone tell me what I should modify?

    @ECHO OFF
    IF "%config%"=="BOOT_MIN" GOTO BOOT_MIN
    SET EXPAND=YES
    SET DIRCMD=/O:N
    SET temp=c:\
    SET tmp=c:\
    PATH=A:\
    LH MSCDEX.EXE /D:oemcd001 /L:D
    ECHO.
    MOUSE.COM
    ECHO.
    DOSKEY /INSERT
    ECHO Available programs:
    ECHO   ATTRIB  DEBUG   DELTREE   DOSSHELL  EDIT
    ECHO   FDISK   FORMAT  FORMATNT  REGEDIT   SCANDISK
    ECHO   SYS     XCOPY
    GOTO QUIT

    :BOOT_MIN
    ECHO Note: This mode has been included for DIAGS.EXE compatibility.

    :QUIT



    Thank you

    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: Need help for my Autoexec.bat file for a HDD boot partition
    « Reply #1 on: February 12, 2009, 06:56:03 PM »
    autoexec.bat runs AFTER DOS boots...
    I was trying to dereference Null Pointers before it was cool.

    GuruGary



      Adviser
      Re: Need help for my Autoexec.bat file for a HDD boot partition
      « Reply #2 on: February 12, 2009, 06:58:56 PM »
      The FORMAT X: /S should have done it.  The AUTOEXEC.BAT won't be your problem.  You don't even need an AUTOEXEC.BAT to boot.  In fact, I would trim yours down to something more simple like just
      Code: [Select]
      @echo off
      set path=C:\

      To troubleshoot the main problem of not booting to the C: drive ... Run FDISK to be sure the partition is set to Active.

      If that's not it, post back and we'll try something else.

      the_importer

        Topic Starter


        Greenhorn

        Re: Need help for my Autoexec.bat file for a HDD boot partition
        « Reply #3 on: February 12, 2009, 07:09:05 PM »
        Afraid that won't work. My Small USB that acts as the boot disk is actually considered the first drive in my PC and FDISK won't allow me to Activate any partition that is NOT on the first drive (which is my USB key).

        Geek-9pm


          Mastermind
        • Geek After Dark
        • Thanked: 1026
          • Gekk9pm bnlog
        • Certifications: List
        • Computer: Specs
        • Experience: Expert
        • OS: Windows 10
        Re: Need help for my Autoexec.bat file for a HDD boot partition
        « Reply #4 on: February 12, 2009, 07:56:10 PM »
        Quote
        My Small USB that acts as the boot disk
        s actually considered the first drive in my PC

        Curious minds here need to know what kind of laptop does that?
        You say it wants to boot from the USB device?
        As the first drive?

        the_importer

          Topic Starter


          Greenhorn

          Re: Need help for my Autoexec.bat file for a HDD boot partition
          « Reply #5 on: February 12, 2009, 07:58:48 PM »
          It's a Dell Mini 9 Netbook

          Also, it's not that I want to have my USB Key to act as the main drive, it's just that I can't boot with anything else. There's not optical drive and no disk drive, so I can't boot with anything BUT a USB key.

          GuruGary



            Adviser
            Re: Need help for my Autoexec.bat file for a HDD boot partition
            « Reply #6 on: February 12, 2009, 10:15:24 PM »
            Well, you aren't going to be able to boot from a partition that isn't active.  I am pretty sure that is your problem.  Try using a 3rd party tool.

            I am pretty sure that the FDISK.EXE from FreeDOS will run under just about any version of dos (6.x and 7.x that came with Win9x) and it will let you make active partitions on any drive.  Actually, probably just about any FDISK or other partition tool from any company will let you set active partitions on drives that are not the 1st drive ... except the Microsoft versions.

            the_importer

              Topic Starter


              Greenhorn

              Re: Need help for my Autoexec.bat file for a HDD boot partition
              « Reply #7 on: February 13, 2009, 04:36:07 AM »
              Thank for the reply, but I've tried stating the XP installation to put the OS on my "D" drive and I got a a message regarding SmartDrive, which is something that happen when you run the winnt.exe file from i386 folder. I'll go buy an external DVD-Burner, this should solve all my problems.

              Geek-9pm


                Mastermind
              • Geek After Dark
              • Thanked: 1026
                • Gekk9pm bnlog
              • Certifications: List
              • Computer: Specs
              • Experience: Expert
              • OS: Windows 10
              Re: Need help for my Autoexec.bat file for a HDD boot partition
              « Reply #8 on: February 13, 2009, 09:11:02 PM »
              Here is a review of this machine.
              http://www.notebookreview.com/default.asp?newsID=4578
              If I had one, I would just leave it as it is.
              It is not super fast, but it is not intended to be a high performer.
              It is small, cure and low priced.

              The link I gave above indicates that this model does not normally  use a Hard Drive or a CD-ROM drive.

              Be careful about using FreeDOS on a large drive. DOS expects a hard drive to be under about 2GB.

              the_importer

                Topic Starter


                Greenhorn

                Re: Need help for my Autoexec.bat file for a HDD boot partition
                « Reply #9 on: February 13, 2009, 09:30:10 PM »
                Here is a review of this machine.
                http://www.notebookreview.com/default.asp?newsID=4578
                If I had one, I would just leave it as it is.
                It is not super fast, but it is not intended to be a high performer.
                It is small, cure and low priced.

                The link I gave above indicates that this model does not normally  use a Hard Drive or a CD-ROM drive.

                Be careful about using FreeDOS on a large drive. DOS expects a hard drive to be under about 2GB.

                This is why a review is personal opinion:

                1- This netbook came with Windows XP home, not any differences between this and XP pro in terms of PC requirements.

                2- I bought this PC at $300 CAD during a BestBuy special and I just bought an external LG DVD burner for $60 CAD which was on special as well and the two of them work great together.

                3- I'm using this laptop to type  this as we speak, it's powerful enough.

                4- Most reviews I read were positives.

                patio

                • Moderator


                • Genius
                • Maud' Dib
                • Thanked: 1769
                  • Yes
                • Experience: Beginner
                • OS: Windows 7
                Re: Need help for my Autoexec.bat file for a HDD boot partition
                « Reply #10 on: February 13, 2009, 10:01:32 PM »
                A few things to keep in mind here:
                If the machine's MBoard/BIOS does not support booting to a USB device no autoexec.bat changes will make this different.
                You cannot simply copy all the Windows files from any install and expect it to be an installable fix.
                Installing from any USB device since XP was released is an exercise in futility and can only be done with a sledgehammer and 3 days of spare time...this is all by design.

                Do you have an XP CD ? ?
                " Anyone who goes to a psychiatrist should have his head examined. "

                the_importer

                  Topic Starter


                  Greenhorn

                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #11 on: February 13, 2009, 10:09:15 PM »
                  A few things to keep in mind here:
                  If the machine's MBoard/BIOS does not support booting to a USB device no autoexec.bat changes will make this different.
                  You cannot simply copy all the Windows files from any install and expect it to be an installable fix.
                  Installing from any USB device since XP was released is an exercise in futility and can only be done with a sledgehammer and 3 days of spare time...this is all by design.

                  Do you have an XP CD ? ?

                  See above :)

                  patio

                  • Moderator


                  • Genius
                  • Maud' Dib
                  • Thanked: 1769
                    • Yes
                  • Experience: Beginner
                  • OS: Windows 7
                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #12 on: February 13, 2009, 10:11:13 PM »
                  See above what ? ?
                  " Anyone who goes to a psychiatrist should have his head examined. "

                  Geek-9pm


                    Mastermind
                  • Geek After Dark
                  • Thanked: 1026
                    • Gekk9pm bnlog
                  • Certifications: List
                  • Computer: Specs
                  • Experience: Expert
                  • OS: Windows 10
                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #13 on: February 13, 2009, 10:36:47 PM »
                  Quote
                  See above what ? ?
                  Patio:
                  He has aIt's a Dell Mini 9 Netbook
                  He wants to install from a copy of the CD.
                  He put the CD on his USB stick.

                  It seems the Mini 9 does not allow any other way of booting.
                  I guess.
                  If I had one I would not fool around with it.

                  He wants to play with an old version of DOS, or something like that.


                  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: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #14 on: February 14, 2009, 09:42:05 AM »
                  old versions of DOS will not boot from a USB drive without a heavy amount of HDD emulation on the part of the BIOS. the BIOS implementation of USB booting assumes that the OS installed to the USB drive is
                  USB aware" such as a diagnostic program intended to run of the drive or perhaps a Linux installation.

                  DOS is not USB aware natively, and requires USB drivers, which can only be loaded after MSDOS.SYS and IO.SYS (or IBMDOS.COM and IBMBIO.COM) load into memory and subsequently read the commands in config.sys.

                  freeDOS, on the other hand, being newer and more powerful in general, would have far more success in booting from a USB drive, as geek9pm has suggested.

                  In fact, if your external CD drive won't boot either, then I doubt a thumb-drive will, since under most circumstances a USB-boot aware PC will boot from a external CD drive with a bootable disc just as well as a external thumb-drive or other storage based USB peripheral.
                  I was trying to dereference Null Pointers before it was cool.

                  Dias de verano

                  • Guest
                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #15 on: February 14, 2009, 01:53:31 PM »
                  I have a 128 Mb pen drive that natively boots MS-DOS 7.10 (from a Windows 98 disk).

                  Geek-9pm


                    Mastermind
                  • Geek After Dark
                  • Thanked: 1026
                    • Gekk9pm bnlog
                  • Certifications: List
                  • Computer: Specs
                  • Experience: Expert
                  • OS: Windows 10
                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #16 on: February 14, 2009, 03:00:28 PM »
                  Quote
                  I have a 128 Mb pen drive that natively boots MS-DOS 7.10 (from a Windows 98 disk).

                  Hey, that may be what he needs.  :o
                   And other curious minds would like to know.
                   How do you get MS-DOS 7 onto a USB thing and have it boot.

                  Dias de verano

                  • Guest
                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #17 on: February 14, 2009, 03:04:32 PM »
                  Quote
                  I have a 128 Mb pen drive that natively boots MS-DOS 7.10 (from a Windows 98 disk).

                  Hey, that may be what he needs.  :o
                   And other curious minds would like to know.
                   How do you get MS-DOS 7 onto a USB thing and have it boot.

                  I used the HP USB Boot Utility. It's all here

                  http://www.bootdisk.com/pendrive.htm


                  patio

                  • Moderator


                  • Genius
                  • Maud' Dib
                  • Thanked: 1769
                    • Yes
                  • Experience: Beginner
                  • OS: Windows 7
                  Re: Need help for my Autoexec.bat file for a HDD boot partition
                  « Reply #18 on: February 15, 2009, 06:19:27 AM »
                  Let's hope his NetBook supports booting from USB devices.
                  So far it doesn't sound like it.
                  " Anyone who goes to a psychiatrist should have his head examined. "

                  GuruGary



                    Adviser
                    Re: Need help for my Autoexec.bat file for a HDD boot partition
                    « Reply #19 on: February 15, 2009, 09:04:50 AM »
                    I am pretty sure it supports booting to USB devices.

                    patio

                    • Moderator


                    • Genius
                    • Maud' Dib
                    • Thanked: 1769
                      • Yes
                    • Experience: Beginner
                    • OS: Windows 7
                    Re: Need help for my Autoexec.bat file for a HDD boot partition
                    « Reply #20 on: February 15, 2009, 03:48:33 PM »
                    I am pretty sure it supports booting to USB devices.

                    Source ? ?
                    " Anyone who goes to a psychiatrist should have his head examined. "

                    GuruGary



                      Adviser
                      Re: Need help for my Autoexec.bat file for a HDD boot partition
                      « Reply #21 on: February 15, 2009, 10:03:45 PM »
                      Source ? ?
                      Experience.  It has been at least 2 years since I have seen a new laptop that does not support booting to USB devices.

                      But here is a link that further supports my guess: http://www.ubuntumini.com/2008/10/installing-ubuntu-on-dell-inspiron-mini.html
                      It includes a video of the BIOS screen changing the boot options, but here text of "Step 2":
                      Quote
                      Step 2. Set your Mini 9 to boot from optical drive or USB

                      At the Dell splash screen (the Dell logo that appears when you turn your Mini on) press 2.
                      This will take you into the Mini's BIOS, from there go to the BOOT tab.
                      Use F6 and F7 (Fn H and J respectively on the mini) to move your intended boot device up and down the list.
                      The optical media drive or USB drive should be a the top of this list.

                      patio

                      • Moderator


                      • Genius
                      • Maud' Dib
                      • Thanked: 1769
                        • Yes
                      • Experience: Beginner
                      • OS: Windows 7
                      Re: Need help for my Autoexec.bat file for a HDD boot partition
                      « Reply #22 on: February 16, 2009, 07:16:11 AM »
                      Got it.

                      Wonder why this is such a struggle then...
                      " Anyone who goes to a psychiatrist should have his head examined. "

                      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: Need help for my Autoexec.bat file for a HDD boot partition
                      « Reply #23 on: February 16, 2009, 10:01:00 AM »
                      Got it.

                      Wonder why this is such a struggle then...

                      probably trying to use DOS 6?
                      I was trying to dereference Null Pointers before it was cool.

                      patio

                      • Moderator


                      • Genius
                      • Maud' Dib
                      • Thanked: 1769
                        • Yes
                      • Experience: Beginner
                      • OS: Windows 7
                      Re: Need help for my Autoexec.bat file for a HDD boot partition
                      « Reply #24 on: February 16, 2009, 01:32:08 PM »
                      Should still be a piece of cake...
                      Use Dias' guide to create a bootable flash drive...boot to the flash and run the OS install.
                      " Anyone who goes to a psychiatrist should have his head examined. "