Joho the Blog
|
|
|
July 07, 2007
Things have been going well with my MacBook (thanks for all the IM help, Britt) until yesterday. The pattern that's emerging brings back the feelings of dread so familiar from my many years of Windows use. First my terminal window stopped working. When it starts up, it shows me the following message:
Then the built-in Web server stopped working. When I try to restart it using System Preferences > Sharing, it hangs. This morning, Smultron has started crashing whenever I try to save a file. I lost a bunch of work, which is just damn depressing, At least with Windows, I have enough experience to know how to try to fix it. With OS X, I've installed third party replacements for the terminal and Web server, but I fear I'm facing cascading system failures. Or is that just a Windows-based reaction? In any case, I'm not enjoying this feeling of helplessness:( [Tags: macintosh macbook whines ] Posted
by D. Weinberger at July 7, 2007 07:55 AM
|
Comments
I suggest checking the health of your hard drive.
I think it's in the utility folder...
Smart Drive or something like that. I'd look it up on my Mac, but it's hard drive crashed and the MacBook Pro is now at Apple getting a new hard drive and motherboard.
New motherboard for the second time.
It's a pain, but now I'm on the Vista laptop that Microsoft sent me and I'm getting errors telling me that I have an unauthorized version of Windows. Ha ha. Microsoft SENT IT TO ME...
So even though my Mac crashed twice, I still like it better than the Vista laptop. Over here on Vista, programs won't run, QuickTime and iTunes won't install, and I've got problems listening to and recording audio.
I have discovered the joys of gmail though. I like it.
Posted by: Steve Garfield | July 7, 2007 09:11 AM
One of the first recommendations for just about any oddity in OS X is to repair the permissions. I'm not every sure what that means, but it usually seems to help. Or maybe that it just makes me feel better. :-)
To do that, run the Disk Utility program (Applications --> Utilities folders). Click the drive name in the left column, click the First Aid tab, and click Repair Disk Permissions.
While the Mac OS is not perfect, it is still head and shoulders above Vista in terms of both usability and reliability.
Posted by: Tim | July 7, 2007 12:05 PM
Disk Utility, repair permissions, yes. That's the first thing I'd do. I have to admit, though, that I've never seen a similar problem.
Posted by: scott | July 7, 2007 12:27 PM
Thanks. I've repaired the permissions. It found some to fix (and some were in the Apache directory), but I'm still having the same problems.
I also ran a disk check, which reports that there are problems with the disk. Googling the message -- "Error: The underlying task reported failure on exit" -- however, suggests that it's not a real problem...just some files that didn't close. Nevertheless, I'm going to try to force an fdsk by booting into safe mode, or whatever the Mac calls it.
Thanks for the help...
Posted by: David Weinberger | July 7, 2007 01:41 PM
You have installed a bunch of third party software (including a third party terminal!) and wonder why there might be conflicts with their untested interaction with the Mac OS.
Smultron has started crashing With OS X, I've installed third party replacements for the terminal and Web server, but I fear I'm facing cascading system failures
Posted by: Gene Warech | July 7, 2007 01:51 PM
Gene, I installed the third party software AFTER and BECAUSE the other apps were failing. I needed a terminal after the Mac terminal failed, and I needed a Web server after the Mac web server failed.
Posted by: David Weinberger | July 7, 2007 02:44 PM
David, try downloading and running AppleJack (Google for it), which is free, and if that doesn't fix your problems, try Onyx (also free) and run the various maintenance utilities in it. If you're still getting system crashes, try a copy of DiskWarrior 4 ($$). Also try to run a hardware diagnostic, you may have a problem with an erratic disk or failing RAM; it may even be a physical problem with the RAM slot, this has been known to happen in Apple portables.
Posted by: Victor Panlilio | July 7, 2007 03:17 PM
David,
You could have called....
Try Cocktail - it does the nightly and weekly cron jobs that BSD likes, but are not triggered unless the MB is on in the middle of the night.
Repairs permissions too.
Posted by: Britt Blaser | July 7, 2007 05:35 PM
Cocktail link:
Posted by: Britt Blaser | July 7, 2007 05:39 PM
Reinstall your system files using the Archive and Restore option. Your applications, data and settings will remain and you will receive a clean installation of OS X. Use the installation disks that came with your machine. Insert Install Disk 1, follow instructions for an Archive and restore.
Posted by: David Funk | July 7, 2007 09:52 PM
Should have mentioned that I'd try DiskWarrior 4 FIRST. This is not free, but it is by far the best repair maintenance utility I've used for the Mac. I wouldn't be without it. It can fix a lot of problems. If it can't fix yours...reinstall the system.
Posted by: David Funk | July 7, 2007 09:55 PM
Um... Had any forced restarts? Tried started up from your system disk and running Disk Utility to repair the HD?
You sound so helpless! And installing third-party SW when the bundled apps don't work?
That's crazy. 4c worth.
Posted by: Ian Goss | July 8, 2007 08:30 AM
Have you tried another user account? Sometimes a broken preference file in ~/Library/Preferences can cause issues with applications..
Also, if you can run it, the Console application (in /Applications/Utilities) might report more useful errors. Run it from an Administrator account to get access to the system log.
Hope this helps.
Posted by: Juan Gatica | July 8, 2007 10:00 AM
I'm on the road without my system disk. I've run Disk Util from a safe boot (or whatever the Mac calls it when you press the shift key while booting). The DU reports no problems with my drive.
Juan, I'll try logging in as a different user. Thanks for the tip. The console app gives me a lot of info I can't make sense of.
And, yes, Ian, I am helpless. That's why I'm asking for help.
Also, Ian, you and Gene both take me to task for installing third party software. I don't understand the problem. Gene seems to be saying that installing 3rd party apps onto a _healthy_ system is foolish. You seem to be saying that installing 3rd party apps onto an _ailing_ system is foolish. Isn't the Mac more robust than that? Or am I missing your point?
Posted by: David Weinberger | July 8, 2007 12:23 PM
> You seem to be saying that installing 3rd party apps onto
> an _ailing_ system is foolish. Isn't the Mac more robust
> than that? Or am I missing your point?
The Mac is more robust than Windows, however it is not a magical system. If your disk is bad or even just the index of the disk is bad you want to avoid all writes because they may be overwriting data. This is a hard drive thing, not a Mac/Windows thing. That's why as soon as you have a problem the first thing you want to do is boot from another disk.
> I'm on the road without my system disk.
Definitely put your system disc into the case your computer travels in. Booting from the install DVD is step one in all troubleshooting. It is worth its weight in gold when you have a problem. From within the Mac OS X installer you can run Disk Utility (its a menu item) and because the hard disk is not the startup disk it can truly interrogate it and fix problems.
> Error: The underlying task reported failure on exit
I hate to break this to you, but your disk is probably bad. Even before you said you got this error, the problems you were having where you saw those errors in Terminal and so on, they screamed to me: "bad disk." The disk is not returning data reliably.
I've been using Mac OS X for 5 years, and in that time I had 3 major problems, and they were all hardware: bad disk, bad video RAM, bad power supply (on different machines). So I am inclined to suspect the hardware more than the software, which is not how it works on Windows, you are much more likely to think "I need to reinstall Windows" when a Windows PC goes bad. On the Mac, the underlying core OS software is so reliable that when you get a major freak-out like you're having, you really should think your hardware is bad. Especially when it is the disk that is suspect ... they go bad, they are complex little boxes with a million parts and they spin at ridiculous rates, it's amazing they're even as reliable as they are.
If you have data on there that is unique (not backed up) then I advise you to back it up ASAP, if you can even get it off of there. You are almost certainly going to have to replace that machine's hard disk and then install Mac OS X and from there you will be back to 100%. So the only thing to do is try to save any unique data off of there.
> At least with Windows, I have enough experience
> to know how to try to fix it.
Running into a problem like this is how you gain experience for troubleshooting next time, so don't be too down about it.
Posted by: Fred Hamranhansenhansen | July 8, 2007 05:56 PM
In situations like this the log files can be your friend. These can be found in /var/log but can only be accessed via a terminal window (Finder hides this directory).
Useful places to start are:
/var/log/system.log
/var/log/crashreporter.log
/var/log/httpd/error_log
e.g. tail -n 1000 /var/log/system.log
Note: You will need to be logged in as the administrator user to read these logs. If you can see a problem in the logs then hit Google and see if it brings up anything.
Another easier tip is to create a new user, restart the computer and log in with that account. See if you experience the same problems with that account as you do your personal one. If it is your account that has something strange going on then at least you've narrowed your problem window :-)
Posted by: David Harrison | July 8, 2007 06:28 PM
Just get a Mac.
Oh wait, you already did that part. (Sorry, I've been reading your blog for too long....)
Seriously, I would second the recommendation for DiskWarrior. It's an amazing tool.
As for the log files that David Harrison mentions, you don't need to start up a terminal to see them (which is good, since that's one of your problems). Just go to the Utilities folder in your Applications folder and start up an application called "Console". If you click on the "Logs" button, you should be able to select pretty much any log you want to view.
Posted by: ralph | July 8, 2007 11:31 PM
I would certainly recommend Disk Warrior. Every Mac owner should have it. That said, if it is a failing HD and you dont have a current back up and do have irreplaceable files then get File Salvage, it has saved my life. And if you suspect that your HD is the problem and you need stuff on it, don't use it at all until you can either repair it or get your data off it.
Good luck, I am sure that your Mac experience will get better.
I have been a Mac user since 1992 and twice I have had HDs go belly up on me, not Apples fault, and in all those years I have never seen the blue screen of death.
Posted by: Richard Dalziel-Sharpe | July 9, 2007 03:59 AM
Repairing permissions can sometimes help, but it is by no means the panacea many claim it is. Read more: http://daringfireball.net/2006/04/repair_permissions
http://daringfireball.net/2006/04/repair_permissions_voodoo
http://www.unsanity.org/archives/000410.php
If you want to see a GREAT list of troubleshooting steps, I recommend you take a look at the following page on MacOSXHints.com - Twenty steps to help diagnose and fix system issues:
http://www.macosxhints.com/article.php?story=2004011205473937
I get the impression that some of the hints posted in the comments here are from people who know as little about Mac OS X as you do. Your first step should never be to re-install the OS. You might not even need to buy DiskWarrior, although it is a very useful tool.
Fixing system problems isn't voodoo, it isn't magic. DiskWarrior deals with directory corruption (and more). It won't fix physical failure in your drive. It won't re-install system files that are damaged. And so on...
The trouble-shooting steps on the MacOSXHints.com page I mentioned are your best place to start. One of the steps is to try logging in a new user - corrupt preference files can cause problems for a given user. That was mentioned above, and is good advice.
Another thing you can try (on the Hints list of 20 steps) is to boot into Single-User Mode. You're essentially booting into a command line without major portions of the OS loading. You can run a command-line disk check from there: fsck -fy
AppleJack can do that for you, among many other things. However, there have been a few issues with AppleJack in the past after a system update made it out-dated. Make sure you check that AppleJack is up-to-date after a system update if you decide to use it.
I will say that the fact that you get error messages just by opening a Terminal window is strange. It sounds as though there is something in your default (or user) shell profile that is trying to run a Java file. Have you installed anything recently?
Posted by: Dan Shockley | July 9, 2007 07:53 AM
Thanks for all the great pointers, tips and help.
FWIW, the Apple diagnostic disk reported no problems, including on a complete surface scan.
If I log in as another user, my terminal window works. So, it's something in the prefs? My cshrc looks ok.
I just bought Disk Warrior and am running it now. I'm thinking that it's not a disk problem, though. I'm about to check my profile.
Thanks again.
And let me say for the record, I'm really enjoying my MacBook. I've owned Mac's on and off since the Mac came out, and for whatever reason, I never really felt comfortable with one before. This one is different. Or I am.
Posted by: David Weinberger | July 9, 2007 03:41 PM
Hi David. Glad switching the user account helped Terminal at least. One thing you can try in your ailing user account is moving the file ~/Library/Preferences/com.apple.Terminal.plist out of that directory. It's possible that it has some startup script that it's running. If you can start up Terminal after moving that file out, then that preference file is the culprit. Unfortunately, if you have customized the behavior of Terminal, you will lose that when deleting the preference file.
One question - have you changed the default shell for Terminal? The default shell is normally bash, which would read .profile, .bash_login, etc and not .cshrc (which is a csh/tcsh startup script).
Posted by: Juan Gatica | July 9, 2007 08:45 PM
Juan, the problem was in the plist! I renamed it and terminal started up like a champ!
Thank you!
Now I just have to figure out why apache stopped running. Plus, I've noticed that a bunch of the standard apps are no longer on my disk. Since I didn't delete them, something wonky went on. But I'm making my way back, thanks to you and the other helpful people who have responded.
I'l blog soon about how much I'm enjoying my MacBook, despite this glitch.
Posted by: David Weinberger | July 13, 2007 08:23 AM