commands: traceroute

Linux 2015. 10. 21. 10:16

UDP traceroute:

 

traceroute 125.152.0.117 -s 220.75.130.5 -p 5160 -U

Posted by yongary
,

SIP stack

IMS 2015. 10. 15. 10:27

SIP stack is process&Library for dealing with SIP.(Sessin Initiation Protocol)

 

Open Source SIP Stack for JAVA:

 -

1) PJSIP-JNI  which is java bindings for the C PJSIP library

2) JAIN-SIP  http://users.cis.fiu.edu/~ege/JAIN/

    https://github.com/Mobicents/jain-sip 

    https://jsip.ci.cloudbees.com/job/jsip/javadoc/ 

    http://www.oracle.com/technetwork/java/introduction-jain-sip-090386.html      (Oracle introduction)

    https://developer.opencloud.com/devportal/devportal/apis/jainsip/1.1/docs/index.html 

    http://www.worldlibrary.org/articles/mobicents 

    http://www.mobicents.org/products.html 

 

    RFC 3261 functionality and the following SIP extensions; the INFO method (RFC 2976), Reliability of provisional responses (RFC 3262), Event Notification Framework (RFC 3265), the UPDATE method (RFC 3311), the Reason Header (RFC 3326), the Message method (RFC 3428) defined for instant messaging and the REFER method (RFC 3515), Distributing Authoritative Name Servers via Shared Unicast Addresses (RFC 3581), the PUBLISH method (RFC3903).

   SDP API(JSR 141) is property of Dynamic Soft. => under JCP License

 

3) MjSip        http://www.mjsip.org

4) javaforce   http://sourceforge.net/projects/javaforce/

5) jSIP          http://jsip.java.net  http://jsip.sourceforge.net/

6) openjsip    http://code.google.com/p/openjsip/

 

 

 

SIP Stack for C

1) reSIPRocate    http://www.resiprocate.org, http://svn.resiprocate.org/dox/ 

 

 

2) Spirent IMS SIP stack = Radvision SIP Stack.   REF-SITE

   - (Avaya m&a Radvision(2012),   spirent m&a Radvision Tech Biz Unit(2014) )

 

  • P-headers: private SIP headers for IMS
  • IPv6 support: the mandatory IMS transportation level
  • Signaling compression: mandatory IMS request for signaling between UE and P-CSCF
  • Support for IM URI, PRES URI, and TEL URI
  • ENUM: translation between phone numbers or TEL URI to SIP URI
  • Support for different event packages, such as presence, reg-event
  • Support for instant messaging (IM)
  • HTTP DIGEST using 3GPP AKA Authentication -"AKAv1-MD5"
  • IPsec: IP security
  • Security agreement negotiation, as defined in RFC 3329
  • Support for mobile registration using Service-route and Path headers
  •  

    Posted by yongary
    ,

    maven

    java core 2015. 10. 15. 09:10

    maven is project management tool for  autobuild & dependency management.


    INSTALL: just download and unzip.  add bin path to $PATH.


    RUN:  $mvn archetype:generate

    => defalt select.

    => groupID,package..etc:  com.ky

    $cd com.ky

    $mvn compile exec:java -Dexec.mainClass=com.ky.App


    Posted by yongary
    ,

    mongoDB

    mongoDB, redis 2015. 10. 13. 22:14

    Functionality vs scalability&performance :

      -mongoDB achievs both. But missing some functionality because of scalibility&performance.


    Not exists in mongoDB:

     -Join, transaction., schema, SQL


    Exists in mongoDB:

      Index, secondary Index



    Command:

      db

      show tables

      db.things.find ().pretty()

      db.things.insert (..json..)  or .save(json)


    SchemaLess example:

    > db.user.insert( {name:"kim"})

    > db.user.insert( {name:"lee", age:11} )

    > var j = db.user.findOne( {name:"kim"} )

    > j.age = 11

    > db.user.save(j)



    Posted by yongary
    ,

    Actor & Future

    scala 2015. 10. 12. 23:31

    Actor is Thread+Queue, while

    Future provide a way to reason about performing many operations in paralle


       http://la-stranger.tistory.com/m/post/entry/Scala-Future-Tutorial

    Posted by yongary
    ,

    linux에서 c로 개발한 후, 코드를 검사하는 방법 몇가지.. 

     

     

    ValgrindREF-SITE

     - 메모리 오류 체크, 메모리 leak 체크.

       특히 메모리 오류가 가장 짜증나는 부분인데 이런 부분을 제법 잡아주므로 꼭 돌릴 필요가 있다.

     

    - 사용법:

    $gcc test.c -o app_test

    $valgrind --leak-check=yes ./app_test

        

     

    CppCheck   http://cppcheck.sourceforge.net/

    -  Linux버전도 있고, pc버전도 있으며, 파일 단위나 폴더단위로 소스를 검사.

       메모리 누수/배열 범위/멀티 Thread 등이 check됨.

     

     

     

    gcov REF-SITE

    - 사용(혹은 TEST) 이 안되고 있는 코드 체크, 코드별 실행 횟수 및 %가 나온다.

     

    - 사용법:

      $gcc -fprofile-arcs -ftest-coverage tmp.c
      $./a.out
      $gcov tmp.c

     

     

    gprof

    - 코드 성능 분석

    Posted by yongary
    ,

    SIP & IMS

    IMS 2015. 10. 6. 14:04

    SIP is protocol like HTTP. while

    IMS is telco System Architecture which uses SIP.

     

     

    <SIP History>


    1998년에 H.323 이 나오고  -( 최초로 RTP사용.)

    1999년에 SIP가 나오면서 혼용되다가,  2008년경부터 본격 사용됨.
        -SIP는 1996년에 나온 HTTP1.0을 차용하여 Text-based로 정의.


    2002년 RFC3261.


    2012년에 8월(skt,lgt) 12월(kt) VoLTE 최초 상용화.




    <IMS>

    - 3G에서부터 HLR, 통화 등을 수용하기 위한 텔코의 시스템 구조로 발전.

          UNI: user to Network Interface (단말과 망 사이)

          NBI : North Border (AS 경계)

          NNI : Network to Network ( 타이통사간 경계)


    - IFC Chaining을 통해서 호가 흘러가는 구조 임.(IFC를 S-CSCF가 HSS로부터 받아오는 게 핵심.)

     

    - PSI 는 최종 서비스 혹은 trigger의 경우 최종 서비스로 바로가는 방법.  

      즉,IFC 는 체이닝이 되어야 효과를 발생하는 과정이고 차이가 큼..


    -  ISC (IMS Service Control )Reference Point 임. 여기서 IFC가 처리됨.


     

    Posted by yongary
    ,

    Ant 자동빌드

    java core 2015. 10. 1. 14:40

    Eclipse에서 프로젝트를 하나 골라서

    -> Export  ->  General 밑에 Ant Buildfiles 로 하면  build.xml 이 생성된다.

     

    Windows -> Show View메뉴에서 -> Ant를 고르면 우측에 Ant 작업창이 뜨고,

    그곳으로 build.xml을 drag하면 build.xml로 빌드가 가능하다

     

     

    장점: jenkins와 연동한 자동 build가 가능하다.  

    Jenkins연동 시에  Build->Add Build Step ->Invoke Ant.

    Posted by yongary
    ,

    Git

    IT 2015. 10. 1. 11:27

    SVN의 단점을 극복한 Git, 리누스 토발즈가 만들어서 더욱 유명하다.

    특히 github.com 서버에서 git을 이용한 무료소스관리를 해주므로 무수한 사용자들이 사용하고 있다.

     

    개인적으로 느낀 git의 가장 큰 장점은

    local 커밋이 가능하다는 점이다. 즉 비행기를 타고 가는 중에도 커밋이 가능하다.

     

    개발자로서 자주 커밋하는 것이 안전하다는 것을 항상 느끼는데,

    수십명이 사용하는 서버에 한줄 고치고 커밋하는 걸 여러번 하면 형상관리가 지저분해지는 단점이 있었는데

    git을 이용하면 로컬 커밋을 자주하다가, 서버에는 push로 올리면 된다.

     

     

     

    http://git-scm.com/book/ko : 공식매뉴얼




    Git 기본 사용법 :

      git config --list

     

      git config --global use.name "myName"

      git config --global user.email my@Email

      git config --global core.editor vim

      git config --global merge.tool vimdiff

     

      git init

      git add <a.c>

      git commit -m 'test'

    git remote add origin gitURL(like github)

      git push -u origin master

     

     

     

    Windows용 git도 있다.  http://www.git-scm.com/downloads  에서 다운로드 가능.

     

    설치해서 icon만 고르면,  minGW의 bash쉘에서 git이 실행이 된다.
    (컴퓨터 이름이 한글일때 prompt가 깨지는 현상이 있음:  Administrator@ㅁㅁㅁ ~$  이렇게 되네요)

     

     

    tip: 한글설정: git config --global core.quotepath false

    이쁘게: .bashrc에 alias ls='ls -al --color=auto --show-conftrol-chars'

     

    Posted by yongary
    ,

    SOAP

    IT 2015. 9. 30. 13:47

    REST가 대세이긴 하지만, 이전 시스템들을 위해 SOAP을 알아둘 필요가 있다.

    REF-SITE



    SOAP(Simple Object Access Protocol)은 HTTP/SMTP 상에서 XML기반 메시지를 교환하는 프로토콜 이다.


    SOAP에서는 SOAP Envelope과 SOAP BODY 를 주로 이용한다.

       -> SOAP BODY에   <Price>$4.0</Price> 와 같이 전달.



    SOAP외에,  WSDL 로 웹서비스가 정의 되기 때문에 WSDL 을 이해하여야 한다.



    WSDL(Web Services Description Language)

       <portType>의  <operation>  메서드 선언 </operation>   : What 정의

        <service>의   <port> 웹서비스 URL </port>   : How&Where  즉 서비스의 EndPoint 정의.



    그리고 실제 구현하면서 JAXB 와 같이 JAVA <-> XML 마샬링 툴등을 이용하게 된다.





    JSON이 대세인데,  SOAP을 보고 있으니 답답하다는 생각이 들긴한다.

    mongoDB + Angular.js 를 이용해 JSON 을 이용해서 REST방식으로 구현하길 권장한다.



    Posted by yongary
    ,