执行python命令 报错如下:nohup python -u py_write_excel.py >>nouhp2.out 2>&1 &

[analyse@host-192-168-1-24 batch]$ more nouhp2.out Traceback (most recent call last): File "py_write_excel.py", line 5, in <module> import cx_Oracle ImportError: No module named cx_Oracle Traceback (most recent call last): File "py_write_excel.py", line 5, in <module> import cx_Oracle ImportError: No module named cx_Oracle nohup: ignoring input Traceback (most recent call last): File "py_write_excel.py", line 5, in <module> import cx_Oracle ImportError: No module named cx_Oracle

  

原因是python,命令  是默认用的python2,python2中默认是没有

cx_Oracle这个模块的,,如果改成python3就可以执行了。因为python3中内置
cx_Oracle这个模块

相关文章:

  • 2022-12-23
  • 2021-08-06
  • 2022-12-23
  • 2021-08-19
  • 2021-06-17
  • 2021-09-22
  • 2021-09-30
  • 2021-12-03
猜你喜欢
  • 2021-06-30
  • 2021-05-14
  • 2021-11-13
  • 2022-12-23
  • 2021-08-31
  • 2022-12-23
  • 2021-09-27
相关资源
相似解决方案