2016年3月15日 星期二

debain安裝ostube

  1. 更新來源庫
    1. echo 'deb http://www.debian-multimedia.org stable main' >> /etc/apt/sources.list
    2. wget http://debian-multimedia.org/gpgkey.pub -O - | apt-key add - && apt-get install debian-multimedia-keyring
    3. apt-get update
  2. 安裝套件
    1. apt-get install mplayer mencoder ruby php5-cli php5-gd flvtool2
    2. 測試
      mencoder -oac help (檢查一下) 
         Available codecs:
         copy     - frame copy, without re-encoding (useful for AC3)
         pcm      - uncompressed PCM audio
         mp3lame  - cbr/abr/vbr MP3 using libmp3lame (這個是重點)
         lavc     - FFmpeg audio encoder (MP2, AC3, ...)
         twolame  - Twolame MP2 audio encoder
         faac     - FAAC AAC audio encoder
      mplayer -vo help (檢查一下) 
      MPlayer 1.0rc1-4.1.2 (C) 2000-2006 MPlayer Team
      CPU: Intel(R) Pentium(R) 4 CPU 2.40GHz (Family: 15, Model: 2, Stepping: 5)
      CPUflags:  MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
      Available video output drivers:
              xv      X11/Xv
              x11     X11 ( XImage/Shm )
              xover   General X11 driver for overlay capable video output drivers
              gl      X11 (OpenGL)
              gl2     X11 (OpenGL) - multiple textures version
              dga     DGA ( Direct Graphic Access V2.0 )
              sdl     SDL YUV/RGB/BGR renderer (SDL v1.1.7+ only!)
              svga    SVGAlib
              aa      AAlib
              caca    libcaca
              directfb        Direct Framebuffer Device
              dfbmga  DirectFB / Matrox G200/G400/G450/G550
              xvidix  X11 (VIDIX)
              cvidix  console VIDIX
              null    Null video output
              xvmc    XVideo Motion Compensation
              mpegpes Mpeg-PES to DVB card
              yuv4mpeg        yuv4mpeg output for mjpegtools
              png     PNG file
              jpeg    JPEG file
              gif89a  animated GIF output
              tga     Targa output
              pnm     PPM/PGM/PGMYUV file
              md5sum  md5sum of each frame
  3. 安裝ostube22中文版
    1. chown -R www-data.www-data ostube22
    2. cd ostube22/cgi-bin
      1. vi ostube22/cgi-bin/uu_default_config.pm
        upload_dir               => $ENV{'DOCUMENT_ROOT'} . '/ostube22/media/tmp/',/tmp/',redirect_url             => 'http://' . $ENV{'SERVER_NAME'} . '/ostube22/upload.php',/upload.php',path_to_upload           => 'http://'. $ENV{'SERVER_NAME'} . '/ostube22/uploads/',
      2. cp * /usr/lib/cgi-bin/
  4. vim /etc/php5/apache2/php.ini
    max_execution_time = 300
    max_input_time = 600
    memory_limit = 160M
    post_max_size = 100M
    upload_max_filesize = 80M
    error_reporting = E_ALL & ~E_NOTICE
  5. 測試