OS X V10.7 Lion :: Cron Job Not Running - Script Uses Rsync, Ssh (with Id_rsa)?
Apr 26, 2012
Does anyone know how to get cron to run a rsync/ssh script which uses id_rsa for passwordless logins? I have a backup script I have slaved for months over that works wonderfully when running it from the command line.  It uses rsync and connects with SSH (passwordless using ssh keys). I have setup id_rsa and id_rsa.pub for passwordless logins (this is my user account, and connects using root@ to the server) As stated all works find when run from the command line. But when I setup a cron job to run this file (exact same line I run from the command line) it does not execute. Actually, it does run, as I have an email notifiction which sends to me. It is just the rsync/ssh part that does not run. Â
I have spent days and days trying to figure it out. No error messages occur, nothing. Took me a while to find out cron is emailing the user account on Lion the messages (not to a proper email address).  The error shows a permission denied, which I believe to be the cron user cannot use the id_rsa/ssh connection.  Cron is running the script as my user, the same I use on the command line. I even tried copying the id_rsa to the root user .ssh folder in case cron is running as root but that does not work either.how to get cron to run this rsync/ssh script which used id_rsa for passwordless logins? Â
I have two disks I have been working with one on my MacBook Pro (HFS+) and one connected to a Linux machine (FAT - this is an external hard drive). Recently I started exploring backing up my files with rsync over an ssh from my Mac to the external hard drive connected to the Linux machine. I did this once successfully and ported all of my Mac files to the external. However, I did something incorrectly the second time and I believe I may have done rsync in the wrong direction and it has overwritten some files on my Mac (configuration files for iCal that had events stored, an iPhone program I've been working on). The full rsync command I used was the following:
Code: rsync -avz -e ssh linux@linuxuser:/media/external/Users /Users However, I was under the impression rsync wouldn't touch files that are timestamped at a newer date so even if it was copying from the linux external to the mac hard drive why would it overwrite newer files??
I have recently downloaded scalpel to try to see if I could find these files but every time I run
Code: ./scalpel /dev/disk0s2 -o recovery/ I get the error
Code: ERROR: You have attempted to use a non-empty output directory. In order to maintain forensic soundness, this is not allowed. Aborting. recovery/ is a directory I created solely for the purpose to scalpel and is empty.
If there is anyone out there who has any ideas that might lead me down the path to recovering some of these overwritten files I would be eternally grateful (especially the iPhone program which I've been working on for 3 months).
I am trying to adapt a workflow that i downloaded from Finished workflow, ready to use zip | 148 kb Sourced from: url...The workflow is a rsync workflow that syncs (mirrors) two folders.At present the Run Shell Script runs rsync -va --delete "$1/" "$2/".However, i would like the script to prompt me with a "Would you like to run a dry run? " dialogue box with a Yes/No answer. The Yes command would run the following script (Dry run) rsync -vaun --delete "$1/" "$2/".The No command would run the following script (Actual run) rsync -vau --delete "$1/" "$2/" set question to display dialog "Would you like to run a Dry Run?" buttons {"Yes", "No"} default button 1 set answer to button returned of question.
Over the past month Lion has been crashing, running slow and freezing constantly.\Â I am not used to having so many PC type issues on my Mac. I have done Disk repair in utilities and removed unecessary programs at start up.Â
least using OS X Lion on a MacBook 3,1 with a 2.2 GHz Core 2 Duo and 4 gigs of RAM or a similar system. I'm thinking about moving up from Snow Leopard 10.6.8 but don't want to do it if it's going to bog the computer down. I know the machine satisfies the basic system requirements, but I want it to be usable in a non-frustrating way.
I'm trying to install 10.7 Lion on my wife's MBP. In the process of doing that, the Lion installer says her hardrive is not "journaled" and that I need to "enable journaling". The recommendation for that is to boot off an install CD and enable it via Disk Doctor. Seems easy enough.Â
Unfortunately, she can't find the 10.6 Snow Leopard CD. I have an old 10.5 Leopard disc that I put in and tried to boot from while holding the C key. The disc spins and spins, but I only see a gray screen.Â
I also tried holding "shift" and selecting the disc as my start up volume. Same thing; gray screen.Â
My questions are:Â
1: Is it even possible to boot off the 10.5 disc when running 10.6?
2: If not, is there anything else I can do to boot off an external volumeÂ
I've been noticing with iStat Pro that out my 8GB of memory, 1.2 GB of it is Active and 1.3 GB is Wired, but when no applications are running. Not even the hidden task bar ones. Then when I start Google Chrome, my Active memory jumps up to 2.4 GB. I'm on a Macbook Pro (thunderbolt gen) with a Core i5 2.3 Ghz, 8 GB memory along with a 500 GB Hard Drive (80% full). I've had my Macbook for almost a year now, and this has become progressively worse.
I've been noticing with iStat Pro that out my 8GB of memory, 1.2 GB of it is Active and 1.3 GB is Wired, but when no applications are running. Not even the hidden task bar ones. Then when I start Google Chrome, my Active memory jumps up to 2.4 GB. I'm on a Macbook Pro (thunderbolt gen) with a Core i5 2.3 Ghz, 8 GB memory along with a 500 GB Hard Drive (80% full). I've had my Macbook for almost a year now, and this has become progressivly worse.
My late 2011 iMac started slowing down about 3 months ago. My hard drive then got corrupt and I restored to mac osx lion anew. It sped up a bit but still slow. Last month my iMac started doing the same thing so instead of restoreing I moves all of my files to an external hard drive. Now I rerestored once again but it didn't help. A prime example of the speed decrease is the game minecraft. Half a year ago I could run a server and run on the good graphics smoothly. Now I can even look around with only minecraft. It took me 30 min to turn on. I had to do this on my iPad because I mac couldnt make it here.
My iMac(Early 2008) 2.4GHz Intel Core 2 Duo. Its has been runing slow lately, it works alright at first but then it starts freezing and sometimes it doesn't load new tabs. I'm runing OS X Lion. Is there a way to make my computer run faster or atleast normal, like it use to run.
I have a new imac 3.4ghz - i7 with 16gbs ram that won't shut down unless I hold in the power button. I checked the Console logs but that did not give me any indication of what might be hanging it up. I also, have a Macbook Pro running 10.6.8 and it has no trouble powering down. Â
I am running AVID Symphony which is not qualified for 10.7.4 yet so I am not going to do the update yet. Â
I have a 2007 Mac Pro running 10.7.4. Will I be able to upgrade to mountain Lion? I have a 2007 Mac Pro running 10.7.4. Will I be able to upgrade to Mountain Lion? I have a 2007 Mac Pro running 10.7.4. Will I be able to upgrade to Mountain Lion?
When it wakes up it tries to connect and fails, but as soon as I choose my home network from the list it connects immediately. I have checked the box remember this network . I have tried all the tricks found on the internet and still have to copnnect manually.
After installing lion os on 2008 macbook air soetimes the system hangs and reboot dores not help . I have had to resore from Recovery HD a couple of time
I moved to an iMac from PC 3 months ago, and installed my NAS server as an externally mounted drive, with password protected user logon, and a separate media folder for all itunes music, videos etc, and all photo storage.
This worked fine for a couple of months, and seemed to connect automatically at startup I don't recall any issues at all.That changed a few weeks ago, and each session I now need to re-connect by logging on to the NAS with password. The consquence is that the Home drive keeps being remapped to the internal HD, and the itunes media storage location to the same internal HD, not the NAS.
Info:iMac (21.5-inch Mid 2011), Mac OS X (10.7.3), QNAP TS-419P NAS server
I have a Power Mac G5 Dual 2.3 running 10.5.8, I understand that I can not upgrade to Lion, so what will happen to my Mobile me, which I can not live with out? Also will I be able to get Icloud to work?
Info: PowerMac, Mac OS X (10.5.8), Can I get ICloud to work
I notice recently the my cursor would jump around at ramdom ..I check the batteries 100% try different mouse still jumps around tried my trackpad still jump around..
Got my new MacBook Pro - I'm used to Mac as I have had iMac & the smaller MacBook for about 6 years so fairly user savvy, but have never come across the problem I have at the moment. Set up my mail accounts - received and sent mails, but the whole time the little gearwheel is running on the sent box. Is this normal - I've never had it before unless I've actually been sending and at the moment I'm not.
Ever since upgrading to OSX 10.7.4, Safari has been very slow loading websites that normally are very fast. When I open Safari or load a page I get the spinning ball for as long as fifteen seconds. This is especially problematic when I initially open Safari in the morning after my iMac has been asleep for several hours.
But recently I discovered, after checking in the Activity Monitor app, that some apps just will retire its icon from the Dock, but they will still be running in the background actively consuming resourses (real mem, % CPU, CPU Time, etc.)Â
I have noticed that this can happen with other apps. (So far) these others are: iTunes, iPhoto, iCal, AddressBook, QuickTime.Â
It is disturbing to think that every time I have to close an app, I have to do it by using the "Quit Process" in the Activity Monitor utility.Â
Either the app is set to keep the icon in the dock or not, after closing the app, the icon's light indicator turns of or the icon removes itself from the dock acordingly, but the app will remaing running in the background.Â
My iMac internet has become so slow I tend not to use it much at all. An adjacent PC runs fine so it seems to be a software issue and is relatively recent.