plexSentry (20160511 Update)

@random.server said:
@mr3rown 7 emails? It sends out 1 to admin and another to user (if error alert), start and stop alerts can be modified from the users section

Odd thing that, every time a new user starts a stream i get 7 identical emails instead of just one.

Did you add a SQL connection string for IIS?
Yes I did… see image

@charlas said:
@mr3rown Let me know what’s missing/wrong from my guide and I’ll fix it, but all working from my end… although I’ll admit, I could have forgotten a step :slight_smile:

This part does not does not work unfortunately…

Aaah, OK, you might want to change the Integrated Security=SSPI over to User Id=myUsername;
Password=myPassword
and create a user/password or Trusted_Connection=True

All depends how SQL is setup, and if it’s SQLExpress use Server=.\SQLExpress;AttachDbFilename=C:\MyFolder\MyDataFile.mdf;Database=dbname;
Trusted_Connection=Yes;

@random.server It’s interesting to see the different things people find important when it comes to storage, whether it’s performance/reliability/ease etc, everyone seems to have their own requirements. That’s what makes all this so interesting.

@charlas said:
Aaah, OK, you might want to change the Integrated Security=SSPI over to User Id=myUsername;
Password=myPassword
and create a user/password or Trusted_Connection=True

All depends how SQL is setup, and if it’s SQLExpress use Server=.\SQLExpress;AttachDbFilename=C:\MyFolder\MyDataFile.mdf;Database=dbname;
Trusted_Connection=Yes;

Unfortunately no joy.

btw not using SQLEXPRESS, using SQL2008 R2, keep getting the database.plex.aspx issue in chrome.

@random.server
Hi, where do I edit the outgoing email text? (cant find it in the code)
Thanks.

@mr3rown said:
@random.server
Hi, where do I edit the outgoing email text? (cant find it in the code)
Thanks.

That’s not an option, once I finish a real world project, I was going to work with @“tharris@9di.com” and add it

Has anyone managed to get this work on FreeNAS/FreeBSD with some sort of configuration and wants to share how they did it?

Hi,

I have plexsentry running and it shows active sessions, but there are a couple errors where it says it can’t update the database.
Updating database with local server info
Database Update Failed
Updating shared user list from plex.tv to database
Plex update failed.

it does get the currently playing and currently connected clients.

I have a sql user that I created and made sure it has update rights.

The other issue I have is the web page loads up, but there is not any data… Just the menu on the left and the Loiin account on the upper right.

Any Suggestions?

@rsissons , did you set the database connection strings?

Yes I did

so I assume it’s getting to the database, just the updates say failed.

Here’s the connection string in the plexsentry.exe.config
value=“Data Source=localhost\SQLEXPRESS;Initial Catalog=PlexSentry;Persist Security Info=True;User ID=xxxxxx;Password=xxxxxxxx;”

Here’s the Chrome Console and none of the entries look problomatic

After looking in the database, serverData is empty, sessions has data in it that seems to be getting updated, and users only has me in it.

I downloaded express profiler to see if the PlexSentry commands were being executed with the user account against the database and they were. The UI shouldn’t have any issue connecting.

Most of the commands run fine.

When it attempts to update the serverData though, it fails.
Msg 8178, Level 16, State 1, Line 0
The parameterized query ‘(@serverID nvarchar(40),@serverToken nvarchar(4000),@userName nv’ expects the parameter ‘@serverToken’, which was not supplied.

@ServerToken is set to default which it doesn’t like.

One more thing…it seems to have a problem when looking at the console[F12]…
Uncaught SyntaxError: Unexpected token ]

**I got the token and inserted the record into the serverData table. I do not have the Unexpected Token any longer and the web page now populates with data. I fear that it’s still not getting updates from the PLEX, as you mentioned to another user.

But I don’t understand is why profiler sees the requests coming through, but the update statements are not formatted correctly and fail…but there is connectivity.
Thanks for your app and assistance.

@rsissons You didn’t populate your variables to the config file did you? The reason there was no token is because there was no name and password to verify against plex.tv. If there’s no name or password, there’s no way to create a token just for this app. That select statement you posted isn’t one of mine, it looks like the system converting the parameterized, maybe.

I do have the variables set with the login and password, and it appears to be connecting as it tells me how many connections and sessions I have and that information (user, show name etc…) does show in the UI when I manually populate the serverdata.

In the screenshot I sent of the cmd window, it tells me how many connections and sessions there are but the updates fail, which is part of your app. Doesn’t that mean it’s connecting to Plex.TV? Otherwise it wouldn’t know how many connections or sessions I had.

I am only making assumptions here as I don’t know what the app is doing behind the scenes and the instructions are not very clear. Funny thing is I am a SQL DBA and an having issues lol. You can also forget about that select query in the master dB, I pulled that from the profile window and thought it was yours.

I will check the config again in the morning to make sure I have them filled out correctly.

Thank you again for your assistance.

@random.server - thanks for the help…almost there.

I checked it, and the password was mis-typed.
I apologize for all the questions, I feel like a dumbass.

Still have 1 error on plexsentry, which is Error When Checking Sync Sessions

I don’t have posters showing up and when I pley plex from my android, it stops playback.
** I updated the external ip address for plex (after opening the firewall) and now it looks like a broken link, but when I click to open the image in a new tab it opens fine.

Console(F12) shows this GET error: net::ERR_UNKNOWN_URL_SCHEME

Also, my user record is listed twice in the database and UI.

Kill Session gives an Error

Thanks!

@rsissons your userID shows up twice because one is tied to a plex.tv id (5 or 6 digits?) and the other is tied to your server (ID 1). the plex.tv id is used to keep track of the various items (ex. sync list) they hold on their servers for when different clients request it.

@random.server

Thanks for the explanation.

After putting http:// in front of my external ip,. posters are working.

Kill Session still fails (POST http://192.168.1.120:8889/database.plex.aspx 500 (Internal Server Error))

Under the Plex Links:
All links display an XML page. Not sure what I am supposed to be seeing here.

Playing plex on my android kills the session almost immediately.

Any suggestions?

What do you all have set for Min-Video? What does that mean? Stream Quality?

Min video and min audio is for syncs, it’s a way to stop users from transcoding syncs