ASP.NET Core项目部署在Linux下可能会出现GDI错误

  1. The type initializer for 'Gdip' threw an exception
    1.   解决方案:创建 libdl 的软链接

      #  /lib/x86_64-linux-gnu/libdl*
      sudo ln -s /lib/x86_64-linux-gnu/libdl.so.2 /lib/x86_64-linux-gnu/libdl.so

      sudo ln -s /lib/x86_64-linux-gnu/libdl-2.xx.so /lib/x86_64-linux-gnu/libdl.so

      #  /lib/x86_64-linux-gnu/libdl*
      sudo ln -s /lib/x86_64-linux-gnu/libdl.so.2 /usr/lib/x86_64-linux-gnu/libdl.so

      sudo ln -s /lib/x86_64-linux-gnu/libdl-2.xx.so /usr/lib/x86_64-linux-gnu/libdl.so
  2. Unable to load DLL 'libgdiplus'
    1.   解决方案:安装 libgdiplus 包

      sudo apt install libgdiplus
      # 有可能还需要创建一个软链接
      sudo ln -s /usr/lib/libgdiplus.so /usr/lib/gdiplus.dll

ASP.Net Core "The type initializer for 'Gdip' threw an exception"的更多相关文章

  1. System.Drawing Linux Centos7 The type initializer for 'Gdip' threw an exception

    System.Drawing 在linux使用时提示异常 The type initializer for 'Gdip' threw an exception 解决方案: yum install au ...

  2. .net Core 在 CentOS7下,报The type initializer for 'Gdip' threw an exception.异常

    .net Core允许在 Centos7 上,使用 System.Draw.Common类库时,报以下错误: "Class":"System.TypeInitializa ...

  3. 使用Spire组件抛出异常The type initializer for 'spr857' threw an exception

    使用Spire组件抛出异常The type initializer for 'spr857' threw an exception 我使用免费的Spire.Xls组件尝试去转换Excel文档到PDF文 ...

  4. Asp.Net Core使用System.Drawing.Common部署到docker报错问题

    Asp.Net Core 2.1发布后,正式支持System.Drawing.Common绘图了,可以用来做一些图片验证码之类的功能.但是把网站部署到docker容器里运行会遇到很多问题,也是非常闹心 ...

  5. 尝试在mac上用dotnet cli运行asp.net core示例程序

    自从知道微软用dotnet cli取代dnx之后,一直在等dotnet cli支持asp.net core... 昨天看到这篇新闻(ASP.NET Core 1.0 Hello World)后,才知道 ...

  6. ASP NET Core --- 资源塑形, HATEOAS, Media Type

    参照 草根专栏- ASP.NET Core + Ng6 实战:https://v.qq.com/x/page/d07652pu1zi.html 一.Get返回资源塑形 1.添加集合塑形Enumerab ...

  7. asp.net core 3.0 JObject The collection type 'Newtonsoft.Json.Linq.JObject' is not supported

    在asp.net core 3.0 中,如果直接在Controller中返回 Jobject 类型,会抛出如下错误: The collection type 'Newtonsoft.Json.Linq ...

  8. [.NET Core]ASP.NET Core中如何解决接收表单时的不支持的媒体类型(HTTP 415 Unsupported Media Type)错误呢?

    [.NET Core]ASP.NET Core中如何解决接收表单时的不支持的媒体类型(HTTP 415 Unsupported Media Type)错误呢? 在ASP.NET Core应用程序中,接 ...

  9. Working with Data » Getting started with ASP.NET Core and Entity Framework Core using Visual Studio » 创建复杂数据模型

    Creating a complex data model 创建复杂数据模型 8 of 9 people found this helpful The Contoso University sampl ...

随机推荐

  1. Windows下利用MKL加速caffe,与openblas比较

    一.介绍:先简单Mark一下网上的介绍资料,弄清楚MKL是个啥,已经与openblas等的关系. 矩阵运算库blas, cblas, openblas, atlas, lapack, mkl之间有什么 ...

  2. VS2015编译FFMPEG,修改FFmpeg缓冲区大小解决实时流解码丢包问题,FFmpeg错误rtsp流地址卡死的问题,设置超时

    之前尝试过很多网上利用Windows编译FFmpeg的文章,都没有办法编译X64位的FFmpeg,有些教程中有专门提到编译64位的FFmpeg需要下载mingw-w64-install,但是编译的过程 ...

  3. CSS(五)

    定位 关于定位 我们可以使用css的position属性来设置元素的定位类型,postion的设置项如下: relative 生成相对定位元素,元素所占据的文档流的位置不变,元素本身相对文档流的位置进 ...

  4. 浅谈AngularJS中的指令和指令间的相互通信

    说到AngularJS,我们首先想到的大概也就是双向数据绑定和指令系统了,这两者也是AngularJS中最为吸引人的地方.双向数据绑定呢,感觉没什么好说的,那么今天我们就来简单的讨论下AngularJ ...

  5. Jenkins调度Selenium脚本不能打开浏览器解决办法

    前提:在Myeclipse里面可以启动起来浏览器,在Jenkins中不能启动浏览器 原因:以程序的方式安装了jenkins,jenkins就成了windows的一个服务了,默认是设置为自动启动的如下图 ...

  6. C语言:二进制模5

    输入一串字符,若是二进制则求其模五的值. 要求:1.若输入的字符包含除0.1以外的值,则输出:invalid 2.若输入的为二进制字符串,则输出所计算的其模五的值 3.若其输入字符均为0.1,但是第一 ...

  7. kubernetes in action - Overview

    传统的应用都是“monoliths”,意思就是大应用,即所有逻辑和模块都耦合在一起的 这样明显很挺多问题的,比如只能scale up,升级必须整体升级,扩容 所以我们就想把大应用,broken dow ...

  8. div盒子水平居垂直中的几种方法

      div盒子水平居垂直中的几种方法<!DOCTYPE html><html>    <head>        <mete charset="ut ...

  9. numpy(二)

    通用函数: np.add  加 np.subtract  减 np.multiply  乘 np.divide  除 np.floor_divide  地板乘除法,取商 np.power  指数运算  ...

  10. spring-boot mybatis配置

    接着我们的spring boot项目,spring boot如何使用mybatis访问数据库呢? 个人习惯使用mapper接口和xml配置sql,从pom.xml入手 1.1 添加依赖 <dep ...