Looking through the scripts, it seems that the mysql script also has this NOT NULL constraint however the pre-0.9.10 upgrade scripts don't, so I assume that that is why you don't have this problem on the production server? I removed the constraints from both the mysql and the postgresql scripts. Would you like me to make a pull request for this?
Kind regards, L.J. 2016-08-26 14:12 GMT+02:00 Laurens van Ruiten <[email protected]>: > Mike, > > The usage entries do not appear in the database either. I did a simple > select * and again just the shared session showed up. I am using postgresql > and I used the scripts from the repository to create the database. Dropped > the old database, so I did not run any of the database update scripts. Just > opened and closed a connection again and then opened catalina.out which > shows an exception. The exception mentions a NOT_NULL violation on > sharing_profile_name while I just opened a session the normal way and not > through a sharing link. > > You can take a look at the exception details here: > https://gist.github.com/anonymous/08915cf6ee9a35d25a0cf8d62c718d31 > > So I guess that explains what happens. When the session is not shared > session_profile_name will always be null and the session cannot be saved > to the database. When the it is however a shared session there is a > session_profile_name and the session can be saved to the database. > > I modified the 001-create-schema.sql for postgresql and removed the > NOT_NULL constraint where it creates the guacamole_connection_history > table. Dropped the database and executed that script again and the history > now works as expected. So the problem comes from the sql scripts. Not sure > if just removing the constraints doesnt have some unwanted side effect, but > it does solve the problem. > > Kind regards, > Lars van Ruiten > > > 2016-08-24 23:41 GMT+02:00 Mike Jumper <[email protected]>: > >> On Aug 24, 2016 6:30 AM, "Laurens van Ruiten" <[email protected]> >> wrote: >> > >> > Hi all, >> > >> > I have spend about 2 hours now with the new version that I build this >> > morning from the repositories and I have a few questions/remarks: >> > >> > The first thing I noticed is that usage history of a connection does not >> > seem to work like it should. >> > What I did is setup a VNC connection to do a simple test and regular >> > sessions do not seem to appear in the history of that connection. (I did >> > press disconnect and reopened a session several times) >> >> They definitely should appear. Can you confirm whether the entries appear >> in the guacamole_connection_history table? >> >> Which database are you using? >> >> > However I also tried the new screen sharing, and when I used the sharing >> > link on another PC that session did show up in the usage history. So >> > although I used that connection several times, only the shared session >> > showed up in the history. Is this new behaviour or a potential bug? >> > >> >> If this is reproducible, it is a potential bug. I've not encountered this >> on our production server, however. Need to figure out why things aren't >> working in your case. >> >> > The new screen recording feature is really nice and will defeninitely be >> > used here once it is released, I was just wondering if there was a way >> to >> > configure guacamole to manage the log files. I just recorded a few >> sessions >> > and have not tried to convert them yet, but they showed up on the server >> as >> > connectionname.1, connectionname.2 etc. Will this keep piling up and >> > eventualy use enormous amounts of disk space or is there a way to >> configure >> > guacamole to automatically delete them after say a month? >> > >> >> If you wish the recordings to be cleaned up automatically, I'd recommend >> just setting up a cron job to delete files older than a particular >> threshold. I believe the find command has options for exactly that. >> >> For the moment, automatic cleanup seems like it would be out of scope for >> guacd. >> >> Thanks, >> >> - Mike >> > >
