Disable single user mode

Is there a way to disable single user mode? I just booted in single user mode and w/o any password I changed my root password! In my mind this is a HUGE security hole, any one could gain root access to my laptop in a matter of less than a minute! I might as well not have a root password. I have the latest and greatest security updates, but this seems to be the biggest security risk in my mind.

If someone has physical access to your computer, your software is vulnerable in the way that you describe. There are a couple of approaches to preventing this problem. I have not tried any of this so I can only point you to some websites.
One way to prevent anyone booting into single user mode is to enable a password in Open Firmware, as described at Setting up firmware password protection in Mac OS X 10.1 or later. You would have to enter the password every time that you booted. And, you definitely would not want to forget your password; if you did, I don't know what you would have to do to recover.
A second approach is to use a 3rd party patch to prohibit casual use of the single-user feature. Look here for info on such a patch: Mac OS X Single User Mode Root Access. I believe that the software discussed here forces someone to type in a password to boot in single-user mode.
One question that I have about the second approach is whether it is possible for the patch to become out of synch with a future OS update. If that happened, one would also need a way to recover.
I hope this helps. If you are really concerned, I suggest that you do some internet searching on this topic.
Rich
EMAC G4 1.0 GHz   Mac OS X (10.4.8)  

Similar Messages

  • Failure to boot in single user mode

    Hi,
    I have an iBook G3 900MHz G3 running 10.4.6. 384MB RAM, ~25GB free disk space.
    it's running slow so I want to boot in single user mode and run applejack.
    the trouble is, it won't boot in single user mode. when I hold command-s or command-v it just boots right to the GUI.
    i've tried both command keys thinking that one might be broken.. no luck. I also have no trouble getting to single user mode on my G4 laptop.
    I have not taken steps to disable single user mode.
    any ideas?
    thanks a lot

    I think it would be worth a try to repair permissions and then boot from the Install disk to run Repair Disk in Disk Utilities. If you still cannot boot into single user mode after that, perhaps obtaining and running Disk Warrior can resolve the problem.
    Bob N.
    Mac Mini 1.5 GHz; iBook 900 mHz; iPod 20 GB   Mac OS X (10.4.6)  

  • How can I secure single user mode

    I have a macbook pro, I would like to disable single user mode.
    thanks,
    Lal.

    To boot from the DVD, insert it, then restart and hold down the C key until the Apple logo appears on screen. If your MBP came with Snow Leopard installed, you must use the gray DVD that was in the box. If it came with an earlier version of the OS, you can use either the gray DVD or the retail disc you used to upgrade. In either case, don't run the Installer; follow the directions in the link above.

  • Disable file service in single user mode?

    After a failed (with an error) attempt to install the latest security update, the iMac won't get past 'waiting for apple file service' during boot. I presume the botched install left something bad, so I'd just like to get it booted so I can retry the install to see if that fixes it.
    Safe startup doesn't work - it just reboots part way through.
    So I'm trying to figure out how to disable the service altogether, from single-user mode.
    Does anyone know what file(s) I need to modify, or what 'defaults' incantations I need to do, to disable it?
    iMac G3, 600MHz Mac OS X (10.3.9)

    I managed to disable it - moved the AppleShare folder out of /System/Library/StartupItems - but it just hung on some other service.
    The CD/DVD drive is toast in this thing, so I can't boot from the O/S disks either. Target disk mode doesn't work either, even though it is supposed to for this model.
    I'm looking into netboot now.
    iMac G3, 600MHz Mac OS X (10.3.9)

  • Data back up from Single User Mode

    Hello,
    I have a problem with my 700 MHz iBook, dual USB, with OS X 10.3.9.
    Unfortunately the OS doesn't start up because of "overlapped extent allocation" problem...
    I would like to re-install the complete OS but before doing it, I would like to back up some directories.
    Is it possible to save some data, by connecting an Ipod or some sort of external peripheral, from the Single User mode?
    If yes, how can I do it?
    Thank you in advance from your kind support.

    Before giving up the ghost check out these:
    http://docs.info.apple.com/article.html?artnum=25770.
    Manually fix Overlapped Extent Allocation Errors without Disk Warrior
    Overlapped overlapped extent allocation errors can be the bane of any Mac user's existence. Often, these errors go unnoticed until the problem becomes visible: your Mac might refuse to boot, crash unexpected, or worse, critical data might disappear from the Finder. Disk Utility can detect, but not fix overlapped extent allocation errors, and certain third-party utilities, such as Alsoft Diskwarrior, can fix them, but generally without reporting the consequences.
    Overlapped extent allocation error occur when the file system thinks that two files are occupying the same area on the hard disk, hence overlapping on the same "inode," which is the structure which holds the location of the data blocks the file occupies, and also file permissions and flags.
    Clearing the "overlapped" or "overallocated" extent allocation essentially means that you'll have to lose some data, because the only way to remove the overlap is to delete the file that's occupying the inode. So, if you suspect, or find out, that the guilty file is a critical system file that resides in one of the hidden system directories such as /etc /var /usr/ or visible system directories such as /System or /Library, and you don't want to reinstall the whole OS (which might not fix the overlapped extent allocation anyway), it's good to have another disk available to copy the files back to your original disk if necessary: a second bootable hard drive or a firewire drive connected to your Mac when you remove the misbehaving file. Just make sure that when you copy the file back to your boot disk that the permissions are correct, so it's best to use the "ditto" command, so that all sticky bits, flags, and permissions are preserved.
    In case you didn't know, you don't have to boot from an install CD in order to check for overlapped extent allocations. All you need to do is restart your Mac, while holding down command + S to boot in "single-user mode."
    At the command prompt that appears, type:
    $ fsck -fy
    If you have an overlapped extent allocation, you'll see:
    "Overlapped Extent Allocation" (File 123456d)
    No matter how many times you run fsck -fy, you'll never be rid of the error.
    So, simply issue the following command:
    find / -inum 123456 -print
    Note the "d" was dropped, or any extra letter that appears after the inode number.
    The find will return a file name that matches with the inode number, and the path to that file. If you remove the file then the fsck will not return this error next time you run it.
    However, before you can delete the file(s) in single-user mode, you'll need to mount the file system. Type:
    $ mount -uw /
    When done, issue the "sync" command, and that will flush the write cache so that all pending writes are written from memory to the disk. Also, since most OS X 10.3 Macs use the HFS+ Journaled file system, it might be a good idea to disable the journal before booting into single-user mode by typing:
    $ sudo diskutil disableJournal /
    then re-enable it when done fixing the overlapped extents and rebooting normally:
    $ sudo diskutil enableJournal /
    Chris Anderson is a long-time Linux propellerhead who just got his first Mac, an ibook G4, and can't keep his hands off of it. He currently works as a "The Architect" and general visionary for a maker of world-class collectibles.
    If you own Disk Warrior then it should be able to repair a drive with overlapped extents.
    There are two backup utilities included in Unix - psync and rsync. You will find them in the /usr/bin/ directory. For documentation simply enter: man psync or man rsync. In order to write data while in single-user mode you need to issue the command: /sbin/mount/ -uw / (Note: there is a "space" between the "uw" and the "/".) To mount an external drive you will need to provide the mountpoint for it in place of the "/", e.g., "/Volumes/volname") without the quotes.

  • Single User Mode: Searching for root...

    My 2 year old unplugged my PowerMac iMac G5 (single) and now it won't start up.
    I was finally able to boot up off of Disk Warrior and replace the directory, but it won't start up past the gray Apple screen. The fan comes on after about 45 seconds and blows hard. Then, I get the circle with a line through it, in gray. I've never seen that on a mac.. the international "no" sign.
    When trying to start up in Single User Mode, I get a long list of stuff either disabled, not found, missing etc and then it starts writing to the screen every 30 seconds a line like:
    Still searching for root.
    I've tried pulling the back off, resetting the SMU, starting up in Safe Mode, etc.
    This has happened with storms before and I can usually get it back.
    I don't have original install discs.

    When you say you have "OSX" but not the "original install disks" do you mean the mac originally came with an earlier version and you don't have those disks, but you have a retail copy of Tiger?
    The circle with the slash means that Open Firmware cannot find BootX. Basically, I think this means that Open Firmware recognises the startup volume as such but cannot hand control to the operating system at all. BootX is what it uses to get the operating system going. Without this, as you've seen, you cannot make even single-user mode.
    What is SMU?
    *Is your data backed up? If not, prioritise that unless you can afford to loose it.*
    Does DiskWarrior repair permissions? If not and you have the Tiger retail version, try running Disk Utility to do that. I don't think this will help, but it won't hurt.
    Do you have another Mac? If so and you have the retail Tiger, you might be able to use Pacifist to replace BootX (in /System/Library/CoreServices). Alternatively, if the other Mac is running the same version of the OS and is also a PPC Mac, you could try copying the file from that machine.
    Before you do any of this (with the exception of the permissions repair), try to backup any data you need if that's at all possible.
    - cfr

  • MBP starts up in Single User Mode by default..

    I restarted the machine because the trackpad was acting up. After file vault reclaimed unused disk space, the computer restarted with a black screen with "localhost :/ root#" in the upper left screen. I know very little unix so please forgive my lack of lingo.
    How can I possibly get back to the graphical multi user login? I have tried to restart in safe mode and from the install dvd but they just bring me back to the "localhost :/ root#" black screen. I have also restarted holding down the option key to select a drive, which I set to my drive name, and same thing-- Apple logo on a grey screen, spinning gear, then black screen localhost :/ root#. Only thing I havent tried that im aware of is target mode, but my other computer (Rev A. iMac) which is the machine I am writng this from is on OS 9 with no fire wire and just a 4g drive.
    So I need some advice if you have any. Hardware appears fine save for the trackpad and button being touchy. Apple has already replaced my swelling battery. They told me the new mbp's have a barrier between the the battery and trackpad assembly, (a prior neglected, inherent design flaw).
    I do have a new USB external hd. Is there any way to login my home folder and completely copy the home folder contents to it in single user mode? If I could do this, I would at least be able to keep my itunes librarys, playlists, keychain data, mail, etc.. Thanks in advance for any help any of you may have

    Ok, I did the dmesg command at the prompt. Here is word for word what it spit out:
    localhost:/ root# dmesg
    hi mem tramps at 0xffe00000
    PRE enabled
    standard timeslicing quantum 10000 us
    vmpagebootstrap:513016 free pages
    migtable_maxdispl = 71
    Enabling XMM register save/restore and SSE/SSE2 opcodes
    96 prelinked modules
    ACPI CA 20060421
    AppleIntelCPUPowerManagement: ready
    AppleACPICPU: ProcessorApicId=0 LocalApicId=0 Enabled
    AppleACPICPU: ProcessorApicId=1 LocalApicId=1 Enabled
    Copyright (c) 1982, 1986, 1989, 1991, 1993
    The Regents of The University of California. All Rights Reserved.
    using 10485 buffer headers and 4096 cluster IO buffer headers
    Enabling XMM register save/restore and SSE/SSE2 opcodes
    Started CPU 01
    IOAPIC: Version 0x20 Vectors 64:87
    ACPI: System State [S0 S3 S4 S5] (S3)
    Security auditing service present
    BSM Auditing Present
    disabled
    rooting via boot-uuid from /chosen: 00001B5D-7D26-0000-2F5D-000090200000
    Waiting on <dict ID="0"><key>IOProviderClass</key><string ID="1">IOResources</string><key>IOResourceMatch</key><string ID="2">boot-uuid-media</string></dict>
    USB caused wake event (EHCI)
    FireWire (OHCI) Lucent ID 5811 PCI now active, GUID 0016cbfffe523440; max speed s400.
    Got boot device =IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/SATA@1F,2/AppleAHCI/PRT 2@2/IOAHCIDevice@0/AppleAHCIDiskDriver/IOAHCIBlockStorageDevice/IOBlockStorageDr iver/ST9100824AS Media/IOGUIDPartitionScheme/Customer02
    BSD root: disk0s2, major 14, minor 2
    CSRHIDTransitionDriver::probe:
    CSRHIDTransitionDriver::start before command
    CSRHIDTransitionDriver::stop
    IOBluetoothHCIController::start Idle Timer Stopped
    disk0s2: 0xe0030005 (UNDEFINED).
    localhost:/ root#
    A couple of things to note:
    1. I did have an external bootable drive, which does work properly when selected as the Startup Disk, but still registers when not plugged in the machine.
    2 File Vault is turned on. And let me tell you. If you ever use more than half your drive space, as most people do, you will have a humbling experience. File Vault is overkill. I am angry that Apple could not come up with a "fail-safe" for legitimate, password bearing rightful owners.
    I just want one chance to get in my home folder to get what I want (my music, photos, mail, passwords, widgets, etc.)

  • IMac G5 won't boot in normal and safe mode, but will from single-user mode

    Hello everyone,
    I'm quite new here, so I try to do my best if you have a question.
    Yesterday, someone nearby me had a iMac G5 (Powermac8,1), and he sayd, that the computer sometimes will boot, sometimes not.
    I did test it, I thought it was running fine, but when I played some music in iTunes, it was stuck on 9 seconds, and crashed (with a kernel panic). The guy also sayd, that there was nothing important on the computer, so a clean install was fine.
    Now, the problem is, that it will not boot in normal mode (without anything pressed on boot), also it won't in safe mode (shift-boot), but it will, when I enter single-user mode, mount the hard drive and exit from single-user mode so it will go futher on booting. Sometimes it will not, and immediately gives you a kernel panic in single-user mode, but it will 90 percent of the time.
    Then you've got another problem: when it's running in the normal desktop from single-user mode, it'll be stuck after some time again. If I look into the Kernel Panic file created, most times it's because of Spotlight indexing, so I disabled that.
    He also gave me the disks (Apple Hardware Test and Extra Applications, and iMac G5 Mac OS X Install Disks 1-3) that came with the Mac. He sayd that I could use them, but I think he didn't test out the SuperDrive, because when I insert a disk, it will try to read, but it will make 2 same sounds, and quits after 10 tries, when it will spit the cd out. Also normal (audio) disks.
    Also, I must hurry with the commands for mounting and exiting in single-user mode, or it will just not boot.
    In all cases, after 30-45 seconds from pressing the power button, the fan will start blowing at full speed, and it will stop after the exit command in Single-user mode. That's weird.
    I can't do anything with the SuperDrive, I can't normally boot in Mac OS X except for Single-user mode (but I don't think he would like to do that every time the computer boots up), and I have very limited time when Mac OS X arrived on the desktop.
    When booting in Verbose mode, it will be stuck on this:
    AppleSMU::PMU vers = 0x000d004c, SPU vers = 0x15, SDB vers = 0x01,
    (and sometimes ends with a kernel crash by fsck_hfs)
    Things I've tried (without any success):
    - /sbin/fsck -fy (in single-user mode)
    - Disabling Spotlight and mds
    If you want some more information, feel free to ask!
    Greetings
    -MrYoranimo
    PS: My main language is Dutch, so my English can be bad at some points.

    Thank you for your support! This reply is a little bit late, because I was to the camping this weekend.
    The only thing I sure do know, is that the iMac has a bad SuperDrive. That's one problem, but I don't really wanna use it, and you fix everything by Single-user mode and when I get to the desktop to test things and change stuff in the Preference Panes.
    What also came to my mind was that there also is a problem with the videocard (driver), because sometimes when I boot into Single-user mode, I can see some white pixels which aren't supposed to be there. And when booting from SUM you can see that some of the colors are different and there are weird patterns on the screen.
    I also tried to setup a NetBoot server on this computer (MacBook Mid 2010) with just Lion 10.7.4 on it, but I'm not that expert and I didn't really find the good posts on the Internet, although I tried it with the Server applications and both Server applications and DeployStudio. But I didn't succeed.
    I don't really like buying a new FireWire hard disk or external FireWire dvd reader/writer, except if it has USB support, because my MacBook doesn't support FireWire, and I really wanna make use of it then.
    If I know more or have fixed it, I will surely post again here with what I did to fix it (if no one else has posted here already ).

  • Can not startup in single-user mode

    I can not get my MacBook to startup in single-user mode. I am holding Command-S at startup but it starts up normally.
    I also tried starting up in verbose mode by holding Command-V. That didn't work either. I then used the Terminal command to make it start up every time in verbise mode. That worked but I don't really want it doing it every time.
    So then I thought it was because I have a firmware password set. I then started up holding the Option key so I can enter the password. The password field popped up as it should, I entered the password, then held down the Command-S keys to startup in single-user mode. No dice.
    Can anyone tell me why I can not get single-user or verbose startup modes working?

    Because entering the password into the Startup Manager doesn't disable it or any of the other functions it provides. You need to use the Terminal method or take the password off.
    (58123)

  • Difference between emergency state and single user mode ?

    Hi,
    I want to know the difference between emergency state which we normally use in suspect mode database and single user mode.
    Navakanth

    Emergency/suspect mode is tells you the state of the database and database is not available for user action but where as single user mode tells the user action preference. Database is active and available for the user action.
    You can refer 
    http://msdn.microsoft.com/en-us/library/bb522682.aspx
    EMERGENCY
    The database is marked READ_ONLY, logging is disabled, and access is limited to members of the sysadmin fixed server role. EMERGENCY is primarily used for troubleshooting purposes. For example, a database marked as suspect due to a corrupted log file can be
    set to the EMERGENCY state. This could enable the system administrator read-only access to the database. Only members of the sysadmin fixed server role can set a database to the EMERGENCY state.
    SINGLE_USER
    Specifies that only one user at a time can access the database. If SINGLE_USER is specified and there are other users connected to the database the ALTER DATABASE statement will be blocked until all users disconnect from the specified database. To override
    this behavior, see the WITH <termination> clause.
    The database remains in SINGLE_USER mode even if the user that set the option logs off. At that point, a different user, but only one, can connect to the database.
    Before you set the database to SINGLE_USER, verify the AUTO_UPDATE_STATISTICS_ASYNC option is set to OFF. When set to ON, the background thread used to update statistics takes a connection against the database, and you will be unable to access the database
    in single-user mode. To view the status of this option, query the is_auto_update_stats_async_on column in the sys.databases catalog view.
    If the option is set to ON, perform the following tasks:
    Set AUTO_UPDATE_STATISTICS_ASYNC to OFF.
    Check for active asynchronous statistics jobs by querying the sys.dm_exec_background_job_queue dynamic management view.
    If there are active jobs, either allow the jobs to complete or manually terminate them by using KILL STATS JOB.
    --Prashanth

  • Command Line Expert Needed: Deleted hostconfig (+ others) - boots to single user mode only !

    Mac OS X Tiger 10.4.11
    Deleted folders/files when logged in as root user. (don't ask!)
    On restart , wont boot up , get grey screen with white apple logo the black screen with command line: localhost:/ root#
    Started up from install cd - repaired permissions (ran twice) &amp; verified hard drive . All okay.
    Restarted but still goes back into command line with same localhost:/ root prompt
    Tried a bunch of different things as per advice on these boards - discovered that there is no hostconfig file.
    Restarted into verbose mode.
    Here are the lines that i think may reveal exactly what I messed up - and hopefully someone out there has an idea how I can try to fix without having to do an archive/install.
    BSM auditing present
    disabled
    rooting via boot-uuid from /chosen: (here a very long string of numbers and letters looks like a password)
    Then a long line about
    "got boot device = IOService:/MacRISC2PE ........."
    Then, the following
    "BSD root: disk0s3, major 14, minor 2"
    "CSRHIDTransitionDriver::stop"
    "IOBluetoothHCIController::start Idle Time Stopped"
    (AND HERE'S THE BIGGIE:)
    /etc/rc: line 93: /etc/hostconfig: No such file or directory
    Apr  1. 06:01:44 launched: /bin/sh on /etc/rc terminated abnormally, going into single user mode
    localhost:/ root#
    I'm pretty sure I messed thing up pretty well - was mainly network/server folders and files - definitely samba, which I think I deleted, and under "network" in the finder, I also might have deleted my computer from the server list
    As an aside in case this provides any insight, when I go to the terminal app when starting up from install cd, the prompt reads :
    "bash-2.05b"
    I'm also able to see the contents of my hard drive when using disk utility from install cd and and trying to "mount image" ---
    Everything looks intact in terms of folders/files in my user account, but in the /root folder, there's only /library - which is empty.
    Any help, insight, troubleshooting and even scolding - will be welcome! I need this thing booted
    Cheers

    I do not have a backup. Should I back up before I try doing a reinstall of the os x?
    That's also known as shutting the barn door after the horse has bolted.
    It can't hurt, but it's not going to help much.
    Camelot: when you say "apps and user content should stay intact" - doesn't sound very definitive. Are there any variables that come into play?
    No.. generally it's pretty reliable, but yours is an odd situation. I wouldn't expect to lose any user data, just CYA
    I do have a start up disk along with some apps that I created in retrospect many years ago ....(I think it's os x 10.2.8) Can I use this to boot up and then just navigate to my user files so I can get some things done that I need to?
    Unlikely. For one have you even tried restoring from your Retrospect backup? (it's not the most reliable system).
    Secondly, you can't boot from your Retrospect backup, so you'll need to restore that system to boot from it. Have you got a second disk to restore to (you do NOT want to restore 10.2.x over your 10.4.x system).
    in terms of "random deleted files" : not entirely random
    Ok, maybe not entire random, but it's also somewhat unknown. You need to have some idea of what files you're trying to restore, but if you haven't got them in a backup where are you going to get them from?
    You cannot just take old copies from your 10.2.x system and hope they'll work (in case that's what you're thinking).
    The BEST solution is to boot from the 10.4.x installer disk and let it do its thing.
    And for what its worth, Unauthorized access attempts, in and of themselves, are not a cause for concern since they were clearly caught by the OS. It's the access attempts that succeed (and are not logged) which are more of an issue.

  • Network driver attachment booting cdrom single user mode

    I am attempting to boot from cdrom in single user mode and reach some network shares. However, when I boot cdrom, the server does not attach the network drivers, meaning I cannot plumb up any of my interfaces.
    Now, I should add that we have an XVR-300 card in an XAUI PCI-E slot. I read somewhere that this can disable one of your network ports, but shouldn't it still see the other ports and attach the network drivers?
    Any body have any ideas or anything I could try?
    Thanks!
    sean

    This link might be helpful.
    http://sun.pmbc.com/faq/7.html

  • Can't boot in Single User Mode or zap PRAM on iMac G5

    I want to boot into Single User Mode in order to run Applejack to "clean" the system before applying Apple's latest security patches. So I hold down Cmd-S at start-up, but it has no effect; the computer boots normally into the Tiger GUI. Thinking that zapping the PRAM might help, I restarted while holding down Cmd-Opt-P-R. Same result: normal startup with no zap. I tried resetting the power management circuit by unplugging the iMac and depressing the power button. No effect.
    Apart from the inability to do special boots, the system seems to be running just fine. Any ideas?
    iMac G5 Mac OS X (10.4.8) 1.5 GB RAM

    Ben F-
    Not guessing yet. You did not provide what steps you have taken thus far and now I know.
    I am thinking then that you have somehow set up firmware password protection.
    At least the things that you describe are disabled if a password is set.
    Luck-
    -DaddyPaycheck

  • Agetty fails to start after switching out of single user mode

    Every time I switch to runlevel 3 from single user mode, agetty fails with this error:
    Jan 29 10:19:28 localhost agetty[1445]: /dev/tty1: cannot open as standard input: Input/output error
    And since it fails, init disables it for 5 minutes… This always happens on the virtual console I run "init 3" on; the other consoles work fine.
    This is how I run agetty from /etc/inittab:
    c1:2345:respawn:/sbin/agetty -8 -s 38400 -a ma --noclear tty1 linux
    Disabling auto-login and removing the --noclear option does not make any difference. Does anyone have a clue what is going on? It is more of an inconvenience than a problem, but still… I am using early KMS on an ATI Radeon 9550 card, by the way.

    So nobody else has been bitten by this stupid bug?
    Anyway, it happens on a pure VGA console too, so it has nothing to do with the video driver. And I take back the “more of an inconvenience” part – it is freaking annoying that one can not just properly change the runlevel. Oh well…

  • Mac not booting normally after running '/sbin/fsck -fy' in Single user mode

    HI, I tried to log in to single user mode and run the '/sbin/fsck -fy' command. This command failed. So I rebooted my Macbook pro by 'reboot' command. On bootup I hear the chime shoud and can see the Mac Symbol but never reach the login prompt. The round circle keeps rotating over the gray screen and nothing happens.
    Then I again hard rebooted mac book and entered single user mode. I ran again '/sbin/fsck -fy' many times and after many attempts the command stuck and never returned.
    Then I tried using the recovery method to reinstall MAC OS X. It asked me to choose the Harddrive where to install MAC OSX. But the option of "macintosh HD" was disabled and message was " hard drive locked".
    Please help me how to boot my MAC normally :'(

    Welcome to the Apple Support Communities
    Boot in Recovery again and open Disk Utility. Then, choose "Macintosh HD" in the sidebar and repair the hard drive. If it is repaired, restart and OS X should start correctly. If not, you will probably have to format the hard disk.
    You only have to use that command when you have problems with the Mac OS X volume filesystem that they couldn't be repaired with Disk Utility, and as this command got stuck, probably damaged the OS X volume filesystem

Maybe you are looking for