Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disappearing shiny server log

I am trying to run a Shiny app on Digital Ocean and it looks like I still have space on the machine:

free
              total        used        free      shared  buff/cache   available
Mem:         500096       78316       54188        5712      367592      385688
Swap:             0           0           0

This is my OS settings:

eliavs:/srv/shiny-server# uname -a
Linux ubuntu-eliavs 4.4.0-64-generic #85-Ubuntu SMP Mon Feb 20 11:50:30 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

After trying to connect to App I can see the log in the directory:

eliavs:/var/log/shiny-server# ls -la
total 12
drwxrwxrwx+ 2 shiny shiny  4096 Feb 27 08:35 .
drwxrwxrwx  8 root  syslog 4096 Feb 27 06:25 ..
-rw-r-----  1 shiny shiny   362 Feb 27 08:35 shiny-server-shiny-20170227-083550-38332.log

When i try to look at the log it seems like the file is not there:

cat shiny-server-shiny-20170227-083550-38332.log
cat: shiny-server-shiny-20170227-083550-38332.log: No such file or directory
root@ubuntu-eliavs:/var/log/shiny-server#

and then when i check again it is gone:

 ls -la
total 8
drwxrwxrwx+ 2 shiny shiny  4096 Feb 27 08:35 .
drwxrwxrwx  8 root  syslog 4096 Feb 27 06:25 ..
like image 823
eliavs Avatar asked Feb 27 '17 08:02

eliavs


People also ask

Where are the logs of Shiny server?

Server Error Log All information related to Shiny Server itself, rather than a particular Shiny application, is logged in the global system log stored in /var/log/shiny-server.

Where is shiny server conf?

Most users will want to customize the configuration to meet their needs. The server will load its configuration from a file stored at /etc/shiny-server/shiny-server. conf ; it is in this file that you should customize your Shiny Server configuration.


1 Answers

I ran into this problem yesterday after updating to shiny v1.5.3.838. I had to change the permissions on the logging directories to match the 'shiny' user. When attempting to solve some bugs in some old apps, I noticed the log files just vanish. To fix this I added the line:

    preserve_logs true; 

to the shiny-server.conf file at the top level.

This was enough for me to fix my errors and move on, so I don't know the reason why they vanish.

like image 138
Jon Bramble Avatar answered Oct 19 '22 18:10

Jon Bramble