ant-media / Ant-Media-Server

Ant Media Server is a live streaming engine software that provides adaptive, ultra low latency streaming by using WebRTC technology with ~0.5 seconds latency. Ant Media Server is auto-scalable and it can run on-premise or on-cloud.
https://antmedia.io
Other
4.27k stars 628 forks source link

Unable to Install Ant Media Server on Ubuntu 20.10 x64 #3197

Closed nobleson closed 3 years ago

nobleson commented 3 years ago

Hello, I am using Ubuntu 20.10 x64 and i followed this Documentation When i try to install the Ant Media, got this error. tivcast@tivcast:/tmp$ sudo ./install_ant-media-server.sh -i ams-v2.3.2 readlink: missing operand Try 'readlink --help' for more information. We are supporting Ubuntu 18.04, Ubuntu 20.04 and Centos 8 Have someone been able to install the media server on 20.10? I will be happy if this distribution can be added to the list. Thanks

mekya commented 3 years ago

Hi @nobleson ,

You need to use package zip as an argument like this

sudo ./install_ant-media-server.sh -i  ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip
nobleson commented 3 years ago

Hi @mekya , I have followed this process and got the same error. tivcast@tivcast:~$ sudo ./install_ant-media-server.sh -i ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip readlink: missing operand Try 'readlink --help' for more information. We are supporting Ubuntu 18.04, Ubuntu 20.04 and Centos 8 tivcast@tivcast:~$ Are you sure Ubuntu 20.10 is supported at all sir?

mekya commented 3 years ago

Hi @nobleson ,

You're right. 20.10 is not supported yet. You can even try installing with -d true parameter.

sudo ./install_ant-media-server.sh -i ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip -d true 

when you just type the install script, it'll print out the options

sudo ./install_ant-media-server.sh 
Usage:
./install_ant-media-server.sh OPTIONS

OPTIONS:
  -i -> Provide Ant Media Server Zip file name. Mandatory
  -r -> Restore settings flag. It can accept true or false. Optional. Default value is false
  -s -> Install Ant Media Server as a service. It can accept true or false. Optional. Default value is true
  -d -> Install Ant Media Server on other Linux operating systems. Default value is false

Sample usage:
./install_ant-media-server.sh -i name-of-the-ant-media-server-zip-file
./install_ant-media-server.sh -i name-of-the-ant-media-server-zip-file -r true -s true
./install_ant-media-server.sh -i name-of-the-ant-media-server-zip-file -i false
./install_ant-media-server.sh -i name-of-the-ant-media-server-zip-file -d true
nobleson commented 3 years ago

Hello @mekya , I have tried and the last option gives this log:) `tivcast@tivcast:~$ sudo ./install_ant-media-server.sh -i ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip -r true -s true [sudo] password for tivcast: readlink: missing operand Try 'readlink --help' for more information. We are supporting Ubuntu 18.04, Ubuntu 20.04 and Centos 8 tivcast@tivcast:~$ sudo ./install_ant-media-server.sh -i ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip -d true [sudo] password for tivcast: readlink: missing operand Try 'readlink --help' for more information.

Are you sure that the above packages are installed? Y/N y Enter JVM Path (default: ): Ign:1 http://ppa.launchpad.net/ansible/ansible/ubuntu groovy InRelease Ign:2 http://ppa.launchpad.net/certbot/certbot/ubuntu groovy InRelease Err:3 http://ppa.launchpad.net/ansible/ansible/ubuntu groovy Release 404 Not Found [IP: 2001:67c:1560:8008::19 80] Err:4 http://ppa.launchpad.net/certbot/certbot/ubuntu groovy Release 404 Not Found [IP: 2001:67c:1560:8008::19 80] Hit:5 http://us.archive.ubuntu.com/ubuntu groovy InRelease Get:6 http://us.archive.ubuntu.com/ubuntu groovy-updates InRelease [115 kB] Get:7 http://us.archive.ubuntu.com/ubuntu groovy-backports InRelease [101 kB] Get:8 http://us.archive.ubuntu.com/ubuntu groovy-security InRelease [110 kB] Get:9 http://us.archive.ubuntu.com/ubuntu groovy-updates/main amd64 Packages [439 kB] Get:10 http://us.archive.ubuntu.com/ubuntu groovy-updates/main Translation-en [110 kB] Get:11 http://us.archive.ubuntu.com/ubuntu groovy-updates/main amd64 c-n-f Metadata [7,452 B] Get:12 http://us.archive.ubuntu.com/ubuntu groovy-updates/universe amd64 Packages [164 kB] Get:13 http://us.archive.ubuntu.com/ubuntu groovy-updates/universe Translation-en [64.6 kB] Get:14 http://us.archive.ubuntu.com/ubuntu groovy-security/main amd64 c-n-f Metadata [3,884 B] Reading package lists... Done E: The repository 'http://ppa.launchpad.net/ansible/ansible/ubuntu groovy Release' does not have a Release file. N: Updating from such a repository can't be done securely, and is therefore disabled by default. N: See apt-secure(8) manpage for repository creation and user configuration details. E: The repository 'http://ppa.launchpad.net/certbot/certbot/ubuntu groovy Release' does not have a Release file. N: Updating from such a repository can't be done securely, and is therefore disabled by default. N: See apt-secure(8) manpage for repository creation and user configuration details. There is a problem in installing the ant media server. Please send the log of this console to support@antmedia.io ` I think i need to wait until Ubuntu 20.10 is supported, Thanks

mekya commented 3 years ago

I'm going to ask from one of my colleague to help you. I mean I'll try to schedule this issue in this sprint meeting(today).

SelimEmre commented 3 years ago

Hi @nobleson,

Thank you for the explanation @mekya. I have an idea for your issue. Maybe your install_ant-media-server.sh script was outdated. Are you using the latest install_ant-media-server.sh script, right?

muratugureminoglu commented 3 years ago

@nobleson

I've changed the install script for you and it works properly on Ubuntu 20.10. You can download it from the link below[1].

[1] http://antmedia.io/temp/install_ant-media-server.sh

Regards.

nobleson commented 3 years ago

Hello,

I tried with this link you sent and this is the log: @.:~$ sudo ./install_ant-media-server.sh -i 'index.html?download_li nk=enterprise_edition' readlink: missing operand Try 'readlink --help' for more information. Ign:1 http://ppa.launchpad.net/ansible/ansible/ubuntu groovy InRelease Ign:2 http://ppa.launchpad.net/certbot/certbot/ubuntu groovy InRelease Err:3 http://ppa.launchpad.net/ansible/ansible/ubuntu groovy Release 404 Not Found [IP: 2001:67c:1560:8008::19 80] Err:4 http://ppa.launchpad.net/certbot/certbot/ubuntu groovy Release 404 Not Found [IP: 2001:67c:1560:8008::19 80] Hit:5 http://us.archive.ubuntu.com/ubuntu groovy InRelease Get:6 http://us.archive.ubuntu.com/ubuntu groovy-updates InRelease [115 kB] Get:7 http://us.archive.ubuntu.com/ubuntu groovy-backports InRelease [101 kB] Get:8 http://us.archive.ubuntu.com/ubuntu groovy-security InRelease [110 kB] Get:9 http://us.archive.ubuntu.com/ubuntu groovy-updates/main amd64 Packages [44 5 kB] Get:10 http://us.archive.ubuntu.com/ubuntu groovy-updates/universe amd64 Package s [165 kB] Reading package lists... Done E: The repository 'http://ppa.launchpad.net/ansible/ansible/ubuntu groovy Releas e' does not have a Release file. N: Updating from such a repository can't be done securely, and is therefore disa bled by default. N: See apt-secure(8) manpage for repository creation and user configuration deta ils. E: The repository 'http://ppa.launchpad.net/certbot/certbot/ubuntu groovy Releas e' does not have a Release file. N: Updating from such a repository can't be done securely, and is therefore disa bled by default. N: See apt-secure(8) manpage for repository creation and user configuration deta ils. There is a problem in installing the ant media server. Please send the log of th is console to @. @.***:~$

Kindly assist, thanks

On Mon, May 3, 2021 at 3:28 PM muratugureminoglu @.***> wrote:

@nobleson https://github.com/nobleson

I've changed the install script for you and it works properly on Ubuntu 20.10. You can download it from the link below[1].

[1] http://antmedia.io/temp/install_ant-media-server.sh

Regards.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ant-media/Ant-Media-Server/issues/3197#issuecomment-831296823, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADRNUG34Z74L3CIHGHJP7DLTL2XJVANCNFSM43Q6FXSQ .

muratugureminoglu commented 3 years ago

@nobleson

The following line is wrong. After the -i parameter, you should specify the location of the zip file.

sudo ./install_ant-media-server.sh -i 'index.html?download_li nk=enterprise_edition'

You need to use package zip as an argument like this.

sudo ./install_ant-media-server.sh -i ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip

nobleson commented 3 years ago

Hello, I am trying to use the Enterprise edition. And the download link that was sent to my email when I signed up for trail is what shows this file 'index.html?download_li nk=enterprise_edition' Although if I download the community edition , it is actually a zip file. What should I do? Is there a way I can get the Enterprise edition as a zip file, if then please let me know? Thanks

On Thu, May 6, 2021, 6:18 AM muratugureminoglu @.***> wrote:

@nobleson https://github.com/nobleson

The following line is wrong. After the -i parameter, you should specify the location of the zip file.

sudo ./install_ant-media-server.sh -i 'index.html?download_li nk=enterprise_edition'

You need to use package zip as an argument like this.

sudo ./install_ant-media-server.sh -i ant-media-server-2.3.2-community-2.3.2-20210422_0754.zip

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ant-media/Ant-Media-Server/issues/3197#issuecomment-833232255, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADRNUGYGEB2YWAPGJHUTCEDTMIRDHANCNFSM43Q6FXSQ .

muratugureminoglu commented 3 years ago

Please download it to your computer first, then upload it to your server.

Regards.

mekya commented 3 years ago

We've added 20.10 support to the install script. However, CI tests are still running on 18.04

https://github.com/ant-media/Scripts/blob/master/install_ant-media-server.sh

Thank you guys @muratugureminoglu @nobleson

Please re-open the issue if it's not working for you @nobleson

mahiprime2001 commented 2 years ago

I have successfully installed ant media server but the service is still inactive when I check the status it shows like this ... ● antmedia.service - AntMedia Loaded: loaded (/etc/systemd/system/antmedia.service; enabled; vendor preset: enabled) Active: activating (auto-restart) (Result: exit-code) since Sat 2022-01-22 07:03:52 UTC; 3s ago Process: 13253 ExecStart=/usr/bin/jsvc -home ${JAVA_HOME} -user antmedia -cwd ${ANTMEDIA_HOME} -Dlogback.ContextSel> Main PID: 13256 (code=exited, status=1/FAILURE) lines 1-5/5 (END)

muratugureminoglu commented 2 years ago

Hi @mahiprime2001

I need to know more information about your issue. Could you please provide the following ?

mahiprime2001 commented 2 years ago

Hi @mahiprime2001

I need to know more information about your issue. Could you please provide the following?

  • OS Version (Ubuntu 20.04, Centos8 etc)
  • Ant Media Server Version
  • Log files (/var/log/antmedia/)

.os ubuntu 20.4 .ant media server (newest version) .same path

muratugureminoglu commented 2 years ago

Hi @mahiprime2001 I need to know more information about your issue. Could you please provide the following?

  • OS Version (Ubuntu 20.04, Centos8 etc)
  • Ant Media Server Version
  • Log files (/var/log/antmedia/)

.os ubuntu 20.4 .ant media server (newest version) .same path

I mean, please provide the log files.

Regards.

mahiprime2001 commented 2 years ago

Hi @mahiprime2001 I need to know more information about your issue. Could you please provide the following?

  • OS Version (Ubuntu 20.04, Centos8 etc)
  • Ant Media Server Version
  • Log files (/var/log/antmedia/)

.os ubuntu 20.4 .ant media server (newest version) .same path

I mean, please provide the log files.

Regards.

there is only one file "antmedia-error.log"

inside the log, I got the below

Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1 Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1 Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1 Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1 Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1 Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1 Cannot find any VM in Java Home /usr/lib/jvm/default-java Cannot locate JVM library file Service exit with a return value of 1

muratugureminoglu commented 2 years ago

Hi @mahiprime2001

Can you share the output of the following commands?

  1. readlink -f $(which java)
  2. cat /etc/systemd/system/antmedia.service
mahiprime2001 commented 2 years ago

Hi @mahiprime2001

Can you share the output of the following commands?

  1. readlink -f $(which java)
  2. cat /etc/systemd/system/antmedia.service
  1. readlink -f $(which java) /usr/lib/jvm/java-11-openjdk-arm64/bin/java

2.output [Unit] Description=AntMedia After=syslog.target network.target

[Service] Type=forking Environment=PID=/var/run/antmedia.pid Environment=JAVA_HOME= LimitNOFILE=65536 Environment=ANTMEDIA_HOME=/usr/local/antmedia WorkingDirectory=/usr/local/antmedia RemainAfterExit=no Restart=on-failure RestartSec=5s

ExecStart=/usr/bin/jsvc -home ${JAVA_HOME} -user antmedia -cwd ${ANTMEDIA_HOME} -Dlogback.ContextSelector=org.red5.logging.LoggingContextSelector -cp ${ANTMEDIA_HOME}/commons-daemon-1.0.15.jar:${ANTMEDIA_HOME}/ant-media-server-service.jar:${ANTMEDIA_HOME}/conf -Djava.security.debug=failure -Djava.awt.headless=true -Djava.security.egd=file:/dev/./urandom -Dcatalina.home=${ANTMEDIA_HOME} -Dcatalina.useNaming=true -Dorg.terracotta.quartz.skipUpdateCheck=true -XX:+UseG1GC -XX:MaxGCPauseMillis=200 -XX:ParallelGCThreads=10 -XX:ConcGCThreads=5 -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.port=5599 -Dcom.sun.management.jmxremote.local.only=true -Dcom.sun.management.jmxremote.host=127.0.0.1 -Djava.rmi.server.hostname=127.0.0.1 -Djava.rmi.server.useLocalHostname=true -Dcom.sun.management.jmxremote.rmi.port=5599 -XX:+HeapDumpOnOutOfMemoryError -Djava.library.path=/usr/local/antmedia/lib/native -Djava.library.path=/usr/local/antmedia/lib/native -Xverify:none -XX:+TieredCompilation -XX:+UseBiasedLocking -XX:InitialCodeCacheSize=8m -XX:ReservedCodeCacheSize=32m -errfile ${ANTMEDIA_HOME}/log/antmedia-error.log -Djava.net.preferIPv4Stack=true -Dorg.bytedeco.javacpp.maxbytes=0 -Dorg.bytedeco.javacpp.maxphysicalbytes=0 -umask 133 -pidfile ${PID} org.red5.daemon.EngineLauncher 9999

ExecStop=/usr/bin/jsvc -stop -pidfile ${PID} org.red5.daemon.EngineLauncher 9999

[Install] WantedBy=multi-user.target

vedranius commented 2 years ago

Hi, I have a similar problem when I try to install I get this error:


./install_ant-media-server_3.sh: line 7: syntax error near unexpected token `newline'
./install_ant-media-server_3.sh: line 7: `<!DOCTYPE html>'

i've tried downloading latest script, and also 2 of them from this thread.

Running this command: ./install_ant-media-server_3.sh -t ant-media-server-community-2.4.1.zip -d true Tnx!

muratugureminoglu commented 2 years ago

@mahiprime2001

Please make sure that the Java package is installed correctly. As far as I can see, you are using arm, reinstall it using the command below.

apt-get reinstall openjdk-11-jdk

@vedranius

Your installation script is broken. I mean you need to download the raw file. Download and install as below.

wget https://raw.githubusercontent.com/ant-media/Scripts/master/install_ant-media-server.sh && chmod 755 install_ant-media-server.sh

Also, the installation command is wrong. Please try below.

sudo ./install_ant-media-server.sh -i ant-media-server-community-2.4.1.zip -d true
vedranius commented 2 years ago

@vedranius

Your installation script is broken. I mean you need to download the raw file. Download and install as below.

wget https://raw.githubusercontent.com/ant-media/Scripts/master/install_ant-media-server.sh && chmod 755 install_ant-media-server.sh

Also, the installation command is wrong. Please try below.

sudo ./install_ant-media-server.sh -i ant-media-server-community-2.4.1.zip -d true

Thanks! This worked out!

TheCoolCyrus commented 2 years ago

Hi, I have nearly the same problem

"root@instance-20221011-1511:~# sudo ./install_ant-media-server.sh -i ant-media-server-community-2.4.3.zip readlink: missing operand Try 'readlink --help' for more information. We are supporting Ubuntu 18.04, Ubuntu 20.04, Centos 8, Rocky Linux 8 and AlmaLinux 8"

how could I solve it?

TheCoolCyrus commented 2 years ago

Then I tried one more time, and this happen

root@instance-20221011-1511:~# sudo ./install_ant-media-server.sh -i ant-media-sever-community-2.4.3.zip -d true readlink: missing operand Try 'readlink --help' for more information.

Are you sure that the above packages are installed? Y/N Y Enter JVM Path (default: ): Get:1 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB] Hit:2 http://iad-ad-3.clouds.archive.ubuntu.com/ubuntu jammy InRelease Get:3 http://iad-ad-3.clouds.archive.ubuntu.com/ubuntu jammy-updates InRelease [114 kB] Get:4 http://iad-ad-3.clouds.archive.ubuntu.com/ubuntu jammy-backports InRelease [99.8 kB] Fetched 324 kB in 1s (360 kB/s)

Reading package lists... Done Reading package lists... Done Building dependency tree... Done Reading state information... Done coreutils is already the newest version (8.32-4.1ubuntu1). coreutils set to manually installed. 0 upgraded, 0 newly installed, 0 to remove and 67 not upgraded.

Hit:1 http://iad-ad-3.clouds.archive.ubuntu.com/ubuntu jammy InRelease Hit:2 http://iad-ad-3.clouds.archive.ubuntu.com/ubuntu jammy-updates InRelease Hit:3 http://iad-ad-3.clouds.archive.ubuntu.com/ubuntu jammy-backports InRelease Hit:4 http://security.ubuntu.com/ubuntu jammy-security InRelease Reading package lists... Done Reading package lists... Done Building dependency tree... Done Reading state information... Done Package libcrystalhd-dev is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source

E: Package 'libcrystalhd-dev' has no installation candidate There is a problem in installing the ant media server. Please send the log of this console to support@antmedia.io

TheCoolCyrus commented 2 years ago

found out that im cureently ubuntu 22.04 which AMS is not supported

https://community.antmedia.io/topic/1373-couldnt-install-ams-in-ubuntu-2204/

but im using Oracle Cloud which only provide 22.04 version for Ubuntu :/, any thing I can do?

muratugureminoglu commented 2 years ago

Hi @TheCoolCyrus

Could you please check this link ?

TheCoolCyrus commented 2 years ago

hi @muratugureminoglu , i followed the "echo..." step then "-bash: /etc/apt/sources.list: Permission denied" happen

muratugureminoglu commented 2 years ago

hi @muratugureminoglu , i followed the "echo..." step then "-bash: /etc/apt/sources.list: Permission denied" happen

use with sudo or edit with the editor like vim, nano

sudo vim /etc/apt/sources.list and the below line then save it. deb http://ftp.ubuntu.com/ubuntu focal universe

TheCoolCyrus commented 2 years ago

sudo vim /etc/apt/sources.list

@muratugureminoglu sorry I'm very new to these, you mean

just input "sudo vim /etc/apt/sources.list"

then "deb http://ftp.ubuntu.com/ubuntu focal universe"?

it turn to this after sudo vim /etc/apt/sources.list

E325: ATTENTION
Found a swap file by the name "/etc/apt/.sources.list.swp"
          owned by: root   dated: Tue Oct 11 18:20:18 2022
         file name: /etc/apt/sources.list
          modified: YES
         user name: root   host name: instance-20221011-1511
        process ID: 5217
While opening file "/etc/apt/sources.list"
             dated: Tue Oct 11 07:14:17 2022

(1) Another program may be editing the same file.  If this is the case,
    be careful not to end up with two different instances of the same
    file when making changes.  Quit, or continue with caution.
(2) An edit session for this file crashed.
    If this is the case, use ":recover" or "vim -r /etc/apt/sources.list"
    to recover the changes (see ":help recovery").
    If you did this already, delete the swap file "/etc/apt/.sources.list.swp"
    to avoid this message.

Swap file "/etc/apt/.sources.list.swp" already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (D)elete it, (Q)uit, (A)bort:
mediageni commented 2 years ago

Hi,

Is ant-media-server-community-2.4.3.zip supported for CentOS v7.9.2009 STANDARD virtuozzo ?

thanks

muratugureminoglu commented 2 years ago

sudo vim /etc/apt/sources.list

@muratugureminoglu sorry I'm very new to these, you mean

just input "sudo vim /etc/apt/sources.list"

then "deb http://ftp.ubuntu.com/ubuntu focal universe"?

it turn to this after sudo vim /etc/apt/sources.list

E325: ATTENTION
Found a swap file by the name "/etc/apt/.sources.list.swp"
          owned by: root   dated: Tue Oct 11 18:20:18 2022
         file name: /etc/apt/sources.list
          modified: YES
         user name: root   host name: instance-20221011-1511
        process ID: 5217
While opening file "/etc/apt/sources.list"
             dated: Tue Oct 11 07:14:17 2022

(1) Another program may be editing the same file.  If this is the case,
    be careful not to end up with two different instances of the same
    file when making changes.  Quit, or continue with caution.
(2) An edit session for this file crashed.
    If this is the case, use ":recover" or "vim -r /etc/apt/sources.list"
    to recover the changes (see ":help recovery").
    If you did this already, delete the swap file "/etc/apt/.sources.list.swp"
    to avoid this message.

Swap file "/etc/apt/.sources.list.swp" already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (D)elete it, (Q)uit, (A)bort:

@TheCoolCyrus Press D or E.

@mediageni Unfortunately it is not supported. Only Ubuntu 20.04, Centos 8, RockLinux 8, AlmaLinux 8