函数计算FC里部署的应用,能打开页面,但运行出现!200错误提示,怎么处理?

函数计算FC里部署的应用,能打开页面,但运行出现!200错误提示,怎么处理?运行接口这个报错 response: {'ErrorCode': 'CAExited', 'ErrorMessage': 'Function instance exited unexpectedly(code 1, message:operation not permitted) with start command \' \'.\nLogs:OpenBLAS WARNING - could not determine the L2 cache size on this system, assuming 256k\r\n2023-10-27 12:22:51,422 - modelscope - INFO - PyTorch version 2.0.1+cu117 Found.\r\n2023-10-27 12:22:51,439 - modelscope - INFO - Loading ast index from /mnt/auto/ast_indexer\r\n2023-10-27 12:22:51,443 - modelscope - INFO - No valid ast index found from /mnt/auto/ast_indexer, generating ast index from prebuilt!\r\n2023-10-27 12:22:51,782 - modelscope - INFO - Loading done! Current index file version is 1.8.1, with md5 2c26b8f616d95476e0bf242e6c0cabb6 and a total number of 893 components indexed\r\nOpenBLAS WARNING - could not determine the L2 cache size on this system, assuming 256k\r\n[2023-10-27 12:22:55,059] [INFO] [real_accelerator.py:133:get_accelerator] Setting ds_accelerator to cuda (auto detect)\r\n2023-10-27 12:22:55.940544: I tensorflow/stream_executor/platform/default/dso_loader.cc:49] Successfully opened dynamic library libcudart.so.11.0\r\nWARNING:tensorflow:Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\r\nTraceback (most recent call last):\r\n File "/usr/src/app/app.py", line 27, in \r\n HubApi().login(sdk_token)\r\n File "/opt/conda/lib/python3.8/site-packages/modelscope/hub/api.py", line 109, in login\r\n raise_for_http_status(r)\r\n File "/opt/conda/lib/python3.8/site-packages/modelscope/hub/errors.py", line 162, in raise_for_http_status\r\n raise HTTPError(http_error_msg, response=rsp)\r\nrequests.exceptions.HTTPError: 400 Client Error: Bad Request for url: http:// www.modelscope.cn/api/v1/login, body: b\'{"AccessToken": "6ddb66db-14ff-4831-8f82-61c852536623"}\''}

展开
收起
三分钟热度的鱼 2023-11-01 12:36:28 229 分享 版权
2 条回答
写回答
取消 提交回答
  • 面对过去,不要迷离;面对未来,不必彷徨;活在今天,你只要把自己完全展示给别人看。

    根据您提供的信息,部署的应用出现“!200 错误”,同时运行接口时出现 CAExited 错误,表明应用进程在启动时出现异常退出。根据错误提示中的堆栈信息,出现此问题可能是因为执行命令的操作未获得许可或操作系统未授权。
    针对这种情况,我建议您:

    1. 检查您的函数计算 FC 实例是否拥有正确的安全组规则和角色权限,以允许应用程序访问相应的资源和服务;
    2. 确保函数代码中的命令和路径没有出现错误;
    3. 更新您的系统组件以及相关的 Python 包,确保其符合函数计算 FC 对于环境的要求;
    4. 尝试重置实例或者重新创建一个新的实例来解决此问题。
    2023-11-02 23:06:42
    赞同 展开评论
  • Java

    当实例启动命令为java -Dserver.port=9000 -jar target/not_exist_file.jar时,报错信息如下。

    Function instance exited unexpectedly(code 1, message:operation not permitted) with start command 'java -Dserver.port=9000 -jar target/not_exist_file.jar '.
    Logs:Error: Unable to access jarfile target/not_exist_file.jar
    从报错日志中可以找到原因Unable to access jarfile target/not_exist_file.jar,即target/not_exist_file.jar文件不存在。报错的退出码为code 1, message:operation not permitted。

    如果启动参数中的文件不存在,则报错信息中的退出码一般为code 2, message:no such file or directory。特殊情况下,报错信息中的退出码可能不是code 2, message:no such file or directory或无退出码,此时,需要根据报错日志进行排查https://help.aliyun.com/zh/fc/user-guide/troubleshooting

    2023-11-01 14:22:47
    赞同 展开评论

快速交付实现商业价值。

还有其他疑问?
咨询AI助理