Internatl Server Error

Hi All,

I'm trying to use a plumber API in RStudio Cloud and I'm getting the error
{
"error": "500 - Internal server error",
"message": "Error in open.connection(con, "rb"): Could not resolve host: .........."
}

when trying to get data from a URL.

I'm surprised because the API works correctly when I'm running it in RStudio desktop app.

Do you know the reason why I'm getting this error?

I'll appreciate your assistance.

Best regards,
Victòria

One hypothesis,

Because the URL you are trying to reach is not available from the RStudio Cloud server. This happens if your URL is resolved from your company name server on the desktop, but the name server is not available on the RStudio Cloud server.

Depending on your level of comfort with server administration, you can modify dhcp client resolution with something like

sudo su
echo "prepend domain-search \"thedomainofyourcompany.extension\";" >> /etc/dhcp/dhclient.conf
echo "prepend domain-name-servers 1.1.1.1, 1.1.1.2;" >> /etc/dhcp/dhclient.conf
dhclient -r; dhclient

Where you replace the domain with the one the URL and the IPs with the one your company uses as name servers.

Thank you for your response. I appreciate that.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.