Home of the Squeezebox™ & Transporter® network music players.
Results 1 to 4 of 4
  1. #1
    Member mugen808's Avatar
    Join Date
    Jul 2016
    Location
    France
    Posts
    31

    Tuto : Install LMS and mount NAS in OSMC

    Hi !

    I have set up my SB installation, and wanted to share for those who (like me) aren’t familiar with Linux process and everything. Cause if you’re trying to do the same configuration without appropriate knowledge, I know for sure that it can be pretty bitchy !

    So what is it about ? I already have Logitech players (actually a radio, a touch and an ipad recognized as a player). I’m using a pi3 and wanted OSMC OS to use the pi as a video player, but also wanted to have a squeezebox server hosted by the raspberry.
    Also, my local music is stored in a nas, and wanted the OMSC to mount the nas folder and boot it at start up.
    Considering that OSMC OS doesn’t have a GUI, it s not that easy for noobs like me. Know that i’m done with it and it s very stable and reliable, so i’m sharing the process :

    First get OSMC image : http://download.osmc.tv/installers/d...0160621.img.gz
    or if you’re reading this post a while after i wrote it, it’s probably outdated so go there to find the last one : https://osmc.tv/download/
    Burn it on micro sd, boot, let it get installed. Once you’re done, you might want to go in the player options, to MyOSMC, Network, and set a static ip.
    Once you’re ready, open putty, login in your OSMC IP with user/ password osmc/ osmc (unless you’ve changed it ofc…)

    Now let’s get LMS installed ! Firstly we need to install perl.
    Here are the commands :

    Code:
    sudo apt-get install aptitude
    Code:
    sudo aptitude install perl
    Now, go to http://downloads.slimdevices.com/nightly/?ver=7.9 and look for the logitechmediaserver_7.9.*_all.deb
    (If my post is really old when you read it, it migh be LMS 8 or even higher. It should be exactly the same process tho) Right click on the all.deb file and copy the url.
    As for today, it makes: http://downloads.slimdevices.com/nig...729831_all.deb
    So each time you see that url in my commands, just replace it with the up-to-date one you got from slimdevices.


    So now, go for :

    Code:
    wget http://downloads.slimdevices.com/nightly/7.9/sc/5d05bcb/logitechmediaserver_7.9.0~1467729831_all.deb
    Code:
    sudo dpkg -i logitechmediaserver_7.9.0~1467729831_all.deb
    After a while (it can take some time), LMS is now installed, web page interface available in your web browser @ : your.osmc.IP :9000

    Now let’s get the nas mounted for the LMS to find your local tracks !

    First we need the cifsutils to be able to mount it.
    Here we go :

    Code:
    sudo apt-get install cifs-utils
    Now let’s make a new directory in /mnt, (but the path is up to you tho) :
    Code:
    sudo mkdir /mnt/mounted
    now let’s mount it right away ! Of course use your own NAS credentials instead of yourlogin and yourpassword and also use your nas ip and share folder corrrect path instead of 192.168.1.1/Share…

    Code:
    sudo mount –t cifs –o username=yourlogin,password=yourpassword //192.168.1.1/Share /mnt/mounted/
    Let’s check if it worked :
    Code:
    systemctl status mnt-mounted.mount

    The files should now be available in the LMS to add the path at first setup page. Just choose /mnt/mounted in LMS web page for the library location’s page to find it.

    Finally, we want the NAS to get mounted automatically after the reboot of the pi. In that purpose we have to modify the fstab config, like this :

    Code:
    sudo nano /etc/fstab
    Leave the two first lines and type a new third line containing :
    Code:
    //192.168.1.1/Share /mnt/mounted cifs username=yourlogin,password=yourpassword,_netdev,noauto,x-systemd.automount,uid=1000,gid=1000,iocharset=utf8,rw,auto,user 0 0
    Press F3, then enter and finally F2

    Check it with
    Code:
    sudo mount -a
    if it’s working it should say nothing. If there is any error it should say something.

    Everything should be working perfectly from here. If you need to restart the LMS, enter :
    Code:
    sudo service logitechmediaserver restart
    You can also replace restart by stop or start.
    Good luck !
    Last edited by mugen808; 2016-07-15 at 10:30.

  2. #2
    Senior Member DJanGo's Avatar
    Join Date
    Sep 2005
    Location
    Germany
    Posts
    2,371
    Quote Originally Posted by mugen808 View Post
    Now let’s make a new directory in /mnt, (but the path is up to you tho) :
    Code:
    sudo mkdir /mnt/mounted
    now let’s mount it right away ! Of course use your own NAS credentials instead of yourlogin and yourpassword and also use your nas ip and share folder corrrect path instead of 192.168.1.1/Share…

    Code:
    sudo mount –t cifs –o username=yourlogin,password=yourpassword //192.168.1.1/Share /mnt/mounted/
    Let’s check if it worked :
    Code:
    systemctl status mnt-mounted.mount

    The files should now be available in the LMS to add the path at first setup page. Just choose /mnt/mounted in LMS web page for the library location’s page to find it.

    Finally, we want the NAS to get mounted automatically after the reboot of the pi. In that purpose we have to modify the fstab config, like this :

    Code:
    sudo nano /etc/fstab
    Leave the two first lines and type a new third line containing :
    Code:
    //192.168.1.1/Share /mnt/mounted cifs username=yourlogin,password=yourpassword,_netdev,noauto,x-systemd.automount,uid=1000,gid=1000,iocharset=utf8,rw,auto,user 0 0
    Press F3, then enter and finally F2

    Check it with
    Code:
    sudo mount -a
    if it’s working it should say nothing. If there is any error it should say something.
    Hi there is one step missing and i believe thats the reason where your other failure (see your other Thread) started.

    You should add some group like lms and put your username, root and squeezeboxserver in it.

    Your fstab should be altered eg. uid=1000,gid=the id from your created group

  3. #3
    Senior Member DJanGo's Avatar
    Join Date
    Sep 2005
    Location
    Germany
    Posts
    2,371
    Quote Originally Posted by mugen808 View Post
    Beside that, sorry i'm really just starting with all that stuff, could you please explain me how to create a group, add me, squeezebox server and root?
    thanks a lot for your support!
    see here
    To get the gid of your created group use something like eg your group is named lms:
    Code:
    grep lms /etc/group|cut -f 3 -d ':'

  4. #4
    Senior Member DJanGo's Avatar
    Join Date
    Sep 2005
    Location
    Germany
    Posts
    2,371
    Hi,

    please add some minor lines in your howto:
    Quote Originally Posted by mugen808 View Post
    Hi !

    Quote Originally Posted by additional Info
    make some folder for your sources and change the current directory to that folder:
    Code:
    mkdir /sources
    cd /sources
    otherwise your deb file is stored anywhere
    So now, go for :

    Code:
    wget http://downloads.slimdevices.com/nightly/7.9/sc/5d05bcb/logitechmediaserver_7.9.0~1467729831_all.deb
    Code:
    sudo dpkg -i logitechmediaserver_7.9.0~1467729831_all.deb
    After a while (it can take some time), LMS is now installed, web page interface available in your web browser @ : your.osmc.IP :9000

    Now let’s get the nas mounted for the LMS to find your local tracks !

    First we need the cifsutils to be able to mount it.
    Here we go :

    Code:
    sudo apt-get install cifs-utils
    Now let’s make a new directory in /mnt, (but the path is up to you tho) :
    Code:
    sudo mkdir /mnt/mounted
    now let’s mount it right away ! Of course use your own NAS credentials instead of yourlogin and yourpassword and also use your nas ip and share folder corrrect path instead of 192.168.1.1/Share…

    Code:
    sudo mount –t cifs –o username=yourlogin,password=yourpassword //192.168.1.1/Share /mnt/mounted/
    Let’s check if it worked :
    Code:
    systemctl status mnt-mounted.mount

    The files should now be available in the LMS to add the path at first setup page. Just choose /mnt/mounted in LMS web page for the library location’s page to find it.

    Finally, we want the NAS to get mounted automatically after the reboot of the pi. In that purpose we have to modify the fstab config, like this :

    Code:
    sudo nano /etc/fstab
    Leave the two first lines and type a new third line containing :
    Code:
    //192.168.1.1/Share /mnt/mounted cifs username=yourlogin,password=yourpassword,_netdev,noauto,x-systemd.automount,uid=1000,gid=1000,iocharset=utf8,rw,auto,user 0 0
    Press F3, then enter and finally F2

    Check it with
    Code:
    sudo mount -a
    if it’s working it should say nothing. If there is any error it should say something.

    Quote Originally Posted by additional Info
    check for the file permissions:
    echo demo>/mnt/mounted/test.txt
    grep demo /mnt/mounted/test.txt
    rm /mnt/mounted/test.txt
    The first command checks for write permissions
    The second for read permissions
    The last one is to check the remove permissions and remove the now unneeded testfile
    Everything should be working perfectly from here. If you need to restart the LMS, enter :
    Code:
    sudo service logitechmediaserver restart
    You can also replace restart by stop or start.
    Good luck !

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
  •