본문 바로가기

Projects/Server

[스크랩 ] VLS를 이용한 스트리밍 서버 환경구현 上

작성환경 : Asianux Server 2.0 Base (kernel 2.6.9-34.26AX 환경)
작성일자 : 2007. 08. 10.
작 성 자 : 시스템 엔지니어 최광민(1979. 08. 06. 인천)
최종수정 : 2007. 08. 11. - 이문서의 최종 수정버전은 오소리(
http://www.osori.org)에서 확인 하실 수 있습니다.
수정요청 : help@osori.org
배포조건 : Creative Commons License
Creative Commons License
이 저작물은 크리에이티브 커먼즈 코리아 저작자표시-비영리-변경금지 2.0 대한민국 라이센스에 따라 이용하실 수 있습니다.

출처 : http://osori.org/?article_srl=78600


VLS는 프랑스에서 개발한 리눅스 기반 스트리밍을 구현해 주는 솔루션중 가장 강력한 오픈소스 솔루션입니다.

GNU/Public 공중 라이센스하에 개발되었기 때문에 어떤 사용자든 자유롭게 사용할수 있으며 무엇보다 리눅스 기반 스트리밍 서비스의 한계였던 Windows 미디어 포멧 방식의 (ASF, WMV, AVI등등) 미디어들을 아파치 웹서버 상에서 간단하게 스트리밍을 구현할수 있다는 장점이 있습니다.

이에 VLS를 설치하시려는 리눅스 사용자 분들이 많았지만 설치에 어려움을 겪는것 같아 이렇게 직접 설치기를 올립니다.

아무쪼록 도움이 되었으면 하는 바램입니다.

이문서는 CCL 라이센스를 따르며 원작성자는 본인 최광민 입니다.



[ 간단한 설명 ]

배포 및 개발사이트 - http://www.videolan.org

VLC - 리눅스 기반 미디어 플레이어

VLS - 리눅스 기반 스트리밍 서버

VLS 다운로드 - http://download.videolan.org/pub/videolan/vls/0.5.6/

VLS 의존 라이브러리 다운로드 - http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/

VLS 사용자 매뉴얼(영문) - http://www.videolan.org/doc/vls-user-guide/en/vls-user-guide-en.html

[ 설치 과정 ]


[root@Asianux2 ~]#
[root@Asianux2 ~]#
[root@Asianux2 ~]# uname -a
Linux Asianux2.0 2.6.9-34.26AX #1 Wed Jan 10 16:13:36 KST 2007 i686 i686 i386 GNU/Linux
[root@Asianux2 ~]#
[root@Asianux2 ~]#
[root@Asianux2 ~]#

 

[root@Asianux2 ~]# rpm -qi gcc
Name        : gcc                          Relocations: (not relocatable)
Version     : 3.4.5                             Vendor: Asianux
Release     : 2.1                           Build Date: 2006년 04월 04일 (화) 오후 06시 02분 52초
Install Date: 2007년 08월 08일 (수) 오후 06시 52분 48초      Build Host: Trinity-IA32.asianux.com
Group       : Development/Languages         Source RPM: gcc-3.4.5-2.1.src.rpm
Size        : 12923972                         License: GPL
Signature   : DSA/SHA1, 2006년 04월 04일 (화) 오후 06시 02분 54초, Key ID 1246298df47bed1d
Packager    : packager@asianux.com
URL         : http://gcc.gnu.org
Summary     : Various compilers (C, C++, Objective-C, Java, ...)
Description :
The gcc package contains the GNU Compiler Collection version 3.4.
You'll need this package in order to compile C code.
[root@Asianux2 ~]#
[root@Asianux2 ~]#



[root@Asianux2 ~]#
[root@Asianux2 ~]# cd /usr/local/src/
[root@Asianux2 src]#
[root@Asianux2 src]#


[root@Asianux2 src]# ll
합계 0
[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# wget http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvb-0.2.2.tar.gz
--11:24:02--  http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvb-0.2.2.tar.gz
           => `libdvb-0.2.2.tar.gz'
Resolving download.videolan.org... 88.191.250.9
Connecting to download.videolan.org|88.191.250.9|:80... connected.
HTTP 요청이 전달되었습니다, 응답을 기다리는 중... 200 OK
길이: 64,345 (63K) [application/x-gzip]

100%[========================================================================================>] 64,345        35.75K/s           

11:24:05 (35.68 KB/s) - `libdvb-0.2.2.tar.gz' saved [64345/64345]

[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# wget http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvbpsi3-0.1.4.tar.gz
--11:24:16--  http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvbpsi3-0.1.4.tar.gz
           => `libdvbpsi3-0.1.4.tar.gz'
Resolving download.videolan.org... 88.191.250.9
Connecting to download.videolan.org|88.191.250.9|:80... connected.
HTTP 요청이 전달되었습니다, 응답을 기다리는 중... 200 OK
길이: 359,515 (351K) [application/x-gzip]

100%[========================================================================================>] 359,515      106.55K/s    ETA 00:00

11:24:22 (106.34 KB/s) - `libdvbpsi3-0.1.4.tar.gz' saved [359515/359515]

[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# wget http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvdcss-1.2.8.tar.gz
--11:24:30--  http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvdcss-1.2.8.tar.gz
           => `libdvdcss-1.2.8.tar.gz'
Resolving download.videolan.org... 88.191.250.9
Connecting to download.videolan.org|88.191.250.9|:80... connected.
HTTP 요청이 전달되었습니다, 응답을 기다리는 중... 200 OK
길이: 273,715 (267K) [application/x-gzip]

100%[========================================================================================>] 273,715       89.81K/s           

11:24:35 (89.61 KB/s) - `libdvdcss-1.2.8.tar.gz' saved [273715/273715]

[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# wget http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvdread-0.9.4.tar.gz
--11:24:44--  http://download.videolan.org/pub/videolan/vls/0.5.6/contrib/libdvdread-0.9.4.tar.gz
           => `libdvdread-0.9.4.tar.gz'
Resolving download.videolan.org... 88.191.250.9
Connecting to download.videolan.org|88.191.250.9|:80... connected.
HTTP 요청이 전달되었습니다, 응답을 기다리는 중... 200 OK
길이: 256,858 (251K) [application/x-gzip]

100%[========================================================================================>] 256,858       85.06K/s           

11:24:47 (84.93 KB/s) - `libdvdread-0.9.4.tar.gz' saved [256858/256858]

[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]# ll
합계 952
-rw-r--r--  1 root root  64345 12월  5  2004 libdvb-0.2.2.tar.gz
-rw-r--r--  1 root root 359515 12월  5  2004 libdvbpsi3-0.1.4.tar.gz
-rw-r--r--  1 root root 273715 12월  5  2004 libdvdcss-1.2.8.tar.gz
-rw-r--r--  1 root root 256858 12월  5  2004 libdvdread-0.9.4.tar.gz
[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# tar -zxvf libdvb-0.2.2.tar.gz
 

[root@Asianux2 src]# tar -zxvf libdvbpsi3-0.1.4.tar.gz


[root@Asianux2 src]# tar -zxvf libdvdcss-1.2.8.tar.gz
 

[root@Asianux2 src]# tar -zxvf libdvdread-0.9.4.tar.gz


[root@Asianux2 src]# ll
합계 968
drwxr-xr-x  2  500 users   4096  3월  8  2003 libdvb-0.2.2
-rw-r--r--  1 root root   64345 12월  5  2004 libdvb-0.2.2.tar.gz
drwxrwsrwx  8 1000  1000   4096  1월  2  2004 libdvbpsi3-0.1.4
-rw-r--r--  1 root root  359515 12월  5  2004 libdvbpsi3-0.1.4.tar.gz
drwxrwxrwx  7 1000  1000   4096  7월 30  2003 libdvdcss-1.2.8
-rw-r--r--  1 root root  273715 12월  5  2004 libdvdcss-1.2.8.tar.gz
drwxrwsrwx  4 6581 30099   4096  2월 23  2003 libdvdread-0.9.4
-rw-r--r--  1 root root  256858 12월  5  2004 libdvdread-0.9.4.tar.gz

 

 

[root@Asianux2 src]# rm -rf ./*.tar.gz
[root@Asianux2 src]# ll
합계 16
drwxr-xr-x  2  500 users 4096  3월  8  2003 libdvb-0.2.2
drwxrwsrwx  8 1000  1000 4096  1월  2  2004 libdvbpsi3-0.1.4
drwxrwxrwx  7 1000  1000 4096  7월 30  2003 libdvdcss-1.2.8
drwxrwsrwx  4 6581 30099 4096  2월 23  2003 libdvdread-0.9.4
[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# wget http://download.videolan.org/pub/videolan/vls/0.5.6/vls-0.5.6.tar.gz
--11:26:30--  http://download.videolan.org/pub/videolan/vls/0.5.6/vls-0.5.6.tar.gz
           => `vls-0.5.6.tar.gz'
Resolving download.videolan.org... 88.191.250.9
Connecting to download.videolan.org|88.191.250.9|:80... connected.
HTTP 요청이 전달되었습니다, 응답을 기다리는 중... 200 OK
길이: 802,901 (784K) [application/x-gzip]

100%[========================================================================================>] 802,901      141.39K/s    ETA 00:00

11:26:42 (128.75 KB/s) - `vls-0.5.6.tar.gz' saved [802901/802901]

[root@Asianux2 src]#
[root@Asianux2 src]#


[root@Asianux2 src]# ll
합계 808
drwxr-xr-x  2  500 users   4096  3월  8  2003 libdvb-0.2.2
drwxrwsrwx  8 1000  1000   4096  1월  2  2004 libdvbpsi3-0.1.4
drwxrwxrwx  7 1000  1000   4096  7월 30  2003 libdvdcss-1.2.8
drwxrwsrwx  4 6581 30099   4096  2월 23  2003 libdvdread-0.9.4
-rw-r--r--  1 root root  802901 12월 12  2004 vls-0.5.6.tar.gz
[root@Asianux2 src]#

 
[root@Asianux2 src]# tar -zxvf vls-0.5.6.tar.gz



[root@Asianux2 src]# rm -rf vls-0.5.6.tar.gz
 

[root@Asianux2 src]# ls
libdvb-0.2.2  libdvbpsi3-0.1.4  libdvdcss-1.2.8  libdvdread-0.9.4  vls-0.5.6
[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]#

 

[root@Asianux2 src]# cd libdvb-0.2.2/
[root@Asianux2 libdvb-0.2.2]#
[root@Asianux2 libdvb-0.2.2]#
[root@Asianux2 libdvb-0.2.2]# ll
합계 392
-rw-r--r--  1 500 users  55177  3월  8  2003 DVB.cc
-rw-r--r--  1 500 users   8362  3월  8  2003 DVB.hh
-rw-r--r--  1 500 users   1093  3월  8  2003 Makefile
-rw-r--r--  1 500 users   3614  3월  8  2003 OSD.c
-rw-r--r--  1 500 users   1037  3월  8  2003 OSD.h
-rw-r--r--  1 500 users    373  3월  8  2003 README
-rw-r--r--  1 500 users   1159  3월  8  2003 channel.h
-rw-r--r--  1 500 users    152  3월  8  2003 conv.cc
-rw-r--r--  1 500 users  10323  3월  8  2003 devices.cc
-rw-r--r--  1 500 users   5840  3월  8  2003 devices.hh
-rw-r--r--  1 500 users 100746  3월  8  2003 dvbrc.3sats
-rw-r--r--  1 500 users 100746  3월  8  2003 dvbrc.4sats
-rw-r--r--  1 500 users  40635  3월  8  2003 dvbrc.astra
-rw-r--r--  1 500 users  12058  3월  8  2003 dvbrc.cable
-rw-r--r--  1 500 users   1491  3월  8  2003 dvbrc.terra
-rw-r--r--  1 500 users    317  3월  8  2003 merge.cc
-rw-r--r--  1 500 users   2353  3월  8  2003 osd.hh
-rw-r--r--  1 500 users   1561  3월  8  2003 satscan.cc

 

 

[root@Asianux2 libdvb-0.2.2]# cat README
LIBDVB - DVB library for SI parsing, OSD, tuning, ...

There are 2 example programs that show how to work with the library.
You can also look at the tuxzap package for further usage information.

conv
converts from one of the various input formats (xml, satcodx, nokia) to the
libdvb format.

satscan
shows how to scan the transponders of a satellite for new channels.


[root@Asianux2 libdvb-0.2.2]#
[root@Asianux2 libdvb-0.2.2]# make

[root@Asianux2 libdvb-0.2.2]# make install
cp libdvb.a /usr/local/lib/
chmod 644 /usr/local/lib/libdvb.a
[root@Asianux2 libdvb-0.2.2]#
[root@Asianux2 libdvb-0.2.2]#


[root@Asianux2 libdvb-0.2.2]# cd ..
[root@Asianux2 src]# ll
합계 20
drwxr-xr-x  2  500 users 4096  8월  9 11:27 libdvb-0.2.2
drwxrwsrwx  8 1000  1000 4096  1월  2  2004 libdvbpsi3-0.1.4
drwxrwxrwx  7 1000  1000 4096  7월 30  2003 libdvdcss-1.2.8
drwxrwsrwx  4 6581 30099 4096  2월 23  2003 libdvdread-0.9.4
drwxr-sr-x  9 1000 dip   4096  2월 17  2004 vls-0.5.6
 

[root@Asianux2 src]# cd libdvbpsi3-0.1.4/
[root@Asianux2 libdvbpsi3-0.1.4]#


[root@Asianux2 libdvbpsi3-0.1.4]# ./configure

[root@Asianux2 libdvbpsi3-0.1.4]# make; make install


[root@Asianux2 libdvbpsi3-0.1.4]# cd ..
[root@Asianux2 src]# ll
합계 20
drwxr-xr-x  2  500 users 4096  8월  9 11:27 libdvb-0.2.2
drwxrwsrwx  8 1000  1000 4096  8월  9 11:29 libdvbpsi3-0.1.4
drwxrwxrwx  7 1000  1000 4096  7월 30  2003 libdvdcss-1.2.8
drwxrwsrwx  4 6581 30099 4096  2월 23  2003 libdvdread-0.9.4
drwxr-sr-x  9 1000 dip   4096  2월 17  2004 vls-0.5.6


[root@Asianux2 src]# cd libdvdcss-1.2.8/


[root@Asianux2 libdvdcss-1.2.8]# ./configure


[root@Asianux2 libdvdcss-1.2.8]# make


[root@Asianux2 libdvdcss-1.2.8]# make install
[root@Asianux2 libdvdcss-1.2.8]#
[root@Asianux2 libdvdcss-1.2.8]#
[root@Asianux2 libdvdcss-1.2.8]# cd ..
[root@Asianux2 src]# ll


[root@Asianux2 src]# cd libdvdread-0.9.4/
[root@Asianux2 libdvdread-0.9.4]#
[root@Asianux2 libdvdread-0.9.4]#


[root@Asianux2 libdvdread-0.9.4]# ./configure


[root@Asianux2 libdvdread-0.9.4]# make


[root@Asianux2 libdvdread-0.9.4]# make install


[root@Asianux2 libdvdread-0.9.4]# cd ..
[root@Asianux2 src]# ll
합계 20
drwxr-xr-x  2  500 users 4096  8월  9 11:27 libdvb-0.2.2
drwxrwsrwx  8 1000  1000 4096  8월  9 11:29 libdvbpsi3-0.1.4
drwxrwxrwx  7 1000  1000 4096  8월  9 11:29 libdvdcss-1.2.8
drwxrwsrwx  4 6581 30099 4096  8월  9 11:30 libdvdread-0.9.4
drwxr-sr-x  9 1000 dip   4096  2월 17  2004 vls-0.5.6
[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]# vi /etc/ld.so.conf
include ld.so.conf.d/*.conf

/usr/local/lib =========> 추가


"/etc/ld.so.conf" [변환 되었습니다] 3L, 44C 저장 했습니다                                                       
[root@Asianux2 src]#
[root@Asianux2 src]#


[root@Asianux2 src]# ldconfig    ==========> 실행
[root@Asianux2 src]#
[root@Asianux2 src]#
[root@Asianux2 src]# ll
합계 20
drwxr-xr-x  2  500 users 4096  8월  9 11:27 libdvb-0.2.2
drwxrwsrwx  8 1000  1000 4096  8월  9 11:29 libdvbpsi3-0.1.4
drwxrwxrwx  7 1000  1000 4096  8월  9 11:29 libdvdcss-1.2.8
drwxrwsrwx  4 6581 30099 4096  8월  9 11:30 libdvdread-0.9.4
drwxr-sr-x  9 1000 dip   4096  2월 17  2004 vls-0.5.6



[root@Asianux2 src]# cd vls-0.5.6/
[root@Asianux2 vls-0.5.6]# ll
합계 536
-rw-r--r--  1 1000 dip   1296 12월  8  2002 AUTHORS
-rw-r--r--  1 1000 dip  17992  8월 31  2001 COPYING
-rw-r--r--  1 1000 dip   8330  2월 17  2004 ChangeLog
-rw-r--r--  1 1000 dip    337  1월 11  2004 INSTALL
-rw-r--r--  1 1000 dip   7930  1월 11  2004 Makefile
-rw-r--r--  1 1000 dip   2664 12월  8  2002 Makefile.dep
-rw-r--r--  1 1000 dip   2429  2월  4  2003 Makefile.module
-rw-r--r--  1 1000 dip   2372 12월  9  2002 Makefile.module.dep
-rw-r--r--  1 1000 dip   2682  2월  4  2003 Makefile.opts.in
-rw-r--r--  1 1000 dip   1439  1월 11  2004 README
-rw-r--r--  1 1000 dip    761  5월 17  2003 README.win32
-rw-r--r--  1 1000 dip   1209  1월 11  2004 TODO
drwxr-sr-x  2 1000 dip   4096  2월 17  2004 bin
drwxr-sr-x  2 1000 dip   4096  2월 17  2004 build_test
-rw-r--r--  1 1000 dip  41134  3월 26  2003 config.guess
-rw-r--r--  1 1000 dip  29763  3월 26  2003 config.sub
-rwxr-xr-x  1 1000 dip 295021  2월 17  2004 configure
-rw-r--r--  1 1000 dip  13633  2월 17  2004 configure.in
drwxr-sr-x  2 1000 dip   4096  2월 17  2004 debian
drwxr-sr-x  3 1000 dip   4096  2월 17  2004 doc
-rwxr-xr-x  1 1000 dip   5603 10월  6  2001 install-sh
drwxr-sr-x  3 1000 dip   4096  2월 17  2004 interface
drwxr-sr-x  7 1000 dip   4096  2월 17  2004 src
drwxr-sr-x  2 1000 dip   4096  2월 17  2004 test
-rwxr-xr-x  1 1000 dip    318 10월  8  2001 todo.pl
-rw-r--r--  1 1000 dip   4479  6월  5  2003 vls.cfg
-rw-r--r--  1 1000 dip    906  9월 24  2002 vls.sln
-rw-r--r--  1 1000 dip   2777 12월  9  2002 vls.spec
-rw-r--r--  1 1000 dip  14326  5월  3  2003 vls.vcproj


[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]# ./configure --help
`configure' configures this package to adapt to many kinds of systems.

Usage: ./configure [OPTION]... [VAR=VALUE]...

To assign environment variables (e.g., CC, CFLAGS...), specify them as
VAR=VALUE.  See below for descriptions of some of the useful variables.

Defaults for the options are specified in brackets.

Configuration:
  -h, --help              display this help and exit
      --help=short        display options specific to this package
      --help=recursive    display the short help of all the included packages
  -V, --version           display version information and exit
  -q, --quiet, --silent   do not print `checking...' messages
      --cache-file=FILE   cache test results in FILE [disabled]
  -C, --config-cache      alias for `--cache-file=config.cache'
  -n, --no-create         do not create output files
      --srcdir=DIR        find the sources in DIR [configure dir or `..']

Installation directories:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [/usr/local]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [PREFIX]

By default, `make install' will install all the files in
`/usr/local/bin', `/usr/local/lib' etc.  You can specify
an installation prefix other than `/usr/local' using `--prefix',
for instance `--prefix=$HOME'.

For better control, use the options below.

Fine tuning of the installation directories:
  --bindir=DIR           user executables [EPREFIX/bin]
  --sbindir=DIR          system admin executables [EPREFIX/sbin]
  --libexecdir=DIR       program executables [EPREFIX/libexec]
  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
  --libdir=DIR           object code libraries [EPREFIX/lib]
  --includedir=DIR       C header files [PREFIX/include]
  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
  --infodir=DIR          info documentation [PREFIX/info]
  --mandir=DIR           man documentation [PREFIX/man]

System types:
  --build=BUILD     configure for building on BUILD [guessed]
  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
  --target=TARGET   configure for building compilers for TARGET [HOST]

Optional Features:
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --enable-debug          Enable debug mode (default disabled)
  --enable-profiling      Enable profiling mode (default disabled)
  --disable-syslog         Logging using syslogd (default enable)
  --disable-daemon        Disable daemon mode (default enabled)
  --disable-dvd           DVD support (default enabled)
  --enable-dvb            DVB support (default disabled)

Optional Packages:
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --with-dvb=PATH         path to DVB driver header files
  --with-libdvb=PATH      path to libdvb
  --with-dvbpsi=PATH      libdvbpsi headers and libraries
  --with-dvbpsi-tree=PATH libdvbpsi tree for static linking

Some influential environment variables:
  CC          C compiler command
  CFLAGS      C compiler flags
  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
              nonstandard directory <lib dir>
  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
              headers in a nonstandard directory <include dir>
  CXX         C++ compiler command
  CXXFLAGS    C++ compiler flags
  CXXCPP      C++ preprocessor

Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.


[root@Asianux2 vls-0.5.6]# whereis gcc32
gcc32: /usr/bin/gcc32
[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]#


[root@Asianux2 vls-0.5.6]# whereis g++32
g++32: /usr/bin/g++32
[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]#


[root@Asianux2 vls-0.5.6]# CC=/usr/bin/gcc32 CXX=/usr/bin/g++32 ./configure --enable-syslog

[root@Asianux2 vls-0.5.6]# make

[root@Asianux2 vls-0.5.6]# make install
mkdir -p /usr/local/bin
/usr/bin/install -c bin/vls /usr/local/bin
/usr/bin/install -c bin/vlsd /usr/local/bin
mkdir -p /usr/local/lib/videolan/vls
/usr/bin/install -c -m 644 bin/dvdreader.so /usr/local/lib/videolan/vls
mkdir -p /usr/local/etc/videolan/vls
test -r /usr/local/etc/videolan/vls/vls.cfg || /usr/bin/install -c -m 644 vls.cfg /usr/local/etc/videolan/vls
Installation succeeded.


[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]#
[root@Asianux2 vls-0.5.6]# cd /usr/local/etc/
[root@Asianux2 etc]# ll
합계 4
drwxr-xr-x  3 root root 4096  8월  9 11:38 videolan
[root@Asianux2 etc]# cd videolan/
[root@Asianux2 videolan]# ll
합계 4
drwxr-xr-x  2 root root 4096  8월  9 11:38 vls
[root@Asianux2 videolan]# cd vls/
[root@Asianux2 vls]# ll
합계 8
-rw-r--r--  1 root root 4479  8월  9 11:38 vls.cfg
[root@Asianux2 vls]#
[root@Asianux2 vls]#
[root@Asianux2 vls]# htpasswd -n monitor  ===========> 중요한 부분이다 밑에 나오는 패스워드를 복사해두자.
New password:
Re-type new password:
monitor:L5UTNxa/HUb62


[root@Asianux2 vls]#
[root@Asianux2 vls]# htpasswd -n master ===========> 역시 중요한 부분이다 밑에 나오는 패스워드를 복사해두자.
New password:
Re-type new password:
master:uWzHbVcKHesWw


[root@Asianux2 vls]#
[root@Asianux2 vls]#
[root@Asianux2 vls]# vi vls.cfg
# vls configuration file (Example)

# Application wide settings
BEGIN "Vls"
  LogFile       = "vls.log"             # log file
  ScreenLog     = "enable"              # log to the console
#  SystemLog     = "disable"             # log to the systemlog
  SystemLog     = "enable"             # log to the systemlog
END

# Security informations :
#
# The section "Groups" describes which group is allowed to use which command.
# Each user who belongs to the 'master" group has all the power on the server.
# Each one who belongs to the "monitor" group is a "read-only" user.
BEGIN "Groups"
# --- Format:
# groupname     = "cmd1|cmd2|..."
# --- Example:
  monitor       = "help|browse|logout"
  master        = "help|browse|start|resume|suspend|stop|shutdown|logout|config|program|input|channel|show"
END

# The section "Users" describes each user
# Use "mkpasswd" to generate the encrypted password.
BEGIN "Users"
# --- Format:
# username      = "encryptedpassword:group"
# --- Example:
  monitor       = "L5UTNxa/HUb62:monitor"    ========> 아까 복사해 두었던 패스워드를 앞쪽에 입력
  master        = "uWzHbVcKHesWw:master"   ========> 아까 복사해 두었던 패스워드를 앞쪽에 입력
END

# Telnet Administration
BEGIN "Telnet"
#  Domain        = "Inet6"              # Inet4 or Inet6
  LocalPort     = "9001"                # Port to use for that purpose
  Use = "true"
END

# Streams sources declaration
BEGIN "Inputs"
# --- Format:
# InputName     = "Type"
# --- Example:
  local1       = "local"                # Local input example
#  kfir         = "video"               # Video input example (mpeg encoder)
#  dvb          = "dvb"                 # Video input example (DVB card)
END

# --- Format:
# BEGIN "program_number"
#   Name     = "program_name"
#   Type     = "type"          # can be Mpeg1-PS, Mpeg2-PS, Mpeg2-TS, or Dvd
#   FileName = "path"          # use this variable if Type is not "Dvd"
#   Device   = "device"        # use this variable with type "Dvd"
# END

# --- Example:
BEGIN "1"     # MPEG2 stream stored in /home/videolan/streams/Dolby.vob
  Name     = "dolby"
  FileName = "/media/films/Dolby_Canyon.vob"
  Type     = "Mpeg2-PS"
END

BEGIN "2"     # another file
  Name     = "canyon"
  FileName = "Dolby_Canyon.vob"
  Type     = "Mpeg2-PS"
END

BEGIN "3"     # DVD
  Name       = "film"
  Device     = "/dev/cdrom"
  Type       = "dvd"
  DvdTitle   = "1"    # Start title
  DvdChapter = "1"    # Start chapter
END

BEGIN "4"     # DVD stored on a hard disk
  Name       = "matrix"
  Device     = "/media/matrix/VIDEO_TS"
  Type       = "dvd"
  DvdTitle   = "1"   # Start title
  DvdChapter = "1"   # Start chapter
END

# Video input configuration
BEGIN "kfir"
# --- Example:
# Device        = "/dev/video"     # Video4linux device (default is /dev/video)
# Type          = "Mpeg2-PS"       # Stream type (default is "Mpeg2-PS")
END

# Video input (DVB) configuration
BEGIN "dvb"
# --- Example:
#  DeviceNumber = "0"                   # /dev/dvb/adapter<i>
#  SendMethod   = "0"                   # 0 - Send All Pids
                                        # 1 - Send only MPEG2 datas
END

# Channel (outputs) declaration
BEGIN "Channels"
# --- Format:
# ChannelName   = "Type"
# --- Example:
  localhost     = "network"
#  client1       = "network"
#  client2       = "network"
#  multicast     = "network"
#  localfile     = "file"
END

# Channels configuration
BEGIN "localhost"         # The client is on the same host as the server
  DstHost = "127.0.0.1"
  DstPort = "1234"
END

#BEGIN "client1"                          # unicast example
#  DstHost = "192.168.1.2"                # destination host
#  DstPort = "1234"                       # destination port
#END

#BEGIN "client2"                          # unicast with IPv6 example
#  Domain  = "inet6"
#  DstHost = "3ffe:ffff::2:12:42"         # destination host
#  DstPort = "1234"                       # destination port
#END

#BEGIN "multicast"                        # multicast example
#  Type    = "multicast"
#  TTL     = "1"                          # Time To Live
#  DstHost = "239.2.12.42"                # multicast address
#  DstPort = "1234"                       # destination port
#END

#BEGIN "localfile"                        # file output example
#  FileName = "stream.ts"
#  Append   = "no"                        # rewrite the file if it exists
#END

# Commands automatically lanched on Startup
# Commands shall be like they would be typed in a telnet console.
BEGIN "LaunchOnStartUp"
#  command1 = "start dolby localhost local1 --loop"
#  command2 = "start 28009 client1 dvb"
"vls.cfg" [변환 되었습니다] 149L, 4543C 저장 했습니다 

 
[root@Asianux2 vls]#
[root@Asianux2 vls]#
[root@Asianux2 vls]# chkconfig --level 35 telnet on
[root@Asianux2 vls]#


[root@Asianux2 vls]# chkconfig --list | grep telnet
        telnet: 활성
        krb5-telnet:    해제
[root@Asianux2 vls]#
[root@Asianux2 vls]#
 

[root@Asianux2 vls]# cat /etc/xinetd.d/telnet
# default: on
# description: The telnet server serves telnet sessions; it uses \
#       unencrypted username/password pairs for authentication.
service telnet
{
        disable = no
        flags           = REUSE
        socket_type     = stream      
        wait            = no
        user            = root
        server          = /usr/sbin/in.telnetd
        log_on_failure  += USERID
}



[root@Asianux2 vls]# vi /etc/hosts.allow
#
# hosts.allow   This file describes the names of the hosts which are
#               allowed to use the local INET services, as decided
#               by the '/usr/sbin/tcpd' server.
#
in.telnetd : 127.0.0.1  ===========> 추가 (스니핑에 취약한 텔넷 보안을 위해 로컬만 허용)
sshd : ALL
httpd : ALL

 
[root@Asianux2 vls]#
[root@Asianux2 vls]# service xinetd restart
xinetd 를 정지함: [  확인  ]
xinetd (을)를 시작합니다: [  확인  ]
[root@Asianux2 vls]#
[root@Asianux2 vls]#


[root@Asianux2 vls]# cd ..
[root@Asianux2 videolan]# ll
합계 4
drwxr-xr-x  2 root root 4096  8월  9 11:42 vls
[root@Asianux2 videolan]# cd ..
[root@Asianux2 etc]# ll
합계 4
drwxr-xr-x  3 root root 4096  8월  9 11:38 videolan
[root@Asianux2 etc]# cd ..


[root@Asianux2 local]# pwd
/usr/local
[root@Asianux2 local]#
[root@Asianux2 local]#
[root@Asianux2 local]# cd bin
[root@Asianux2 bin]# ll
합계 1424
-rwxr-xr-x  1 root root 721970  8월  9 11:38 vls
-rwxr-xr-x  1 root root 721970  8월  9 11:38 vlsd
[root@Asianux2 bin]#


[root@Asianux2 bin]# ./vlsd
VideoLAN Server v 0.5.6 (Aug  9 2007) - (c)1999-2003 VideoLAN
[root@Asianux2 bin]#
[root@Asianux2 bin]#


[root@Asianux2 bin]# ps -ef | grep vls
root     22456     1  0 11:45 ?        00:00:00 ./vlsd
root     22459  2822  0 11:45 pts/0    00:00:00 grep vls
[root@Asianux2 bin]#
[root@Asianux2 bin]#
[root@Asianux2 bin]#
[root@Asianux2 bin]#


[root@Asianux2 bin]# telnet localhost 9001
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.

Videolan Server Administration System

Login: master
Password:

master@vls>
master@vls> help
Provider: Admin
Status: 0
Info: help: gives help on the specified command.
Info: program: configure an input with programs.
Info: logout: terminates the administration session.
Info: show: show running broadcasts, available channels, programs or inputs
Info: start: launches a program.
Info: stop: stops a program.
Info: suspend: suspends streaming.
Info: config: load and save configuration file.
Info: input: configure a new input.
Info: shutdown: stops the server.
Info: browse: gives the program list
Info: channel: configure a new channel.
Info: resume: resumes streaming.

master@vls> logout
Closing connection
Connection closed by foreign host.
[root@Asianux2 bin]#
[root@Asianux2 bin]#


다음편에는 VLS를 이용하여 실제 스트리밍 환경을 궇성하는 예를 설명하고 vls.cfg 상세 설정에 대해서 다뤄보고자 합니다.
감사합니다.