09/24: Linux > SSH マニュアル
ssh_config
ServerAliveInterval (サーバ生存確認の間隔)
ServerAliveInterval (サーバ生存確認の間隔)
09/24: Linux > SSH
keep-alive for ssh"Heartbeat 300"
How To Tile Windows In Gnome the ubuntu guy
wmtile
# Login as root and browse to /usr/share/tile/
# Open the rc file in gedit
# Change the second option to read “multi-desktop netwm”
wmtile
# Login as root and browse to /usr/share/tile/
# Open the rc file in gedit
# Change the second option to read “multi-desktop netwm”
How to install Adobe PDF Reader with Plug-in for Mozilla Firefox in Feisty Fawn -- Ubuntu Geek
sudo apt-get install acroread mozilla-acroread acroread-plugins
sudo apt-get install acroread mozilla-acroread acroread-plugins
09/21: Linux > SVN GUI client
deb http://archive.ubuntulinux.jp/ubuntu-ja gutsy/ deb-src http://archive.ubuntulinux.jp/ubuntu-ja gutsy/ deb http://archive.ubuntulinux.jp/ubuntu-ja gutsy-ja/ deb-src http://archive.ubuntulinux.jp/ubuntu-ja gutsy-ja/
Linux&BSD:導入メモ:Ubuntu 7.40
Japanese Input and Fonts in Ubuntu 7.10
Japanese_Input_and_Fonts_in_Ubuntu_8.04_using_SCIM
Japanese Input and Fonts in Ubuntu 7.10
Japanese_Input_and_Fonts_in_Ubuntu_8.04_using_SCIM
09/11: Linux > SSHFS
% printenv | less
UNIX Tutorial Eight
UNIX Tutorial Eight
* OSTYPE (OS type) * USER (your login name) * HOME (the path name of your home directory) * HOST (the name of the computer you are using) * ARCH (the architecture of the computers processor) * DISPLAY (the name of the computer screen to display X windows) * PRINTER (the default printer to send print jobs) * PATH (the directories the shell should search to find a command)
09/10: Linux > UNIX Tutorial Four
UNIX Tutorial Four
$ apropos keyword
Arnolds wor(l)ds Eclipse problems solved (finally)
Install the SUN Java (at least 5.0) $ sudo update-java-alternatives -s java-1.x.x-sun $ eclipse -vm /usr/lib/jvm/java-1.x.x-sun/jre/bin/java * you might need to use sudo to create some files at the first time.
09/10: Linux > SSH
ITmedia エンタープライズ : Linux Tips「SSHのログイン制限を確認しよう」
PermitRootLogin no PermitEmptyPasswords no PasswordAuthentication no AllowUsers hoge CheckHostIP yes
FreeNX - Community Ubuntu Documentation
$ gksudo gedit /etc/apt/sources.list deb http://free.linux.hp.com/~brett/seveas/freenx feisty-seveas freenx deb-src http://free.linux.hp.com/~brett/seveas/freenx feisty-seveas freenx $ wget http://free.linux.hp.com/~brett/seveas/freenx/seveas.gpg -O- | sudo apt-key add - $ sudo apt-get update $ sudo aptitude install freenx $ sudo nxserver --adduser username $ sudo nxserver --passwd username $ sudo nxserver --restart
09/06: Linux > システムをチェックする際のコマンド
cat /var/log/messages | less <<< all the system message
cat /var/log/boot.log | less <<< boot log
dmesg -n 1 <<< all panic message at boot time by rc.sysinit
/proc システムの状態
procinfo /procのサマリー表示
vmstat 秒数 メモリやディスクの利用状況
last ログインしたユーザの履歴
w 現在ログインしているユーザ
lastlog show login info by user
top プロセスの監視
ps aux 実行中のプログラム eg. ps aux | grep service
ps axo user,pid,ppid,tty,start,time,command | grep agent | grep -v grep
ps -ef 実行中のプログラム
ps f -a hierarchical view of the parent-child relationships
ps -l shows more detailed information
pstree
uptime CPUの負荷をチェック
netstat -an 通信の調査
lsof オープンファイルの確認
lsof -i -n オープンポートとプロセスの対応を確認
lsof -i:22 -n 指定した番号のポートをオープンしているプロセスの確認
lsof -u(ログイン名orID) ログイン名 or ユーザーIDを指定
find / -type f \( -perm -u+s -o -perm -g+s \) -ls 不審なファイルのチェック
find / -type f -perm -04000 -ls 不審なファイル(SUID)のチェック
find / -perm +6000 -exec ls -l {} \; SUID or SGID
du カレントフォルダ内の使用量
(eg. du -ha /home | grep '^[0-9]\{3,\}M': find more than 100MB in home)
df ディスクの状態
(eg. df -i: check inode usage, df -l: check local filesystems only)
hdparm -ft /dev/sda1 sda1にベンチマークテスト
dumpe2fs -h Show the file system parameters
fsck デバイス(HDD)のチェック(使用前にはumountが必須、設定を変更するには tune2fs)
-A: All file system
-C: Progress bars
-N: Dry run
-V: Verbose output
-a Noninteractive
makebootdisk [kernel version] <<< uname -r
fdisk -l <<< To see /dev info
pnpdump <<< viwe isa p&p
file <<< determin file type
# file tree*.rpm <<< check RPM’s architecture
# file /etc/* | grep empty <<< find all the empty file
# uname -a Linuxのバージョンチェック
# cat /proc/version
09/06: Linux check memory usage
Linux check memory usage
$ top $ vmstat $ free -m -t
How to mount a remote ssh filesystem using sshfs Ubuntu Blog
$ sshfs -o transform_symlinks example.com:/stuff /media/home-pc
$ fusermount -u /media/home-pc
$ sshfs -o transform_symlinks example.com:/stuff /media/home-pc
$ fusermount -u /media/home-pc
Use Evolution with Microsoft Exchange : Ubuntu (6.06 / 6.10) : Ubuntu Tutorials : Dapper - Edgy - Feisty - Gutsy
Server Type: “Microsoft Exchange”
Username: domain/username (ie; your windows domain and user account)
OWA URL: The URL for your office / domain webmail. (ie; https://webmail.domain.com/exchange/)
Server Type: “Microsoft Exchange”
Username: domain/username (ie; your windows domain and user account)
OWA URL: The URL for your office / domain webmail. (ie; https://webmail.domain.com/exchange/)
09/05: Linux > Keyboard shortcuts
[Ctrl] + [Alt] + [F1] : Change to CUI (command console) [Ctrl] + [Alt] + [L] : Lock the screen [Alt] + [F2] : Run command
How To Use NTFS Drives/Partitions Under Ubuntu Edgy Eft | HowtoForge - Linux Howtos and Tutorials
$ sudo vi /etc/apt/sources.list Add deb http://flomertens.keo.in/ubuntu/ edgy main main-all $ sudo apt-get update $ sudo apt-get install pmount $ sudo apt-get install ntfs-3g $ sudo mkdir /media/windows $ sudo mount -t ntfs-3g /dev/sdd1 /media/windows (-o force)
09/05: Linux > VMWare server
How To Install VMware Server On Ubuntu 7.04 (Feisty Fawn) | HowtoForge - Linux Howtos and Tutorials
How-to for 8.04
# sudo vmware-install.pl
Before running VMware Server for the first time, you need to configure it by invoking the following command: "/usr/bin/vmware-config.pl". Do you want this program to invoke the command for you now? [yes] NO
# sudo ./runme.pl (vmware-any-any-updateXXX)
This time, we can run vmware-config.pl.
How-to for 8.04
# sudo vmware-install.pl
Before running VMware Server for the first time, you need to configure it by invoking the following command: "/usr/bin/vmware-config.pl". Do you want this program to invoke the command for you now? [yes] NO
# sudo ./runme.pl (vmware-any-any-updateXXX)
This time, we can run vmware-config.pl.
09/03: Linux > GNU screen
Oreilly Screen
screenのススメ
SCREEN
"C-a c" : create a new screen
"C-a C-\" : quite screen
# screen -list
# screen -S [name]
screenのススメ
SCREEN
"C-a c" : create a new screen
"C-a C-\" : quite screen
# screen -list
# screen -S [name]
UNIX Tutorial Five
If you start a long-running task and forget to add the ampersand, you can still swap that task into the background. Instead of pressing ctrl-C (to terminate the foreground task) and then restarting it in the background, just press ctrl-Z after the command starts, type bg, and press enter. You'll get your prompt back and be able to continue with other work. Use the fg command to bring a background task to the foreground.
$ sleep 1000 (type any command to be background) Ctrl + z, then type bg $ jobs (to check current jobs) $ fg %1Processes - Linux Shell Commands
cc hugepgm.c > outlist &Note: It's a good idea to redirect the output of background tasks to a file, as shown here, since the background task still shares the console with foreground tasks. If you don't, the background task will splash any output it might produce all over your screen while you're editing a file or typing another command.
If you start a long-running task and forget to add the ampersand, you can still swap that task into the background. Instead of pressing ctrl-C (to terminate the foreground task) and then restarting it in the background, just press ctrl-Z after the command starts, type bg, and press enter. You'll get your prompt back and be able to continue with other work. Use the fg command to bring a background task to the foreground.
09/03: LPIC > Using the Linux Shell
The /bin/false is a special shell which returns a nonzero error code for blocking access by a user.
The /etc/nologin is used to block logins for accounts and echo a message.
The /etc/profile is the global configuration file that affects all users' environment if they use the bash shell. The user's ~/.bash_profile, if et exists, is the next script that's sourced. This script calls, or sources, ~/.bashrc.
Multiple Command Operators
The semicolon causes all listed commands to be executed independently.
make modules ; echo DO MAKE MODULES_INSTALL NEXT
The double ampersand causes the second command to be excuted if the first command has an exit status of 0 (success).
The double pipe is opposite of the double ampersand.
The /etc/nologin is used to block logins for accounts and echo a message.
The /etc/profile is the global configuration file that affects all users' environment if they use the bash shell. The user's ~/.bash_profile, if et exists, is the next script that's sourced. This script calls, or sources, ~/.bashrc.
Multiple Command Operators
The semicolon causes all listed commands to be executed independently.
make modules ; echo DO MAKE MODULES_INSTALL NEXT
The double ampersand causes the second command to be excuted if the first command has an exit status of 0 (success).
The double pipe is opposite of the double ampersand.