ubuntu 12.04 lts安装完的设置
ubuntu/mint添加ll命令,加快ping域名和ssh的速度
来源{
http://ubuntuforums.org/showthread.php?t=1357310
http://ubuntuforums.org/showthread.php?t=1960183
http://www.techpage3.com/2012/04/fix-for-slow-ssh-connection.html
}
在/etc/bash.bashrc中查找alias,按格式添加{
#添加自定义命令ll
alias ll='ls -l'
#加快ping域名的速度
alias ping='ping -n'
}
加快ssh的速度{
在/etc/ssh/sshd_config中添加
UseDNS no
然后重启ssh服务
sh>service ssh restart
在/etc/pam.d/sshd中注释此行
#session optional pam_motd.so # [1]
原因{
Usually in ubuntu when you login thru ssh you will see a system information including system load, processes, disk usage, memory & swap usage, ip address, etc....
Depending on the load on the system, it may even take upto 5 minutes to collect this information and display it as a MOTD (message of the day). Till than your ssh connection will be stuck. Disabling this will make the login faster but disable the system information after login.
}
}
==========
其他设置命令
参考{
http://gm100861.blog.51cto.com/1930562/950066
http://www.binghe.org/2009/12/manage-services-using-sysv-rc-conf-in-ubuntu/
}
root命令不能自动补全{
修改/root/.bashrc文件,把注释掉的这段让其起作用,或添加也可以。
if [ -f /etc/bash_completion ] && ! shopt -oq posix; then
. /etc/bash_completion
fi
}
重启网络命令{
service network-manager restart
或在本机的命令
ifconfig eth0 down;ifconfig eth0 up
}
图形界面root登陆,修改/etc/lightdm/lightdm.conf,添加{
greeter-show-manual-login=true
allow-guest=false
}
设置开机自启动服务{
apt-get install sysv-rc-conf
直接输入sysv-rc-conf,然后简单图形界面设置
列出服务的启动状态,默认为所有服务
sysv-rc-conf --list 服务名
设置服务的启动级别
sysv-rc-conf [--level 2345 ] 服务名 on|off
}
apt查找软件{
apt-cache search 软件名
}