2017年2月27日 星期一

TurnKey: node.js

node.js can be easily deployed by TurnKey. we don't need to worry about the complicated environment setup. Only need to focus on the app configuration itself. For example:

# git clone https://github.com/myproject/project.git
# npm install
# grunt serve
# vi ./node_modules/getobject/Gruntfile.js
# grunt serve

2017年2月26日 星期日

NDI: Windows & Linux solutions

Free NDI windows solutions including vlc plugin are officially supported by NewTek itself, as below. It can be used as user side workstation solution.

http://tips.newtek.com/vlc-media-player-and-newtek-ndi-vlc-plugin/

Therefore playlist playback may be directly done via VLC. NDI works as a output device for VLC.

mlt has a NDI module for both consumer and producer in the latest version, which could be used as server side solution. However, build script cannot include this module due to NDI SDK require. Latest Ubuntu LTS versions may run the build scripts without problem.

2017年2月25日 星期六

FTP over SSL

REF: http://www.proftpd.org/docs/howto/TLS.html

RFC 4217 defines FTP over SSL/TLS:
  http://www.faqs.org/rfcs/rfc4217.html
The mod_tls module for proftpd is an implementation of RFC 4217.
RFC 2228 defines FTP Security Extensions, of which mod_tls is one implementation. Another such RFC 2228 implementation is the mod_gssmodule, available from SourceForge.
Example mod_tls configuration:
  
    # If mod_tls was built as a shared/DSO module, load it
    LoadModule mod_tls.c
  

2017年2月24日 星期五

NDI: VLC plugin

REF: http://tips.newtek.com/vlc-media-player-and-newtek-ndi-vlc-plugin/

When the NDI Video Monitor is running, right-click on the UI to get the selection list of NDI sources that are on the network. Your VLC stream will be showing as one of these.  Select it.
Click to enlarge.
Click to enlarge.
Now you should see the video that VLC is playing in the NDI Video Monitor window.
Click to enlarge.
Click to enlarge.
Learn More about NewTek NDI.

2017年2月23日 星期四

Check_MK: virtual hosts

There're plugins for Nagios / Check_MK to monitor virtual hosts such as ESX or PVE. for example, running VMs as well as their CPU and RAM usage could be checked via the official scripts from proxmox:

Client-Check

/usr/lib/check_mk_agent/plugins/mh_qemu

Plugin

/omd/versions/0.44/share/check_mk/checks/qemu

REF: https://pve.proxmox.com/wiki/Nagios_check_mk


2017年2月22日 星期三

TriCaster: web automation

TriCaster can record your Live News. The automation of web videos can be set as following:

  • Use NLE software for finding proper timecode.
  • split software for cutting the recorded file to single news videos, according to the timecodes. 
  • export metadata like title, description of the news videos from NRCS.
  • comp software to insert the metadata to web server and upload video files.

Android: PC in then new era

Android devices are the new PC in the past ten years. We can disassemble them like PC although harder: case, motherboard, wires, battery, power, etc. We may be able to replace battery, fix power button if needed. Interesting :)

REF: https://www.youtube.com/watch?v=doPuXkQTGbc

2017年2月20日 星期一

bacula for backup

bacula has a pretty good infra for backup: client for pulling files, storage for keeping backup, and director for job control.

REF: https://www.digitalocean.com/community/tutorials/how-to-configure-remote-backups-using-bacula-in-an-ubuntu-12-04-vps

Bacula - How To Install Bacula Backups + Postgresql on CentOS 5 

2017年2月19日 星期日

TriCaster: NDI integrated, etc

  • Multiple ME. Many layers comp in one ME.
  • 2+ DDR for video playback. 
  • video recorder, based on the number of HDD you have. Even USB-plugged.

2017年2月18日 星期六

graphite: easy metrics

Graphite, or Grafana, is a good tool for developers to generate beautiful graphs for metrics easily. Compared with other MIS-oriented tools, it may be more flexible for customized inputs for specified application development. Nagios or Zabbix may still be better choice for standard checks such as SNMP or agent inputs.   


REF: 
http://graphite.readthedocs.io/en/latest/tools.html

2017年2月17日 星期五

TriCaster: IP based, all in one

TriCaster from NewTek can be viewed as a all-in-one, IP based broadcast solution, In addition to video switcher, it also acts as playout, CG, recorder. MOS is also supported. video streaming such as webcast, NDI is supported.

2017年2月16日 星期四

Syslog: graylog for dashboards

Graylog is a pretty easy-to-use search & dashboard system. if we need to collect lots of data with rather simple dashboards and user management, it's enough for this purpose. setup of appliance is also easy. remote logging from syslog is enabled by default. Advanced analysis still requires Splunk.

2017年2月15日 星期三

Syslog: logger xferlog

xferlog can be filtered then written into syslog with the utility 'logger'. Here's a script with check_log style. Column 8 and 15 is the ip / id pair:

xferlog=/var/log/proftpd/xferlog

if [ ! -f ${xferlog}.old ]; then
 cp $xferlog ${xferlog}.old
fi

diff $xferlog ${xferlog}.old | grep "<" | awk '{print $8 " " $15}' | while read LINE
do
logger $LINE
done

rm -rf ${xferlog}.old
cp $xferlog ${xferlog}.old

2017年2月14日 星期二

ffmpeg: chapters & subtitles

ffmpeg can remove embedded chapters or subtitles in a file, as below.

# ffmpeg -y -i input.mov -i input.wav -f mov -sn -vcodec dvvideo -r 29.97 -s 720x480 -aspect 16:9 -pix_fmt yuv411p -acodec copy -map_chapters -1 -map 0:v:0 -map 1:a:0 outputwithwav.mov

VPN for Windows

It's not easy to determine the best VPN for Windows, except those on Windows servers. The most stable one is PPTP but it's really out-dated.  

L2TP/IPsec such as npppd may not work properly on newest Windows. Embedded routers may still work.

OpenVPN may be a more universal across platforms. Noted that Mac, iOS, Android does not need the 'dev tun' line, while Windows or Linux/BSD required. Windows especially needs the 'dev tun' or 'dev tap' exactly the same with that on server! Otherwise WARNING occurs in log and ip cannot be fetched. Keep on waiting TUN/TAP interface...

2017年2月12日 星期日

NewTek MediaDS

Sooo cool buddy to use in IP-based broadcast environment. Wowza integraded x4. Good solution for OTT.

2017年2月11日 星期六

Projector maintenece

一台將近三萬元,換燈泡就要八千多,過熱當機也可能是風扇問題。燈泡只保固一年。或是改用不用換燈泡的機種,開機快,又不會很熱。

http://www.mobile01.com/newsdetail/17507/casio-xj-v1

都是要經驗才能選到CP不錯的。這樣我們學到:保固條件很重要,耗材成本要先問。就是賣印表機賺碳粉的概念。這種物件應該是算使用時數消耗的,若看很多也是物超所值啦。

2017年2月10日 星期五

Cron for Windows

Using cygwin for running cron on Windows may be an method. But if we only run simple exe for example for NSCA alerts on Windows, Task Scheduler would be a better option.

REF:
http://stackoverflow.com/questions/707184/how-do-you-run-a-crontab-in-cygwin-on-windows#707220

Check_MK: Downtime setup

Downtime setup can be processed during event alerts. for example 'Event of service XX, YY host'. Then the orange alerts on main page will disappear temporarily according to the time period. Another way is to 'Acknowledge' the alert, and it will vanish from the 'Unhandled' orange alert but service alert stays.

2017年2月8日 星期三

KVM: clock drift

Full virtualization such as Linux KVM, VMware has serious clock drift issue. If we need pretty accurate precision like TV broadcast scheduling, hardware clock is required. Therefore, container virtualization could be chosen.

REF: https://access.redhat.com/solutions/27865

2017年2月7日 星期二

HDD selection

2TB ($2999) vs. 4TB ($4888) for video storage:若都是WD My Passport,我看只有總容量差別,性能差不多。4TB的「每TB性價比」當然比較好一點點 (4888/4 < 2999/2 ),但4888總價比較高。

若照原本1TB可以用個好幾年,選2TB用個三年應該比較合算,4TB可能用不完,尤其影片壓縮技術越來越好,空間需求不會變大。

Check_MK: mkeventd err

If you have enabled Event Console but sometimes receive errors on distributed sites about 'mkeventd:...contact group not found', just goto Global settings then disable notification to Event Console group. Save and apply but error again, then enable it again. ALL done. Seems like just a bug.

2017年2月5日 星期日

HDD inspection

遇過硬碟只看到裡面的檔案名稱,檔案無法開啟,可能是檔案系統或硬體有問題了。
  • 硬體面:請先使用硬碟官方工具檢測,或升級硬碟韌體。例如WD硬碟,WD utility的基本檢查過了,接下來深層檢查用Mac自帶工具,就需要先format掉,再讓Mac的磁碟工具查,看新的filesystem是否ok。若通過,WD complete 再試跑一次,再關機->拔掉->開機->插回。
  • 軟體面:格式化檔案系統。

REF: As an alternative, you can run the test from the Disk Utility. It is a test similar to ours and should give you a proper response since it will suspend built in services on the computer to run the test. I will include the web link for this.

2017年2月4日 星期六

Check_MK: Discovery & Alerts

許多monitoring solution沒有auto discovery與專門的alert engine,設定起來會花些時間。

針對不同開發專案,Nagios based 如 Check_MK 可直接設定一個distributor site給這個project用,大概兩個小時。每台server裝個agent大概五分鐘,可以auto discovery本機十幾二十個左右的常見matrix如CPU, memory之類的,特別的服務才需要寫script.

alert policy可針對services, host, contact group分別定義,其實大家都很忙,除MIS之外,其他人大概只會看alert。

REF: http://mathias-kettner.com/check_mk_multisite_screenshots.html

2017年2月3日 星期五

Check_MK: Event Console

Event Console MUST be enabled in 'omd config' before any 'proactive' actions can be set as response for service alerts. The EC config button will appear in WATO then. Action can be set in its setting following the official reference 'Integration with Nagios; 'step-by-step, playing as a role of event handler.

REF: https://mathias-kettner.de/checkmk_mkeventd.html

2017年2月2日 星期四

AnyDesk remote support

AnyDesk is also a free remote support solution similar with Teamviewer.

2017年2月1日 星期三

node.js

Setting up an unfamiliar environment, such as node.js, may require spending quite some time. If we use PaaS deployment procedure, it would be much easier. First get the packed App from vendors like TurnKey, then boot it up in your PaaS. Necessary dependencies should already done in the pre-built app.

Finally, 'git clone' some example project source, and 'npm install' specific dependencies with the node package manager.