最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
Ubuntu使用安装学习笔记
时间:2013-10-16 编辑:简简单单 来源:一聚教程网
一些操作的记录,只为个人所用,勿喷,持续不定时updating….
新建用户git:
useradd git
修改git用户密码: passwd git
git用户添加到管理组: gpasswd -a git admin
给git用户创建自己的目录:
cd /home
mkdir git
chown git /home/git
删除用户git
userdel -r git(-r 删除与git用户相关的文件)
—————————————————————–
ssh生成密钥
ssh-keygen -t rsa -C “zsw.scorpio@gmail.com”
ssh公钥复制到服务器
ssh-copy-id -i .ssh/id_rsa.pub scorpio@192.168.137.60
修改密钥口令(以前的密钥一直有密码的….太烦了,所以想删掉)
ssh-keygen -p
ssh服务器配置文件
/etc/ssh/sshd_config
ssh服务器开始重启关闭
/etc/init.d/ssh start(restart)(stop)
—————————————————————–
# the PS1
export PS1=’n[e[01;37m][`a=$?;if [ $a -ne 0 ]; then echo -n -e “[e[01;32;41m]{$a}”; fi`[33[01;32m]u[33[01;33m]@[33[01;35m]h[33[00m] [33[01;34m]`pwd“B=$(git branch 2>/dev/null | sed -e “/^ /d” -e “s/* (.*)/1/”); if [ "$B" != "" ]; then S=”git”; elif [ -e .bzr ]; then S=bzr; elif [ -e .hg ]; then S=”hg”;B=”$(hg branch)”; elif [ -e .svn ]; then S=”svn”; else S=”"; fi; if [ "$S" != "" ]; then if [ "$B" != "" ]; then M=$S:$B; else M=$S; fi; fi; [[ "$M" != "" ]] && echo -n -e “[e[33;40m($M)[33[01;32m][e[00m]“`[33[01;34m][e[01;37m]]n[e[01;34m]$ [e[00m]‘
if [ $UID -eq 0 ]
then
export PS1=’n[e[01;37m][`a=$?;if [ $a -ne 0 ]; then echo -n -e “[e[01;32;41m]{$a}”; fi`[33[01;31m]u[33[01;33m]@[33[01;31m]h[33[00m] [33[01;34m]`pwd“B=$(git branch 2>/dev/null | sed -e “/^ /d” -e “s/* (.*)/1/”); if [ "$B" != "" ]; then S=”git”; elif [ -e .bzr ]; then S=bzr; elif [ -e .hg ]; then S=”hg”;B=”$(hg branch)”; elif [ -e .svn ]; then S=”svn”; else S=”"; fi; if [ "$S" != "" ]; then if [ "$B" != "" ]; then M=$S:$B; else M=$S; fi; fi; [[ "$M" != "" ]] && echo -n -e “[e[33;40m]($M)[33[01;32m][e[00m]“`[33[01;34m][e[01;37m]]n[e[01;34m]$ [e[00m]‘
fi
—————————————————————–
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the ECDSA key sent by the remote host is
c1:87:72:73:01:cf:96:f8:62:23:92:db:8f:a7:3a:11.
Please contact your system administrator.
Add correct host key in /home/Scorpio/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /home/Scorpio/.ssh/known_hosts:9
ECDSA host key for 192.168.137.60 has changed and you have requested strict checking.
Host key verification failed.晚上登录出现这个情况,好像是因为本地known_hosts里面有虚拟主机的信息,但是虚拟主机没pubkey所以错误,只要删除known_hosts记录就好了。-
----------------------------------------------------------------Ubuntu11.10源
deb http://mirrors.163.com/ubuntu/ oneiric main universe restricted multiverse
deb-src http://mirrors.163.com/ubuntu/ oneiric main universe restricted multiverse
deb http://mirrors.163.com/ubuntu/ oneiric-security universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ oneiric-security universe main multiverse restricted
deb http://mirrors.163.com/ubuntu/ oneiric-updates universe main multiverse restricted
deb http://mirrors.163.com/ubuntu/ oneiric-proposed universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ oneiric-proposed universe main multiverse restricted
deb http://mirrors.163.com/ubuntu/ oneiric-backports universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ oneiric-backports universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ oneiric-updates universe main multiverse restricted-----------------------------------------------------------------修改系统登录信息:
sudo vim /etc/motd----------------------------------------------------------------- ./configure在输入:make
make: *** No targets specified and no makefile found. Stop. 这是因为make出错了!木有makefile
-
上一个: 服务器ARP攻击与防范方法总结
-
下一个: Linux搜索或查找超过指定大小的文件?
相关文章
- sphinx安装与 api 学习笔记整理 12-11
- 扬扬的J2EE学习笔记(五)Installing J2EE SDK(安装J2EE SDK) 01-12
- win11内核隔离和内存完整性介绍 10-31
- win10全屏缩放设置教程 10-31
- win10系统备份出错解决教程 10-31
- win10打开软件每次都要询问解决教程 10-31