Centos系统的安装与配置
一. 系统的初级安装与配置
1. 加载光驱,按照正常步骤安装。
国内速度较快的常用更新源如下:
http://mirrors.163.com/centos/ 163-网易
http://mirrors.ta139.com/centos/ 中国移动通信(山东移动)
http://centos.ustc.edu.cn/centos/ 中国科学技术大学
http://mirror.neu.edu.cn/centos/ 东北大学
编辑yum配置文件:
#vi /etc/yum.repos.d/CentOS-Base.repo
2. 系统安装成功,安装ntfs-3g挂在硬盘。
先安装fuse
wget http://nchc.dl.sourceforge.net/project/fuse/fuse-2.X/2.9.2/fuse-2.9.2.tar.gz
tar -zxvf tar -zxvf fuse-2.9.2.tar.gz
cd fuse-2.9.2
./configure
make
make install
modprobe fuse
再安装ntfs-3g
wget http://tuxera.com/opensource/ntfs-3g_ntfsprogs-2013.1.13.tgz
tar -zxvf tar ntfs-3g_ntfsprogs-2013.1.13.tgz
cd ntfs-3g_ntfsprogs-2013.1.13
./configure
make
makeinstall
挂载
mount -t ntfs-3g /dev/sd2 /samu/sd2/
3. 安装rpmforge 源
http://wiki.centos.org/AdditionalResources/Repositories/RPMForge
4. 安装mplayer
1) yum -y install mplayer
2) yum -y install mplayer-gui
3) yum -y install ffmpeg*
5. 安装flash插件
https://get.adobe.com/cn/flashplayer/?fpchrome下载rpm包,安装
6. 安装VNC server
Yum install tight-vncserver
yum install vncerver
二.常用路径
1. 环境变量
系统环境"/etc/profile", 用户环境变量"~/.bash_profile"
2 源文件所在位置.vi /etc/yum.repos.d/CentOS-Base.repo
3. 开机自动挂载windows硬盘的配置文件
/etc/fstab
4. 为用户添加sudo权限
编辑/etc/sudoers文件。也就是输入命令"vim /etc/sudoers",进入编辑模式,找到这一行:"root ALL=(ALL) ALL"在起下面添加"xxx ALL=(ALL) ALL"(这里的xxx是你的用户名),然后保存退出
三.常用命令
1. 双显示器控制
xrandr --output VGA --same-as LVDS --auto
打开外接显示器(最高分辨率),与笔记本液晶屏幕显示同样内容(克隆)
xrandr --output VGA --same-as LVDS --mode1024x768
打开外接显示器(分辨率为1024x768),与笔记本液晶屏幕显示同样内容(克隆)
xrandr --output VGA --right-of LVDS --auto
打开外接显示器(最高分辨率),设置为右侧扩展屏幕
xrandr --output VGA --off
关闭外接显示器
xrandr --output VGA --auto --output LVDS --off
打开外接显示器,同时关闭笔记本液晶屏幕(只用外接显示器工作)
xrandr --output VGA --off --output LVDS --auto
关闭外接显示器,同时打开笔记本液晶屏幕 (只用笔记本液晶屏)
2. 挂在samba服务器
Mount –ousername=***,password=**** //10.192.130.110/$C /mnt/smb