前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >CVS的迁移

CVS的迁移

作者头像
三杯水Plus
发布2018-11-14 17:49:22
1.1K0
发布2018-11-14 17:49:22
举报
文章被收录于专栏:运维

cvs的迁移 1,把原dell2950上的rhel3 的/cvs目录做成 nfs共享 2,在新dell720上的rhel5.8上挂载nfs共享,并复制 mount -t nfs rhel3:/cvs /mnt  (新服务器上) cp -aP  /mnt /cvs  (新服务器上的帐号在前面已经迁移好,主要这样做是为了保证权限一致) 3,rhel5.8上安装cvs,cvs-inetd cvs-1.11.22-11.el5 cvs-inetd-1.11.22-11.el5 4,编辑/etc/xinetd.d/cvs文件(这里多project的配置方法,原那个地方直接注释也可以多project) cat /etc/xinetd.d/cvs # default: on # description: The CVS service can record the history of your source \ #              files. CVS stores all the versions of a file in a single \ #              file in a clever way that only stores the differences \ #              between versions. service cvspserver {         disable                 = no         port                    = 2401         socket_type             = stream         protocol                = tcp         wait                    = no         user                    = root         passenv                 = PATH         server                  = /usr/bin/cvs #       env                     = HOME=/var/cvs         server_args             = -f --allow-root=/cvs --allow-root=/cvs/project1  --allow-root=/cvs/project2  --allow-root=/cvs/project3 --allow-root=/cvs/project4 --allow-root=/cvs/project5 #       bind                    = 127.0.0.1         only_from               = 172.16.10.0/24 5,重启xinetd 6,客户端测试 $tail -n 1 .bash_profile export CVSROOT=:pserver:user1@cvsserver:/cvs/project1 18:07:54 user1@cvsserver (~) [103]$cvs login Logging in to :pserver:user1@cvsserver:2401/cvs/project1 CVS password: 输入密码即可 $cvs checkout someone

最后注意点:

如果你迁移时IP地址也更改了,客户端正在使用的就会报错,应为check out 下来的每个文件夹下都有

一个CVS,每个CVS下都有一个文件Root,里面记录了原来CVS服务器的IP地址,如果你想迁移,最好别改

IP,如果改了,就得在自己的目录下把Root里面的IP地址更改掉或者重新check out 一遍。

下面是快速更改IP的方法

find ./* -name Root |xargs sed -i "s/\:pserver\:user\@oldip\:\/cvs/\:pserver\:user\@newip\:\/cvs/g" ​更简单的写法是  find ./* -name Root | xargs sed -i 's/oldip/newip/g'

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2012/12/03 ,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档