Home of the Squeezebox™ & Transporter® network music players.
Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1
    Junior Member
    Join Date
    Apr 2020
    Posts
    3

    Running both pCP and LMS in RAM on RPI3

    Hi all,

    I have been looking for the best software to turn my RPI3 into a music streamer for my HIFI system (through an USB DAC). It will mainly be used for Spotify premium, but might also in the future be for Tidal HIFI and maybe a few local FLAC files, just to try it out. Preferably it should be spotify connect, which seems to be possible with pCP. The very interesting points for me about the pCP, is its ability to run in RAM, making it safe to cut the power without proper shutdown, as I want to cut the power from the RPI based on the trigger of my amplifyer, as I do with many other devices e.g. my DAC.

    However, I do not have an always powered on PC/NAS or anything else, which can run the LMS. I basically want the RPI to be standalone, meaning the RPI should also run the necessary LMS. This however, will as I read it, violate the nice property of no SD card writes, and thereby the setup is not power safe anymore and can corrupt the SD card if the power is pulled in an write cycle.

    So is there any way, to keep this property when the RPI is both running pCP and LMS? Maybe the LMS writes can be moved to e.g. an attached USB stick? Is it only chache or also other things which needs to moved? Have anyone tried this?

    I hope someone can help me here

    Regards
    Jesper

  2. #2
    Senior Member
    Join Date
    Apr 2005
    Location
    UK/London
    Posts
    4,771
    Yes - you can configure the location of the LMS cache and put it on a USB device.

    When I tried it years ago it did not work if the USB was FAT formatted.
    But that might have changed. In any case - you can format the USB device as Ext4 or something else.
    Paul Webster
    http://dabdig.blogspot.com
    Author of "Now Playing" plugins covering Radio France (FIP etc), PlanetRadio (Bauer - Kiss, Absolute, Scala, JazzFM etc), KCRW, ABC Australia, CBC/Radio-Canada and RTE Ireland
    and, via the extra "Radio Now Playing" plugin, AllZIC Radio, Caroline Flashback, Cesky rozhlas, Frequence3, JukeRadio, KlassikRadio.de, Linn Radio, Mother Earth, Naim Radio, Nova.fr, RadioBlues Flac, Radio Espace, Somehow Jazz, Supla Finland

  3. #3
    Junior Member
    Join Date
    Apr 2020
    Posts
    3
    Thanks Paul,

    Yea, I have read this somewhere, but is that everything needed in order to have a power safe system, such that the SD card is never corrupted? I just install LMS on the SD card as normal, but just moves the cache and that is it?

  4. #4
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    20,605

    Running both pCP and LMS in RAM on RPI3

    > So is there any way, to keep this property when the RPI is both running
    > pCP and LMS? Maybe the LMS writes can be moved to e.g. an attached USB
    > stick?


    The USB stick will suffer the same risk of getting corrupted as the SD
    card does. It won't solve that problem.

    --

    Michael

  5. #5
    Senior Member kidstypike's Avatar
    Join Date
    Feb 2007
    Location
    Brindle
    Posts
    4,791
    Quote Originally Posted by mxjelle View Post
    Thanks Paul,

    Yea, I have read this somewhere, but is that everything needed in order to have a power safe system, such that the SD card is never corrupted? I just install LMS on the SD card as normal, but just moves the cache and that is it?
    Yes, you can move LMS cache to a USB device, but then if that device gets corrupted when you pull the power? But of course you will make regular backups.
    Server - LMS 8.3.0 Pi4B 4GB/Argon one case/pCP 8.0.0 - 75K library, playlists & LMS cache on SSD (ntfs)
    Study - Pi4/pCP 8.0.0/Topping E30 DAC/Ruark MR1 Mk2
    Lounge - Pi2/pCP 8.0.0 > HiFiBerry DIGI+ > AudioEngine DAC1 > AVI DM5
    Dining Room - Pi3B/pCP/Bluetooth/Echo Show 8
    Garage - DAC32 > Edifier speakers

    Spares - 2xTouch, 1xSB Radio. 1xSB3, 6xRPi

  6. #6
    Senior Member
    Join Date
    Apr 2005
    Location
    UK/London
    Posts
    4,771
    Should mean less writes to the SD card though which might make it last longer - and less chance of it failing to boot because of corruption and potentially easier to back up the USB disk than it is to get the SD card out of a box.

    However, I still run mine entirely via SD.
    Paul Webster
    http://dabdig.blogspot.com
    Author of "Now Playing" plugins covering Radio France (FIP etc), PlanetRadio (Bauer - Kiss, Absolute, Scala, JazzFM etc), KCRW, ABC Australia, CBC/Radio-Canada and RTE Ireland
    and, via the extra "Radio Now Playing" plugin, AllZIC Radio, Caroline Flashback, Cesky rozhlas, Frequence3, JukeRadio, KlassikRadio.de, Linn Radio, Mother Earth, Naim Radio, Nova.fr, RadioBlues Flac, Radio Espace, Somehow Jazz, Supla Finland

  7. #7
    Senior Member paul-'s Avatar
    Join Date
    Jan 2013
    Posts
    4,421
    File system corruption causing a boot failure is the only significant concern. But that can be fixed with a keyboard and monitor. One of these days I'll make that automatic if corrupted.
    piCorePlayer a small player for the Raspberry Pi in RAM.
    Homepage: https://www.picoreplayer.org

    Please donate if you like the piCorePlayer

  8. #8
    Junior Member
    Join Date
    Apr 2020
    Posts
    3
    Thanks for your replies!

    I see that it does not solve the problem by moving it to an USB stick, as this can also be corrupted, it is just a write to another source which is not properly closed before shutoff. But IF I move the cache to an USB stick, will I then be sure that the SD card will not corrupt? In this case I guess it will mean, that given a corruption of the USB stick, none of the configurations and the installation itself are lost. If this happens, I should only format the USB stick and plug it back in, without restoring an old backup of it, as it is only used for cache and anything will be back to normal?

    @paul- Can you elaborate a bit further on this. This seems very interesting and if it would be possible to do that automatically, such that it has a selfrepairing feature, without configuration and so on being lost, it would be AWESOME!

  9. #9
    Senior Member kidstypike's Avatar
    Join Date
    Feb 2007
    Location
    Brindle
    Posts
    4,791
    Quote Originally Posted by mxjelle View Post
    Thanks for your replies!

    I see that it does not solve the problem by moving it to an USB stick, as this can also be corrupted, it is just a write to another source which is not properly closed before shutoff. But IF I move the cache to an USB stick, will I then be sure that the SD card will not corrupt? In this case I guess it will mean, that given a corruption of the USB stick, none of the configurations and the installation itself are lost. If this happens, I should only format the USB stick and plug it back in, without restoring an old backup of it, as it is only used for cache and anything will be back to normal?

    @paul- Can you elaborate a bit further on this. This seems very interesting and if it would be possible to do that automatically, such that it has a selfrepairing feature, without configuration and so on being lost, it would be AWESOME!
    No, all LMS player configurations, plugins, database, prefs, favourites artwork etc. are stored in the cache, if the USB device is corrupted you would need to set LMS up again. You can backup the cache on a USB device without removing it from the pi using SAMBA, which is easily configured in the pCP interface.
    Server - LMS 8.3.0 Pi4B 4GB/Argon one case/pCP 8.0.0 - 75K library, playlists & LMS cache on SSD (ntfs)
    Study - Pi4/pCP 8.0.0/Topping E30 DAC/Ruark MR1 Mk2
    Lounge - Pi2/pCP 8.0.0 > HiFiBerry DIGI+ > AudioEngine DAC1 > AVI DM5
    Dining Room - Pi3B/pCP/Bluetooth/Echo Show 8
    Garage - DAC32 > Edifier speakers

    Spares - 2xTouch, 1xSB Radio. 1xSB3, 6xRPi

  10. #10
    Senior Member kidstypike's Avatar
    Join Date
    Feb 2007
    Location
    Brindle
    Posts
    4,791
    To add to above post.

    Reformatting an SD card and setting up pCP is trivial compared to having to redo LMS player configurations, favourites, plugins, etc..
    Server - LMS 8.3.0 Pi4B 4GB/Argon one case/pCP 8.0.0 - 75K library, playlists & LMS cache on SSD (ntfs)
    Study - Pi4/pCP 8.0.0/Topping E30 DAC/Ruark MR1 Mk2
    Lounge - Pi2/pCP 8.0.0 > HiFiBerry DIGI+ > AudioEngine DAC1 > AVI DM5
    Dining Room - Pi3B/pCP/Bluetooth/Echo Show 8
    Garage - DAC32 > Edifier speakers

    Spares - 2xTouch, 1xSB Radio. 1xSB3, 6xRPi

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •