voiceboys / sbcos Goto Github PK
View Code? Open in Web Editor NEWBarebone Opensource Powered SBC
License: GNU General Public License v3.0
Barebone Opensource Powered SBC
License: GNU General Public License v3.0
bootinst.bat requires runadmin.vbs and samedisk.vbs
but these are not present in the repository.
Errors:
---------------------------
Windows Script Host
---------------------------
Can not find script file "E:\sbc\boot\samedisk.vbs".
---------------------------
OK
---------------------------
===============================================================================
Setting your drive to boot
===============================================================================
Administrator Rights are required
Invoking UAC for Privilege Escalation
'runadmin.vbs' is not recognized as an internal or external command,
operable program or batch file.
hi theare. from where i can take iso image ?
Hi Alex,
i tried ubuntu/bionic64 as vagrant box to build an ISO File. First script on how-to relies on /etc/apt/trusted.gpg and breaks.
Are you sure that its works on Ubuntu?
root@sbcbuilder:/vagrant/provisioning/sbcOS/SbcOS# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.2 LTS
Release: 18.04
Codename: bionic
apt-get update
apt-get install reprepro
apt-get install multistrap
root@sbcbuilder:/vagrant/provisioning/sbcOS/SbcOS# bash build_rootfs.sh
build_rootfs.sh: line 10: mkpasswd: command not found
-= build stripped base rootfs for future squashfs
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/img"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/tmp"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/log"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/deb/import"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/rfs/squashfs"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/rfs/bootstrap"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/rfs/rootfs"
| create directory "/vagrant/provisioning/sbcOS/SbcOS/build/rfs/src"
use parameter [-debian] for update builder
-= build sbc-repository repository
cp: cannot stat '/etc/apt/trusted.gpg': No such file or directory
157 build_rootfs.sh
! error. exiting now.
ERROR: tls [tls_util.h:42]: tls_err_ret(): TLS accept:error:24064064:random number generator:RAND_bytes:PRNG not seeded
ERROR: tls [tls_util.h:42]: tls_err_ret(): TLS accept:error:140B512D:SSL routines:ssl_get_new_session:ssl session id callback failed
ERROR: [core/tcp_read.c:1505]: tcp_read_req(): ERROR: tcp_read_req: error reading - c: 0x7fcafd73d638 r: 0x7fcafd73d6b8 (-1)
Hi, we would like to use the sbcos, but when the softphone register to it, we get the error as below:
SIP/2.0 500 Service not available
Via: SIP/2.0/UDP 192.168.1.47:8440;branch=z9hG4bK-524287-1---a5d586273e2c625d;rport=8440;received=192.168.1.47
To: <sip:[email protected]>;tag=221e192f9bab43739afcb90db051aeca.7d7b
From: <sip:[email protected]>;tag=8175241c
Call-ID: LPY1kworjeeqqF8T4G0X-w..
CSeq: 1 REGISTER
P-SBC-Error: B-Trunk access
Server: SBC-OS
Content-Length: 0
Does there have any guides we can learn?
Thanks
Hi
We have a use-case where we would want to handle REFER messages, and send the INVITE request to the new destination (this needs to be done in the sbc because if the REFER is forwarded to carrier it becomes invalid, this REFER is valid in the context of the SBC only). How to achieve the same in SBC-OS ? (I couldn't find any documentation of kamailio routing by which this can be done. Any help is appreciated. )
Personally I would love to nuke the binary .deb files (maybe the Arch port will fix this) and just have the build system download them as needed. I figured the best method would be to have the config file list the versions requested.
For Kamailio/Telegraf/RTPengine itself, that's super easy.
For the RTPengine kernel module though, that's trickier since it has to build against a kernel. We obviously don't want to have to copy the kernel headers into the root image, so the only things I can think of currently are:
Any other ideas?
[
sbc ada.pdf
](url)
Question:
I have an internal, central siprouter. That siprouter sends to the (in the example config) 10.1.1.4 the calls.
How can i select a other Upstream Trunk? It seems to me that is always an "pair" of Source-Target in the tables.
@Micro-Mike described the Trunking Szenario in Issue #9
For trunking mode:
In database file address the external (untrusted) and internal (trusted) IPs of the SBC are configured. Beside the external and internal IP the Mapping (ID 2001 and 1001) include the destination IPs of the Trunk. Trusted ID 2001 includes the destination SER, Asterisk, etc. in your core-network. Untrusted ID 1001 includes the external IP of your partner SBC, partner SER, etc.
Trusted: 1:1:10.1.1.4:32:0:NULL:Trusted, Core IP 2001:2001:trunk-[10.1.1.4]-[172.168.5.152].sbc:32:0:NULL:Internal-Trunk-Trusted Untrusted: 101:101:192.168.1.4:32:0:NULL:Untrusted, Access IP 1001:1001:trunk-[192.168.1.4]-[193.22.119.66].sbc:32:0:NULL:External-Trunking-Untrusted
In dispatcher file the internal (trusted) connection ID (2001) is used to specify the destination SER, Asterisk, etc. in your core-network. The external (untrusted) connection ID (1001) is used to specify the destination IP of your partner SBC, partner SER, etc:
Untrusted: 1001 sip:193.22.119.66:5060 0 0 access=10.1.1.4:5060;socket=udp:10.1.1.4:5060;weight=100 Trusted: 2001 sip:172.168.5.152:5060 0 0 access=192.168.1.4:5060;socket=udp:192.168.1.4:5060;weight=100
In rtpengine.conf you can specify the internal and external IP the RTPEngine is using for RTP relay. This will also be linked with the IDs used in address table (trusted 1 & untrusted 101):
interface=1/10.1.1.4;101/192.168.1.4
Originally posted by @Micro-Mike in #9 (comment)
I tried the REGISTERED MODE in my lab and i saw this behavoir. My Softphone dont set the FROM User - its only sip:172.20.100.166.
I know i can add an own if statement but then the config differs from "vanilla".
$fU - From URI username - if $fU is empty then it should not filed up From: sip:@mysbc.host.com;tag=788860019 seems broken to me.
----------------------------
SBC-OS 172.20.160.167 TRUSTED
SBC-OS 172.20.160.168 UNTRUSTED
INVITE sip:[email protected]:5060 SIP/2.0
Max-Forwards: 20
Via: SIP/2.0/UDP 172.20.100.166:5060;rport;branch=z9hG4bK1885587274
From: <sip:172.20.100.166>;tag=788860019
To: <sip:[email protected]:5060>
Call-ID: [email protected]
CSeq: 6 INVITE
User-Agent: YATE/5.5.0
Contact: <sip:[email protected]:5060>
Allow: ACK, INVITE, BYE, CANCEL, OPTIONS, INFO
Content-Type: application/sdp
Content-Length: 508
----------------------------
2019/05/13 12:22:34.099403 172.20.160.167:5060 -> 212.xx.xx.xx:5060
INVITE sip:[email protected]:5060 SIP/2.0
Via: SIP/2.0/UDP 172.20.160.167;branch=z9hG4bKcd72.6992983b07d1c8269b4594fbcb7dd4b9.0
Max-Forwards: 19
From: <sip:@mysbc.host.com>;tag=788860019
To: <sip:[email protected]>
Call-ID: [email protected]
CSeq: 6 INVITE
User-Agent: YATE/5.5.0
Allow: ACK, INVITE, BYE, CANCEL, OPTIONS, INFO
Content-Type: application/sdp
Content-Length: 534
X-Group-SBC: 301
X-Routing-SBC: register un2tr-cgn-reg
Contact: <sip:[email protected]>
I try to generate the ISO on an fresh Ubuntu 18.04.3 LTS. But it is not working.
First problem the location of the gpg file has change.
Second the KEYS of the installation packets are not available
<---- log of build_rootfs.sh ---->
Last login: Wed Oct 9 12:40:39 2019 from 192.168.100.29
sysadmin@sbcoscreator:$ uname -a$ lsb_release -a
Linux sbcoscreator 4.15.0-65-generic #74-Ubuntu SMP Tue Sep 17 17:06:04 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
sysadmin@sbcoscreator:
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.3 LTS
Release: 18.04
Codename: bionic
sysadmin@sbcoscreator:$ pwd$ cd sbcos/
/home/sysadmin
sysadmin@sbcoscreator:
sysadmin@sbcoscreator:/sbcos$ git clone https://github.com/voiceboys/sbcOS.git/sbcos$
Cloning into 'sbcOS'...
remote: Enumerating objects: 47, done.
remote: Counting objects: 100% (47/47), done.
remote: Compressing objects: 100% (47/47), done.
remote: Total 922 (delta 21), reused 1 (delta 0), pack-reused 875
Receiving objects: 100% (922/922), 184.40 MiB | 5.32 MiB/s, done.
Resolving deltas: 100% (204/204), done.
sysadmin@sbcoscreator:
sysadmin@sbcoscreator:/sbcos$ ls/sbcos$ cd sbcOS/
sbcOS
sysadmin@sbcoscreator:
sysadmin@sbcoscreator:/sbcos/sbcOS$ ls/sbcos/sbcOS$ cd SbcOS/
bootfiles bootinfo.txt build config DOC initramfs ISO LICENSE livekitlib options.txt README.md SbcOS tools
sysadmin@sbcoscreator:
sysadmin@sbcoscreator:~/sbcos/sbcOS/SbcOS$ sudo su
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS# ./build_rootfs.sh
-= build stripped base rootfs for future squashfs
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/img"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/tmp"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/log"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb/import"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/squashfs"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/bootstrap"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/src"
use parameter [-debian] for update builder
-= build sbc-repository repository
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/rootfs"
cp: cannot stat '/etc/apt/trusted.gpg': No such file or directory
163 ./build_rootfs.sh
! error. exiting now.
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS# vu build_rootfs.sh
vu: command not found
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS# vi +163 build_rootfs.sh
---> cp /etc/apt/trusted.gpg.d/* "${BOOTSTRAPDIR}/etc/apt"
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS# ./build_rootfs.sh
-= build stripped base rootfs for future squashfs
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/img"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/tmp"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/log"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb/import"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/squashfs"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/bootstrap"
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/src"
use parameter [-debian] for update builder
-= build sbc-repository repository
| create directory "/home/sysadmin/sbcos/sbcOS/SbcOS/build/rfs/rootfs"
| install current debian stable to setup package repository
multistrap 2.2.9 benutzt /home/sysadmin/sbcos/sbcOS/SbcOS/configs/multistrap-bootstrap-current.conf
multistrap 2.2.9 benutzt /home/sysadmin/sbcos/sbcOS/SbcOS/configs/multistrap-bootstrap-current.conf
Architektur wird nativ vorgegeben als: amd64
multistrap baut amd64-Multistrap auf »amd64«
I: Symbolischer Link /home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/lib64 -> /home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/lib wird gesetzt.
Getting package lists: APT_CONFIG=/tmp/multistrap.ixT6Tg apt-get -o Apt::Architecture=amd64 -o Dir::Etc::TrustedParts=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/etc/apt/trusted.gpg.d -o Dir::Etc::Trusted=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/etc/apt/trusted.gpg -o Apt::Get::AllowUnauthenticated=true -o Apt::Get::Download-Only=true -o Apt::Install-Recommends=false -o Dir=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/ -o Dir::Etc=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/etc/apt/ -o Dir::Etc::Parts=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/etc/apt/apt.conf.d/ -o Dir::Etc::PreferencesParts=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/etc/apt/preferences.d/ -o APT::Default-Release=stretch -o Dir::State=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/var/lib/apt/ -o Dir::State::Status=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/var/lib/dpkg/status -o Dir::Cache=/home/sysadmin/sbcos/sbcOS/SbcOS/build/deb-rfs/bootstrap/var/cache/apt/ update
Ign:1 http://cdn-fastly.deb.debian.org/debian stretch InRelease
Holen:2 http://cdn-fastly.deb.debian.org/debian stretch Release [118 kB]
Holen:3 http://cdn-fastly.deb.debian.org/debian stretch Release.gpg [2.365 B]
Ign:3 http://cdn-fastly.deb.debian.org/debian stretch Release.gpg
Paketlisten werden gelesen... Fertig
W: GPG-Fehler: http://cdn-fastly.deb.debian.org/debian stretch Release: Die folgenden Signaturen konnten nicht überprüft werden, weil ihr öffentlicher Schlüssel nicht verfügbar ist: NO_PUBKEY 7638D0442B90D010 NO_PUBKEY 04EE7237B7D453EC NO_PUBKEY EF0F382A1A7B6500
E: Das Depot »http://httpredir.debian.org/debian stretch Release« ist nicht signiert.
N: Eine Aktualisierung von solch einem Depot kann nicht auf eine sichere Art durchgeführt werden, daher ist es standardmäÃig deaktiviert.
N: Weitere Details zur Erzeugung von Paketdepots sowie zu deren Benutzerkonfiguration finden Sie in der Handbuchseite apt-secure(8).
Apt-Aktualisierung fehlgeschlagen. Rückgabewert: 100
171 ./build_rootfs.sh
! error. exiting now.
root@sbcoscreator:/home/sysadmin/sbcos/sbcOS/SbcOS#
</-------->
I downloaded missing keys but I got more errors.
Has anybody successful build and ran ISO with Ubuntu 18.04.03 ?
I am not sure where the hook is to deploy own debian packages like open-vm-tools.
And i asume that i should handle the init-script for starting by-myself as well. Can you point me to the right direction? It could be make switchable via config enviroment or so then.
Build-Maschine:
root@sbcbuilder:~/sbcOS/ISO# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.2 LTS
Release: 18.04
Codename: bionic
root@sbcbuilder:~/sbcOS/ISO# uname -ra
Linux sbcbuilder 4.15.0-48-generic #51-Ubuntu SMP Wed Apr 3 08:28:49 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
I think it could be the not existing pid file. Take a look. Pid 681 is still there. Made this on local console - so there is not an "staying connection" from myself.
Build-Maschine:
root@sbcbuilder:~/sbcOS/ISO# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.2 LTS
Release: 18.04
Codename: bionic
root@sbcbuilder:~/sbcOS/ISO# uname -ra
Linux sbcbuilder 4.15.0-48-generic #51-Ubuntu SMP Wed Apr 3 08:28:49 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
LIVE-ISO 4122d7f
ps auxwww | grep sshd
681 root /usr/sbin/sshd
978 root grep sshd
/etc/init.d/ssh stop
Stopping daemon: sshd.
ps auxwww | grep sshd
681 root /usr/sbin/sshd
985 root grep sshd
root@plusbc01-live:~# ls -R /var/run/
/var/run/:
kamailio monit.pid rsyslogd.pid sshd telegraf.pid utmp
/var/run/kamailio:
kamailio.pid kamailio_ctl kamailio_radius.seq
/var/run/sshd:
I must type this from the virtualbox console:
PAM _pam_load_conf_file: unable to open /etc/pam.d/common-auth
PAM _pam_init_handlers: error reading /etc/pam.d/sshd
So sshd process is restarting during monit and its not usable - also not with ssh localhost.
And for the archive - building machine:
vagrant box ubuntu/bionic64
root@sbcbuilder:~/sbcOS/ISO# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.2 LTS
Release: 18.04
Codename: bionic
At the moment i do many testing on my local maschine in virtualbox. So there is it easy to run the ISO file to take a look at SBC-OS.
For an testing-lab i want to setup something on my VMWare ESX Host to attach an Test SIP-Core and Test SIPTRUNK. For this purpose it would make sense for me to "install" maybe from the ISO the files on hdd.
Are there any hints to do this easy? I dont want to make VMIMAGES. IPXE would be also an option, cos PXE is default on without OS Installation in VMWARE.
I ask for the "USB-STICK" as well, cos i thought, thats the only installation with permanent storing of configuration changes.
2 years without update kinda flag this as dead project
Any intention of upgrading this to latest kamilio and linux kernel etc?
It seems xt_RTPENGINE.ko is missing when compiling on debian 9...
./build
Changing current directory to /usr/src/sbcOS
Building intramfs image...
cp: cannot stat 'modules/4.9.0-9-amd64/xt_RTPENGINE.ko': No such file or directory
-----------------------------
Finished. Find your result in /tmp/sbc-data-29957
To build ISO, run: /tmp/gen_sbc_iso.sh
To build ZIP, run: /tmp/gen_sbc_zip.sh
I see an internal and an external Interface and some intressting entries for dispatcher and address as flatfile db. But some words about them would be nice and how these are glued together.
I thought there are minimum 3 kind of services in there, the SbC-OS, the own internal boxed "core" siprouter and the external world with siptrunks.
Would be nice to describe some senarios i asume be "normal":
Binding an SIPTRUNK to SBC-OS on IP Allow base:
[EXTERNAL-SIPTRUNK] <----> [SBC-OS] <----> [YOUR-CORE-NETWORK]
Binding an SIPTRUNK on SIP REGISTER base
What i forgot and you maybe already use.
Also how to "take care of kamailio and rtpengine" - like "kamcmd dispatcher.list" - i found that "kamctl dispatcher dump" didnt work - there is no ctl and no db mode.
Is this project still under development? Where can I find a more comprehensive documentation? I downloaded the ISO image mentioned in the ISSUES and successfully started it on my local machine, reaching the system interface. However, I'm not sure what to do next. When I disconnected the server and restarted, I couldn't access the system anymore.
Hi, we would like to try it with our project, does it support video calls?
Thanks
I wont to write an ISO file from sbc-os. The script sbcOS/ISO/gen_sbc_iso.sh relies on fixed and full path /tmp/sbc-data-15062
apt-get install genisoimage is also nessesary.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.