Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Yes it means that cron is running. What crontab are you using /etc/crontab, or a file under /etc/cron.daily|weekly|monthly or a user crontab under /var/spool/cron?
not really sure just typed crontab cron.txt in the directory that cron.txt is located... when I type crontab -l it shows the crontab that I have setup, it is:
No result - your crontab would just not be executed.
You should have cron logfile - usually /var/log/cron, or there maybe a /var/log/cron directory under which there are a few logfiles - 'info', 'errors' and 'warnings'
Do these logs say anything about your particular job? When was the cron log last updated? Can you see jobs being executed recently?
If it shows the cron that you setup - then it means that cron executed the job.
Are you not seeing results? If not, what should happen that is not happening?
You might also want to try and keep the stderr - so remove 2>&1 from the end of the command, that way if there is an error, it will be sent to your mailbox (type mail to read it) and hence help in any diagnosis.
I am running the cron to do backups, the results is that I should have a copy of the files saved on an external hard drive connected to the computer... the only problem is that I am not getting the files copied.
While you're waiting for it, some things to think about:
1. Remember to try and execute via cron, without throwing away the stderr - it may send a useful error to your mail.
2. Ensure that any commands you are running in the script have been declared in a PATH variable - cron will not inherit the environmental variables of your shell, so if you're using any commands that have not been declared in the PATH variable in the script, cron will not be able to find them. (if the script works from the command line it's probably easier to copy the PATH variable declaration from your .bashrc or .bash_profile - wherever it is located for your user).
These may not solve the problem, but they will help troubleshoot and eliminate possible causes.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.