2014-10-17 9 views
1

centos 6에서 광 서버를 사용 중이며, 대부분의 내 앱에서 잘 작동하지만 잘못된 점이 있습니다. 내가 rCharts와 함께 사용할 때 (ggplot2는 괜찮습니다). 크롬에서 "리소스를로드하지 못했습니다. 서버가 500 (내부 서버 오류) 상태로 응답했습니다."라는 메시지가 표시되지만 로컬 Windows7 시스템에서 동일한 코드를 실행할 수 있습니다. 오류 로그가 없습니다. 뭐가 잘못 됐어. 친구가 그 문제를 어떻게 처리해야하는지 알고 있으면 감사 인사하십시오.shiny-server 리소스를로드하지 못했습니다 : 서버가 500 (내부 서버 오류)의 응답으로 응답했습니다.

코드는 다음과 같습니다

server.R

require(rCharts) 
shinyServer(function(input, output) { 
    output$myChart <- renderChart({ 
    names(iris) = gsub("\\.", "", names(iris)) 
    p1 <- rPlot(input$x, input$y, data = iris, color = "Species", 
     facet = "Species", type = 'point') 
    p1$addParams(dom = 'myChart') 
    return(p1) 
    }) 
}) 

#ui.R 
require(rCharts) 
shinyUI(pageWithSidebar(
    headerPanel("rCharts: Interactive Charts from R using polychart.js"), 

    sidebarPanel(
    selectInput(inputId = "x", 
    label = "Choose X", 
    choices = c('SepalLength', 'SepalWidth', 'PetalLength', 'PetalWidth'), 
    selected = "SepalLength"), 
    selectInput(inputId = "y", 
     label = "Choose Y", 
     choices = c('SepalLength', 'SepalWidth', 'PetalLength', 'PetalWidth'), 
     selected = "SepalWidth") 
), 
    mainPanel(
    showOutput("myChart", "polycharts") 
) 
)) 

답변

0

그래 나는이 마지막으로 내가 응용 프로그램의 모드를 변경하지 않았기 때문에 것을 확인해 (ui.R 및 server.R)! 에서 읽을 수있는 모드로! ui.R과 server.R의 chmod 755 이후, 잘 작동했습니다.