kagemomiji / airsonic-advanced

airsonic-advanced
GNU General Public License v3.0
152 stars 14 forks source link

[Bug]: Failed to auto-import playlist /data/mstream_data/_MusicPlaylists/XXXX.m3u #215

Open litebito opened 1 year ago

litebito commented 1 year ago

What happened?

When I noticed that my playlists were not updating with newly added tracks, I checked the logs, and (probably already for some time) I see messages Failed to auto-import playlist for every playlist now.

I upgraded to the latest Airsonic version, and it is still the same.

I had this issue in the past, then it disappeared for a while, then it came back ....

Steps to reproduce

  1. Export the playlists from my main mediacenter (Jriver) to disk on my NAS (Qnap)
  2. Sync the playlists from my NAS to a dedicated directory on my streaming server (Centos 7 server with Airsonic)
  3. See in the airsonic log the "failed to auto-import" message.
  4. Remove some playlists from Airsonic, remove them from that directory in Centos
  5. Resync from NAS to the Centos server
  6. Still the same error

Version

11.1.x (Edge)

Version Detail

11.1.3-SNAPSHOT.20230430161124

Operating System

CentOS 7

Java Version

openjdk 18.0.2 2022-07-19

Database

Other

DB Detail

builtin

Configuration paramter

======================================= airsonic.properties

# Airsonic preferences.  NOTE: This file is automatically generated. Do not modify while application is running

EncryptionKeyPassword=xxx
EncryptionKeySalt=xxx
SettingsChanged=1669213623913
JWTKey=gacpcbrrjqn9qrgnnfbssp1ur8
PodcastUpdateInterval=-1
PodcastEpisodeRetentionCount=10
PodcastEpisodeDownloadCount=1
PodcastFolder=/var/airsonic/podcast
GettingStartedEnabled=false
IndexCreationInterval=1
IndexCreationHour=4
FastCacheEnabled=false
OrganizeByFolderStructure=true
ExcludePattern=
IgnoreSymLinks=false
FullScan=true
ClearFullScanSettingAfterScan=false
IndexString=A B C D E F G H I J K L M N O P Q R S T U V W X-Z(XYZ)
IgnoredArticles=The El La Los Las Le Les
GenreSeparators=;
Shortcuts=New Incoming Podcast
PlaylistFolder=/data/mstream_data/_MusicPlaylists
MusicFileTypes=mp3 ogg oga aac m4a m4b flac wav wma aif aiff ape mpc shn mka opus alm 669 mdl far xm mod fnk imf it liq wow mtm ptm rtm stm s3m ult dmf dbm med okt emod sfx m15 mtn amf gdm stx gmc psm j2b umx amd rad hsc flx gtk mgt mtp
VideoFileTypes=flv avi mpg mpeg mp4 m4v mkv mov wmv ogv divx m2ts webm
CoverArtFileTypes2=cover.jpg cover.png cover.gif folder.jpg jpg jpeg gif png
CoverArtSource=TAGFILE
CoverArtConcurrency=10
CoverArtQuality=100
SortAlbumsByYear=true
WelcomeTitle= 
WelcomeSubtitle= 
WelcomeMessage2= 
LoginMessage= 
Theme=default
LocaleLanguage=en
LocaleCountry=
LocaleVariant=
spring.liquibase.parameters.defaultPodcastFolder=/var/airsonic/podcast
UploadsFolder=%{['USER_MUSIC_FOLDERS'][0]}/Incoming
server.servlet.session.timeout=14d
spring.liquibase.parameters.mysqlVarcharLimit=384
DbBackupUpdateInterval=168
DbBackupRetentionCount=10

=======================

etc/systemd/system/airsonic.service

etc/systemd/system/airsonic.service
[Unit]
Description=Airsonic Media Server
After=remote-fs.target network.target
AssertPathExists=/var/airsonic

[Service]
Type=simple
Environment="JAVA_JAR=/var/airsonic/airsonic.war"
Environment="JAVA_OPTS=-Xmx700m"
Environment="AIRSONIC_HOME=/var/airsonic"
Environment="PORT=8080"
Environment="CONTEXT_PATH=/airsonic"
Environment="JAVA_ARGS="
EnvironmentFile=-/etc/sysconfig/airsonic
ExecStart=/usr/bin/java \
          $JAVA_OPTS \
          -Dairsonic.home=${AIRSONIC_HOME} \
          -Dserver.servlet.contextPath=${CONTEXT_PATH} \
          -Dserver.port=${PORT} \
          -Dfile.encoding=UTF-8 \
          -Dsun.jnu.encoding=UTF-8 \
          -jar ${JAVA_JAR} $JAVA_ARGS
User=airsonic
Group=airsonic

# See https://www.freedesktop.org/software/systemd/man/systemd.exec.html
# for details
DevicePolicy=closed
DeviceAllow=char-alsa rw
NoNewPrivileges=yes
PrivateTmp=yes
PrivateUsers=yes
ProtectControlGroups=yes
ProtectKernelModules=yes
ProtectKernelTunables=yes
RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6
RestrictNamespaces=yes
RestrictRealtime=yes
SystemCallFilter=~@clock @debug @module @mount @obsolete @privileged @reboot @setuid @swap
ReadWritePaths=/var/airsonic

# You can uncomment the following line if you're not using the jukebox
# This will prevent airsonic from accessing any real (physical) devices
#PrivateDevices=yes

# You can change the following line to `strict` instead of `full`
# if you don't want airsonic to be able to
# write anything on your filesystem outside of AIRSONIC_HOME.
ProtectSystem=full

# You can uncomment the following line if you don't have any media
# in /home/…. This will prevent airsonic from ever reading/writing anything there.
ProtectHome=true

# You can uncomment the following line if you're not using the OpenJDK.
# This will prevent processes from having a memory zone that is both writeable
# and executeable, making hacker's lifes a bit harder.
#MemoryDenyWriteExecute=yes

[Install]
WantedBy=multi-user.target

=============================== /etc/sysconfig/airsonic

# Set the location of the standalone war to use
JAVA_JAR=/var/airsonic/airsonic.war

# Set any java opts separated by spaces
JAVA_OPTS=-Xmx2048m -Xms2048m

# Set a different location for airsonic home.
# If this path is /var/libresonic or even contains "libresonic",
# the data from a previous libresonic can be used as is (i.e. without
# renaming libresonic.properties,db/libresonic*,etc
AIRSONIC_HOME=/var/airsonic

# Change the port to listen on
PORT=14040

# Change the path that is listened on
CONTEXT_PATH=/

# Add any java args. These are different than JAVA_OPTS in that
# they are passed directly to the program. The default is empty:
#JAVA_ARGS=

# Note that there are several settings for spring boot, not explicitly listed
# here, but can be used in either JAVA_OPTS or JAVA_ARGS. The full list
# can be found here:
# https://docs.spring.io/spring-boot/docs/1.4.5.RELEASE/reference/htmlsingle/#common-application-properties
# For example to set debug across the board:
#JAVA_ARGS=--debug

# Or to change the ip address that is listened on:
#JAVA_ARGS=--server.address=127.0.0.1

JAVA_ARGS=--logging.level.org.airsonic=info

And in reality, running as : (ps -ef)

/usr/bin/java -Xmx2048m -Xms2048m -Dairsonic.home=/var/airsonic -Dserver.servlet.contextPath=/ -Dserver.port=14040 -Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8 -jar /var/airsonic/airsonic.war --logging.level.org.airsonic=info

Proxy Server

none

client detail

not applicable

language

English

Relevant log output

2023-05-01 12:24:27.292  WARN --- o.a.p.service.PlaylistService            : Failed to auto-import playlist /data/mstream_data/_MusicPlaylists/Fotoshoot.m3u

java.lang.Exception: Unsupported playlist Fotoshoot.m3u
        at org.airsonic.player.service.PlaylistService.importPlaylist(PlaylistService.java:342) ~[classes!/:11.1.3-SNAPSHOT]
        at org.airsonic.player.service.PlaylistService.importPlaylistIfUpdated(PlaylistService.java:385) ~[classes!/:11.1.3-SNAPSHOT]
        at org.airsonic.player.service.PlaylistService.importPlaylist(PlaylistService.java:330) ~[classes!/:11.1.3-SNAPSHOT]
        at org.airsonic.player.service.PlaylistService.lambda$0(PlaylistService.java:118) ~[classes!/:11.1.3-SNAPSHOT]
        at org.airsonic.player.service.PathWatcherService.lambda$2(PathWatcherService.java:56) ~[classes!/:11.1.3-SNAPSHOT]
        at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[na:na]
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[na:na]
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[na:na]
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[na:na]
        at java.base/java.lang.Thread.run(Thread.java:833) ~[na:na]
kagemomiji commented 1 year ago

@litebito May I ask for the m3u file that is causing the issue? It is okay to delete any sensitive information.

litebito commented 1 year ago

This is an example. Fotoshoot.m3u.txt

litebito commented 1 year ago

It's strange behavior... after a few reboots of the server, they start to import again... then after a while, the error comes back