Pandoc文档转换失败,错误127 [英] pandoc document conversion failed with error 127
问题描述
我不确定如何制作一个可复制的示例,但是我很想知道是否有人遇到了这个问题。我有一个R Markdown文件通过运行Ubuntu的EC2实例上的闪亮服务器托管。几天里一切正常,现在当我尝试在浏览器中查看文档时突然出现以下错误:
I'm not sure how to make a reproducible example of this, but I'm curious to hear if anyone else has encountered this problem. I have an R Markdown file hosted via shiny server on an EC2 instance running Ubuntu. Everything was working fine for days and now suddenly I get the following error when I try to view the document in the browser:
pandoc document conversion failed with error 127
我没有转换为pdf,没有进行任何更改,几个小时前就开始运作了我在网上找不到有关此错误代码的任何内容,因此我不知道如何调试此问题。
I'm not converting to pdf, haven't pushed any changes, and it was working a few hours ago. I'm not finding much of anything online about this error code so I have no idea how to debug this issue. Anyone had this happen before?
推荐答案
我今天也遇到了类似的问题(请参见.log文件中的以下内容):
I faced a similar issue today (see below from .log file):
Warning in system(command) : system call failed: Cannot allocate memory
Warning: Error in : pandoc document conversion failed with error 127
Stack trace (innermost first):
105: pandoc_convert
104: convert
103: render
102: discover_rmd_resources
101: find_external_resources
100: copy_render_intermediates
99: output_format$intermediates_generator
98: <Anonymous>
97: do.call
96: contextFunc
95: .getReactiveEnvironment()$runWith
94: shiny::maskReactiveContext
93: <reactive>
82: doc
81: shiny::renderUI
80: func
79: origRenderFunc
78: output$__reactivedoc__
3: <Anonymous>
2: do.call
1: rmarkdown::run
我也是在EC2实例上通过Ubuntu运行Shiny Server,特别是 t2.micro
。我通过在此处投票最多的答案来解决此问题:如何您是否将交换添加到EC2实例?
I too am running Shiny Server via Ubuntu on an EC2 instance, specifically t2.micro
. I solved this issue by following the top-voted answer here: How do you add swap to an EC2 instance?
sudo /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024
sudo /sbin/mkswap /var/swap.1
sudo chmod 600 /var/swap.1
sudo /sbin/swapon /var/swap.1
添加到 / etc / fstab
:
/var/swap.1 swap swap defaults 0 0
简而言之,您可以在EBS上创建交换(内存)空间(因为 t2.micro
实例没有临时存储),并且应该缓解您的内存问题(不必升级到更大的EC2实例)。
In short, you can create swap (memory) space on your EBS (since t2.micro
instances don't have ephemeral storage) and this should alleviate your memory issue (without having to move up to a larger EC2 instance).
这篇关于Pandoc文档转换失败,错误127的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!