Format Hard Drive in Single User Mode

Hi All-
I'm having some issues with my MacBook with a bad B-Tree. I've read a lot about how to use DiskWarrior to repair it. I'm not really interested in recovering my data, but I would like to install OS X.
Those who've had a catalog issue or B-tree issue knows that fsck doesn't repair it.
I'm having an issue with the Disk Utility on the start up disk. It's having trouble reading the disk and hangs at "Gathering disk information". I would like to boot into single user more and repartition the disk, I just don't know how.
I have not had any success in finding my answer on the web, and am hoping that you can help out.
Thanks!
john

John,
Disk Utility is also available at the command line. Open Terminal and type:
<pre style="overflow:auto; font-family: 'Monaco'; font-size: 10px">man diskutil</pre>
then press <RETURN> to view the man pages. I suggest that you give those man pages a good read, then come back here if you have further questions. If you cannot get to the man pages (if you don't have a working installation of OS X), I could give you a specific command to run, but I'll need to know absolutely everything about what results you want (just "repartition" is WAY too vague).
Also, you might want to give Disk Utility another try, and give it plenty of time to handle the broken file system. Sometimes, a broken file system will become available for formatting, but only after an extended period of time (several minutes to an hour).
Scott

Similar Messages

  • Mounting a usb hard drive in single user mode

    I've gotten as far as connecting the hard drive at boot, but I don't know how to figure out which dev is the hard drive, and which arguments to use with the mount command. I can't do much when I login, and I'm trying to cp files from my hard drive to my external hard drive through single user mode.
    Any help is greatly appreciated. Thanks.

    Hi leung wai,
       I wouldn't mind knowing the answer myself. I think the problem with doing it in the manner you attempted is that the device tree hasn't been created yet so the mount command is certainly not going to work. I assume that the answer is to start up enough of the system to have the device tree created. Unfortunately, I don't know where in the startup process that occurs. You could try the following command after making the boot volume writable:
    /usr/libexec/registermach_bootstrapservers /etc/mach_init.d
    Then check to see if the /dev virtual filesystem has been created. Of course it wouldn't surprise me if that didn't also mount your disks. If not, try the following:
    /sbin/SystemStarter
    It should have been created after that because at that point almost the whole system has started.
    Gary
    ~~~~
       You've been telling me to relax all the way here, and
       now you're telling me just to be myself?
             -- The Return of the Secaucus Seven

  • Mount an external hard drive in single user mode

    Do any know how to mount an external hard drive in single user mode:
    I've issue the following command:
    /sbin/mount -uw /
    mkdir /Volumes/ex1
    /sbin/mount_hfs /dev/disk2s3 /Volumes/ex1
    (I've checked my external hard drive using df -k showing the device is disk2s3)
    Result:
    Permission denied

    Hi leung wai,
       I wouldn't mind knowing the answer myself. I think the problem with doing it in the manner you attempted is that the device tree hasn't been created yet so the mount command is certainly not going to work. I assume that the answer is to start up enough of the system to have the device tree created. Unfortunately, I don't know where in the startup process that occurs. You could try the following command after making the boot volume writable:
    /usr/libexec/registermach_bootstrapservers /etc/mach_init.d
    Then check to see if the /dev virtual filesystem has been created. Of course it wouldn't surprise me if that didn't also mount your disks. If not, try the following:
    /sbin/SystemStarter
    It should have been created after that because at that point almost the whole system has started.
    Gary
    ~~~~
       You've been telling me to relax all the way here, and
       now you're telling me just to be myself?
             -- The Return of the Secaucus Seven

  • Mount external Hard drive in Single user mode

    Do any know how to mount an external hard drive in single user mode:
    I've issue the following command:
    /sbin/mount -uw /
    mkdir /Volumes/ex1
    /sbin/mount_hfs /dev/disk2s3 /Volumes/ex1
    (I've checked my external hard drive using df -k showing the device is disk2s3)
    Result:
    Permission denied

    I seem to remember the "Permission denied" or "Device busy" coming up in some situations but not others when attempting to mount drives at this early stage in "single user" mode...
    It might be worth trying to run:<pre>sh /etc/rc</pre>This is actually present among the "Tiger" messages in "Single User" mode, as the procedure to continue booting but remaining in "single user" mode. Indeed, it seems to start up the usual "services" like starting disk arbitration (so you can eg. use 'diskutil' to repair permissions, or loading "NetInfo" so you don't need to work in '-raw' mode - in the past, people had posted complicated procedures for doing these things manually.
    After running the 'rc' script, try creating your mount point and and running 'mount_hfs' as usual...

  • How do i repair my hard drive in single user mode when disk is full?

    Hi there Apple Community!
    I have an old Macbook Pro 17" with an upgraded 500GB harddrive and 4GB memory. I'm running Mac OSX Lion.
    Was hoping you could help me out.  THis is the situation:
    Long story short I spilt wine on my macbook and the screen went a bit blobby. Switched it off for a few days, removed the battery etc. etc. Opened it up cleaned out as much of the wine as possible, but unfortunately some of it came in behind the LCD, so now the screen has a nice red stain.  Obviously I'm not going to try to clean that out of the LCD. 
    My Macbook Pro still worked for a few days after that, but then my harddrive gave up.  I booted in the Recovery HD menu, verified the drive and I got the error "Keys out of order - This disk needs to be repaired, click Repair Disk." I attempted to repair the disk but got the error "Keys out of order - Disk Full Error - The volume could not be repaired".
    Unfortnately of this 500GB I only have about 7GB free on it, as I have a huge iPhoto and iTunes library. I did make a TIme Machine backup of my user directory, but not the system files.  I don't really want to do a clean install because:
    1) I'm paranoid that there's something I did not fully back up
    2) I don't want to have to download the whole Mac OSX Lion again. I should have made a USB bootable backup when I had the chance.  I don't have access to a broadband connection.
    What I feel are my viable options, are as follows:
    1) I did buy a replacement internal 500GB harddrive, so I can probably try to make an image of the hard drive to this new drive, but not sure how. I believe it's through the Disk Utility with the "New Image" option but not sure how to go from there.
    2) Start up in Single User Mode and delete some unnecessary files and re-attempt to run the fschk -fy utility again (I tried this earlier and got the same Disk Full Error).  - the problem with this is, I'm not familiar with the command line and have no clue how to delete files.  I don't know my way around Unix.
    3) I can also probably attempt to make a Ghost Image or Acronis Image of the failed drive to this new drive, but not sure if Norton Ghost or Acronis True Image will be able to read this HFS drive - I believe it's possible as it's a simple hard drive clone. 
    If you can guide me in the best option - probably there is a better solution than my proposed ones above, I appreciate any feedback and comments you might have!

    hi Baltwo,
    So I ended up copying my user folder to another harddrive. I managed to download the whole osx lion again, reinstalled, and recovered my home folder using this discussion:
    http://support.apple.com/kb/HT1428
    I have managed to get all my files back. My iTunes library works fine, but my iPhoto library when I open it, get the following error:
    iPhoto cannot be opened because of a problem.
    Here's the error log
    Process:         iPhoto [1540]
    Path:            /Applications/iPhoto.app/Contents/MacOS/iPhoto
    Identifier:      com.apple.iPhoto
    Version:         8.1.2 (8.1.2)
    Build Info:      iPhotoProject-4240000~8
    Code Type:       X86 (Native)
    Parent Process:  launchd [209]
    Date/Time:       2012-09-19 19:56:45.528 +0200
    OS Version:      Mac OS X 10.7.4 (11E53)
    Report Version:  9
    Sleep/Wake UUID: 7948ABE2-5294-4F87-B6E3-777095A2F2EE
    Interval Since Last Report:          4780 sec
    Crashes Since Last Report:           9
    Per-App Crashes Since Last Report:   9
    Anonymous UUID:                      70117D38-03EA-4F9C-B810-50B743864B9E
    Crashed Thread:  0
    Exception Type:  EXC_BREAKPOINT (SIGTRAP)
    Exception Codes: 0x0000000000000002, 0x0000000000000000
    Application Specific Information:
    dyld: launch, loading dependent libraries
    Dyld Error Message:
      Library not loaded: /System/Library/PrivateFrameworks/iLifeSlideshow.framework/Versions/A/iLifeSlid eshow
      Referenced from: /Applications/iPhoto.app/Contents/MacOS/iPhoto
      Reason: image not found
    I've done an Apple Software Update but it didn't find an update for iPhoto.
    One thing to note is, this library was originally created on iLife 08, upgraded to '09 and it stayed on that version. It hasn't een upgraded to iLife '11.  It worked fine on my previous install of OSX Lion.  How do I recover the library without upgrading to '11 ?

  • How format the hard disk in single-user mode

    Hi all, i would like to format the internal hard disk of my macbook pro 13'' through single-user mode. How can I do it, please?

    Ok, to do that you need to hold c and boot off the 10.6 installer disk and second screen in under the Utilities Menu is Disk Utility.
    You can then select the hard drive makers name (your "bare metal") and peform the wipe/format of the entire drive or a "partition" on that drive.
    In the picture below there is only one partition, the Mac HD. In the picture above there are two partitions which both would show up under the hard drive makers name and both or either partition can be wiped in Disk Utility.
    Use the Security Option to Zero your hard drive of all lingering data.
    When you Quit Disk utiltiy, your back in the installer and can quit or install OS X.
    Note: messing with Disk utility will erase all data on the drive, if there is something you need to recover better stop and ask!
    If you don't see your internal boot drive in Disk Utility, the drive is dead.

  • How to mount USB & CDROM drives from single user mode - Solaris boot disk?

    Hi All,
    I need to carry out ufsrestore on a single newly replaced system disk (no redundancy / mirroring) from either USB or CDROM drives from the following steps:
    ( i ) GRUB => e, e, cdrom –s, Enter, b (boot from Solaris 10 x86 media).
    ( ii ) Choose menu 1 for Install Solaris Interactive Mode to reach single user mode.Below are the commands that I have tried in single user mode without success:
    mount –r –F pcfs /dev/dsk/c1t0d0p0 /cdrom (after unmount Solaris CD)
      mount: /dev/dsk/c1t0d0p0 is not a DOS filesystem.
    svcadm –v enable smserver
      svcadm: Pattern ‘smserver’ doesn’t match any instances
    svcadm enable autofs
      svcadm: Pattern ‘autofs’ doesn’t match any instances
    devfsadm
      devfsadm: mkdir failed for /dev 0s1ed: Read-only file system
    mkdir /mnt
      mkdir: Failed to make directory “/mnt”; Read-only file systemPart of the problem is due to the current READ ONLY filesystems which does not allow the creation of mount point such as /mnt.
    I have been able to create both / root (/dev/dsk/c1t0d0s0) and /export/home (/dev/dsk/c1t0d0s0) filesystems with newfs that are awaiting for restore using ufsrestore.
    The only option I am left with is to attach a secondary disk to install Solaris 10 on either of them before bring the system to multi-user mode so that service such as volmgt, autofs, volfs are available to access USB & CDROM drives.
    Any suggestion on how to resolve this issue?
    Many thanks,
    Jack

    Hi JKGN,
    Is the directory a located under the root filesystem. ie /a? Are there any other mount point for say USB drive as well? I am not in a position to try it out right now but will get back
    to you soon on whether /a exist or not.
    Btw, the last thing I managed to do on this system at the time was added a secondary 1TB internal disk with the intention to restore both / and /export/home data onto this disk while
    making use of all the disk device management services such as the following services only available in a fully installed Solaris system (both single & multi-user modes) installed on the
    primary disk:
    # svcs smserver
    STATE          STIME    FMRI
    online         Jun_08   svc:/network/rpc/smserver:default
    # svcs autofs
    STATE          STIME    FMRI
    online         Jun_08   svc:/system/filesystem/autofs:default
    # devfsadm
    # iostat -En
    c1t0d0           Soft Errors: 0 Hard Errors: 0 Transport Errors: 0
    Vendor: ATA      Product: SAMSUNG HD321KJ  Revision: 0-11 Serial No: 
    Size: 320.07GB <320072932864 bytes>
    Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
    Illegal Request: 41 Predictive Failure Analysis: 0
    c0t0d0           Soft Errors: 0 Hard Errors: 5 Transport Errors: 0
    Vendor: PHILIPS  Product: DVD+-RW DVD8801  Revision: AD21 Serial 
    Size: 17.54GB <17538875392 bytes>
    Media Error: 0 Device Not Ready: 5 No Device: 0 Recoverable: 0
    Illegal Request: 10 Predictive Failure Analysis: 0
    c2t0d0           Soft Errors: 0 Hard Errors: 0 Transport Errors: 0
    Vendor: JetFlash Product: Transcend 16GB   Revision: 1100 Serial No: 
    Size: 0.00GB <0 bytes>
    Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
    Illegal Request: 7 Predictive Failure Analysis: 0
    # rmformat
    Looking for devices...
         1. Volmgt Node: /vol/dev/aliases/cdrom0
            Logical Node: /dev/rdsk/c0t0d0s2
            Physical Node: /pci@0,0/pci-ide@1f,1/ide@0/sd@0,0
            Connected Device: PHILIPS  DVD+-RW DVD8801  AD21
            Device Type: DVD Reader/WriterHowever, I was disappointed that "iostat -En" has not found the secondary disk (1 TB) even though it was available earlier, for Solaris installation as the only disk on the same system.
    As a result, I am left with no option but the need to rebuild this system with only a single primary disk while in single user mode. However, the single user mode that I am in is the
    one from Solaris installation disk with restrictive (_cannot create folder for mount point or running disk management utilities_) capability such as those services just covered, compared to one from a completed Solaris installation system with full access to all filesystems and utilities / commands in general.
    I would very much value your assistance on how to mount both CD & USB in this restrictive limited Read Only OS (assume that it is running from memory) in order to get complete access to
    the blank primary disk so that full restore with ufsrestore could take place.
    Thanks in advance,
    Jack
    Edited by: 797805 on 9/06/2012 04:15

  • Mounting external drives in single-user mode?

    Sigh. What were the odds of the HD on my month-old MacBook Pro and the HD on my somewhat older one (which was filling in for the moment as a backup) failing on the same night? Pretty low, I'm guessing, but that's what has happened. The Genius Bar has confirmed that the new drive is completely toast, and Apple is replacing it now, but of course they can't salvage the data. As for the old drive, while it won't boot and isn't visible to other machines in target disk mode, I am able to mount it in single-user mode and even view text files. What I can't seem to do is mount my external FireWire/USB2 drive so that I can try actually copying the files off.
    I've re-read the man page for "mount" in hopes of discovering the correct incantation, but so far it has eluded me. I've been trying things like "/sbin/mount -w /dev/disk1 /Volumes" and "/sbin/mount -w /dev/disk1 /Volumes/rescue", which return "Permission denied" and "No such file or directory" respectively...not sure that's the right device, but finding an acceptable mount point seems to be an issue regardless. Hoping someone can point me in the right direction, and thanks for reading.

    Thanks, macbig...no joy yet, but definitely a helpful link.
    I've confirmed via System Profiler on laptop #3 that my external USB drive is formatted as MS-DOS FAT32, so mount_msdos seems like the right utility to use. (The drive shows up there as /dev/disk1s1.) Meanwhile, "ls /dev/disk*" on the problem machine returns the following:
    /dev/disk0 /dev/disk0s1 /dev/disk0s2 /dev/disk1 /dev/disk1s1 /dev/disk1s2 /dev/disk1s3 /dev/disk2 /dev/disk2s1
    I've created /Volumes/rescue as a mount point and tried most of those devices with "/sbin/mount_msdos [device] /Volumes/rescue", with the following results:
    /dev/disk1:
    mount_msdos: Unsupported sector size (0)
    /dev/disk1s1:
    mount_msdos: Unsupported sector size (1)
    /dev/disk1s2:
    mount_msdos: /dev/disk1s2: Bad file descriptor
    /dev/disk1s3:
    mount_msdos: Unsupported sector size (0)
    /dev/disk2:
    mount_msdos: Unsupported sector size (64543)
    /dev/disk2s1:
    kextload: cannot resolve dependencies for kernel extension /System/Library/Extensions/msdosfs.kext
    error loading extension /System/Library/Extensions/msdosfs.kext
    mount_msdos: msdos filesystem is not available
    Based on this, I'm guessing that disk2s1 is the device I want. Unfortunately, when I try to poke around in /System/Library/Extensions, I'm getting I/O errors...gah. I have a bad feeling about this.

  • Format mac hd in single user mode.

    Several have asked this question.  I haven't seen anybody actually answer it.  People start asking, "why would you want to do that?  You really don't want to, instead you should..."  I really want to.  I have explored all the options available.  I don't really want to get into why.  I just want to know how.  Please.

    As I attempted to suggest, solutions like Recovery Partition or booting from the installation cd are not available.  I have been working on this for some months. 
    For others in a similar situation, I find I can run diskutil by running these commands first
    mount -uw /
    launchctl load /System/Library/LaunchDaemons/com.apple.notifyd.plist
    launchctl load /System/Library/LaunchDaemons/com.apple.configd.plist
    launchctl load /System/Library/LaunchDaemons/com.apple.diskmanagementd.plist
    launchctl load /System/Library/LaunchDaemons/com.apple.securityd.plist
    launchctl load /System/Library/LaunchDaemons/com.apple.diskarbitrationd.plist
    Single User Mode boots onto the OSX Base System partition.  Since I want to format the Recovery Partition, the operation seems doable.  And once I have diskutil loaded into memory, formatting the OBS partion might be possible too.  Will work on that.
    In the meantime, How do I boot from Apple servers?

  • Boot Snow Leopard from Thumb Drive in Single User Mode on Macbook Air

    I'm trying to boot from a thumb drive that I transferred the Snow Leopard .dmg on. My macbook air only lets me get into single user mode. Every time I try to boot or enter safe mode or regular mode, the Macbook Air shuts down.

    I do have the installation media on my usb flash drive. I'm sure it's leopard, and the problem is that I cannot get passed the apple logo on boot. The laptop turns off after trying to finish the boot for twenty seconds. However, I can get into single user mode. I just can't seem to install the media in single user mode due to my lack of know how.

  • Mounting devices as drives in single-user mode

    i am having a problem with a computer that won't start up into mac osx and i am wondering about mounting an external hard drive that shows up under /dev/ but not /volumes/. i am trying to back up some files using the tar command, but i need a drive available first before i can do so. thanks in advance for any replies!

    Gary,
    THANK YOU!!!
    The "diskutil disableJournal /" command worked and allowed me to FINALLY mount the disk via target mode. I successfully backed up my most important files. As of now, I don't know why this has worked, despite the read-only status of the disk, but it has. Once I typed the command and hit enter, I heard the hard drive spinning and doing some work for about 15 seconds. After that, nothing happened and, for some reason, I decided to force a shut down, restart the mac in target mode, and see what happened. However, I tried trashing some stuff, which locked up both computers, but I am trying the command again and being more patient with the it to see if I can do some more back up work. Even if that was a short-lived fix, it was long enough for me to back up my honors thesis, which I worked on for two years and counting. I have been working on this problem to no avail (off and on) for the past two months, so to finally see some progress has been pretty nice (understatement). whew! yeah!
    again, thanks!
    neal
    P.S., i will do some diagnostic stuff on the disk after i attempt another disabling of journaling (fsck or the tiger dvd diskutility app). I'll keep you posted.

  • Mounting USB Drive in Single user mode

    My Intel Imac fails to boot up. fsck -y fails too ... can't think of any other way to get my data out ...
    I am left with the only option to copy my data into my usb drive in the terminal mode .
    But I am unable to mount my USB drive. I also need to know the mount point. can anyone provide me with help.

    The mountpoint can be anything you want. The tricky part is figuring out the device your drive is using. I don't know for sure (can't test it right now), but dmesg or one of the system logs might have that information in it if you boot to SUM with the external drive attached. The logs also might have a record of what device this drive used in the past when connected. It will likely use the same device every time.
    If not, you can guess. I have seen one of my external disks mount using the device disk1s2. If I were to attach that to my machine in SUM, I could then mount it like this:
    mount_hfs /dev/disk1s2 /Volumes/recover
    where the mount point /Volumes/recover is something I created (i.e. just a simple "mkdir /Volumes/recover"). This could be anything you want.

  • Single-User Mode Copying Files/System Does not Boot Past Apple Logo Screen

    I have a Macbook 2.0GHZ, 2GB RAM, that recently tried to download a secuirty and keynot update. Following the download the system will no longer boot past the Apple Logo Screen with the spinning wheel. I do not have access to a OS disk yet or to a firewire cable either. I've have seen posts from others that describe how to use traget disk mode to reinstall the secuirty update manually and then they can boot their computer. Safe mode will not work. I did boot into single-user mode and run the disk utility there and it says my HD is OK. Since I do not have a firewire or an OS Disk, I am wondering if there is a way to copy those files i need to a USB pen stick then install them onto the computer via single-user mode, considering this is the only way I can boot and manipulate the machine at this time. If this is not possible please let me know so I can find a way to scrounge up a firewire cable or disk. Thank you in advance for any assistance.
    Ted K

    Thanks to Limnos and BDAqua I know you guys have helped others with these kind of problems from the other posts I read. I just want to list what I did exactly in case anyone wants to try to do this with a usb drive or does not have access to a boot disk or firewire cable.
    1: Install security update on a pen drive
    2: Boot in single user mode, CMD-S on startup
    3: /sbin/mount -uw /
    4: mkdir /Volumes/usb (usb can be any name, name of usb drive or anything you want)
    5: ls /dev (you need to get the drive listing for the usb drive to mount it appropriately, it should be disk#s# but this is close to what the HD and Cd drives are listed as so you may need to list once before you put the usb stick in and once ater. I had issues inserting the usb drive in single-user mode and it would freeze up the root drive)
    6: /sbin/mount_msdos /dev/disk1s1 /Volumes/usb (this mounts the usb drive, i had to use msdos because of how my usb drive was formatted, you may need to check your usb drive format, hfs is the apple format for usb drives but it did not work for me)
    7: cp /Volumes/usb/SecUpd2009-001Intel.dmg (this copies the files from the usb drive to the root drivel, at this point you no longer need the usb drive)
    8: hdiutil mount /SecUpd2009-001Intel.dmg (this mounts the disk image)
    9: cd /Volumes/"Security Update 2009-001" (after i mounted the image this is how it appeared in the Volumes directory, you might need to do ls /Volumes to get the name, the quotes are important to get the whole file directory changed)
    10: installer -pkg SecUpd2009-001Intel.pkg -target / (this installs the acutal update, i used the SecUpd2009-001Intel.pkg and it worked though I think you might be able to use "Security Update 2009-001" with quotes as well.)
    11: reboot
    i hope this helps anyone looking to do this. Thanks again to those who helpes and all the other posts that had information that helped me identify and then fix my issue! I still love my mac.

  • Back up files through Single user mode

    Hello there,
    it seems that I have problem with my hard drive. I tried to repair it with disk utility and the fsck command in Single user mode with no luck. The fsck command gives me the "Exited with signal 8" message and it won't start up the usual way or under Safe boot so I came to the conclusion to back up my files on an external drive and reinstall the system. I need step by step instructions how to back up the entire hard drive onto the external drive in Single User mode.

    Do you have another mac with firewire?
    Try target disk mode.
    If you have a second Mac computer, you may want to try to copy over as many files you can. One way is to use target disk mode.
    http://support.apple.com/kb/HT1661
    http://lowendmac.com/misc/06/0710.html
    This requires you to use your installation disk. With errors from fdsk, I do not think you will be able to copy all directories. I used a flash drive. A harddrive should be the same. To copy everything, use the directory /Volumes/Macintosh-HD
    You may try to recover your data by booting up an installation cd/dvd and using the terminal.
    You could try getting into the Unix command line interface and copy some files or directories.
    You can copy files on the Unix command line interface if you placed the flash drive the USB port before powering on your machine.
    Boot up your installation CD or DVD. To do this, place to the CD or DVD its drive. Power off the the machine. Hold down the c key then power on your machine. After you specify the language you will come to the installation panel. Do not install. Go to the top of the screen and click on the tools menu item. Click on Terminal to use the command line interface.
    You should verify that the files have been copied correctly by trying them in another Mac before it the deleting the original.
    *Here is an overview of the commands.*
    Lets assume that the problem account has a short user name of mac.
    #Copy directory "/Applications/Applescript files" to
    # directory "/Volumes/Spotless/Applescript files".
    # "Spotless" is my flash drive.
    ditto -X -rsrc /Applications/Applescript\ files /Volumes/Spotless/Applescript\ files
    #cd is change directory
    cd /Volumes/COPYIT/answers/
    # pwd is print working directory
    pwd
    #the ls command is for list
    # l is long
    # a to show hidden files. not shown in this example.
    # F is type of file where / is directory
    sh-2.05b# # Please note ls is the list command. l is a lower case L
    sh-2.05b# ls -lF
    Here is what these commands mean:
    cd is change directory
    pwd is a print working directory
    ls is list
    sudo is Super user do
    # The sudo command will ask for your administration password. No characters will appear when typing your password. Press return when done typing.
    cp is copy
    copy a file example:
    sh-2.05b#
    sh-2.05b# cd /Volumes/Macintosh-HD/Users/mac/desktop
    sh-2.05b# pwd
    /Volumes/Macintosh-HD/Users/mac/desktop
    sh-2.05b# cp -i answers.txt /Volumes/SpotMore
    Will copy the file answers.txt in the directory SpotMore.
    Some files have a space in the name. You need to escape. see example:
    mac $ ls -l ~/"see it"
    -rw-r--r-- 1 mac staff 3171 Oct 26 23:38 /Users/mac/see it
    mac $
    mac $ cd /Users/mac/Desktop/ttt\ html\ copy/
    Do you know about tabing? Type in a few letters of a name then press the tab key. The computer will type out the rest of the name if it is unique.
    The up arrow key will retrive the previous command. You the left arror and right arror keys to move around. Use the delete key to delete a character to the left.
    <eol>
    *More examples and moving around*
    sh-2.05b# pwd
    sh-2.05b# ls /Volumes
    .Trashes        Classic                Macintosh-HD
    ._.Trashes      Mac OS X Install DVD   SpotMore
    sh-2.05b#
    sh-2.05b# df -h
    Filesystem      Size   Used  Avail Capacity  Mounted on
    /dev/disk4s3    2.6G   2.5G    89M    97%    /
    devfs           121K   121K     0B   100%    /dev
    fdesc           1.0K   1.0K     0B   100%    /dev
    <volfs>         512K   512K     0B   100%    /.vol
    /dev/disk5      467K   9.0K   435K     2%    /Volumes
    /dev/disk6       95K    64K    27K    70%    /private/var/tmp
    /dev/disk7       95K    14K    77K    15%    /private/var/run
    /dev/disk3s1    3.7G   1.3G   2.5G    34%    /Volumes/SpotMore
    /dev/disk0s10   1.1G   1.1G   3.4M   100%    /Volumes/Classic
    /dev/disk0s12    70G    45G    25G    65%    /Volumes/Macintosh-HD
    sh-2.05b#
    sh-2.05b# cd /Volumes/SpotMore/
    sh-2.05b# pwd
    /Volumes/SpotMore
    sh-2.05b# # Please note ls is the list command.  l is a lower case L
    sh-2.05b# ls -l
    total 880
    -rw-r--r--    1 unknown  unknown    6148 Sep 10  2010 .DS_Store
    drw-------    4 unknown  unknown     136 Aug 25  2010 .Spotlight-V100
    drwxrwxrwt    3 unknown  unknown     102 Sep  3  2010 .TemporaryItems
    d-wx-wx-wt    3 unknown  unknown     102 Sep 10  2010 .Trashes
    drwx------    3 unknown  unknown     102 Sep  3  2010 Desktop
    -rw-r--r--    1 unknown  unknown   18944 Aug 27  2010 Desktop DB
    -rw-r--r--    1 unknown  unknown       2 Jul 29  2010 Desktop DF
    -rwxrwxrwx    1 unknown  unknown   26281 Oct 27  2009 Warranty Information.PDF
    drwxr-xr-x   13 unknown  unknown     442 Aug  4  2010 backup
    drwxr-xr-x   13 unknown  unknown     442 Aug  4  2010 backupPrior
    drwxr-xr-x    7 unknown  unknown     238 Aug 27  2010 cons
    drwxr-xr-x   65 unknown  unknown    2210 Sep  4  2010 iMac-back
    ... clipped ...
    sh-2.05b#
    sh-2.05b# cd /Volumes/Macintosh-HD/Users/mac/desktop
    sh-2.05b# pwd
    /Volumes/Macintosh-HD/Users/mac/desktop
    sh-2.05b# # Please note ls is the list command.  l is a lower case L
    sh-2.05b# ls
     Z2300               iMac
    .DS_Store            move
    .FBCIndex            new Belward
    .FBCLockFolder       primary-comments-new copy.doc
    Consolidate-rc       primary-comments-new.doc
    Downloads            psc 1200
    ... clipped ...
    sh-2.05b# ditto -X -rsrc iMac /Volumes/SpotMore/iMac-back
    sh-2.05b#
    sh-2.05b# # Please note ls is the list command.  l is a lower case L
    sh-2.05b# ls -h /Volumes/SpotMore/iMac-back/
    total 2800
    -rw-r--r--    1 unknown  unknown    24K Sep 12  2010 .DS_Store
    -rw-r--r--    1 unknown  unknown     2K Apr 18  2010 Differentiate Between Models .html
    ... clipped ...
    sh-2.05b# pwd
    /Volumes/Macintosh-HD/Users/mac/desktop
    sh-2.05b# ls
     Z2300               iMac
    .DS_Store            move
    .FBCIndex            new Belward
    .FBCLockFolder       primary-comments-new copy.doc
    ... clipped ...
    sh-2.05b#

  • Single user mode USB support

    My macbook HD has broken, and Im attempting to recover my files through a USB drive.
    I've only been able to boot up in single user mode and I've ran fsck and its getting alot of I/O errors.
    I've followed the instructions here: http://www.macsage.com/mounting-usb-drive-in-single-user-mode/ but I dont seem to be able to my attached USB drive.
    I run [CODE]ls /dev/disk*[/CODE] by booting with usb drive attached and again without it attached and both times i get: disk0 disk0s1 disk0s2 disk0s3
    I'm pretty sure disk0s2 is my main HD as thats whats getting the errors from fsck.
    So I'm really needing to know how to mount the USB though I dont know which disk it is (by doing disk*)
    Any help is greatly appreciated!

    wonza wrote:
    its MS-DOS Fat32, as my other computer is a PC. I've tried
    oops, pressed post too soon! meant to delete the "I've tried"

Maybe you are looking for