Good Day All . . .
This is a bit of everything and it seems to have happened since I installed 7.04.
I have a bash script that runs hourly on a Kcron job. It takes the new files from my personal area, /home and using rsync -avu copies them to a daily directory on two of my noauto,exec,user removable hard drives (No UUID in use) in the same box and logs the results.
I mount the drive, copy the files then unmount the drive. This is done twice.
The problem is that the second or last hard drive partition does not unmount on a Kcron job.
If I manually 'Run Now' in Kcron then both drive partitions are mounted and properly unmounted.
I have moved the cron job from user to root and reversed the two storage drives to see if a hardware problem is present but the problem is still exists.
Here are some observations:
1. The first run of the day captures the date and creates a new directory in storage drive one and transfers all the files in /home as it should. The log file shows that the second drive is mounted but the dated directory is the only footprint left. No files are transferred and the exit error routine is not activated.
2. Subsequent runs unmount the drives first. This is a less then graceful way of exiting if the drives are in use. The files are copied to storage drive one but my error routine kicks in when the script cannot save to storage drive two. A user mounted the drive but that same user cannot unmount the drive via a cron job but can unmount it if run as a standalone script in a terminal.
I have checked all the permissions and all the stats but nothing shows up. I have gone through the mount and umount help but no command line argument works.
I cannot divide then up into two scripts because the first run of the day may take 30 - 45 minutes to run while subsequent runs take only about ten seconds and I want them on an hourly basis.
Anyone point me in a new direction?
Thanks . . .
This is a bit of everything and it seems to have happened since I installed 7.04.
I have a bash script that runs hourly on a Kcron job. It takes the new files from my personal area, /home and using rsync -avu copies them to a daily directory on two of my noauto,exec,user removable hard drives (No UUID in use) in the same box and logs the results.
I mount the drive, copy the files then unmount the drive. This is done twice.
The problem is that the second or last hard drive partition does not unmount on a Kcron job.
If I manually 'Run Now' in Kcron then both drive partitions are mounted and properly unmounted.
I have moved the cron job from user to root and reversed the two storage drives to see if a hardware problem is present but the problem is still exists.
Here are some observations:
1. The first run of the day captures the date and creates a new directory in storage drive one and transfers all the files in /home as it should. The log file shows that the second drive is mounted but the dated directory is the only footprint left. No files are transferred and the exit error routine is not activated.
2. Subsequent runs unmount the drives first. This is a less then graceful way of exiting if the drives are in use. The files are copied to storage drive one but my error routine kicks in when the script cannot save to storage drive two. A user mounted the drive but that same user cannot unmount the drive via a cron job but can unmount it if run as a standalone script in a terminal.
I have checked all the permissions and all the stats but nothing shows up. I have gone through the mount and umount help but no command line argument works.
I cannot divide then up into two scripts because the first run of the day may take 30 - 45 minutes to run while subsequent runs take only about ten seconds and I want them on an hourly basis.
Anyone point me in a new direction?
Thanks . . .
Comment