Home of the Squeezebox™ & Transporter® network music players.
Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1

    Can I copy server.prefs from one machine to another? (No connection with firewall)

    I have two Raspberries with Raspbian on them and copied the
    Code:
    /var/lib/squeezeboxserver/prefs/server.prefs
    from one machine to the other.

    I have uncomplicated firewall activated. It is on both like this:

    Code:
     $ sudo ufw status
    Status: active
    
    To                         Action      From
    --                         ------      ----
    22/tcp                     LIMIT       Anywhere                  
    22                         ALLOW       192.168.100.0/24          
    90                         ALLOW       192.168.100.0/24          
    31337                      ALLOW       192.168.100.0/24          
    3438                       ALLOW       192.168.100.0/24          
    9000                       ALLOW       192.168.100.0/24          
    9090                       ALLOW       192.168.100.0/24          
    445                        ALLOW       192.168.100.0/24          
    8200                       ALLOW       192.168.100.0/24          
    1900                       ALLOW       192.168.100.0/24          
    22/tcp (v6)                LIMIT       Anywhere (v6)
    A few days ago I changed my hostname. Yesterday I rebooted both machines. They also run bitcoin, minidlna and cifs and it all works. Both hostnames look like this (RPi2 for the other machine).

    Code:
     $ cat /etc/hosts
    127.0.0.1	localhost
    ::1		localhost ip6-localhost ip6-loopback
    ff02::1		ip6-allnodes
    ff02::2		ip6-allrouters
    
    127.0.1.1	RPi3
    ~ - 08:22:33 - pi - RPi3@192.168.100.169 Tue Sep 10 
     $ cat /etc/hostname
    RPi3
    My squeezeboxes can access the old server but they can not access the new server unless I deactivate the firewall. I don't understand this behaviour. First, I thought it might be related to the firewall setting up its rules with hostnames. I was under the impression that deleting the rule and setting it up newly was helping. But today I again have the same problem. My squeezebox does not connect.

    I can connect via the GUI, but it then of course shows no entry for the boxes.

  2. #2
    The player that is not recognised is

    Code:
    Logitech Media Server Version: 7.9.2 - 1564788734 
    Perl-Version: 5.28.1 - arm-linux-gnueabihf-thread-multi-64int
    IO::Socket::SSL: 2.060
    the one that works is

    Code:
    Logitech Media Server Version: 7.9.2 - 1551709029 
    Perl-Version: 5.24.1 - arm-linux-gnueabihf-thread-multi-64int
    IO::Socket::SSL: 2.044
    But it did work during the last days!

    The squeezebox does just show the old server under "sources". As soon as I switch off the firewall with
    Code:
    sudo ufw disable
    the new server is availlable on the menu in the box.
    Last edited by bvrulez; 2019-09-10 at 00:46.

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

    Can I copy server.prefs from onemachine to another? (No connection with firewall)

    > My squeezeboxes can access the old server but *they can not access the
    > new server unless I deactivate the firewall. * I don't understand this
    > behaviour.


    In the server.prefs there's a server_uuid or similar value. You'll have
    to delete this when copying the file to another machine, or devices can
    get confused.

    --

    Michael

  4. #4
    THANKS! There are two entries:
    Code:
    server_uuid: 44e88511-a31f-49e9-b842-68f4f61e47da
    and
    Code:
    _ts_server_uuid: 1506710398
    .

    Do I delete both?

  5. #5
    And most importantly: Why does the connection work when I disable the firewall? How is this related?

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

    Can I copy server.prefs from onemachine to another? (No connection with firewall)

    > And most importantly: Why does the connection work when I disable the
    > firewall? How is this related?


    No idea.

    The _ts_... value is a timestamp. Not as important as the real value.
    Delete the full line (while LMS is down).

    --

    Michael

  7. #7
    I deleted both values in the file. The file was updated with new values (different ones).

    It is still not connecting to my squeezeboxes with firewall turned on. With firewall turned off it does (as it did before).

  8. #8
    I now also deleted the whole lines after stopping LMS. I started it and no connection. The values where updated and are different now.

    I can connect with disabled firewall instantly after disabling it.

  9. #9
    Following a hint from someone I allowed all ports from a certain client's IP address in the firewall. Now there is no problem. So it seems that the connection is established using a different port than the one I know: 3438. Or maybe there is something wrong with my firewall (and that port, since 9000 works fine).

    EDIT: I reinstalled my firewall (purged it). This did NOT help.

    EDIT: Is it possible to change 3438 in the server.prefs file? Maybe I did it by accident.
    Last edited by bvrulez; 2019-09-10 at 02:21.

  10. #10
    Member
    Join Date
    Sep 2017
    Location
    ┼kersberga, Sweden
    Posts
    85
    Quote Originally Posted by bvrulez View Post
    Following a hint from someone I allowed all ports from a certain client's IP address in the firewall. Now there is no problem. So it seems that the connection is established using a different port than the one I know: 3438. Or maybe there is something wrong with my firewall (and that port, since 9000 works fine).

    EDIT: I reinstalled my firewall (purged it). This did NOT help.

    EDIT: Is it possible to change 3438 in the server.prefs file? Maybe I did it by accident.
    I think the default port that is used in server discovery by the clients is 3483 (not 3438). Besides I don't think that this is a parameter in the server.prefs file, it should hard-coded in both the server and client software.
    A suggestion is for you to open the firewall to incoming udp/tcp 3483 from your LAN. I guess you already have port 9000 open? You should also check the setting for the CLI command (Settings -> Advanced -> Commandline) and open that port as well (by default it is 9090).
    2 Touch, 2 Picoreplayer 5.0.0 on RaspBerry 3B, 1 RasbBerry Zero running Raspian and Squeezelite 1.8
    LMS latest nightly on Ubuntu 18.04.3 on Intel Core2 Duo E4500 @ 2.20GHz, 2GB
    All wired

Posting Permissions

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