Unmounting before shutdown

If I don't unmount a hard drive partition,etc. before shutting down the computer will it mess things up?

Hopefully not, but you always run the risk of corruption. Any time a disk is writing and it gets shut down unexpectedly you're going to have some data loss. With that being said, I've never known my base Linux system being hurt by unclean shutdowns.

Similar Messages

  • Registry writing right before shutdown fails

    Hi,
    In my NDIS driver code I am trying to write a parameter to the registry (using NdisWriteConfiguration and then I call NdisCloseConfiguration). Usually it works fine, but when I do that just before shutdown the registry is not updated. Can you please help?
    Thanks.

    At some point during shutdown, the registry unmounts itself.  This is normal.  During an orderly shutdown, the registry flushes its caches, clears the in-use flag, closes the registry.  Then the filesystem flushes its caches, clears its in-use
    flag, and closes the disk volume.  While this is happening, you can't write to the registry, since that would invalidate all the dismounting work.
    If you really need to save off state, you can call
    IoRegisterShutdownNotification to be notified before this happens.  But this is sort of unusual and I don't really encourage it.
    Of course, you still need to have a plan for what happens if there shutdown is
    not orderly. E.g., what if the power cord gets yanked out? My inclination is to make the "disorderly shutdown" case the every-time case. Then you don't have to worry about special cases, and your recovery code gets tested on every boot.

  • Apps auto-launch on startup, despite System Prefs and quitting before shutdown.

    All apps that were open before shutdown are relaunching themselves upon startup.
    This behavior occurs even if I quit each application individually before initiating system shutdown.
    This behavior occurs whether I tick or untick the following settings within System Preferences / General:
    • Ask to keep changes when closing documents.
    • Close windows when quitting an application.
    This behavior occurs despite none of the apps being listed within System Prefs / Login Items.
    Examples of auto-launching apps (behavior occured just now with these): TextEdit, Dictionary, Calendar, Contacts, Safari, Firefox, Excel, Acrobat.
    I am the administrator and only user on this machine.
    Early 2011 MacBook Pro 13"
    Mac OS X 8.5
    Build 12F45
    2.7 GHz Intel
    8GB RAM

    Back up all data.
    This procedure will unlock all your user files (not system files) and reset their ownership and access-control lists to the default. If you've set special values for those attributes on any of your files, they will be reverted. In that case, either stop here, or be prepared to recreate the settings if necessary. Do so only after verifying that those settings didn't cause the problem. If none of this is meaningful to you, you don't need to worry about it.
    I've tested these instructions only with the Safari web browser. If you use another browser, they may not work as described.
    Step 1
    If you have more than one user account, and the one in question is not an administrator account, then temporarily promote it to administrator status in the Users & Groups preference pane. To do that, unlock the preference pane using the credentials of an administrator, check the box markedAllow user to administer this computer, then reboot. You can demote the problem account back to standard status when this step has been completed.
    Triple-click anywhere in the following line on this page to select it:
    { sudo chflags -R nouchg,nouappnd ~ $TMPDIR.. ; sudo chown -R $UID:staff ~ $_ ; sudo chmod -R u+rwX ~ $_ ; chmod -R -N ~ $_ ; } 2> /dev/null
    Copy the selected text to the Clipboard by pressing the key combination command-C.
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Paste into the Terminal window (command-V). I've tested these instructions only with the Safari web browser. If you use  another browser, you may have to press the return key after pasting.
    You'll be prompted for your login password. Nothing will be displayed when you type it. You may get a one-time warning to be careful. If you don’t have a login password, you’ll need to set one before you can run the command. If you see a message that your username "is not in the sudoers file," then you're not logged in as an administrator.
    The command may take a few minutes to run, or perhaps longer if you have literally millions of files in your home folder. Wait for a new line ending in a dollar sign (“$”) to appear, then quit Terminal.
    Step 2 (optional)
    Take this step only if you have trouble with Step 1 or if it doesn't solve the problem.
    Boot into Recovery. When the OS X Utilities screen appears, select
    Utilities ▹ Terminal
    from the menu bar. A Terminal window will open.
    In the Terminal window, type this:
    res
    Press the tab key. The partial command you typed will automatically be completed to this:
    resetpassword
    Press return. A Reset Password window will open. You’re not going to reset a password.
    Select your boot volume ("Macintosh HD," unless you gave it a different name) if not already selected.
    Select your username from the menu labeled Select the user account if not already selected.
    Under Reset Home Directory Permissions and ACLs, click the Reset button.
    Select
     ▹ Restart
    from the menu bar.

  • Before shutdown

    Hi,
    IS there any proactive before shutdown in oracle 9i/10g?
    like JOB_QUEUE_PROCESSES. AQ_TM_PROCESSES(is it deprecated).

    Press the Power button once. If the Shutdown dialog appears then press RETURN to shut down. If it does not appear then you must do an abnormal shutdown by pressing and holding down the Power button for 5-10 seconds until the computer shuts down.
    Before restarting the computer do the following:
    Repairing the Hard Drive and Permissions
    Boot from your Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger, Leopard or Snow Leopard.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported, then quit DU and return to the installer. Now restart normally.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.

  • My Book for Mac unmounting before I can do access it

    I literally just got this drive today.  I installed the utility software, but not the security software.  All that went well.  I got it registered.  Now the hard drive automatically unmounts before I can do anything with it.  The icon appears on the screen for a few seconds; then disappears.  I uninstalled the software, rebooted, and it keeps doing the same thing.  I've read that others have had similar problems, but haven't seen a viable solution.  It's incredibly frustrating and, quite frankly ridiculous, to have to waste time with this thing when it's a brand new product supposedly designed specifically for use with a Mac.  Any ideas?  If I can't get this thing working by tomorrow, I'm giving up and returning it.   I have a mid-2009 MBP running snow leopard.  Yes, it's old, but it still works just fine, except with this drive.  

    July 2015 Solution for Multiple Problems with a New ‘My Passport for Mac’ (Note: I am posting this same message in response to several topics in this Forum, since the symptoms sounded similar to mine and I suspect WD software is causing them.) Like many other Users here, I recently bought a new external WD drive. The irony here is that I already own 3 other WD external drives, and they have been running fine for several years on our two Mac computers for photo and backup uses. Not so with this new drive. Following the WD installation steps, I first installed their software WD Drive Utilities and WD Security. And then my confusion started, because I now got the message ‘Error in RAID configuration’, even though I don’t use RAID and had done nothing except plug in the new drive. I ran the WD Drive Utility, Status Check, and my laptop actually crashed! I also saw the new drive mount at first, then spontaneously dismount after a minute or so. I even dismounted the new disk, mounted one of my older disks I have used for several years, and now it reported ‘Error in RAID configuration’, something it had never done before, and when I ran the WD Drive Utility, Status Check, on my older Passport drive my laptop again crashed. Like others here, I wasted a lot of time trying to resolve this, but let me skip all that and get right to what I did to get this new disk (and my old ones) to work correctly again. Solution which worked for me: I uninstalled the WD Drive Utilities software (the entire folder) completely. So far I have not uninstalled the WD Security software, although I have not dared to use it yet and likely never will. To uninstall WD Drive utilities, I used the free app AppCleaner from freemacsoft.net (NOT the app in the Mac App store similarly named App Cleaner; it may work just as well, but I have never used it.) Now that the WD Drive Utility is off my computer, I can use the new WD Passport and all my older Passport drives. I have run Apple’s Disk Utility, Verify, numerous times on the new drive, and using Carbon Copy Cloner I have cloned up to 340 GB to the new Passport drive, followed by Verifying it, without errors or any of the symptoms listed above. WD versions for me were:  WD Drive Utilities 2.0.2.18, which folder contained WDDriveUtilityHelper 1.0.0.16. I hope this helps others on this Forum.

  • Run a  script before shutdown with launchd

    Is there a way to run a shell script before shutdown with launchd? In 10.4, I have a shell script to remove user's folder when a user logs off.
    Lisa Perez

    the only way to do it that I know of is using a logout hook. see this link for details
    http://www.bombich.com/mactips/loginhooks.html
    However, I'm not sure exactly at what point in the logout process the logout hook is executed so there might be a problem running a script that deletes the home directory of the user that's being logged out.

  • Manual unmount Firewire hard drives before shutdown

    I'm having shutdown problems again possibly due to my new firewire hard drive, the firewire driver supplied by OS X, or some combination thereof.
    The issue is if I don't manually unmount my Firewire hard drive, the MacBook Pro does not ever properly shutdown and just spends its time doing the "spinning sun ray". If I manually unmount the firewire hard drives (by dragging to trash, for example) then there is no shutdown problem. Why should this be a problem at all? I don't understand. Why can't the shutdown command also unmount Firewire hard drives consistently?
    My set up:
    MacBook Pro <--> LaCie 120Gb firewire <--> Maxtor OneTouch 4 Plus 500GB
    I also saw this article:
    http://www.fcpworld.com/fcpworld/articles/E14514A0-F957-48E4-835A-81CE505C03D5.h tml
    Any times on how to solve this problem so that I can go to the shutdown command without first having to manually unmount the Firewire hard drives? Thanks!

    Frank Canzolino wrote:
    Thanks for reporting back, the idea was just a theory that I had never tried before. I do know that Macs will have difficulty shutting down if the state of a network is changed during to shutdown, say pulling the ethernet cable. Firewire has been implemented as a network port (actually a while ago).
    Yeah, I've known Firewire was implemented as a network port a long time ago. The strange thing is that I'm not using the Firewire port as a network device AND it has also been deactivated. It was deleting the port that seemed to have helped it.

  • Eject external HD before shutdown? Conflicting advice.

    Hi all. My first post. Hooray!
    Anyway, having searched this forum and other websites there seems to be conflicting advice as to whether one should eject an external HD before the computer is shutdown or not. I have a Western Digital My Passport Essential and according to WD's knowledgebase I am supposed to eject my external HD before I shut down:-
    Knowledgebase Answer ID 976 ( http://wdc.custhelp.com/cgi-bin/wdc.cfg/php/enduser/stdadp.php?pfaqid=976 )
    "Question:
    What is the recommended shutdown procedure for a Mac with a USB or FireWire drive installed?
    Answer:
    In some cases, shutting down the system without properly unmounting the drive results in data corruption. If the OS stops the device while data remains in the drive cache, data can be lost or file system damage can occur. To avoid possible data corruption, Western Digital recommends that FireWire and USB drives be properly unmounted from the Mac OS prior to turning off the system.
    To properly unmount the drive, simply drag the drive icon to the trash. This will assure that all data is properly cleared from the drive cache before the drive is removed. At this point the FireWire or USB data cable can be safely removed and the drive and Mac system can be powered off."
    I really do not want to jeopardise my backed up data on the external HD, so which advice should I follow?
    Many thanks.
    Resali

    Welcome to Discussions! What took you so long???
    I have always dragged the hard drive icon to the trash, then shut it off, before shutting my computer down. I have received too many warnings that "a device was improperly removed, data corruption may have occurred" or something similar, to ignore the advice.
    In addition, updating your system with a firewire drive attached can cause problems, I remove all peripherals before any update.
    So, in short - eject the external before doing anything with the internal computer, such as shutting down or updating.

  • Root filesystem not cleanly unmounted on shutdown

    I have installed arch on a EEEPC701 on a flash card that is connected to the USB port. The filesystem is ext2. All is fine except that I often get error on the filesystem. Quite often the filesystem is marched clean but if I force a fsck on it I nevertheless get errors. I have modified /etc/rc.shutdown to do sync;sleep 5 just before the shutting down (after having remounted it ro) but the problem persists. Has anyone an idea; should it be possible to unmount it completely before the shutdown instead of remounting it ro? Might it be the problem?

    Hi olive,
    I don't know a lot about ext2 but if you do an fsync while disk filesystems are ro it won't have any effect I guess, so maybe you can put it earlier in the rc.shutdown script.
    I found a thread on linux kernel mailing list related to your issue, not sure if it's still relevant though because it's about 2.4 kernels. anyway, here's the link:
    http://lkml.indiana.edu/hypermail/linux … /1417.html
    cheers,

  • Systemd and cifs unmount at shutdown problem

    I have configured my cifs mounts in /etc/fstab, they have the noauto,x-systemd.automount option. (not the cause of the problem, but theoretically systemd should handle it better)
    It all works ok, except at shutdown. Systemd brings the network down BEFORE unmounting the cifs mounts. This results in 1m30s of wait until the unmount fails due to timeout.
    This has been happening a long time ago. When I'm in a hurry I just use sysrq to terminate all, but I would like to disable the sysrq key in my system.
    Any clues?
    * It happens with wicd and networkmanager
    Last edited by eduardo.eae (2014-03-04 22:46:25)

    seiichiro0185 wrote:
    I had this problem too in the beginning, but did solve it by setting the hostid like this:
    ~# hostid > /etc/hostid
    After this I rebuilt my initrd with
    ~# mkinitcpio -p linux
    After these two steps I could remove the zfs_force from my kernel line and it works without a problem since then.
    This solution f*******ed up my installation and now i'am have a real pain to reinstall my system because there is a version problem with the zfs module :
    https://bbs.archlinux.org/viewtopic.php … 0#p1331360
    And it may also have f***ed up my dd.
    Bussiere

  • Arch does not umount busy disks before shutdown?

    Hello,
    Been using Arch on my Laptop, Desktop, Firewall and HTPC for a couple years now. I really like the setup.
    When shutting down the pc, Arch runs the shutdown scripts that umount the mounted volumes. If the volume is busy, it gives me a message:
    "/mnt/sdc4: device is busy"
    But then continues to power off, leaving my disk(s) in an inconsistent state on boot. It seems to me that Arch should wait until the disks are properly un-mounted before shutting off.
    Does anyone else see this as an issue?
    Thanks,
    Nate

    Just saw this:
    http://bbs.archlinux.org/viewtopic.php?id=40747
    Guess I'm not the only one with this issue...

  • Possible to run Automator job before shutdown (automatically)?

    Subject says it all, really: I have an Autamator job that copies some files from one place to another.
    I want to run this job automatically before the machine shuts down. Is this possible?

    Yes. Just add it to the Automator workflow with the "Run AppleScript" action and save it as an application to put in your Dock, or the sidebar in a Finder window, or the toolbar in a Finder window.
    If you don't want it to be too easy, then put it in a folder first. Then put the folder either in the Dock, or the sidebar or toolbar of the Finder window so you'll have to perform two clicks.
    In the "Run AppleScript" action, you can delete everything in the text box since you don't need to process any items, and then add this:
    tell application "System Events" to shut down
    Note that "shut down" is two words. You can also use the words "restart", "sleep", or "log out". There will not be a confirmation dialog, excepting when applications ask to save unsaved documents (unless sleeping).
    In the future, you can find this is out again with Script Editor somewhere in the Applications folder (or use Spotlight). You'll want to open the "System Events" scripting dictionary, and it's probably already in the "Library" window (check the Window menu, or Command-Shift-L). Use the search in the "System Events" dictionary window to find "shut down", or anything else.
    Be careful about testing this script since it will immediately shutdown the computer without a confirmation dialog. Perhaps have an unsaved document opened while testing, such as another Automator workflow with any action added and unsaved, or a new TextEdit document with a some random text typed in (a single letter will do).

  • Spinning wheel freezes before shutdown

    Can anyone enlighten me please on what is being checked by the system during shutdown while the spinning wheel is spinning?
    My Mac Pro is not shutting down properly and the wheel freezes just before the system reboots. This reboot does not allow you to do a Safe start or go to alternate OS on startup
    I am using a Matrox Triple Head to Go box and the Mac works fine when I bypass it However I have a three montior system for a reason and having to fall back to one is very painful
    I do recall seeing something in passing on a browse about the spinning wheel inicates the system is looking for something and when it freezes it may have to do with nor finding that something, sorry I did not pay closer attnetion to that comment at the time
    Any insights most welcome
    Thanks a lot
    Geoff

    Any help?

  • Stuck before shutdown

    I was installing ilok software. It said installation was finished and it would need to log off. Now the MBP isn't doing anything and the menu bar is transparent - time and info on the right side, but no apple on the left.
    I can access Finder and some programs, but typing doesn't work.
    Is there a way I can shut down safely? Or do I have to do a hard reset with the power button?
    Any info is appreciated.

    Press the Power button once. If the Shutdown dialog appears then press RETURN to shut down. If it does not appear then you must do an abnormal shutdown by pressing and holding down the Power button for 5-10 seconds until the computer shuts down.
    Before restarting the computer do the following:
    Repairing the Hard Drive and Permissions
    Boot from your Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger, Leopard or Snow Leopard.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported, then quit DU and return to the installer. Now restart normally.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.

  • Stop before shutdown

    Hi everybody,
    I need to stop a shutoff browser process before close it (like when we shutdown the Operatin System and there is a modified document opened).
    Is there anything like this?
    Thanks,
    Maur�cio S. Mudrik
    IT Director
    Intercomax - Your Office in Transit
    Cybertools - Tools for Cyber Spaces
    Aeroshopping.net - The (future) Brazilian Airports Portal Services
    55 11 6445-2399 / 2388 / 2622

    Yes!
    I thinks is this I want.
    I gonna test it.
    Is there any example?
    Thanks.
    Maur�cio S. Mudrik
    IT Director
    Intercomax - Your Office in Transit
    Cybertools - Tools for Cyber Spaces
    Aeroshopping.net - The (future) Brazilian Airports Portal Services

Maybe you are looking for

  • Install error 11gR2 on Windows 2008 Server R2

    Hello, I have a question about an installation error I received on Windows 2008 Server R2 while trying to install the 11g R2 on an test machine. I had downloaded both cd's and extracted them and copied the first cd into an new directory and then trie

  • Regarding File to JDBC/MS Access database

    Hi all, I am trying to insert some values in to MS access database table.I kept the .mdb file in the local PI folder.I am getting connection error com.sap.aii.af.service.util.concurrent.ResourcePoolException: Unable to create new pooled resource: Dri

  • How to copy my current bookmarks to a new firefox bookmark ?

    okay ,i posted before where do i find the place of my bookmarks on the hard drive ...But now i want to format my hard drive ,so i want to copy my current firefox bookmarks .--> to the new firefox when i install new windows ..if you can just show me h

  • App to monitor hard drive activity?

    Hi, I posted here: http://discussions.apple.com/thread.jspa?threadID=2001256&tstart=0 about my Seagate external firewire 800 drive that keeps waking up from sleep, apparently unecessarily. I have seen one other person with this problem with a Lacie D

  • Email contact info

    I have my company directory in my contacts on my iphone. There are several people with the same name. Too many to change. When I try to use email & select the contact there is no way to know if i selected the correct person. Is there a way to see mor