Trying to install Unifi Controller

Comments

16 comments

  • Avatar
    Michael Bierman

    The install didn’t work for me either.

    Since we are still alpha I installed the unifi controller on my Synology NAS instead for now, but I would like to run it on firewalla in the future. I felt the tutorial could be more helpful in a few areas. I may write something up now that I have experience setting it up on Synology sucessfully.

     

    0
    Comment actions Permalink
  • Avatar
    Blake

    Well I got past the first roadblock in that you have to run the compose file. Seems obvious once I realized this tutorial assumes you know what you’re doing. However now I’m stuck in that I don’t know what the file in step 3 should be named or where to put it.

    1
    Comment actions Permalink
  • Avatar
    Michael Bierman

    That caught me up too. Also, why isn’t installed in the same place top level directory as say, homebridge? I’d rather have all my dockers in one place. It seems more organized. 

    0
    Comment actions Permalink
  • Avatar
    Blake

    I got it figured out!  Step 3 isn't telling you to make a file, but to run those commands.  I now have a Controller docker image running on my Gold!  Yippee!

    I posted more detais on what I did to get it all to work that the guide didn't include on the guide's article.

    0
    Comment actions Permalink
  • Avatar
    Firewalla

    Thank you Blake, I have added the docker-compose in the doc 

    0
    Comment actions Permalink
  • Avatar
    Håvard Steinsbekk

    Hi, following the instructions I got the docker image with Controller image running, and the first time I tried I could connect to the controller and started the set up process of the controller.

    But the next time I tried to connect, I only get a "ERR_CONNECTION_TIMED_OUT" when trying to access the Unfi Controller. 

    I us my FW Gold IP address:8443 to access controller and no luck (same as first time when it worked). After some googling I tried installing another container containing a static web page, and get the same result (time out). Using Curl after SSH-ing into to FW Gold I get a respons from the static web page. 

    So there seems to be something with going from my computer via the FW Gold IP address and reaching the container with the controller. As far as I can se the container is running as it should 

    Output from container ps -a:

    CONTAINER ID        IMAGE                       COMMAND                  CREATED             STATUS                   PORTS                                                                                                                            NAMES

    df65ce049028        jacobalberty/unifi:stable   "/usr/local/bin/dock…"   8 minutes ago       Up 8 minutes (healthy)   0.0.0.0:8080->8080/tcp, 6789/tcp, 8843/tcp, 0.0.0.0:3478->3478/udp, 0.0.0.0:10001->10001/udp, 8880/tcp, 0.0.0.0:8443->8443/tcp   unifi

    This is my first try to set up a Docker container, so I may have missed something obvious, but if any one have a suggestion on how to resolve this I would be grateful. 

     

    0
    Comment actions Permalink
  • Avatar
    Michael Bierman

    Try FW Gold IP address:8080. If I recall it seems to prefer to redirect you to the https page. At least mine does. Also, make sure you use the right IP address for FW LAN. Firewalla’s About reports one of your WAN addresses which I find confusing. You need one that might look like 192.168.0.1.

    0
    Comment actions Permalink
  • Avatar
    Håvard Steinsbekk

    Thanks, I tried 192.168.119.1:8080, and got same response (ie timeout): And I tried the WAN address first when I first started trying, but figured it out in the end ;-)

    After my post I have tried deleting the image, and restarting but same result. 

    But I finally figured it out. I ran the two commands 

    sudo ip route add 172.16.1.0/24 dev br-$(sudo docker network ls | awk '$2 == "unifi_default" {print $1}') table lan_routable
    sudo ip route add 172.16.1.0/24 dev br-$(sudo docker network ls | awk '$2 == "unifi_default" {print $1}') table wan_routable

    from the guide, and that fixed the problem. 

    But that adds another question. I thought adding the file start_unifi.sh described at the and of the guide should handle persistence for this setup, including the routing done by the commands above. 

    I thought the commands

    sudo ipset create -! docker_lan_routable_net_set hash:net
    sudo ipset add -! docker_lan_routable_net_set 172.16.1.0/24
    sudo ipset create -! docker_wan_routable_net_set hash:net
    sudo ipset add -! docker_wan_routable_net_set 172.16.1.0/24

    duplicated the "ip rout add" commands (but like I said this is my first attempt on this stuff). 

    Any ideas why this does not work, or am I missing something?

    0
    Comment actions Permalink
  • Avatar
    Blake

    I think the first two commands are to change how the routing works since the contorller is in a container. The last few commands are to make sure your settings persist after a power recycle. However the last two commands will only work in version 1.971 which hasn’t been released yet.

    0
    Comment actions Permalink
  • Avatar
    Håvard Steinsbekk

    Ah, that explains the problem. I just assumed that as the guide referred to 1.971 that it was the latest released version. But I see om my FW that I have version 1.97.

    Anyway, thanks for the response to my questions. I will have to research ip rout and ipset  bit more I guess in preparation for version 1.971. ;-)

     

    0
    Comment actions Permalink
  • Avatar
    Angel Alvarez

    Hoping someone can help. I am able to get the service running but can't reach the controller web ui. Running V1.971 on Firewalla Gold

    Trying to run step 2:

    sudo ip route add 172.16.1.0/24 dev br-$(sudo docker network ls | awk '$2 == "unifi_default" {print $1}') table lan_routable
    sudo ip route add 172.16.1.0/24 dev br-$(sudo docker network ls | awk '$2 == "unifi_default" {print $1}') table wan_routable

    I get an error cannot find device "br-"

    I run: sudo docker network ls and "unifi_default" is not listed.

    Any ideas?

    0
    Comment actions Permalink
  • Avatar
    Michael Bierman

    What do you get with 

    sudo docker ps
    0
    Comment actions Permalink
  • Avatar
    Angel Alvarez

    It's blank even though the service appears to be running. I run sudo systemctl status docker-compose@unifi.service and it is running. Definitely out of my depth with Dockers so if I had to do more than the guide outlines that wouldn't surprise me.

    0
    Comment actions Permalink
  • Avatar
    Michael Bierman

    I think if

    sudo docker ps 

    isn't showing anything the container isn't running. 

    sudo systemctl start docker-compose@unifi

     

    Will start the container if all is well. But the container can be misconfigured and will not start or keep restarting.

    Try this:

    # Start docker

    sudo systemctl start docker
    

    # tell docker to start on boot

    sudo systemctl enable docker
    

    # bring up the unfi docker container (Must be in the directory with the compose.yml I believe)

    sudo docker-compose up -d
    0
    Comment actions Permalink
  • Avatar
    Angel Alvarez

    When I get to sudo docker-compose up -d I get the error "Pool overlaps with other one on this address space" so it sounds like it exists but doesn't?

    sudo docker ps shows nothing even after running all commands and the errors

    sudo systemctl status docker-compose@unifi shows the unifi service running

    0
    Comment actions Permalink
  • Avatar
    Michael Bierman

    The address space is the IP set up. I believe the container can't start because things aren't configured correctly yet. I'm not expert enough to guide you on that part and I don't want to steer you wrong. 

     

    0
    Comment actions Permalink

Please sign in to leave a comment.