Page 1 of 2

Multiple profile mySQL Database connection fails

Posted: 01 Oct 2016, 14:47
by logan_x50
I have just set up external mySQL (mySQL is hosted on my NAS)

I have 2 Profiles; 1 for the kids movies and tv and 1 for the parents movies and tv. in order to seperate the content for each profile i chose different name for the video and music database. so profile 1 the video database name is DadVideo and profile 2 the video database name is MyVideo. same logic for music database names

If i switch between profiles mrmc will fail to connect to the database and not show the movies or tv for the profile i switched to

this can be rectified by going to settings>services>mySQL client and toggle the "enable" radio button off/on

However, not very kid friendly so will have to go back to a local database which is a pity. can this be fixed in a future MrMC version please?

Re: Multiple profile mySQL Database connection fails

Posted: 04 Oct 2016, 09:20
by logan_x50
I thought that swapping to a local database for one of the profiles would fix it but it doesn't.

Guess mrmc needs some logic to check the database location and make a new connection on each login

Re: Multiple profile mySQL Database connection fails

Posted: 05 Oct 2016, 15:04
by amet
I am looking into it, thanks for bringing it up.

Re: Multiple profile mySQL Database connection fails

Posted: 05 Oct 2016, 15:15
by amet
hm, I fail to reproduce this ...

my daughter has a separate Mysql database, called ana_v/ana_m ... I have a default one for our stuff... when I added her mysql database to her profile it all loads nicely.. just her tvshows and movies , switch back to master and I get our stuff.

are you sure you created profile correctly? I chose "Start Fresh" when creating new profile for both offered choices.

Re: Multiple profile mySQL Database connection fails

Posted: 06 Oct 2016, 08:29
by logan_x50
Hi Amet,

thanks for looking into it. pretty sure. one variation from your description is i'm using the default mysql myVideo for the non-master profile (for no good reason). I'll try and flatten the entire environment and start from scratch with master profile using default and the kids with their own mysql naming...be back in about two weeks:(

Re: Multiple profile mySQL Database connection fails

Posted: 06 Oct 2016, 11:32
by amet
hey logan_x50,

Database naming is not important at all(looking at the code), its important to start the new profile "from scratch" .. it will ask you if you want to copy from existing or start clean, choose start clean and setup that user with its own database name.

database credential are saved within new user profile and that gets loaded on switch, hence you should only see whats in the users database.

if you are not getting these results, please note down exact steps to reproduce it and I'll try to do the same on my side.

thanks, ttys
amet

Re: Multiple profile mySQL Database connection fails

Posted: 06 Oct 2016, 13:05
by logan_x50
thanks again. I just started with 1 fire tv and noted the steps

uninstalled mrmc and reinstalled
Step:
1. master user profile - enabled mysql leaving the default MyVideos database name. mrmc creates the database on my nas. aok
2. created the sources to videos and tv and scanned. so far so good

3. now create a new profile (kids). i leave every option as default. so i don't touch where the profile is created, sources as "separate" and as you said "start fresh" is default so i also (and have always) use that option. so literally just hit the fire tv ok button a few times to create a new profile, i'm not selecting anything other than the default options
4.log-off master user and log on to the newly created profile
5. run through the process of setting up mysql but this time change the database names to "kidsVideos" and "kidsMusic". created on my nas aok.
6. create the media sources, scan. aok. library updated.

now i log-off kids profile and back into master profile and :( no go
in order to bring the master profile movies and tv library back i need to toggle the mysql services off/on

same if i then switch back kids profile

i can't imagine what i'm doing that's different to how you have it working amet???

from your description the anomaly is the "get's loaded on switch". that doesn't seem to happen for me. one thing that is a little strange is if i look at the "Videos" menu when the library menus of Movies and TV Shows aren't loaded then i do see the sources that i created listed. does that mean that the database is loaded and there's something with the "library" loading?

can i post an image or movie to make this any clearer for you?

Re: Multiple profile mySQL Database connection fails

Posted: 06 Oct 2016, 13:22
by amet
Thats exactly how I am setting it up, only difference is I do it on tvOS and my OSX test environment.

I'll test later on ftv and see if I can reproduce there.

One thing to note is that if you are looking at recently added (on home screen) as indicator for library loaded, it could take few seconds for that content to refresh.

If you specifically enter movies/tvshow folder, you still don't see the correct content?

Re: Multiple profile mySQL Database connection fails

Posted: 06 Oct 2016, 15:37
by logan_x50
hi amet, that's why i thought a photo might help....in fact the "Movies" and "Tv Shows" menu doesn't show up on the home page at all. So that's why its obvious that its not working. as soon as i toggle the mySQL Client off/on and back out to the home screen the Movies and Tv Show menu's will appear with the recently added thumbnails populating shortly afterwards

Re: Multiple profile mySQL Database connection fails

Posted: 06 Oct 2016, 16:17
by amet
Maybe a debuglog ? Start one, switch to the other and let us see the log.

Checked again, all okay here on tvOS... I am lost :(