Genieacs的搭建及使用方法

2021-02-01, updated 2021-10-31

genieacs是用于tr069 服务器

acs url: http://ip:7547/genieacs

管理界面: http://ip:3000

默认登录用户名密码: admin:amdin

环境搭建

https://github.com/genieacs/genieacs/wiki/Installation-Guide-Ubuntu-16.04

系统要求: ubuntu 16.04

脚本备份,来源于上面的链接

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
First you should update all components and install the following perquisites

sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install redis-server mongodb build-essential ruby-bundler ruby-dev libsqlite3-dev
cd ~
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
sudo apt install nodejs
sudo npm install libxmljs
Install GenieACS itself
sudo npm install -g genieacs
**And now make some files to start and stop all files in a TMUX Session, don't forget to change the "ui-jwt-secret" from "changeme" to something else **

cat << EOF > ./genieacs-start.sh
#!/bin/sh
if tmux has-session -t 'genieacs'; then
  echo "GenieACS is already running."
  echo "To stop it use: ./genieacs-stop.sh"
  echo "To attach to it use: tmux attach -t genieacs"
else
  tmux new-session -s 'genieacs' -d
  tmux send-keys 'genieacs-cwmp' 'C-m'
  tmux split-window
  tmux send-keys 'genieacs-nbi' 'C-m'
  tmux split-window
  tmux send-keys 'genieacs-fs' 'C-m'
  tmux split-window
  tmux send-keys 'genieacs-ui --ui-jwt-secret changeme' 'C-m'
  tmux select-layout tiled 2>/dev/null
  tmux rename-window 'GenieACS'

  echo "GenieACS has been started in tmux session 'geneiacs'"
  echo "To attach to session, use: tmux attach -t genieacs"
  echo "To switch between panes use Ctrl+B-ArrowKey"
  echo "To deattach, press Ctrl+B-D"
  echo "To stop GenieACS, use: ./genieacs-stop.sh"
fi
EOF

cat << EOF > ./genieacs-stop.sh
#!/bin/sh
if tmux has-session -t 'genieacs' 2>/dev/null; then
  tmux kill-session -t genieacs 2>/dev/null
  echo "GenieACS has been stopped."
else
  echo "GenieACS is not running!"
fi
EOF

chmod +x genieacs-start.sh genieacs-stop.sh
After all those steps GenieACS should be installed properly and is ready for the first start.

./genieacs-start.sh
tmux attach -t genieacs

docker搭建genieacs环境

GenieACS-Docker

genieacs auth config

选择标签页

Admin --> Config

New config新增配置

1
2
key: cwmp.auth
value: AUTH("acs-username", "acs-password")

tr111 环境搭建

安装stun-server

1
sudo apt install stun-server

执行命令开启stun server

1
stun -h ip -m 11111

保证cpe usernamepassword匹配

https://forum.genieacs.com/t/stun-or-whatever-server-with-genieacs/83/13

使用coturn时,需要在服务器配置cwmp.udpConnectionRequestPort 3478

words: 526 tags: genieacs tr069