Backup diff of Linux/NX Client(No. 2)


  • The added line is THIS COLOR.
  • The deleted line is THIS COLOR.
[[Linux]]

$ cat ~/.bash_profile
if [ -f ~/.bashrc ] ; then
. ~/.bashrc
fi
* Mac上でNX Client(OpenNX)を使う方法 [#d94f1185]

ターミナル起動時にgatewayやSSHトンネルなどの手順を書いた.bashrcを読み込ませるためには,

 $ cat ~/.bash_profile
 if [ -f ~/.bashrc ] ; then
 . ~/.bashrc
 fi

とすればよい..bashrcのサンプルは,

 # make permission of newly created file 644
 umask 022
 
 # prohibit to generate core damp
 ulimit -c 0
 
 # force to use "less" for "man" etc.
 export PAGER=less
 
 # put % and line number in "less"
 export LESS='-X -i -P ?f%f:(stdin).  ?lb%lb?L/%L..  [?eEOF:?pb%pb\%..]'
 
 # aliases
 alias cd..="cd .."
 alias l="ls -al"
 alias lp="ls -p"
 alias la="ls -al"
 alias ll="ls -alrt"
 alias h=history
 
 # appearance of prompt
 PS1='\u@\h:\w \! \$ '
 
 #-----#
 # X11 #
 #-----#
 export DISPLAY=:0.0
 PATH=${PATH}:/usr/X11R6/bin
 
 # remote servers
 alias gatex="ssh -X -i /Users/hoge/.ssh/hoge_id_rsa -L 8888:remoteserver.hoge.ac.jp:22 hoge@gate.hoge.ac.jp"
 alias umi="ssh -X hoge@hoge.ac.jp"

のような感じ.
Mac OS 10.7以降ではNoMachine NX Clientが使えないが,OpenNX Clientは問題なく動作する.

 http://opennx.net/

をインストールする.設定方法は例えば,

 http://help.nceas.ucsb.edu/Remote_Access_using_OpenNX

などを参考にすればよい.