Python Forum
crontab on RHEL7 not calling python script wrapped in shell script
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
crontab on RHEL7 not calling python script wrapped in shell script
#1
Hi I have a Python3 script wrapped in a shell script (needs to be for the moment) which executes fine when running from command line, but doesn't execute from crontab.

I have tested touching a file within the wrapper and it is created, so the script is running, but the python call does nothing.

Shell script contains as follows, very basic:

python dvdsrefresh.py ${1}

No errors, no output.

"which python" resolves to: /opt/rh/rh-python36/root/bin/python
Reply
#2
You need to provide more details. When you say "wrapped in a shell" I expected the Python code to be embedded in a shell script, but you show a .py file. Please give enough detail to reproduce.
Feel like you're not getting the answers you want? Checkout the help/rules for things like what to include/not include in a post, how to use code tags, how to ask smart questions, and more.

Pro-tip - there's an inverse correlation between the number of lines of code posted and my enthusiasm for helping with a question :)
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How can I get Python Bulk Email Verification Script With API? zainalee 1 214 Jun-06-2021, 09:19 AM
Last Post: snippsat
  Python script for excel sheet Nabil 5 309 Jun-01-2021, 02:29 PM
Last Post: anuradha
  Calling python from c++ in visual studio pdk5 0 232 May-24-2021, 10:18 AM
Last Post: pdk5
  Automatic user/password entry on prompt by bash script PBOX_XS4_2001 3 341 May-18-2021, 06:42 PM
Last Post: Skaperen
  Possible to execute a python script before log off/shutdown with input commands? Kaltex 1 225 May-18-2021, 06:31 AM
Last Post: Skaperen
  cant use ping, sudo or other commands in remote shell script. throwaway34 7 441 May-17-2021, 11:29 AM
Last Post: throwaway34
  Running script on multiple files Afrodizzyjack 1 237 May-14-2021, 10:49 PM
Last Post: Yoriz
  Run CMD Command In Python Script shantanu97 2 1,040 May-13-2021, 08:08 AM
Last Post: Gribouillis
  Python script in Ubuntu core Nithin_Kumar 1 406 May-11-2021, 01:14 AM
Last Post: Skaperen
  Run one Python Script from Another Script stylingpat 1 268 May-03-2021, 02:59 PM
Last Post: Marbelous

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020