Techsurvivors

Archives => 2003 => Topic started by: rongold on September 11, 2003, 06:13:39 AM

Title: OS X Maintenance
Post by: rongold on September 11, 2003, 06:13:39 AM
Having gotten into habit of weekly maintenance while using OS 8.6, based on posts here, are there suggestions as to maintenance routine with OS X?

Since I don't leave my computer on all night, I don't rely on system to run cron daily, weekly and monthly maintenance scripts. Instead, I am using Cocktail, which though shareware, enables most of the maintenance chores to be done with one program rather than with several freeware programs (e.g. Cache Out, MacJanitor, Maintenance1).  I also run Diskwarrior 3.

My question is how often to do this. The easy part is the cron scripts (daily, wekly, monthly). How frequently should Disk Warrior, cache deletion, and other chores such as log deletion, be run?

I am on 17" iMac G4, OS 10.2.6, 512 MB RAM. My primary uses are email, relatively small amount of daily browsing, and lots of word processing.

Thanks.
Title: OS X Maintenance
Post by: kelly on September 11, 2003, 09:07:16 AM
Don't have Diskwarrior. But just to start. Once a month? smile.gif
Title: OS X Maintenance
Post by: kps on September 11, 2003, 10:03:29 AM
The daily,weekly,monthly cron jobs won't run when the machine is sleeping anyway. What I have done is change the time for the system to run the scripts when the machine is likely to be on, that way they run quietly in the background. I set all of them to run at 9:30AM. You can do this as root, either in the terminal or with BBEdit's "command line plug-in, by editing the time portion of the /etc/crontab file.

The weekly script also does log rotation, so it's not necessary to trash logs manually or with Cocktail.

DiskWarrior....like kelly says.

I have had no reason to delete any caches...yet. I'd only do it if problems develop, I don't think it necessary as part of regular maintenance.
Title: OS X Maintenance
Post by: ljocampo on September 11, 2003, 06:37:00 PM
I run Diskwarrior 3 once a month (as Kelly suggest) and I use Retrospect to backup every week.  I clean the caches only if it seems to need it.  And since you boot up everyday, as I do, you really don't need any other maintenance, because OS X rebuilds itself at boot time.
Title: OS X Maintenance
Post by: June Drabek on September 11, 2003, 08:34:54 PM
What is this "cron" I am reading about ?
Title: OS X Maintenance
Post by: ljocampo on September 11, 2003, 11:59:29 PM
June:

CRON refers to UNIX system routines that do garbage collection, i.e. file maintenance chores to those who don't know the lingo.  These chores (cron routines) are usually done automatically by the UNIX systems.  However, as KPS says above, they're scheduled to run in the early AM hours.  Since Apple basically hasn't addressed this AM issue, programs like MacJanitor automate these cron routine for people who never have their computers on in the early AM hours, and subsequencially, the garbage doesn't get thrown out.  Download a free copy of MacJanitor (using it is a simple one click deal), and follow the other suggestions in the post above.
Title: OS X Maintenance
Post by: June Drabek on September 12, 2003, 02:25:47 PM
ljocampo....I downloaded Macjanitor, and I now have one copy on my hard disk, one copy on the dock, and one on the desktop, which does not want  to be trashed. It tells me, " Macjanitor cannot be moved because the disk Macjanitor is in use"...does that mean it will live in three different places  on my computer now ? Mercy !!!
Title: OS X Maintenance
Post by: Mrious_be on September 12, 2003, 02:57:41 PM
A guess:
You downloaded MacJanitor, which is a .dmg file stuffed as a .sit.
After downloading, you unstuffed it (or osx did it by itself) and a "drive" icon appeared on your desktop.
You copied the drive icon to a folder where you wanted the program to be saved.
The one in your dock is just an alias, that is put there by the program.
When MacJanitor runs, the alias will be visible, it can stay visible if you do "ctrl+click" on the icon in your dock and choose it from the popup menu.
The reason why the drive didn't wanted to trash is probably cause you opened the program from on your desktop, and it was still running while you tried to delete it.
OR the icon in your dock is an alias pointing out to the drive icon on your desktop, and not to the copy that you put in one of your folders.

I think this should solve that problem smile.gif
Title: OS X Maintenance
Post by: Mrious_be on September 12, 2003, 02:59:53 PM
QUOTE(ljocampo @ Sep 12 2003, 6:59 AM)
However, as KPS says above, they're scheduled to run in the early AM hours.

 Do you know what hours to?
It's very interesting actually smile.gif
Title: OS X Maintenance
Post by: June Drabek on September 12, 2003, 03:19:13 PM
mrious_be

It just  keeps growing.....this is what my trash  contains now. Still  one in dock, which I placed there..one on hard drive, and one on desktop. Woe is  me.

MacJanitor_1.2.1.dmg.sit
MacJanitor 1.2.1 alias copy
MacJanitor 1.2.1 alias copy 2
MacJanitor 1.2.1 alias copy 3
MacJanitor 1.2.1
<-- Drag 'MacJanitor' to your hard drive
MacJanitor 1.2.1 alias
MacJanitor_1.2.1.dmg
MacJanitor 1.2.1 alias copy 1
Title: OS X Maintenance
Post by: ljocampo on September 12, 2003, 04:00:21 PM
June:

The one on the desktop is probably the disk image (dmg file).  To get rid of it you need to eject it by draging it to the trash or control clicking and choose eject from the contextual menu.  This is NOT the program, it's a dmg file. You should have double clicked this dmg file first and dragged the MacJanitor program to your applications folder and run the program from this one.

The one the dock should be an aliases, unless you mistakenly dragged the dmg file there instead.  Look to see if there is a little black triangle. If so quit it the normal way.  Either way, just drag it out of the dock.  If it goes puff and vanishes, it was an aliases to the program, but if it stays on the desktop, it's probably the dmg file so drag it to the trash and or eject.

Once you have quit the program and and put all those extra icons in the trash you should be able to empty the trash.  If not log out and then back in to reset everything and then empty the trash.

After all this you should have only one MacJanitor application (hint: if get info doesn't say its an application you still have the dmg file) in your applications folder where you dragged it.  The reason you got into this trouble in the first, is not your fault.  It's the developer's fault because he used a custon icon for the dmg (disk image) file that is the same as the program.  This is a real no no in interface design.
Title: OS X Maintenance
Post by: ljocampo on September 12, 2003, 04:05:11 PM
Mrious:  That's a real UNIX mystery.  But if if you really need to, I guess you can go to the BSD website and find out,  Apple uses 4.4BSD as it's OS X UNIX core.
Title: OS X Maintenance
Post by: Mrious_be on September 13, 2003, 03:05:20 AM
QUOTE(ljocampo @ Sep 12 2003, 11:05 PM)
Mrious:  That's a real UNIX mystery.  But if if you really need to, I guess you can go to the BSD website and find out,  Apple uses 4.4BSD as it's OS X UNIX core.

 I'm not sure if i want to dig into that biggrin.gif
But i'll try to see anyway wink.gif

thx
Title: OS X Maintenance
Post by: Mrious_be on September 13, 2003, 03:06:42 AM
Aaargh, i posted the same reply twice... well the board did biggrin.gif
First had an error, than had the "flood control" message, than it worked but it seems it added the reply already by than.

 oops.gif
Title: OS X Maintenance
Post by: June Drabek on September 13, 2003, 11:47:19 AM
I installed  and ran Macjanitor, then went to look at some other programs, and couldn't get  to anything. So I shut down the comuter..came  back about an hour later, turned it on and was able to go anywhere, but Macjanitor has completely disappeared.  Do you think it is  rejecting me or my eMac ?
Title: OS X Maintenance
Post by: kps on September 13, 2003, 10:19:34 PM
Mrious_be, drag and drop the /etc/crontab file onto TextEdit and you can see when the scripts are to be run... (TextEdit can not run as root any longer, so don't worry about doing anything to your system by opening it).

I talked about it here many month ago... THREAD. Scroll near the bottom.

Since I changed mine, I don't remember the times exactly, but I believe they are:

Daily::::::4:15 AM each day
Weekly:::4:30 AM each Saturday
Monthly::5:30 AM on the 1st Day of each month
Title: OS X Maintenance
Post by: Gary S on September 13, 2003, 10:38:57 PM
I just use MacJanitor to run the cron scripts, Disk Utility and DiskWarrior 3 about once a month.
Title: OS X Maintenance
Post by: ljocampo on September 13, 2003, 10:42:37 PM
KPS:   You have have told Mrious that the crontab file in NOT a visible file.  She is not going to find it unless she search for invisible files.   Thinking.gif
Title: OS X Maintenance
Post by: ljocampo on September 13, 2003, 10:43:54 PM
have have = should have    oops.gif
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 04:43:41 AM
QUOTE(kps @ Sep 14 2003, 5:19 AM)
Mrious_be, drag and drop the /etc/crontab file onto TextEdit and you can see when the scripts are to be run...

Daily::::::4:15 AM each day
Weekly:::4:30 AM each Saturday
Monthly::5:30 AM on the 1st Day of each month

 Woooow KPS, that's very interesting.
I would like to change mine to, cause it's what i thought.... it's to early for since i get up every weekday at 5am, but not in the weekdays.
So with a little luck only the monthly are working sometimes.
Than again, it might be easier if i just use MacJanitor again (i downloaded it already).

I do check that out though smile.gif

Thx, really interesting.
Title: OS X Maintenance
Post by: kps on September 14, 2003, 08:36:07 AM
Ijocampo, the crontab file is not invisible, the /etc directory is... wink.gif

I think Marcel knows this. The simplest way to get there is using the GO menu in the Finder. Go To Folder :: /etc and you're there.

Find crontab and Drag and Drop it onto TextEdit to see it. You wont be able to make any changes because it's owned by the System, but it gives you a chance to see how it works.

To change the crontab file, you must be root and consequently root must be enabled...however sudo should work even without root being enabled (I'm not sure of this as I have root enabled).

Marcel, the absolute easiest way to change the times in crontab is to use the Terminal Tool in BBEdit 6.5 or higher. Just navigate to /etc/crontab, edit and save. BBEdit will authenticate you as root and you're done...wonderful.

The other way is to use a CLI editor such as Pico, vi or emacs. But I dont think you're into it. wink.gif  If you are, let me know and I'll give you the instructions.
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 09:21:17 AM
QUOTE(ljocampo @ Sep 14 2003, 5:42 AM)
KPS:   You have have told Mrious that the crontab file in NOT a visible file.  She is not going to find it unless she search for invisible files.   Thinking.gif

 "She"? biggrin.gif
It could be a "He" wink.gif

yup yup B)
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 09:29:06 AM
QUOTE(kps @ Sep 14 2003, 3:36 PM)
I think Marcel knows this. The simplest way to get there is using the GO menu in the Finder. Go To Folder :: /etc and you're there.

Marcel, the absolute easiest way to change the times in crontab is to use the Terminal Tool in BBEdit 6.5 or higher. Just navigate to /etc/crontab, edit and save. BBEdit will authenticate you as root and you're done...wonderful.

The other way is to use a CLI editor such as Pico, vi or emacs. But I dont think you're into it. wink.gif  If you are, let me know and I'll give you the instructions.

 Well kps, this is kinda nice feeling but i think you have a to big credit when you think of me wink.gif
I wouldn't even know how to begin using the terminal, and i didn't know it was an invisible file blush-anim-cl.gif

But, i did found BBEdit is a shareware software it seems, i'm looking out for it on the net to see if it works for a while if i trie it in "Demo" mode.
Than i am gonna search for that Cron file.

Let you know smile.gif
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 09:30:35 AM
There's BBEdit Lite 6.1.2, but it's a lower version than you mentioned, so that won't work.

Found that Version 7.0.4 has a free trial for 30 days, i'm gonna give it a shot.
Actually i'm downloading already.

smile.gif
Title: OS X Maintenance
Post by: kps on September 14, 2003, 09:41:17 AM
Sorry, Marcel, I thought you had a full version of BBEdit. The "demo" doesn't have the Terminal Tool.

No problem, with respect to the "terminal" thang....  biggrin.gif  I know we discussed it several times over the past year or so... smile.gif
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 10:06:32 AM
Found it all as you said:
QUOTE
# Run daily/weekly/monthly jobs.
15   3   *   *   *   root   periodic daily
30   4   *   *   6   root   periodic weekly
30   5   1   *   *   root   periodic monthly


Wanted to change it in:
QUOTE
# Run daily/weekly/monthly jobs.
30   5   *   *   *   root   periodic daily
45   5   *   *   1   root   periodic weekly
30   11   1   *   *   root   periodic monthly


But than i started doubting if it was ok to enter a two number digit on the "monthly" line?
I do not wanna screw up things biggrin.gif
Title: OS X Maintenance
Post by: kps on September 14, 2003, 10:19:15 AM
Yes, you can change it to any time you want...a two digit # is okay.

Just remember, you will need to be root and do it in the terminal if you don't have the full version of BBEdit.

Want me to post the instructions?

You should practice with the terminal and pico first....
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 11:45:50 AM
QUOTE(kps @ Sep 14 2003, 5:19 PM)
Want me to post the instructions?
You should practice with the terminal and pico first....

 Well you can post them, than i'll see if i change them or not.
If not, i'll use MacJanitor myself.

smile.gif
Title: OS X Maintenance
Post by: kps on September 14, 2003, 03:48:06 PM
Okay here goes:

Open the Terminal and at the prompt, (%)
type: sudo pico /etc/crontab
Password: enter your admin pswd

the crontab file will open in Pico with root privileges and look like this:

CODE
# /etc/crontab
SHELL=/bin/sh
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin
HOME=/var/log
#
#minute    hour    mday    month    wday    who    command
#
#*/5    *    *    *    *    root    /usr/libexec/atrun
#
# Run daily/weekly/monthly jobs.
35    9    *    *    *    root    periodic daily
30    9    *    *    6    root    periodic weekly
30    9    1    *    *    root    periodic monthly


Just by using your arrow keys to navigate, change the time values to what you want...in my case they're all around 9:30AM.

With pico you have to delete extra characters, as they will not be deleted as you type the new ones. Use control+D to do that. Place the cursor over the character to delete and complete the key sequence ^D.

When you're done changing the values type: control+O (the letter O) to write the changes from Pico's buffer to the actual file. Re-read it making sure you made no errors. Then hit the <RETURN> key. Next, to exit Pico,  hit control+X (the letter x) that'll return you to the prompt. That's it!

Type: exit to exit the terminal and stop any processes. Finaly, quit the terminal app.

Have fun!
Title: OS X Maintenance
Post by: Mrious_be on September 14, 2003, 09:44:09 PM
QUOTE(kps @ Sep 14 2003, 5:19 PM)
Just remember, you will need to be root and do it in the terminal if you don't have the full version of BBEdit.

 When i first read that you said this, it made me doubt if it was doable with this Demo version.
But than i remember that the website mentionted this:
QUOTE
The BBEdit 7.0.4 Demo is fully-featured and functional to offer a true test of the software -- it will expire after 30 days but it is otherwise identical to the retail version and can be activated with a serial number upon purchase. Enjoy!

So i'm pretty sure i can do it with this Demo i have now.
If not, it seems not to hard to do it with the terminal so i'll give that a try.
I wish i found a book that contained good explanations about the Terminal and maybe some Unix.
In Belgium however there isn't much to find for the Terminal use on OsX (most books only mention it slightly).

Thanks again smile.gif
Title: OS X Maintenance
Post by: ljocampo on September 14, 2003, 11:08:33 PM
OK OK Guys here it is so no one go find it

# /etc/crontab
SHELL=/bin/sh
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin
HOME=/var/log
#
#minute   hour   mday   month   wday   who   command
#
#*/5   *   *   *   *   root   /usr/libexec/atrun
#
# Run daily/weekly/monthly jobs.
15   3   *   *   *   root   periodic daily
30   4   *   *   6   root   periodic weekly
30   5   1   *   *   root   periodic monthly

BTW  Mrious_be  sorry for assuming you as a "she."
Title: OS X Maintenance
Post by: ljocampo on September 14, 2003, 11:11:12 PM
BTW kps:  theree are several files named crontab that ARE invisible.   tongue.gif
Title: OS X Maintenance
Post by: kps on September 14, 2003, 11:39:04 PM
I'll reiterate, the files are not invisible and in reality the directories aren't either...it's just that the OS X Finder will not display the unix directories unless requested to do so.

The terminal, on the other hand, will list these directories by default and when asked will display all invisible files as well...the ones commonly refered to as "dot' files because they have a 'period' preceeding them.

There are three 'crontab' files in OS X by default, the file we're discussing, the binary and the manual page.
Title: OS X Maintenance
Post by: Mrious_be on September 15, 2003, 01:21:05 PM
Done smile.gif (and proud at myself) wink.gif
QUOTE
# /etc/crontab
SHELL=/bin/sh
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin
HOME=/var/log
#
#minute   hour   mday   month   wday   who   command
#
#*/5   *   *   *   *   root   /usr/libexec/atrun
#
# Run daily/weekly/monthly jobs.
30   5   *   *   *   root   periodic daily
40   5   *   *   1   root   periodic weekly
50   5   1   *   *   root   periodic monthly


 notworthy.gif kps & ljocampo clap.gif
Title: OS X Maintenance
Post by: June Drabek on September 16, 2003, 03:29:25 PM
In todays  email,  I received this message. It was  from"Microsoft" <security@microsoft.com> The message  reads,  Dear Friend, use this  patch immediately. dangerous virus in the Internet now ! More than 500,000 already infected. Then there is  an icon that reads "Patch exe 9.05 k.b. " I put it in  the trash and  checked out Hoax  Busters,  and Symantec and neither of them  had a report  on this.  What do you all  think ?
 
 sweatingbullets.gif
Title: OS X Maintenance
Post by: pendragon on September 16, 2003, 03:39:19 PM
June, As the KelMeister noted in another thread, what you have is the Dumaru Worm.

Details at http://us.mcafee.com/virusInfo/default.asp...00560&affid=125

Macs can't get this worm. Unless you are running a Virtual PC program of some sort, not to worry. You could however, forward it to your PC colleagues, so indeed you did the right thing by deleting it. clap.gif

Harv
Title: OS X Maintenance
Post by: June Drabek on September 16, 2003, 04:54:01 PM
Thank you HARV..I will go back and read your clickable now. Why do these idiots have to throw a scare into us like that ? I rarely open any email unless  it is a  recognizable person or organization,  but the way this came in made it sound more legitimate. brrrrrr...spookiy !!
Title: OS X Maintenance
Post by: Mrious_be on September 16, 2003, 10:38:54 PM
QUOTE(June Drabek @ Sep 16 2003, 11:54 PM)
...but the way this came in made it sound more legitimate. brrrrrr...spookiy !!

 That's one of the reason why so many people got infected sad.gif
Glad we are on a mac wink.gif

smile.gif