免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 789 | 回复: 0
打印 上一主题 下一主题

tips for linux [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-09-20 13:47 |只看该作者 |倒序浏览

               
               
               
               
               
               

tips for Linux

1.
    When your computer is running with Windows and you want to lookup files of Linux partitions, the tool "LinuxDos" is useful. It is less than 500k, you can get it by internet.
2.
    If you want to add an user in you Linux system, you can take following command:
    #adduser
    #passwd [newuser] //set the password for newly added user.
Linux提供了六个虚拟控制台,用ALT+F1~F6切换(在X-window下用CRTL+ALT+F1~F6切换),每个控制台均可以用不同的用户登录,运行不同的程序。
重启X-window:CTRL+BACKSPACE.
3.
    install and uninstall software in Linux:
    (by rpm: redhat package manager)
install:     rpm -ivh
uninstall:    rpm -e
update:        rpm -Uvh
#rpm will automatically erase the old software and install #the new version of the software.
4.改变grub默认启动的系统
     这需要修改/boot/grub/grub.conf。举一个例子, 假设你的/boot/grub/grub.conf是这样子的:
default=0
timeout=10
splashimage=(hd0,7)/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-14)
root (hd0,7)
kernel /vmlinuz-2.4.18-14 ro root=LABEL=/
initrd /initrd-2.4.18-14.img
title Windows
rootnoverify (hd0,0)
chainloader +1
那么你的grub会默认启动Red Hat Linux (2.4.18-14)这个系统,把default=0改成default=1,那么grub会默认启动Windows这个系统。注意,这里的要点是:你想默认启动第n个title所指的系统,那么default应该是等于n-1.
5.机器重装windows后,开机启动就直接进入了windows,原来的linux进不去了
   
这是由于windows的霸道。重装windows后,windows重写了你的mbr,覆盖掉了grub。解决方法很简单:
用你的linux第一张安装盘引导进入linx rescue模式(如何进入?你注意一下系统的提示信息就知道了),执行下面两条命令就可以了
chroot /mnt/sysimage #改变你的根目录
grub-install /dev/hda #安装grub到mbr
6.同时启动多个X系统
    以前的帖子,估计很多人没看过,贴出来温习一下Linux里的X-Windows以其独特的面貌和强大的功能吸引了很多原先对linux不感兴趣的人,特别是KDE和GNOME,功能强大不说,而且自带了很多很棒的软件,界面非常友好,很适合于初学者。
    下面告诉大家一个同时启动6个X的小技巧:
在~/.bashrc中加入 以下几行:
alias X=startx -- -bpp 32 -quiet&
alias X1=startx -- :1 -bpp 32 -quiet&
alias X2=startx -- :2 -bpp 32 -quiet&
alias X3=startx -- :3 -bpp 32 -quiet&
alias X4=startx -- :4 -bpp 32 -quiet&
alias X5=startx -- :5 -bpp 32 -quiet&
其中32是显示器的色彩深度,你应该根据自己的实际情况设置。
之后运行
# bash
使改变生效,以后只要依次运行X,X1,X2,X3,X4,X5就可以启动6个X-Windows了。
7. Command
#du -sh //目录所用空间
#df -h//文件系统信息,剩余空间等.
#top //显示CPU,MEMORY等的使用情况
8.
linux下解压rar文件
[color="#5b4937"]http://rarlab.com/rar/rarlinux-3.6.b6.tar.gz
  cd rar
  make
  make install
  
  使用方法:
  
  压缩过程: rar a 压缩后的文件名.rar 待压文件
  
  解压过程: unrar x 待解压文件
               
               
               
               
               
               
               
               
               
               
               
               
               
               
               
               
               

本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/20260/showart_174008.html
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP