"You are not logged in" / 401 errors

140 views
Skip to first unread message

Sam Horowitz

unread,
Oct 25, 2018, 3:39:52 PM10/25/18
to Canvas LMS Users
New Canvas install on an admittedly underpowered Ubuntu 16.04 VM.

I am getting lots of "You are not currently logged in, possibly due to a long period of inactivity" notifications while poking around Canvas. But, I am logged in and I can (usually) continue to navigate just fine, even in areas that would require authorization. Not all views spring the errors, and some are worse than others. I restored a course from one of our Moodle modules with scores of files, and viewing the files for that course will cause scores and scores of these notification banners. 

Viewing the pages in the Developer Tools, I see lots of 401 errors with what I am interpreting as asynchronous API calls (and I can see them now in the apache logs). E.g., on a files view, I see:
Failed to load resource: the server responded with a status of 401 (Unauthorized)              /api/v1/files/82:1
Failed to load resource: the server responded with a status of 401 (Unauthorized)              /api/v1/files/254:1
and so on…

If I select a single file and delete, it usually is successful. If I select more than one, I will get Unauthorized errors as above on the POST (and the corresponding Canvas notifications). 

Running htop on the VM shows resources are pretty well used up. High CPU usage, RAM has only a few hundred megs free. 

I thought maybe this was just my test server being maxed out, and these 401s would magically go away if I spun this VM up with more resources on a beefier machine? But adding more resources to the VM did not solve the 401s. 

Are there configs I can be tweaking? I am unfamiliar with Passenger and Ruby, and I primarily use nginx on our primary web servers so I have lost a little Apache knowledge too. I don't even know where to begin poking around.


Host machine: 2012 Mac Mini (core i5 2.5 GHz), 8 GB RAM, spinning harddrive
VirtualBox 5.2.20

VM Guest: 4 cores, Ubuntu 16.04, 5 GB RAM, 150 GB Harddrive


Sam Horowitz

unread,
Oct 29, 2018, 11:18:05 AM10/29/18
to Canvas LMS Users
I seem to have cleared this issue up by increasing MaxKeepAliveRequests to 500 (I lowered the KeepAliveTimeout to 3) in /etc/apache2/apache2.conf

dark...@ufl.edu

unread,
Nov 10, 2018, 12:31:26 AM11/10/18
to Canvas LMS Users
Thanks for this - it fixed my problem!
Reply all
Reply to author
Forward
0 new messages