Disk Permissions Verify & Repair on RAID 0?

Discussion in 'Mac mini' started by donklaus, Jan 8, 2012.

  1. donklaus macrumors member

    Joined:
    Mar 6, 2011
    #1
    I gather from a number of message boards that users are unable to run Disk Permissions Verify and Disk Permissions Repair on their RAID drives with Lion installed. That would include me - my mini server with RAID O config will not run either the verify or permissions unti.

    Since this seems to be a common problem, anyone found a solution that I haven't stumbled upon? I run both until on my MBP as part of regular maintenance and would like to keep my mini clean too.

    TIA>
     
  2. GGJstudios macrumors Westmere

    GGJstudios

    Joined:
    May 16, 2008
    #2
    Some people repair, or recommend repairing permissions for situations where it isn't appropriate. Repairing permissions only addresses very specific issues. It is not a "cure all" or a general performance enhancer, and doesn't need to be done on a regular basis. It also doesn't address permissions problems with your files or 3rd party apps.
    There are times when repairing permissions is appropriate. To do so, here are the instructions:
    If repairing permissions results in error messages, some of these messages can be ignored and should be no cause for concern.
     
  3. donklaus thread starter macrumors member

    Joined:
    Mar 6, 2011
    #3
    Just to keep the thread on point.

    Verify Disk Permissions and Repair Disk Permissions do not run on my RAID 0 config with Lion installed. I've gathered that this is a common problem with RAID drives with Lion OS (i do know how to click on a drive icon, then on the correct utility command button. Really.)

    Anyone found a solution to this often-commented upon issue? Apologies if this has been addressed in a previous thread, but my search of MR didn't yield anything. Thanks.
     
  4. GGJstudios macrumors Westmere

    GGJstudios

    Joined:
    May 16, 2008
    #4
    This is your point that I was addressing:
    The point is, you don't need to repair permissions as a part of regular maintenance, and doing so is a useless exercise. It only needs to be done if you have a particular problem that repairing permissions addresses. You're asking how to do something that you don't need to be doing in the first place.

    It also appears it can't be done: Disk Utility cannot / will not repair permissions
     
  5. KScottMyers, Jan 9, 2012
    Last edited: Jan 9, 2012

    KScottMyers macrumors regular

    Joined:
    Jul 17, 2009
    Location:
    Orlando, FL
    #5
    Run it in Terminal. Works with Lion and RAID.
    sudo diskutil repairPermissions /

    You can also run in single user mode to run disk repair and permissions repair.

    Single User Mode
    Immediately press and hold the Command (Apple) key and the "s" key for single-user mode. (Command-S)

    Disk Repair
    /sbin/fsck -fy
    sudo fsck_hfs -f /dev/disk4s2

    Repair Permissions
    sudo diskutil repairPermissions /
     
  6. Tesselator macrumors 601

    Tesselator

    Joined:
    Jan 9, 2008
    Location:
    Japan
    #6



    Yeah, but if he's on a raid I assume it's large. If large that will take a long time to complete. Give that puppy some cache with the -c switch: like so:

    sudo fsck_hfs -f -c 2g /dev/disk4s2

    which will give it 2GB of cache to do it's thing and it's complete in less than a minute (typically...).

    Here's a little script I wrote for my non-boot RAID0 arrays (it uses 4g (4GB) so if you have less RAM just change that.). With this you don't need to reboot or anything. Just open the terminal and execute it. :) :


    #########################################################################
    #!/bin/bash
    # Faster RAID Repair Volume
    export VOLUME=/Volumes/$1
    echo "Yo, $VOLUME -- Where ya at little bro?"
    export DISK=`diskutil info $VOLUME | sed -n '/ Device Node\:/s/.* \(\/dev\/disk.*\).*/\1/p'`
    if [ "$DISK" = "" ]; then
    echo "Dude, you like, gotta enter the volume name..."
    exit 1
    fi
    echo "OK, Found it... It's $DISK and I'm checking it out now - Hang on bruthu..."

    #>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<
    #>>>>>>>>>>> The Important Bits Start Here <<<<<<<<<
    #>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<

    diskutil unmountDisk $DISK
    sudo fsck_hfs -f -c 4g $DISK
    diskutil mountDisk $DISK

    #>>>>>>>>>>>>>>>>> All Done <<<<<<<<<<<<<<<<
    echo "If $1 doesn't show up on your Desktop please select and mount it using DiskUtility (in your Applications/Utilities folder)"
    #########################################################################


    Save this as FRRV.sh or anything you like and execute it in the terminal window (after CDing to where you saved it) like:

    sh FRRV.sh <volume name>



    I added that last echo statement because mine doesn't show up. I'm not sure why... it says mounting was successful... <shrug> It's no big deal but kind of an annoyance. Maybe someone else knows?
     

Share This Page