Re: [Toolserver-l] cronsub
Op 8 jan 2011, om 03:28 heeft River Tarnell het volgende geschreven: > I've made a couple of changes to cronsub in response to some issues > reported by > users. Specifically: > > * cronsub now requires that the script file be executable, and will > raise an > error if it's not. The previous behaviour was that non-executable > scripts > would be executed by /bin/sh. If this affects you, the fix is to > make the > script executable (chmod +x). > > I appreciate that the first item may be a breaking change for some > users. > However, on balance this seems like the lesser evil. I had an entry in my crontab like: 55 * * * * cronsub -l -s krinkle_clogger $HOME/bots/clogger-start.sh I got e-mails since a few minutes ago about it not being executable. This can be fixed by giving the user that executes it (in most cases the owner, you) the chmod x right So if it were chmodded like 644 it now needs to be 744 :) -- Krinkle ___ Toolserver-l mailing list (Toolserver-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/toolserver-l Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette
[Toolserver-l] cronsub
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi, I've made a couple of changes to cronsub in response to some issues reported by users. Specifically: * cronsub now requires that the script file be executable, and will raise an error if it's not. The previous behaviour was that non-executable scripts would be executed by /bin/sh. If this affects you, the fix is to make the script executable (chmod +x). * Previously, SGE would copy the job script to a shared directory and execute it there. For example, if you submitted $HOME/test.py, it would be copied to a file such as /sge62/default/spool/wolfsbane/job_scripts/117333 before starting. This was unfortunate for Python users who depended on Python's behaviour of treating the script's directory as part of the "import" search path. This behaviour has been changed, so that the script file will be executed in its original location. I appreciate that the first item may be a breaking change for some users. However, on balance this seems like the lesser evil. - river. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0ny8sACgkQIXd7fCuc5vK1UwCfaIt9gOSWym8sDOKR8bekuUaK Qy4AoLLJIB1xaUjeKdpUHLZ6npg/0FiS =VV97 -END PGP SIGNATURE- ___ Toolserver-l mailing list (Toolserver-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/toolserver-l Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette
Re: [Toolserver-l] Job scheduling a python bot script
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Dr. Trigon: > ... and this is the point were I am getting lost... this message > looks VERY strange to me, since I'm not using an X server (explicitely) > and I have no clue what the 'error/import.c' means there. The problem is that your Python script is not executable, and is therefore run as a shell (/bin/sh) script. "import" is a shell command from ImageMagick which takes a screenshot of an X display. The fix is to make the script executable. This behaviour is somewhat unfortunate and there's an open issue to resolve it, which will probably mean having cronsub raise an error if the script is not executable. - river. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0nwtIACgkQIXd7fCuc5vLM6wCgwBN1yHu13cevCpInD11g0SP3 wvwAoJq3lQD8gTIfJhpzXCGpjqZX8Vqm =Ckff -END PGP SIGNATURE- ___ Toolserver-l mailing list (Toolserver-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/toolserver-l Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette
[Toolserver-l] Job scheduling a python bot script
Hello all I'm currently trying to get 'Job scheduling' working form my modified pywikipedia bot python script. According to https://wiki.toolserver.org/view/Job_scheduling (Converting an existing cron job to use the scheduler) I tried to convert = 0 2 * * * nice -n +15 python /home/drtrigon/pywikipedia/runbotrun.py -cron 0 0 1,16 * * nice -n +15 python /home/drtrigon/pywikipedia/runbotrun.py -skip_clean_user_sandbox -compress_history:[] -cron 0 6 * * * nice -n +15 python /home/drtrigon/pywikipedia/subster_beta.py 2>> /home/drtrigon/public_html/DrTrigonBot/subster.html = to = 0 2 * * * cronsub -s mainbot $HOME/pywikipedia/runbotrun.py -cron 0 0 1,16 * * cronsub -s compbot $HOME/pywikipedia/runbotrun.py -skip_clean_user_sandbox -compress_history:[] -cron 0 6 * * * cronsub -s substerbot $HOME/pywikipedia/subster_beta.py 2>> $HOME/public_html/DrTrigonBot/subster.html = AND I tried to run to first of those jobs with 'qsub', by: qsub $HOME/pywikipedia/runbotrun.py -cron BUT this leads to the follwing output in my $HOME: = /sge62/default/spool/wolfsbane/job_scripts/117222: ^JThis bot is the general DrTrigonBot caller. It runs all the different sub tasks,^Jthat DrTrigonBot does.^J^J...^J: not found import: unable to open X server `' @ error/import.c/ImportImageCommand/364. import: unable to open X server `' @ error/import.c/ImportImageCommand/364. import: unable to open X server `' @ error/import.c/ImportImageCommand/364. import: unable to open X server `' @ error/import.c/ImportImageCommand/364. import: unable to open X server `' @ error/import.c/ImportImageCommand/364. /sge62/default/spool/wolfsbane/job_scripts/117222: from: not found logname: extra operand `=' Try `logname --help' for more information. /sge62/default/spool/wolfsbane/job_scripts/117222: logger_tmsp: not found /sge62/default/spool/wolfsbane/job_scripts/117222: syntax error at line 65: `(' unexpected = ... and this is the point were I am getting lost... this message looks VERY strange to me, since I'm not using an X server (explicitely) and I have no clue what the 'error/import.c' means there. Please can somebody give me a hint? Any ideas are welcome!! Thanks a lot and greetings Dr. Trigon ps: by the way; thanks for the good server maintenance and all that stuff!! ___ Toolserver-l mailing list (Toolserver-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/toolserver-l Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette
Re: [Toolserver-l] .environment file
2011/1/6 River Tarnell > Hash: SHA1 > > Hi, > > It's now possible to set environment variables in your $HOME/.environment > file, > as a series of NAME=value pairs, for example: > > PYTHONPATH=$HOME/pylib > > This will affect interactive logins, cron jobs and SGE jobs, but currently > not > web server CGI scripts. > >- river. > This promises to be useful. This evening I'll stop my #irc bot and I'll review the code of the the other script (which didn't survive the SGE migration. :-( Then I'll begin again to test scripts "by scratch", using new setting for jobs only. I am running at my limits, please be patient in case of mistakes. Alex ___ Toolserver-l mailing list (Toolserver-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/toolserver-l Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette