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.

Similar Messages

  • Mount USB Device in Single User Mode

    Hi All,
    Can anyone give me any assistance of mounting a USB stick in single user mode?
    I am trying to use the command:
    $ mount -uw /dev/disk2s1 /Volumes/usb
    But it get the error:
    --specified device does not match mounted device
    If I put the USB stick in normal OSX mode, then run 'df -k' in terminal, it is mounted by automounter, but I can't seem to get it to mount in single user mode.
    Thanks,
    Nik

    Hi Nik,
       I don't believe that there are enough services started in Single User Mode to do this; you'll have to start the services yourself. However, I haven't tested this so I don't know. Wanna be a Guinea Pig?
       If your going to need to write to the boot drive, mount it read/write with:
    /sbin/mount -uw /
    Next, start the basic services, including diskarbitrationd:
    /usr/libexec/registermach_bootstrapservers /etc/mach_init.d
    The above should be one line, modulo wrapping. Then start diskarbitrationd:
    /sbin/SystemStarter start Disks
    You should probably check /dev and see what disks are already mounted. (without the USB stick) I assume that the services that mount removable media are now started so insert the stick and see if it appears mounted in /Volumes. Otherwise, check /dev and see if there's a new disk. If it only appears in /dev, you can use the standard mount command to mount it. If it doesn't appear in /dev then you might reboot into Single User Mode and repeat the procedure with the USB stick already inserted. If none of that works then this must not be the right method and you have my apologies.
    Gary
    ~~~~
       Computers are like air conditioners. Both stop working
       if you open windows.
          -- Adam Heath

  • Cannot  mount USB disk in SIngle-user mode (solaris 10)

    Hi all ,
    I need some help please :
    I can read/write to my USB disks when i'm in muti-user mode but when to I swith to single-user mode ( init S ), I cannot mount it.
    in Single-user mode , i started volume management daemon :
    #/etc/init.d/volgmt start
    #volcheck
    but i'm still not able to mount it.
    I tried to mount manually:
    #mount /dev/dsk/c2t0d0p0 /testpoint , i have this error: < mount : not a UFS magic number ( 0x0) , dev/dsk/c2t0d0p0 is not of this fstype.
    My system recognizes the USB device though in single-user mode:
    This is an output of #iostat -En
    c2t0d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
    Vendor: BUFFALO Product: ClipDrive Revision: 2.00 Serial No:
    Size:0.07GB <65339392 bytes>
    Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
    Illegal Request: 1 Predictive Failure Analysis: 0

    Hi ,
    thanks for your advice. My problem is resolved.
    The USB drive was actually a FAT filesystem.
    so I did # mount -F pcfs /dev/dsk/c2t0d0p0:c /testpoint and everything went fine
    I can read/write to my USB disks when i'm in
    muti-user mode but when to I swith to single-user
    mode ( init S ), I cannot mount it.
    in Single-user mode , i started volume management
    daemon :
    /etc/init.d/volgmt start
    #volcheck
    but i'm still not able to mount it.It probably requires other items to be started
    first.
    I tried to mount manually:
    #mount /dev/dsk/c2t0d0p0 /testpoint , i have
    this
    error: < mount : not a UFS magic number ( 0x0) ,
    dev/dsk/c2t0d0p0 is not of this fstype.
    Looks like it's assuming UFS. If this is a pcfs
    filesystem, give it the type on the mount line.
    # mount -F pcfs /dev/dsk/c2t0d0p0 /testpointYeah, this was the right command, I had to specify option < -F pcfs >.
    but I read somethere on this forum i had to specify :c as the drive for FAT at the end of c2t0d0p0 , so the full command was:
    # mount -F pcfs /dev/dsk/c2t0d0p0:c /testpoint
    >
    DarrenThanks,
    Sakolan.

  • 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.

  • 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...

  • Mounting a dmg in single user mode

    When ever I try to mount a .dmg in single user mode using "hdiutil mount /path/to/dmg" I get no errors but I can't actually access the mounted dmg, it never appears in /Volumes
    My question is how do you access a mounted dmg is single user mode

    I've run into similar difficulties. I don't know about 10.6, but in 10.5.8 the HDI driver appears to load fine. (You can check that with the kextstat utility.)
    In fact, my 10.5 Install CD uses hdik to create RAM disks early in startup. However, the same calls to hdik fail when I try them in single-user mode.

  • 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

  • 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 ?

  • Mounting Windows Disk within Single User Mode

    A Windows machine I administer kacked and the users didn't back up all their data. Windows won't touch the drive, so I popped it in a 10.3.9 Mac... I can copy a handful of files and folders from the Finder, but some directories won't read -- there may be physical damage to the drive (if the kernel panics are any indication).
    When I boot into Single User Mode, I can't get into the disk.... the disk(s) show up under /Volumes, but you can't actually get into them... only a file named .autodiskmounted shows up for each Windows partition. I'm guessing this is a product of the disk being formatted as a NTFS drive (I'm thinking that's probably what Windows XP Home used on this drive).
    Can you mount a NTFS or FAT32 disk from Single User Mode? How?
    Many thanks!

    Everett
    To mount a disk in 10.3.9, look at the first part of this FAQ: Resetting the System Immutable Flag in 10.3.
    You will need to replace the "mount -t hfs" with "mount -t msdos", but I don't know if you would need further options.
    If you can find a 10.4 system, it may be easier, since "autodiskmount" appears to work again. See: kmosx4: Resetting the System Immutable Flag in OS X 10.4

  • Mounting disk0s2 while in single user mode

    My mac mini wont boot.  The recovery mode tells that disk0s2 has I/O Error and more specificly, its a "Disk full error".  To delete some files and free up space, I booted mac into single user mode.  But how to month disk0s2 from here so that I can delete some files?

    An I/O error indicates either a corrupted file system or a physical disk failure. If you couldn't repair the boot volume (disk0s2) in recovery mode, it's most likely the latter and you need to get your HDD replaced. If you have access to another Mac, you can attempt to mount the mini as an external hard drive using Target Disk mode to salvage data. Hopefully you have a current back up. Best of luck.
    Transfer files between two computers using target disk mode

  • 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 USB drive as regular user (with ntfs-3g)

    Hello. First of all, I not asking to do the homework for me, rather is someone can help me understand why I can't get this work.
    I spent the last night trying to figure how mount an USB drive as a regular user, using ntfs-3g. I read the related wiki entries and researched quite a lot in the forums. I came up with this:
    fstab:
    # /etc/fstab: static file system information
    # <file system> <dir> <type> <options> <dump> <pass>
    devpts /dev/pts devpts defaults 0 0
    shm /dev/shm tmpfs nodev,nosuid 0 0
    #/dev/cdrom /media/cd auto ro,user,noauto,unhide 0 0
    #/dev/dvd /media/dvd auto ro,user,noauto,unhide 0 0
    #/dev/fd0 /media/fl auto user,noauto 0 0
    /dev/sda1 / ext3 defaults,noatime 0 1
    /dev/sda2 /home ext3 defaults,noatime 0 2
    /dev/sda3 swap swap defaults 0 0
    /dev/sdb1 /mnt/usb ntfs-3g noauto,uid=0,gid=0,noatime,umask=000, 0 0
    I created a ntfsuser group, added my user to that group and trim permissions to the ntfd-3g executable (link in this post). That allows me mount the partition as root and read/write as regular user. It works, so (i think) not big deal here.
    However if I add user to the mount options the following error shows up:
    Mount is denied because setuid and setgid root ntfs-3g is insecure with the
    external FUSE library. Either remove the setuid/setgid bit from the binary
    or rebuild NTFS-3G with integrated FUSE support and make it setuid root.
    Please see more information at http://ntfs-3g.org/support.html#unprivileged
    What bugs me the most is I don't understand why I can't mount as regular user when the user option is set in the fstab. Shouldn't that allow regular users to mount and unmount? Is not like that I'm mounting and dismounting USB drives every 5', but I would like to get this done because I know it can be done
    Sorry for asking such trivial question, but I sense that I'm missing something really stupid and I just can't figure what it is

    Beware of the double post! (+1)
    Ok, I decided I'd get this to work, although the method and the implications it could have might not seem pretty to some. There are certain conditions for a user to mount any ntfs volume with ntfs-3g, I will name them here:
    1. ntfs-3g with integrated fuse support. You'll get this by:
        1A. Removing ntfs-3g and fuse from your system if you have them installed as separate packages, so do this as root:
    pacman -Rn ntfs-3g
    pacman -Rn fuse
    Now you can install the new package.
        1B. Getting a modified version of the PKGBUILD found in that AUR link previously mentioned by me, here's mine:
    # Maintainer: Gula <gulanito.archlinux.org>
    # Slightly modified by anderfs
    # Don't forget to setuid-root for the ntfs-3g binary after you install this
    pkgname=ntfs-3g-fuse-internal
    pkgver=2010.5.16
    pkgrel=1
    pkgdesc="Stable read and write NTFS driver (whit internal fuse suport)"
    url="http://www.tuxera.com"
    arch=('i686' 'x86_64')
    license=('GPL2')
    depends=('glibc')
    conflicts=('ntfs-3g')
    makedepends=('pkgconfig')
    options=('!libtool')
    source=(http://www.tuxera.com/opensource/ntfs-3g-${pkgver}.tgz
    http://aur.archlinux.org/packages/ntfs-3g-fuse-internal/ntfs-3g-fuse-internal/25-ntfs-config-write-policy.fdi)
    sha1sums=('895da556ad974743841f743c49b734132b2a7cbc'
    '200029f2999a2c284fd30ae25734abf6459c3501')
    build() {
    cd "${srcdir}/ntfs-3g-${pkgver}"
    ac_cv_path_LDCONFIG=/bin/true ./configure --prefix=/usr \
    --with-fuse=internal --disable-static || return 1
    make || return 1
    package() {
    cd "${srcdir}/ntfs-3g-${pkgver}"
    make DESTDIR="${pkgdir}" install || return 1
    ln -s /bin/ntfs-3g "${pkgdir}/sbin/mount.ntfs" || return 1
    install -m755 -d "${pkgdir}/usr/share/hal/fdi/policy/10osvendor"
    install -m644 "${srcdir}/25-ntfs-config-write-policy.fdi" "${pkgdir}/usr/share/hal/fdi/policy/10osvendor/" || return 1
    Save this as PKGBUILD, preferrably in an empty directory so it doesn't clutter things up when you build it.
        1C. Now go to the directory where you saved it and do this as a regular user:
    makepkg PKGBUILD
    After that's done, you'll get a package called ntfs-3g-fuse-internal-2010.5.16-1-i686.pkg.tar.xz, or something similar.
        1D. Install that package as root:
    pacman -U ntfs-3g-fuse-internal-2010.5.16-1-i686.pkg.tar.xz
    If all went well you now have ntfs-3g compiled with integrated fuse support.
    2. The ntfs-3g version must be higher than 1.2506, this is already covered, the package installed from AUR matches this requirement.
    3. The ntfs-3g binary must be set to setuid-root, to accomplish this you shall do the following as root:
    chown root $(which ntfs-3g)
    chmod 4755 $(which ntfs-3g)
    I used 4750 instad of 4755, I guess that last bit can be a matter of personal taste as long as it isn't something obnoxious like "7".
    4. The user must have the right access to the volume. Okay, this is the ugly part, volumes are owned by root and managed by the disk group with permissions brw-rw----, this means you have to add any users you want mounting this volume to the disk group.
        4A. So, do this as root:
    gpasswd -a [user] disk
    Where [user] is obviously the name of whichever user you're adding to the disk group, do this for any user you want mounting this volume.
        Any users currently logged in will have to log out and back in for these change to take effect, this most likely includes you.
        4B. Now that you logged back in, try this:
    groups
    One of the groups listed should be disk, if it's not there you didn't completely log out of all open sessions.
    5. The user must have the right permissions/access to the mount point. For a user to be able to mount something to a mount point, that user needs to have read permission (pretty self-explanatory), write permission (so the user can make any changes to the sub-structure of the mount point), and execute permission (so the user can change-dir to that mount point) to it. Mount points can be anywhere, so this really depends where you're mounting.
    In my case, I'm mounting these volumes on certain directories under /mnt/, for example /mnt/example. If you're mounting stuff there, you might as well take advantage of the fact your "mounting user" is already in the group disk, and do the following as root:
    chgrp disk /mnt/example
    chmod 774 /mnt/example
    Now users in the disk group will be able to manage these mount points.
    6. Mount it. That's it, you should now be able to mount ntfs volumes as an "unpriveleged enough" user. Here's an example of what you'd have to put in /etc/fstab:
    UUID=XXXXYYYYXXXXYYYY /mnt/example ntfs-3g noauto,noatime,user,uid=0,gid=6,fmask=137,dmask=027,rw 0 0
    uid=0 means root will be the owner of this mount-point and anything in it after it's mounted. This is due to the fact that even though users might own their mountpoints and have rwx permissions on them, you might still not want them to write to the mounted ntfs volumes. Remove this if you want them to be able to write to the volume.
    gid=6 means this will be managed by the disk group in my system. Perhaps the disk group has a different id in your system, run "id root" to find out, as root usually is part of this group.
    fmask = 137 means the owner (root) can do anything with files in this volume except executing files. Group members (disk) can only read files here, not create or execute them. And other users can't do anything in this volume.
    dmask = 027 means the owner can do anything with directories (execute here is needed to chdir), users can't write directories but they can read or execute in them (once again, needed by 'cd'), and finally other users still don't have any access.
    You can use whichever fmask and dmask makes sense to you, or use an umask instead.
    Last edited by anderfs (2010-07-15 11:34:48)

  • 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

Maybe you are looking for

  • User-exit or BADI required for changing Plant-sp.matl status in MM02

    Hi Folks, Our user requirement is when standard price is 0, we should assign value 'Z4' to Plant-sp.matl status(in MRP1 and Costing1 tabsin MM02) . Could any one suggest me a user-exit name or a BADI name to change Plant-sp.matl status in MM02. <REMO

  • Webdynpro for ABAP versus Enterprise Services

    Hi, With ECC 6.0 the WebDynpro for ABAP will be available. After converting my well-known ABAP-dynpro screens to WebDynpro I will have the possibility to expose all R/3 functionality from within the portal. Two years from now the Enterprise Services

  • Apex Homepage is not showing up

    Hi, I am new to APEX and i would really like to learn about it. I have the following environment OS : Linux SUSE9 Database : Oracle Database 10.2.0.3 OracleHTTP Server 10.2.0.1 (installed from Oracle 10g Companion CD) APEX 3.0.1 I have Oracle HTTP Se

  • Cleaning a moth turd off of my iMac 24" Screen

    So, moments ago I'm sitting here happily surfing the web and a moth is attracted to my brand new 24" iMac screen and leaves his calling card. A wet dot of poop the size of the letter "o", maybe a tad smaller. So I gently wipe it with a soft cloth and

  • Simple example of a custom annotation    for log

    Please help me write me my custom annotations. I like to use them to provide log ,security etc . I did not find articles where I can write my annotation to change the behaviour. Suppoe I decare annotation on a method , I want jvm to call code in my a