Posts: 785
Joined: Feb 2015
Reputation:
38
Rechi
Team-Kodi Member
Posts: 785
Set HOME variable to the path you want, '.kodi' will be appended.
Posts: 6
Joined: Jan 2015
Reputation:
0
Thanks,
but that is too much. I only want to have .kodi at a different location not the full HOME.
I did this before but I encountered some issues. So only put .kodi somewhere else is enough.
Regards
LPK
Posts: 785
Joined: Feb 2015
Reputation:
38
Rechi
Team-Kodi Member
Posts: 785
Only change the HOME variable for Kodi not for the whole system.
Posts: 6
Joined: Jan 2015
Reputation:
0
2018-09-19, 13:53
(This post was last modified: 2018-09-19, 17:55 by lpkurdelski.)
I forgot to mention:
Raspberry Pi 2/3
Rasbian strech
kodi 17.6 Git:20171115-d69a54a
I am not sure where HOME resides.
So USERDATA_DIR in /usr/bin/kodi ist not the right place. Should I set KODI_HOME in .profile or in /etc/default/kodi?
.profile wil not be overridden if I do an upgrade to kodi.
Regards
LPK
Posts: 785
Joined: Feb 2015
Reputation:
38
Rechi
Team-Kodi Member
Posts: 785
Why you are still asking about USERDATA_DIR and KODI_HOME, thoes are the wrong variables.
To set HOME environment variable only for Kodi, start with 'HOME=<NEW-PATH> kodi' from a terminal.
Posts: 6
Joined: Jan 2015
Reputation:
0
Well,
echo $HOME gives usually /home/<username> on unix system
if I change HOME I am in a situation I do not want.
lets have it this way:
the users home directorie resides on a network drive. So echo $HOME gives something like /mnt/<username> and /mnt/<username> is a mount point to a directory on lets say a samba drive (CIFS). .kodi on a network drive will not work because SQLite does not work with the database on a network drive. Ok, it would help if mysql would be supported, too.
So I try to let the user have her home directory on the network drive BUT change the .kodi directory to something on the local drive. But changing HOME changes the usershome as well.
I see it very common that a special name is used for just such a purpose. That's why I thought USERDATA_DIR is just made for this.
Thats why I am asking. To me it also seems that "special://" is somehow hard coded in kodi to the result of $HOME.
Regards
LPK
Posts: 7,650
Joined: Jun 2011
Reputation:
287
that USERDATA_DIR is not used is actually a bug. I'll look into it.
Posts: 316
Joined: Jul 2015
Reputation:
21
Move it wherever you want and symlink?
Posts: 6
Joined: Jan 2015
Reputation:
0
Well, thanks so far. I appreciate all the hints.
I also hope that the bug could be solved soon.
The symlink wiill work if you stay on a drive local to the computer but will fail if home is on the network drive. There are many more suggestion like keeping home on the local computer but put directories like Documents, Pictures, Musik, Viedo etc on the network. But this will have a great effort on the user becaues he/she will stay with the files in the "Personal Folder" on the computer itself. It is that he/she has to be strict in where the data are stored.
It might be strange to put the home on the network drive but it is also one way to keep the client as thin as possible, and backup rather simple, too. I am also thinking of a full virtiual solution, but it may break because of the video and audio drivers are on the virtual machine and the loudspeaker are on the local computer, not to methion some latency with video due to the virtualization. And it requires a lot of computing power in the central system.
So I found the solution having most of HOME on the NAS and some directories local may help a lot. to be honest there are other programs using SQLite and similar which need to keep there home local to the computer. But this is ok as long as the special home can be set by an environment variable. If it is never set the default will work as expected. But if set system it will work well too because at every place the home is well defined but at a different path transparent to the system.
Regards
LPK