16 tháng 2, 2012

Compiling and install Darwin Streaming Server on Ubuntu 10.x

Quick tutorial for installing DSS on Ubuntu 8.04.1 64bit (x86_64).

Most of these details can be found here: http://dss.macosforge.org/trac/ticket/6

Hopefully they will integrate these patches in to the next release, but until then here are the build instructions for Ubuntu:

Download DSS 6.0.3: http://static.macosforge.org/dss/downloads/DarwinStreamingSrvr6.0.3-Source.tar

Download this patch: http://dss.macosforge.org/trac/raw-attachment/ticket/6/dss-6.0.3.patch (Thank you Sverker Abrahamsson!)

And this patch: http://dss.macosforge.org/trac/raw-attachment/ticket/6/dss-hh-20080728-1.patch

Finally get the modified Install script: http://dss.macosforge.org/trac/raw-attachment/ticket/6/Install

The basic process is:

1. Get the build dependencies from the repositories.
2. Set up the qtss user (this is because the Install script does it in a way that is incompatible with Ubuntu)
3. Extract the source code.
4. Apply both patches.
5. Replace the Install script and chmod +x it.
6. Compile.
7. Install.

Notably for ssl admin you need the openssl and libnet-ssleay-perl packages, unfortunately even with these packages I was unable to get ssl admin to work.

I created the modified Install script; you can do a diff with the original if you want to see what I changed. Mostly just the paths were broken, but I am guessing that some other modules and such will probably not work.

You can create script file like below or input command step by step:
#!/bin/bash
# install build-essential, wget and patch
sudo apt-get install build-essential wget patch
sudo addgroup --system qtss
sudo adduser --system --no-create-home --ingroup qtss qtss

#download DarwinStreamingSrvr6.0.3-Source.tar from macosforge
wget http://static.macosforge.org/dss/downloads/DarwinStreamingSrvr6.0.3-Source.tar

#extract tar file
tar -xvf DarwinStreamingSrvr6.0.3-Source.tar

#rename
sudo mv DarwinStreamingSrvr6.0.3-Source DarwinStreamingSrvr6.0.3-Source.orig

#download patch file
wget http://dss.macosforge.org/trac/raw-attachment/ticket/6/dss-6.0.3.patch

#run patch file
sudo patch -p0 < dss-6.0.3.patch
sudo mv DarwinStreamingSrvr6.0.3-Source.orig DarwinStreamingSrvr6.0.3-Source
wget http://dss.macosforge.org/trac/raw-attachment/ticket/6/dss-hh-20080728-1.patch
sudo patch -p0 < dss-hh-20080728-1.patch

#need to answer n then y
cd DarwinStreamingSrvr6.0.3-Source
sudo mv Install Install.orig
wget http://dss.macosforge.org/trac/raw-attachment/ticket/6/Install
chmod +x Install

# compile
sudo ./Buildit

# and install
Sudo ./Install


wget http://dss.macosforge.org/trac/raw-attachment/ticket/6/darwin-streaming-server
chmod +x darwin-streaming-server
sudo cp darwin-streaming-server /etc/init.d/darwin-streaming-server
sudo update-rc.d darwin-streaming-server defaults


after installing you can use this command to check it
ps -Af | grep -i stream
and
netstat -taunp | grep Darwin
check port and kill program:
killall "program name"
kill "ps name"
fuser -k -n tcp "number port"

/usr/local/sbin/Darwin Streaming Server ---- Server Software
/usr/local/sbin/streamingadminserver.pl ---- Web Frontend
/etc/streaming ---- Configuration Dir
/etc/streaming/streamingserver.xml ---- Configuration File Server
/var/streaming/logs ---- Logs
/usr/local/movies ---- Default directory for video files


if DarwinStreamingServer can not start you can download this below part and install again.
http://ppa.launchpad.net/rzr/ubuntu/pool/main/d/dss/dss_6.0.3-0ubuntu0~rzr8_i386.deb
or
http://ppa.launchpad.net/rzr/ubuntu/pool/main/d/dss/
enjoy it!
run Darwin Streaming Server on windows
http://www.iupui.edu/~nmstream/live/howtoquicktime.html
it's Okie on ubuntu v11.10.
-->đọc tiếp...

15 tháng 2, 2012

Cách remove drm trong Calibre với MobiDRM plugin

Nếu bạn nào dùng Calibre để quản lý ebook, nhiều khi muốn convert prc sang các định dạng khác thường thấy thông báo lỗi DRM. Sau 1 hồi tìm tòi, mình thấy cách kết hợp MobiDRM vào Calibre plugin khá thuận tiện. Nhưng do nó chỉ remove drm khi add book, mình đã sửa đi để nó support remove drm trước khi convert. (Nếu phải add lại đống sách prc thì chắc teo mất)

Cách thực hiện như sau (đã test chạy ngon lành trên Windows 7, calibre 0.7.10):
1. Cài python (hiện mình dùng python 2.7) và wxpython for python 2.7
Link download
http://www.python.org/download/
http://www.wxpython.org/download.php

2. Thiết lập biến môi trường
My computer - Properties - Advanced system configuration
Environment Variables

Thêm biến name = PYTHONPATH, value = %PYTHONPATH%;C:\Python27\libs

Sửa biến PATH, thêm C:\Python27

3. Download plugin
http://www.mediafire.com/?bnze783alah7xqe

4. Mở Calibre, vào Preferences, đến mục Plugins
Ở phần Add new plugin, chọn file đến file zip vừa down, sau đó Add

5. Cài MobiReader, sau đó chạy, mở Help, About, lấy PID
Mở Calibre, đến Plugins trong Preferences
File type plugins - click MobilDRMConversion, Customize plugin, gõ PID lấy ở trên vào.

6. Done.
-->đọc tiếp...

Vào facebook bằng chỉnh sửa file hosts

Với mạng VNPT hoặc Viettel:
125.252.224.88 facebook.com
125.252.224.88 www.facebook.com
69.63.181.12 apps.facebook.com
69.63.187.16 facebook.com
69.63.181.22 login.facebook.com
69.63.186.12 apps.facebook.com
69.63.187.16 www.facebook.com
69.63.181.22 www.login.facebook.com
153.16.15.71 www.facebook.com
153.16.15.71 www.logins.facebook.com
153.16.15.71 facebook.com
153.16.15.71 logins.facebook.com
153.16.15.71 apps.facebook.com
153.16.15.71 upload.facebook.com
153.16.15.71 www.connect.facebook.com
153.16.15.71 graph.facebook.com
153.16.15.71 static.ak.connect.facebook.com
153.16.15.71 developers.facebook.com
153.16.15.71 error.facebook.com
96.17.180.162 channel.facebook.com
96.17.180.162 upload.facebook.com
96.17.180.162 register.facebook.com
96.17.180.162 bigzipfiles.facebook.com
96.17.180.162 pixel.facebook.com
96.17.180.162 upload.facebook.com
96.17.180.162 register.facebook.com
96.17.180.162 bigzipfiles.facebook.com
96.17.180.162 pixel.facebook.com
Với mạng FPT:
60.254.175.42 facebook.com
60.254.175.42 www.facebook.com
60.254.175.42 register.facebook.com
60.254.175.42 www.logins.facebook.com
60.254.175.42 blog.facebook.com
60.254.175.42 logins.facebook.com
60.254.175.42 login.facebook.com
60.254.175.42 apps.facebook.com
153.16.15.71 upload.facebook.com
60.254.175.42 graph.facebook.com
60.254.175.42 profile.ak.fbcdn.net
60.254.175.42 photos-a.ak.fbcdn.net
60.254.175.42 photos-b.ak.fbcdn.net
60.254.175.42 photos-c.ak.fbcdn.net
60.254.175.42 photos-d.ak.fbcdn.net
60.254.175.42 photos-e.ak.fbcdn.net
60.254.175.42 photos-f.ak.fbcdn.net
60.254.175.42 photos-g.ak.fbcdn.net
60.254.175.42 photos-h.ak.fbcdn.net
60.254.175.42 static.ak.connect.facebook.com
60.254.175.42 static.ak.fbcdn.net
60.254.175.42 b.static.ak.fbcdn.net
60.254.175.42 error.facebook.com
60.254.175.42 developers.facebook.com
60.254.175.42 pixel.facebook.com
60.254.175.42 api.facebook.com
60.254.175.42 chanel.facebook.com
60.254.175.42 0.50.chanel.facebook.com
60.254.175.42 external.ak.fbcdn.net
60.254.175.42 profile.ak.fbcdn.net
60.254.175.42 creative.ak.fbcdn.net
60.254.175.42 chat.facebook.com
60.254.175.42 vupload.facebook.com
60.254.175.42 secure.facebook.com
60.254.175.42 connect.facebook.com
60.254.175.42 channel.facebook.com 
60.254.175.42 connect.facebook.net
-->đọc tiếp...
BlogWeb: tạo từ Blog của Google
Nội dung: lấy từ nhiều Nguồn khác nhau.
Mục đích: note lại bài Hướng dẫn hay và Đáng đọc.
Kết quả: nghiện Internet Nặng.
Tương lại: xuống lỗ Vẫn Nghiện nếu không có ai giúp.
Blog Web của: Trí Dũng đến từ Việt Nam - Liên kết đến trang Blog Cá Nhân
Tôi biết (^_^)
Thông tin về Tác giả. Chi Tiết
Sử dụng (FireFox | Google Chrome on Ubuntu) để xem tốt nhất. Học Nhiều Hơn Tại Đây
©2009 Google Blogger - HuuNguyen's Home