1.普通用户添加sudo权限及sudo 无密码配置

    1.1 添加sudo权限,在root ALL=(ALL) ALL 行下面增加一行

    $sudo vi  /etc/sudoers
    username ALL =(ALL) ALL

    1.2 sudo 无密码设置

   jun  ALL=NOPASSWD: ALL   
  #用户名 空格 ALL=NOPASSWD 空格:ALL;下次普通用户jun sudo su 则无需输入密码设定

    

2. Mysql 密码忘记的修复方法

    2.1 停止mysql 服务

#/etc/init.d/mysqld stop   或 killall -TERM mysqld

    2.2 绕开安全权限启动mysqld

    #/usr/bin/mysqld_safe --skip-grant-tables &

    2.3 修改mysql库中的user表,重新赋予新的权限

    >use mysql 
    >update user set password=password("new_pass") where user="root"; 
    >flush privileges;


3.Ubuntu,RHEL与SUSE系统语言配置文件路径

    3.1 ubuntu 路径:

    #cat /etc/default/locale

LANG=en_US.UTF-8
LANGUAGE=en_US:en
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

    3.2 RHEL 路径

    #cat /etc/sysconfig/i18n

   3.3 SUSE 路径

   #cat /etc/sysconfig/language

4.修改Centos6.5 YUM 源

通常在安装完CentOS后一般需要修改yum源,才能够在安装更新rpm包。同时为了获得比较理想的速度,这里采用了国内比较快的有163源、sohu源;这里以163源为例子。

# cd /etc/yum.repos.d
# mv CentOS-Base.repo CentOS-Base.repo.bak
# wget http://mirrors.163.com/.help/CentOS6-Base-163.repo
# mv CentOS6-Base-163.repo CentOS-Base.repo
# yum clean all


5.Linux 网址杂烩

国外
 

 http://lwn.net/
  http://www.tldp.org/
  https://rhn.redhat.com
  http://www.justlinux.com/
  http://www.linuxtoday.com/
  http://www.linuxquestions.org/
  http://www.fokus.gmd.de/linux/
  http://www.linux-tutorial.info/
  http://public.www.planetmirror.com/
  http://www.freebsdforums.org/forums/
  http://www.netfilter.org/documentation/
  http://www-106.ibm.com/developerworks/linux/
  http://www.redhat.com/docs/ redhat官方文档,

国内

http://www.fanqiang.com/
  http://www.linuxsir.com/
  http://www.chinaunix.net/
  http://www.linuxfans.org/
  http://www.linuxeden.com/
  http://www.linuxforum.net/
  http://www.linuxaid.com.cn/
  http://freesoft.online.sh.cn/
  http://www-900.ibm.com/developerWorks/cn/linux/index.shtml

redhat linux下载地址

 ftp://ftp.redhat.com/pub/redhat/linux
  http://redhat.com/download/mirror.html

linux 常用软件搜索

 http://bingle.pku.edu.cn 
  http://www.linuxforum.net/
  http://rpmfind.net
  http://freshmeat.net
  http://sourceforge.net
  http://www.linuxgazette.com/ linux在线杂志
  http://linux.tcpip.com.cn/download/ linux中文版文档和软件下载
  http://cosoft.org.cn/html/documents/ 很多中文版手册


linux 桌面主站一览表

  GNOME: http://www.gnome.org
  KDE: http://www.kde.org
  XFce: http://www.xfce.org/
  Window Maker: http://www.windowmaker.org/
  BlackBox: http://sourceforge.net/projects/blackboxwm
  XPde: http://www.xpde.com
  ROX: http://sourceforge.net/projects/rox
  5dwm: http://5dwm.org/
  foXdesktop: http://sourceforge.net/projects/foxdesktop
  EDE: http://sourceforge.net/projects/ede
  UDE: http://sourceforge.net/projects/udeproject

其它OS:

  Mandrake linux http://www.mandrakelinux.com
  debian linux http://www.debian.org
  slackware linux http://www.slackware.com
  suse linux http://www.suse.com
  FreeBSD http://www.freebsd.org
  netbsd http://www.netbsd.org
  openbsd http://www.openbsd.org
  Solaris http://www.sun.com/solaris
  linux Kernel内核: http://www.kernel.org

主要服务器软件主站

1. WWW server:
  Apache http://www.apache.org Apache
  SSL模块Mod_ssl http://www.modssl.org
  aol server http://www.aolserver.com
2. Servlets/JSP引擎:
  Tomcat: http://jakarta.apache.org
  Resin: http://www.caucho.com
  开源应用服务器AS--Jboss: http://www.jboss.org
3. 服务器语言:
  PHP http://www.php.net
  Zend http://www.zend.com
  Java http://www.javasoft.com
  Python http://www.python.org
  Zope http://www.zope.org
  Perl http://www.perl.org
  Ruby http://www.ruby-lang.org/en
4. 数据库:
  MySQL http://www.mysql.com
  PostgreSQL http://www.postgresql.org
  Oracle http://www.oracle.com
  sap db http://www.sapdb.org
  PHPMyAdmin -- http://www.phpmyadmin.org
  PHPPgAdmin: http://sourceforge.net/projects/phppgadmin
5. FTP服务器
  wu-ftpd http://www.wu-ftpd.org
  Proftpd http://www.proftpd.org
  Pure-ftpd http://www.pureftpd.org
  ncftpd http://www.ncftpd.com
  vsftpd http://vsftpd.beasts.org
6. SMTP服务器
  Sendmail http://www.sendmail.org
  qmail http://www.qmail.org
  Postfix http://www.postfix.org
  Exim http://www.exim.org
  POP3--qpopper http://www.qpopper.org
7. IMAP服务器
  Cyrus-IMAPD http://asg.web.cmu.edu/cyrus/imapd
  UW IMAP http://www.washington.edu/imap
  courierimap http://www.inter7.com/courierimap
8. 基本安全工具
  firewall Iptables: http://www.iptables.org
  shorewall: http://www.shorewall.net
  inetd Xinetd: http://www.xinetd.org
  Openssl: http://www.openssl.org
  OpenSSH: http://www.openssh.org
  nmap: http://http://www.insecure.org/nmap
  Tripwire: http://www.tripwire.org
  snort: http://www.snort.org
  nessus: http://www.nessus.org
  GnuPG: http://www.gnupg.org
  chkrootkit: http://www.chkrootkit.org
  安全顾问: http://www.cert.org

9. 其它服务器软件

  CVS--CVS http://www.cvshome.org
  DNS域名解析BIND http://www.isc.org/products/BIND/
  DHCP--DHCP http://www.isc.org/products/DHCP/
  INN新闻组INN: http://www.isc.org/products/INN/
  Proxy代理缓存: Squid http://www.squid-cache.org
  Socks代理:http://www.socks.nec.com/
  Samba Server: http://www.samba.org
  Print CUPS: http://www.cups.org
  LDAP OpenLDAP: http://www.openldap.org
  流量分析 MRTG http://www.mrtg.org
  日志分析 webalizer http://www.mrunix.net/webalizer/
  Ipsec/××× http://www.freeswan.org
  路由 Zebra http://www.zebra.org
  集群 LVS http://www.linuxvirtualserver.org
  MPICH http://www-unix.mcs.anl.gov/mpi/mpich/
  PVM:http://www.netlib.org/pvm3/
  Rsync: http://rsync.samba.org
  linuxconf: http://www.solucorp.qc.ca/linuxconf/
  Webmin: http://www.webmin.com

6.Cygwin 设置ls 带颜色显示文件及目录

$ vi .bashrc
alias ls='ls -hF --color=tty'  #开启
$ source .bashrc

7. CentOS 支持 中文输入法

#yum install "@Chinese Support"

安装完成之后在图形界面点击System 》Preferences》中会出现 Input Method 选项,点击进入;

弹出框后,选择 USE  IBUS (recommended),点击 Input Method Preferences  选项进入

再选择General 选项包含 快捷键等设置,Input Method 中选择常用输入法,在Select an  input method中选择Chinese,会出现右边的中文输入法列表,这里选择Pinyin,然后点击add,关闭窗口,即设置成功。如果不生效的情况下则注销用户重新登录。


8. Ubuntu 怎么在右键添加打开终端

$sudo apt-get install nautilus-open-terminal 
$nautilus -q     #重新加载文件管理器或注销再登录即要使用


9.Ubuntu 更换桌面

换成lxde桌面
$sudo apt-get install lubuntu-desktop
这是换成xfce4的桌面
$sudo apt-get install xubuntu-desktop