64
Linux illustration

Linux illustration

  • Upload
    elise

  • View
    88

  • Download
    0

Embed Size (px)

DESCRIPTION

Linux illustration. content. why we use linux Basic concept for linux newbie Useful commands in linux System configuration howto How to work efficiently Programming under linux Remote operation howto About our work. Why we use linux. Linux is more efficient Linux is more stable - PowerPoint PPT Presentation

Citation preview

Page 1: Linux illustration

Linux illustration

Page 2: Linux illustration

content

why we use linux Basic concept for linux newbie Useful commands in linux System configuration howto How to work efficiently Programming under linux Remote operation howto About our work

Page 3: Linux illustration

Why we use linux Linux is more efficient Linux is more stable For compatibility Linux is free Linux is more flexible

Page 4: Linux illustration

新手上路之基本概念 预备知识 文件系统 进程 Linux 环境

Page 5: Linux illustration

预备知识 登陆到 linux 从 linux 注销 控制台和视窗环境 重起活着关闭 linux Linux 中最有用的命令

Page 6: Linux illustration

登陆到 linux 字符界面登陆,蓝色字符表示输入Red Hat Linux release 9 (Shrike)Kernel 2.4.20-mosix on an i686login: dhhPassword: 这里输入密码,没有回显Last login: Tue Apr 6 18:05:38 from 10.14.122.253You have new mail.[dhh@d6 dhh]$最后一行是命令提示符号,表示进入了 shell.

Page 7: Linux illustration

登陆到 linux 图形界面登陆这种登陆界面和 windows 的登陆界面类似。所以这

里就不详细介绍了。至于用那种模式登陆取决于文件/etc/inittab. 在这个文件中有一行包含字符:“ id:

3:initdefault:” ,其中的数字 3 指定了登陆的模式为字符界面的。如果把 3 改成 5 就是图形界面登陆模式。具体可以参照 man inittab 。

Page 8: Linux illustration

从 linux 注销 [dhh@d6 dhh]$ exit [dhh@d6 dhh]$ Ctrl-d输入 exit 按回车或者直接按 Ctrl 和 d 的复合

键就可以从 linux 中退出。如果在图形界面的情况下面有菜单可以选择退出或者关机。

Page 9: Linux illustration

控制台和视窗环境 [dhh@d6 dhh]$

当你在字符模式下面登陆到 linux 的时候,你处于控制台(你处于一个正在运行的 shell 中 ) ,你可以通过 Ctrl 和 Fn 键来切换控制台,这里的 n 指的是数字,譬如说 F1,F2等等。一般来说, linux 默认有 6 个控制台可以切换。如果你愿意的话,你可以把它添加到上百个。上面的字符就是 linux 的 shell 的提示符号的一种。

进入视窗环境 [dhh@d6 dhh]$ startx

startx 是进入视窗环境的一个命令

Page 10: Linux illustration

重起或者关闭 linux shutdown init halt reboot这里的有些命令默认只能由 root 来执行。比

较常用的是 shutdown,halt 和 reboot

Page 11: Linux illustration

Linux 中最有用的命令 man – 按格式打印出 linux 的在线文档命令举例: man man

man ls按 q 来退出 man 。下面就是 man g77 的一段:G77(1) GNU G77(1)

NAME g77 - GNU project Fortran 77 compiler

SYNOPSIS

Page 12: Linux illustration

文件系统文件系统的结构是树状的[dhh@d6 dhh]$ tree binbin|-- flitter|-- rpm2targz| |-- README| |-- rpm2targz| `-- rpmoffset.c`-- tmp1 directory, 6 files[dhh@d6 dhh]$和 windows 不一样的是, linux 只有一个根 (root) 或者说 /

Page 13: Linux illustration

文件系统 mount – 挂载一个文件系统[dhh@d6 dhh]$ cat /etc/fstabLABEL=/ / ext3 defaults 1 1none /dev/pts devpts gid=5,mode=620 0 0LABEL=/home /home ext3 defaults 1 2none /proc proc defaults 0 0none /dev/shm tmpfs defaults 0 0LABEL=/usr /usr ext3 defaults 1 2LABEL=/var /var ext3 defaults 1 2/dev/hda5 swap swap defaults 0 0/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0none /mfs mfs dfsa=1 0 0[dhh@d6 dhh]$Fstab 里面写的是系统启动的时候挂载的分区列表。尝试用命令 fdisk –l 来察看磁盘的分区结构 .

Page 14: Linux illustration

文件系统 ls – 列出文件或者目录命令举例 : ls -lh *.html

ls -ltr cp – 拷贝文件或者目录命令举例 : cp file1.c ~/tmp/file2.c mv – 移动或者重命名文件命令举例 : mv ising.c ising.c.old

mv ising.c ~/backup/

Page 15: Linux illustration

文件系统 rm – 移除 / 删除文件命令举例 : rm -rf ~/bin命令 rmdir 只删除空目录 pwd – 打印工作目录(当前目录) cd – 改变当前目录到其他目录命令举例 : cd ..

cd /homecd –

chgrp – 改变文件或者目录的属组命令举例 : chgrp users filename这样就把 filename 这个文件改成属于 users 这个组。

Page 16: Linux illustration

文件系统 chown – 改变文件的属主命令举例: chown -R dhh.users bin/ chmod – 改变文件的存取权限举例 : 当你用 ls –l 来察看文件的时候,会看到类似情况:   -rwxr-x--x 表示文件是一个普通文件。文件的主人可以读 (r) ,写 (w) 和执行 (x) 文件。在同一个组的用户可以读可执行文件,而其他的用户只有执行文件的权限。

试试 chmod 600 filename ; chmod +x filename看看文件的权限在命令前后有什么变化?试试 chmod –x filename ,然后去执行这个文件?

Page 17: Linux illustration

文件系统 控制台下面察看文件的命令more – 分屏显示文件,翻页用 f(forward),b(backward) 或者

空格,可以按回车单向逐行翻动显示内容。cat – 连接文件并且在标准输出输出文件内容,普通用法和

more 类似,但是不会分屏显示,而是一下子全部输出。命令举例: cat file

cat file1 file2less – 分屏显示文件,可以用方向键逐行翻动文件你可以按 q 来退出 more 或者 less 的察看文件的状态。按键

q 可以使得你能在 linux 的很多暂停状态下面退出来,譬如在运行命令 top 的时候。

Page 18: Linux illustration

进程[dhh@z3 dhh]$ date;whoTue Apr 6 15:55:57 CST 2004dhh pts/0 Apr 6 15:0 (10.14.122.253)[dhh@z3 dhh]$当你运行程序的时候,那就是说, linux 里面有进程在运行。

进程是 linux 运行的程序单位。 你可以给正在运行的进程发送信号。如果你在 shell 的前台

运行程序,你可以按 Ctrl-c 来向当前进程发送 SIGINT 这样的信号。默认的对信号 SIGINT 的处理方式是终止进程。

问题: date && who 和上面的 data;who 有什么区别?

Page 19: Linux illustration

进程举例: [dhh@z3 dhh]$ ./isingCtrl-c[dhh@z3 dhh]$进程 ising也许需要运行 10天才能正常结束。这里的 Ctrl-c

中断了进程的继续运行。每个运行中的进程有唯一的一个整数和它对应,我们称呼 这

个整数为进程 id ,往往用 pid 作为缩写。你可以用命令 ps 或者 top 来找到进程的进程 id 。尝试用 Ctrl-c 来终止一个进程?

Page 20: Linux illustration

进程 top – 显示最占用 cpu/内存等等的程序 ps – 报告进程状态的命令命令举例: ps -u dhh

ps –aux尝试在 ps 的输出项中找到 pid项。 nohup – 运行一个程序,忽略挂起信号,同时使得输出

为非终端。往往用在需要长期运算的程序。 nice – 运行一个进程优先级别经过调整的程序。 at – 调整或设定计划任务(单次执行)命令举例: at now+5min < file

Page 21: Linux illustration

进程 在后台运行进程[dhh@z3 dhh]$ nohup nice ./ising > /dev/null &[1] 4931[dhh@z3 dhh]$ jobs[1]+ Running nohup nice ./ising >/dev/null &[dhh@z3 dhh]$ fg %1nohup nice ./ising >/dev/nullCtrl-c[dhh@z3 dhh]$ jobs[dhh@z3 dhh]$

Page 22: Linux illustration

进程 在后台运行进程[dhh@z3 dhh]$ ./isingCtrl-z[1]+ Stopped ./ising[dhh@z3 dhh]$ bg[1]+ ./ising &[dhh@z3 dhh]$这里的 Ctrl-z 向进程发送了信号 SIGSTP 。命令 bg 把进程放到了后台,相反的命令是 fg. 命令 jobs 列出了被放到后台的可以由 shell 控制的进程列表。

Page 23: Linux illustration

进程 kill – 终止 /杀死进程事实上, kill 只是向进程发送信号。默认的发送给进程的信号是 SIGTERM。这个信号往往会让进程体面的终止它自己。

用法举例 :[dhh@z3 dhh]$ ps -u dhh PID TTY TIME CMD 4635 pts/0 00:00:00 bash 5026 pts/0 00:00:00 ps[dhh@z3 dhh]$ kill –s SIGSTP 4635如果你想让操作系统,而不是进程来终止进程,你可以这样运行命令:

kill -9 4635 。这个命令并不是发送信号。没有 9这样的信号。

Page 24: Linux illustration

进程关于信号的一个有趣的练习[dhh@z3 dhh]$ more trap.sh#!/bin/shtrap 'echo sigint catched' 2trap 'echo oh! My god! someone want kill me!' 15read inecho "$in is inputed"[dhh@z3 dhh]$运行命令 chmod +x trap.sh. 运行这个脚本,按 Ctrl-c 或

者尝试 kill 来杀死进程,看看发生了什么?

Page 25: Linux illustration

Linux 环境 新手上路-怎样执行一个程序?通过绝对路径来执行命令:/sbin/ifconfig通过一个相对路径来执行命令:cd /sbin./ifconfig

Page 26: Linux illustration

Linux 环境 Shell 是怎样找到命令的?[dhh@z3 dhh]$ echo $PATH/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/

home/dhh/bin

[dhh@z3 dhh]$

这里的 PATH 是一个系统的环境变量。

Page 27: Linux illustration

Linux 环境 管道和 I/O 重定向who | wc -l“|” 这里就是一个管道。通过管道的连接命令“ wh

o” 的输出就作为了命令“ wc -l” 的输入。ls -l > ls.out“>” 是 I/O 重定向指示符。可以察看文件 ls.out 来获得输出内容。

比较 who | sort 和 who > sort 之间的区别。

Page 28: Linux illustration

Linux 环境 管道和 I/O 重定向 在一般的环境下面,每个进程在启动的时候有三

个文件描述符和它关联,其中之一是对应标准输入 (3) ,其中之一对应标准输出 (1) ,另外一个用来打印诊断和错误信息,那就是标准错误 (2) 。

f77 –o ising ising.f90 2>&1 | moref77 -o ising ising.f 2 > err.log

Page 29: Linux illustration

Linux 中有用的命令 grep – 打印匹配的内容用法举例:[dhh@d6 dhh]$ whoecono3 tty1 Apr 6 23:27dhh pts/1 Apr 7 01:41 (10.14.122.253)econo3 pts/0 Apr 6 23:31 (:0.0)[dhh@d6 dhh]$ who | grep dhhdhh pts/1 Apr 7 01:41 (10.14.122.253)[dhh@d6 dhh]$ who | grep -v dhhecono3 tty1 Apr 6 23:27econo3 pts/0 Apr 6 23:31 (:0.0)[dhh@d6 dhh]$ who | grep -v "eco*"dhh pts/1 Apr 7 01:41 (10.14.122.253)[dhh@d6 dhh]$

Page 30: Linux illustration

Linux 中有用的命令 find – 在指定的目录中找查找文件用法举例:find . -name “*.mp3” -exec rm {} \; locate – 在一个 updatedb产生的数据库里面查找文件 who – 显示谁在线 which – 显示被使用的命令的全路径

注:可能多个相同命名的程序,可以找到当前被执行的是哪个。 whereis – 定位一个命令的可执行文件,源码和手册的路径用法举例: [dhh@d6 dhh]$ whereis ls ls: /bin/ls /usr/share/man/man1/ls.1.gz [dhh@d6 dhh]$

Page 31: Linux illustration

Linux 中有用的命令 su – 运行一个具有不同用户 id 和组 id 的 shell ,或者说

切换用户。用法举例: su - dhh tar – GNU版本的打包工具用法举例: tar jxvf file.tar.bz2

tar zxvf file.tar.gztar jcvf file.tar.bz2 ./file/tar zcf file.gz ./file/*

gzip – 压缩或者解压缩文件 (zip) bzip2 – 一个块压缩 /解压缩工具 (bzip2)

Page 32: Linux illustration

Linux 中有用的命令 passwd – 更新 /修改用户的密码 adduser – 新建用户用法举例: adduser dhh -g users file – 判断文件类型的命令 tail – 输出文件的最后部分 head – 输出文件的最前面部分 wc – 打印出文件的大小,单词个数或者行数。用法举例: wc -l result.dat用现有的命令怎么打印出文件的第一行?

Page 33: Linux illustration

Linux 中有用的命令 sed 和 awk用法举例: more file | sed s/abc/def/g

cat file | sed –n 5psed s&<[^>]*>&&g fileawk ‘{print $5}’ file

我确实看到过有一本很厚的书仅仅用来讲 sed 和 awk 的用法。命令 sed 和 awk 的威力是远远超出你的想像能力的。

Page 34: Linux illustration

系统配置 howto ftp服务/etc/init.d/vsftpd start/stop/restart telnet 服务 ( 不安全 )修改 /etc/xinetd.d/telnet, 修改 disable = yes 为

disable = no. 然后运行 /etc/init.d/xinetd restart.

ssh 服务 (推荐 )/etc/init.d/sshd start/stop/restart在 ssh 中传输的数据是加密过的,所以它比较安全

Page 35: Linux illustration

系统配置 howto ftp客户端在 linux 下面: gftp, lftp, ncftp, ftp在 windows 下面: leapftp 等等 telnet 客户端Linux 下面: gnome-terminal->telnetWindows 下面 telnet, putty,fterm (推荐 ) ssh clientLinux 下面 ssh, scp, sftpWindows 下面 sshwinclient, putty,fterm其中 sshwinclient 支持 sftp 文件传输

Page 36: Linux illustration

系统配置 howto lftp 的一个例子[dhh@hhding dhh]$ lftp 10.14.122.166 -u dhhPassword:lftp [email protected]:~> lsdrwxrwxr-x 3 505 100 4096 Mar 30 11:29 bindrwxr-xr-x 7 505 100 4096 Apr 04 21:19 dldrwxrwxr-x 6 505 100 4096 Apr 03 07:31 docdrwxr-xr-x 2 505 100 4096 Apr 06 19:25 srcdrwxr-xr-x 3 505 100 4096 Apr 08 16:30 tmpdrwxr-xr-x 4 505 100 4096 Apr 06 11:27 worklftp [email protected]:~> bye[dhh@hhding dhh]$

Page 37: Linux illustration

系统配置 howtolftp 里面的一些命令get – 从服务器取得单个文件mget – 从服务器取得多个文件(支持通配符)put – 上传文件到服务器mput – 上传多个文件到服务器binary – 设置传输模式为二进制(这个命令可以简写为 bin)lcd – 改变上传的本地目录! – 在不退出 ftp 状态的情况下切换到一个 shell 环境中open – 连接指定端口的远程主机user – 指定用户名bye – 断开连接几乎所有的基于字符界面的 ftp客户端都支持以上命令。mirror && mirror –Rqueue – 把一个任务放入队列我们可以象在 shell 中那样按 Ctrl-z 把任务放到后台运行。lftp支持 TAB 自动补全,我们将会在稍后介绍。

Page 38: Linux illustration

系统配置 howto 和 ssh 有关的几个命令ssh -l dhh 10.14.122.166ssh -l -X [email protected]最后的那个命令使得 X forward生效。Public key (公共密匙?)验证第一步: ssh-keygen -t dsa第二步: scp ~/.ssh/id_dsa.pub target_host:~/.ssh/auth

orized_keys这里的 target_host应该替换成为远程主机的实际的机器名

或者 ip 。

Page 39: Linux illustration

系统配置 howto软件安装 howto

在 linux世界里面,往往存在两大类安装方式的软件,其中一种是源代码安装方式,另外一种是二进制的文件安装方式。所以我们应该用不同的方式处理这两种软件。

Page 40: Linux illustration

系统配置 howto 源代码方式一般来说每个安装软件都有安装文档,他们们可能

是 README 或者 INSTALL ,里面一般都有详细的安装过程介绍。最普通的安装软件方式,也是比较通用的安装软件的步骤是:

./configuremakemake install以上命令应该在源代码所在目录运行。

Page 41: Linux illustration

系统配置 howto 二进制软件我们常用的 redhat公司发布的 linux ,常见的的二

进制软件包是 rpm 包。我们可以在 Xwindows 的 gnome 窗口环境下通过双击 rpm 包来安装 rpm 包。如果在命令行的情况下面,可以通过运行命令 rpm -ivh file.rpm 来安装软件,可以通过运行 rpm -e file 来卸载软件。

具体信息可以通过察看 rpm 的手册来获得。

Page 42: Linux illustration

系统配置 howto ifup && ifdown – 激活或者禁用网络设备 ifconfig – 配置网络设备应用举例: /sbin/ifconfig eth0 10.14.122.167

/sbin/ifconfig eth0什么文件控制了网络配置信息?看看文件 /etc/sysconfig/network-scripts/ifcfg-et

h0 的内容或者看在下面的目录中包含的文件: /etc/sysconfig/networking/profiles/default/

Page 43: Linux illustration

系统配置 howto uname – 打印出系统基本信息 free – 显示被使用和空闲的内存 df - 显示文件系统的磁盘使用情况 du – 估计文件占用磁盘空间情况用法举例: du -sh * vmstat – 显示虚拟内存统计情况

Page 44: Linux illustration

系统配置 howto 存取外部设备我们怎样存取软驱,光驱或者 u 盘?/dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0前面两行是从文件 /etc/fstab 拷贝过来的, 他们指定了挂载光驱和软驱的选项,

通过这些选项,每个用户都可以存取这两个设备。挂载 U 盘的命令:mount -t vfat /dev/sda1 /the/mount/point/mount 的几个常用用法挂载软驱 mount -t ext3 /dev/fd0 /mnt/floppy挂载光驱 mount -t iso9660 -o loop /dev/cdrom /mnt/cdrom挂载 iso 文件 mount -t iso9660 -o loop /dir/file.iso /target/directory

Page 45: Linux illustration

高效工作的技巧 Shell脚本无法归类的技巧 定制你的工作环境

Page 46: Linux illustration

Shell脚本 假设在当前目录下面有 10000 个压缩文件,假设文件类似

0001.tar.bz2,0002.tar.bz2 ,你怎样才能把所有的这些文件解压缩?输入下面的命令:

[dhh@d6 dhh]$ for fn in *.tar.bz2> do tar jxf $fn> done[dhh@d6 dhh]$ Ok, 你会发现所有的文件都被解压缩了。这只不过是 shel

l 的一个小技巧而已。如果你愿意的话,你可以把这些命令写到文件里面,那么这个文件就叫做 shell脚本了。

Page 47: Linux illustration

Shell 脚本 我的一个简单的 shell脚本[dhh@d6 bin]$ more gg#!/bin/shinfile=$1/usr/bin/gcc -ggdb -o ${infile%.c} $infile -lm[dhh@d6 src]$ ls ising.cising.c[dhh@d6 src]$ gg ising.cising.c: In function `main':ising.c:27: warning: return type of `main' is not `int'[dhh@d6 src]$这样你就不用输入很长的 gcc –ggdb –o ising ising.c –lm 了

Page 48: Linux illustration

无法归类的技巧 关于 TAB这里有一个文件名很长的文件:“ who am I, I am dhh, do

you know me, who are you”, oh, my god! 这确实是一个文件名!我想察看文件内容,那么我应该输入所有的这些文字吗?

[dhh@d6 test]$ lscurrent ising_Metropolis_current.c who am I, I am dhh, do

you know me , who are you[dhh@d6 test]$ more who\ am\ I\,\ I\ am\ dhh\,\ do\ you\

know\ me , who\ are\ you我所输入的是: more w<TAB>, 然后就可以了。 Is it great?

Page 49: Linux illustration

无法归类的技巧 alias我在 ~/.bashrc 里面的部分 alias :alias cx='chmod u+x'alias c=clearalias vv='konqueror &'alias mm='mozilla &'alias 88='lftp 10.13.22.88 -p 52088‘不错 , 命令 alias 是命令的缩写 , 如果你运用这个技巧的话,

可以节省很多时间。如果你不再需要某些 alias ,你可以用命令 unalias 来使得这些 alias失效。

Page 50: Linux illustration

无法归类的技巧 alias 的几个例子 在 fortran 的编程中,我们经常做一些烦琐的事情。举例 r

m 输出文件 , 编译 fortran 文件 , 而且这种过程要重复非常多次。让我们采取一些技巧来简化这些问题。

假设我们需要编译的文件是 test.f, the binary file test will output 2 files named ising.dat and sum.dat.

Ok, 输入以下命令: alias r=“rm ising.dat sum.dat”;alias f=“f77 –o test test.f”; alias e=“./test &”;alias p=“r;f”; 这样,你就可以节省很多时间了。

Page 51: Linux illustration

无法归类的技巧 当你结束工作的时候退出 linux The xwindows or screensaver will cost a lo

t of source: maybe 100-200M memory and 3%-40% cpu time. So logout after you finished the work is a good idea.

Page 52: Linux illustration

定制你的工作环境 正如上面提到的那样,你可以定制你的工作环境。 ~/.bashrc这个文件会在启动 shell 的时候被执行。 ~/.bash_profile这个文件会在你登陆 linux 的时候被执行 ~/.vimrc我的 .vimrc 的内容:map <F3> :w^M:!gcc -ggdb -o %< % -lm ^M:syntax on

Page 53: Linux illustration

在 linux 工作环境中编程 f77 – gnu 的 fortran 77编译器。应用举例: f77 -o file file.for gcc – gnu 的 C 和 C++编译器集合应用举例: gcc -ggdb -o file file.c -lm gdb – gnu 的调试器 ddd – ddd 是 gdb 的图形版本?好像还没有能比较好调试 fortran 的调试器,不过已经有商业版本的 fortran调试器已经被开发出来。 gdb 可以调试 fortran ,但是到目前为止,它对 fortran 的调试支持的还不是很好。

Page 54: Linux illustration

在 linux 工作环境中编程 gdb[dhh@d6 src]$ gdb -q ising_Metropolis(gdb) list20 void neighbor(int i, int nn[ ]);21 void monte_carlo();22 void energy(double *);2324 /* The main program */2526 void main()27 {28 int i, mc;29 double e = 0;(gdb) break mainBreakpoint 1 at 0x8048430: file ising_Metropolis.c, line 29.

Page 55: Linux illustration

在 linux 工作环境中编程 gdb 中的几个基本命令run – 运行程序,可以加命令行参数list – 列出源码break – 设定断点watch – 设定需要被 watch 的变量bt – print backtrace of all stack frames

打印出所有函数间的调用关系print – 打印出变量数值等等shell – 暂时到一个 shell 里面step – 单步执行,调试子函数next – 单步执行,遇到子函数不进入子函数执行

Page 56: Linux illustration

在 linux 工作环境中编程 几个在调试的时候的技巧在屏幕上打印出你想知道的信息,这种做法有些时

候比使用调试器还要有用。这也许是在没有调试器的时候调试程序的唯一方法。

一些在运行程序时候的错误信息:Segmentation fault( 段错误 )? 这种错误往往发生在

类似情况:你开了一个数组: a[0:100], 但是在你的程序中,你去存取 a[102], 这个时候错误就发生了。

Page 57: Linux illustration

在 linux 工作环境中编程源码编辑器 gedit (推荐新手使用 ) nedit (推荐新手使用 ) vim ( 功能很多,但是上手有些麻烦 ) emacs (专家使用 )我从来没学过 emacs. 这个编辑器太复杂,

看起来比较的可怕。

Page 58: Linux illustration

远程操作 howto 从 windows远程操作所需软件:xwin32 和 (telnet 或者 ssh 客户端 )[dhh@d6 dhh]$ alias ppalias pp='export DISPLAY=10.14.122.253:0'[dhh@d6 dhh]$ pp在 10.14.122.253(windows) 运行 xwin32 ,把 d6 加为 可信任的 主机. 在 xwin32 中添加一个 xdmcp session(会话)

在远程主机上运行图形界面的程序,这个程序的输出会被显示到 windows 的机器上。 view

Page 59: Linux illustration

远程操作 howto 从 linux远程操作[dhh@d6 dhh]$ alias ppalias pp='export DISPLAY=10.14.122.253:0'[dhh@d6 dhh]$ pp本地主机运行: xhost + d6,然后就可以象本地机器上运行程序一样运行远程主机上的程序了。

Page 60: Linux illustration

关于我们的工作 用什么浏览器替代 ie 来找文献?mozilla 是一个优秀的 web浏览器konqueror 在某些情况下面比 mozilla做的更好。 xpdf我们可以用 xpdf 来浏览 pdf 文件。 Email?evolution 和 outlook 比较相似。 mutt 它功能比较强大,但是它用起来比较复杂(基于字符界面的)

Page 61: Linux illustration

关于我们的工作 xmgraceOh! You can download it and try to install it. Please

read the /usr/local/grace/doc/Tutorial.html, you can know how to operate the xmgrace by learning the document.

latexYeah, latex is the default installed software in linux.

there are a tutorial for you!

Page 62: Linux illustration

关于我们的工作 Latex

Latex 是一个非常优秀的软件,怎么写 latex 文件是一个很细致的问题,可以看以上教程,从 latex 的源文件生成到 pdf 或者 ps 文件需要两个步骤: 1.用命令 latex src.tex生成设备无关的 dvi 文件 src.dvi 。 2. 用命令 dvipdf/dvips 把这个设备无关文件转化成 pdf/ps 文件,也就是我们平常看到的打印效果。

Page 63: Linux illustration

Useful links

http://zimp.zju.edu.cn/~fren/

The link doc and mirror_of_wy contain many ebooks and example about linux.

You can find the document about latex, gdb, vim and many useful document there.

Page 64: Linux illustration

Thanks

Thank the cpsp group members.

I can’t finish this work without their support. Thank the free software developer.

Without their work, there is no linux here. Thank all people attend the seminar.