Open alfonsojon opened 5 years ago
I'm not comfortable with Java, but a suggested solution to this would be to append the current user's name to the directory in /tmp
that way there are no permissions conflicts. For example instead of:
/tmp/lava-jni-natives/
maybe try:
/tmp/lava-jni-natives.timothy/
I would recommend bringing this issue up on the lavaplayer repository, as all the handling of natives is handled by lavaplayer.
Relevant line in lavaplayer (based on a quick search) is here
That being said, try running the bot with a flag -Djava.io.tmpdir=/custom/path/here/
, as lavaplayer looks at the system properties for where the 'tmp' directory is.
@jagrosh Thanks for pointing me to the line, I made a pull request on lavaplayer which should fix this.
Thanks @alfonsojon for documenting the issue and the pull request to lavaplayer.
Thanks @jagrosh for the alt tmp dir suggestion. Is it possible to add the "tmpdir" as a suggestion when running the bot?
/usr/bin/java -Dnogui=true -Djava.io.tmpdir=/home/$USER/JMusicBot/tmp -jar JMusicBot-0.2.2-Linux.jar
@strikerttd I implemented that flag as a workaround in my script that runs the bot. It's still not an out-of-box solution but works well enough for my needs. Thank you!
Describe the bug If you are trying to run JMusicBot on a Linux server which already has another user running JMusicBot, it will crash with an error due to being unable to make a directory in /tmp for the native libraries.
To Reproduce Steps to reproduce the behavior:
Workaround As a user with permission, or with admin privileges, empty /tmp.
Crash Dump
Version Info (please complete the following information):