svn 架设详细教程.docx

上传人:b****6 文档编号:8078413 上传时间:2023-01-28 格式:DOCX 页数:12 大小:320.96KB
下载 相关 举报
svn 架设详细教程.docx_第1页
第1页 / 共12页
svn 架设详细教程.docx_第2页
第2页 / 共12页
svn 架设详细教程.docx_第3页
第3页 / 共12页
svn 架设详细教程.docx_第4页
第4页 / 共12页
svn 架设详细教程.docx_第5页
第5页 / 共12页
点击查看更多>>
下载资源
资源描述

svn 架设详细教程.docx

《svn 架设详细教程.docx》由会员分享,可在线阅读,更多相关《svn 架设详细教程.docx(12页珍藏版)》请在冰豆网上搜索。

svn 架设详细教程.docx

svn架设详细教程

 

LinuxSVN服务器CollabNetSubversion搭建howtoinstallCSVN如何成功在linux上成功启动CollabNetSu

2011年04月29日星期五下午01:

56

1.    下载安装Svn服务器

(1)下载CollabNetSubversion,到这个网址去下载最新版本:

       

如下图所示:

 

下载完之后文件:

 

 

(3)以超级用户登录系统,设置我们安装CollabNetSubversion目录/opt的读写权限,设置svn群组下的用户对该文件具有读写权限,如下图所示

 

最后点击“对包含的文件应用权限”按钮。

      把svn群组下的用户加入到sudo组,打开/etc/sudoers文件,找到rootALL=(ALL)ALL,在下一行加入svnuserALL=(ALL)ALL,强制保存退出。

       (4)解压安装,执行如下命令:

      启动成功之后,默认管理员登录地址:

地址:

http:

//localhost:

3343/csvn

用户名:

admin

密码:

admin

2.   添加项目库和用户

(1)添加项目库,在浏览器中打开http:

//localhost:

3343/csvn,以admin/admin登录。

  

点击菜单栏“Repositories”——“newRepository”, 在Name中输入code项目库名,再点击右下角的Create按钮即可。

(2)、添加用户,点击菜单栏“Users”——“newUser”, 在右边输入相应的用户信息,再点击右下角的Create按钮即可。

 

3.    Window安装TortoiseSVN

在window 下安装 TortoiseSVN-1.6.10.19898-win32-svn-1.6.12.msi客户端,安装过程一直点下一步即可。

最后CheckOut项目,如下图所示:

 

4.    安装过程出错问题汇总

 1、-Exitstatus=1Processerroutput:

httpd:

Syntaxerroronline72of/opt/csvn/data/conf/httpd.conf:

Syntaxerroronline23of/opt/csvn/data/conf/svn_viewvc_httpd.conf:

Cannotload/opt/csvn/lib/modules/mod_python.so.2.4intoserver:

 libpython.so.2.4.1.0:

cannotopensharedobjectfile:

Nosuchfileordirectory

原因:

没有先安装python-2.4.3-27.el5.i386.rpm,在/usr/lib/文件夹里找不到libpython。

 

2、ERRORservices.CommandLineService-Exitstatus=1Processerror:

httpd:

badusername7230

原因:

当前csvnstart的用户为超级管理员root,不能使用root用户启动程序。

 

3、userisnotinthesudoersfile.Thisincidentwillbereported.

原因:

当前用户不属于sudoer组。

解决方法:

(1)$whereissudoers -------找出文件所在的位置,默认都是/etc/sudoers

#chmodu+w/etc/sudoers    以超级用户登录su-root ,修改文件权限即添加文件

拥有这的写权限 限,ls-al/etc/sudoers 可以查看原文件的权限。

(2)vim/etc/sudoers 编辑文件,在rootALL=(ALL)ALL行下添加XXXALL=(ALL)ALL,XXX

为你的用户名。

添加方法:

找到root行,按下”i“键进入编辑模式添加即可!

编辑好

后esc键进入一般模式,“:

w!

",":

q!

"保存退出!

(3)最后,#chmodu-w/etc/sudoers 回到文件的原权限!

 4、sudo:

/etc/sudoersismode0640,shouldbe0440

原因:

/etc/sudoer 的权限为0440时才能正常使用,否则sudo命令就不能正常使用。

解决方法:

(1)、Ctrl+Alt+F1   进入文本模式。

用超级用户登录,如root

(2)、输入:

chmod0440/etc/sudoers           //回车

(3)、exit 退出

(4)、Ctrl+Alt+F7 返回图形模式。

(5)、在试试sudo命令,可以用了

上面转自:

 

说下我碰到的问题吧!

开始是使用ROOT用户进去使用  bin/csvnstart 能够使用admin/admin登录,但是点击启动时出现,服务器出错,

后面在网上看倒了这篇文章。

里面说要使用不要使用ROOT用户。

还有就是要复制.SO文件,

但启动时,还是会报服务器错误。

 

后面又看了这篇文章,但说的内容还是和上面的一样。

但是一定要看安装说明,由于全是英文的,看起来有些吃力,所以就没有认真看。

碰到问题就还是的坚持去看。

里面的内容也大致和网上的说的差不多,后面我再分析下。

看到提供的有论坛地址,我就在想是不是别人也碰到过相同的问题。

我想应该会找到答案。

就试着用如Startserver等字样搜索。

找到了许多的文章。

在如下地址里找到了 apachectlstart字样的,是不是里面还有Apache没有启动。

把这命令一执行,服务就启动了。

后面的事情就比较顺利了。

 

下面看下一些重要的步骤(建议安装程序前一定要认真看里面的内容)

CollabNetSubversionEdge-Linux32/64-bit

Version1.3.2

ReleaseDate:

March3,2011

Contents

  1.Overview

  2.Platformandconfiguration

  3.Requirements

  4.Installationnotes

  5.Updates

  6.Documentation

  7.Knownissues

  8.SupportforCollabNetSubversionEdge

  9.AboutSubversionandCollabNet

  

1.Overview(概述)

  CollabNetSubversionEdgeincludeseverythingyouneedtoinstall,manage

  andoperateaSubversionserver. ItincludesalloftheSubversionand

  ApachebinariesneededtorunaSubversionserver. Italsointegratesthe

  popularViewVCrepositorybrowsingtoolsothatuserscanviewrepository

  historyfromawebbrowser.

  CollabNetSubversionEdgealsoincludesapowerfulweb-basedmanagement

  consolethatmakesiteasytoconfigureandmanageyourApacheserverand

  Subversionrepositories. YoucaneasilysetuptheservertouseSSL

  connectionsandevenconnecttheservertoacorporateLDAPrepository,

  includingMicrosoftActiveDirectory.

  CollabNetSubversionEdgeonlysupportsservingSubversionrepositoriesvia

  ApachehttpdanditonlysupportstheSubversionfsfsrepositoryformat.

 

2.Platformandconfiguration(需要的平台和配置)

  Product:

CollabNetSubversionEdge

  License:

GNUAfferoGeneralPublicLicense3.0(AGPLv3)

  Certifiedplatforms:

RedHatEnterpriseLinux5.x

                       CentOS5.x

                       SuSELinuxEnterprise11.x

  

  NOTE:

Thesearetheplatformsweformallycertifywhentesting. CollabNet

  SubversionEdgeisknowntoworkonvirtuallyallLinuxdistributionsandis

  informallytestedonotherssuchasUbuntuandFedora.

  

  Thereareseparatedownloadsfor32-bitand64-bitLinux. Downloadthe

  appropriateversionforyourdistributionandkernel.

  

3.Requirements(所需运行换进环境)

  

  *Java1.6JRE/JDKmustbeinstalled.WerecommendtheJREprovidedby

    Sun/Oracle. Whentestingon64-bitLinuxwehaveusedthe64-bitJVM.(JAVA环境1.6及以上)

  

  *Python2.4to2.6mustbeinstalled.(Python2.4到2.6,看了一下后台好像也支持2.7,但没有试过。

Centos5.6默认会安装Python2.4,不必重新安装。

 

4.InstallationNotes(安装说明)

  IMPORTANT:

DonotuntarCollabNetSubversionEdgeusingrootorsudo.(不要使用ROOT和SUDO进行解压,也就是说不要在ROOT用户下安装运行。

) This  willcausetheUID/GIDonthefilestocarrythevaluesfromourbuild

  systeminsteadofbeingreset.

  

  1.SettheJAVA_HOMEenvironmentvariable,andpointittoyourJava6JRE(配置JAVA运行环境,使用JAVA -Version,如果看倒输出的)

     home. Forexample:

     exportJAVA_HOME=/usr/java/default

  

     Testthevariable:

  

     $$JAVA_HOME/bin/java-version

     javaversion"1.6.0_20"

     Java(TM)SERuntimeEnvironment(build1.6.0_20-b02)

     JavaHotSpot(TM)ClientVM(build16.3-b01,mixedmode,sharing)

  

  2.SwitchtothefolderwhereyouwanttoinstallCollabNetSubversion

     Edge. Youmusthavewritepermissionstothisfolder.

     

     $cd/opt (转到SVN所以的目录)

     

  3.UntarthefileyoudownloadedfromCollabNet.

  

     $tarzxfCollabNetSubversionEdge-x.y.z_linux-x86.tar.gz (解压下载文件)

     

     Thiswillcreateafoldernamed"csvn"inthecurrentdirectory.Youcan

     renamethisfolderifdesired.(产生一个叫CSVN的文件夹)

     

  4.Optional.Installtheapplicationsothatitwillstartautomatically

     whentheserverrestarts. Thiscommandgenerallyrequiresroot/sudoto

     execute.

     

     $cdcsvn 

     $sudo-Ebin/csvninstall (使用SUDO命令进行安装,目的是自动配置运行环境。

如JAVA环境等。

     

     Inadditiontoconfiguringyoursystemsothattheserverisstarted

     withthesystem,itwillalsowritethecurrentJAVA_HOMEandthe

     currentusernameintothefiledata/conf/csvn.conf. Youcaneditthis

     fileifneededasitcontrolsthestartupsettingsfortheapplication.

     BysettingtheJAVA_HOMEandRUN_AS_USERvariablesinthisfile,it

     ensurestheyaresetcorrectlywhentheapplicationisrun.

     

  5.Optional.Configureproxysettings. CollabNetSubversionEdgeneed

     accesstotheinternettocheckforandinstallupdates. Ifyouneedto

     gothroughaproxytoaccesstheinternet,thenyoucanconfigurethe

     proxybyeditingthedata/conf/csvn.conffilewhichwascreatedbythe

     previousstep. UncommentandedittheHTTP_PROXYvariabletoconfigure

     yourproxyserver.

     

  6.Starttheserver. Besurethatyouareloggedinasyourownuseridand

     notrunningasroot.运行如下命令时不要在ROOT用户运行。

     

     $bin/csvnstart (在CSVN目录下使用非ROOT用户运行程序。

     

     Thiswilltakeafewminutesandthescriptwillloopuntilitseesthat

     theserverisrunning. Iftheserverdoesnotstart,thentrystarting

     theserverwiththiscommand:

     

     $bin/csvnconsole  (如果启动不成功,使用这个命令进行重新配置)

     

     Thiswillstarttheserverbutoutputtheinitialstartupmessagesto

     theconsole.

  YoumustlogintotheCollabNetSubversionEdgebrowser-basedmanagement

  consoleandconfiguretheApacheserverbeforeitcanberunforthefirst

  time. TheUIofthemanagementconsolewritestheneededApache

  configurationfilesbasedontheinformationyouprovide.

  Thedefaultadministratorloginis:

可以使用如下地址进行登录

  Address:

http:

//localhost:

3343/csvn

  Username:

admin

  Password:

admin

  

  SubversionEdgealsostartsanSSL-protectedversionusingaself-signedSSL

  certificate. YoucanaccesstheSSLversiononthisURL:

  

  Address:

https:

//localhost:

4434/csvn

 

  YoucanforceuserstouseSSLfromtheServerconfiguration. Thiswillcause

  attemptstoaccessthesiteviaplainHTTPonport3343toberedirectedtothe

  secureporton4434.

5.Updates

  CollabNetSubversionEdgeincludesabuilt-inmechanismfordiscoveringand

  installingupdates. Youmustusethisfacilitytoinstallupdates. Donot

  downloadandrunanewversionoftheapplicationinstaller.

  Theupdatemechanismwillrequireyoutorestarttheserversattheendof

  theprocess,butitwilldoitforyou.

6.Documentation(相关文档)

  

  DocumentationforCollabNetSubversionEdgeisavailablehere:

  

  

  Context-sensitivehelpisalsolinkedtothislocationfromwithinthe

  application.

 

7.Knownissues

  -ForthelatestFAQ,visittheprojecthomepagehere:

(常见问题)

  

    

  -IfyoutrytoaccessanexistingBDB(BerkeleyDB)basedrepository

    throughCollabNetSubversionEdge,thenyouwillreceiveanalert"Failed

    toloadmoduleforFStype'bdb'."ThisisbecauseCollabNetSubversion

    EdgedoesnotsupportBDB. CollabNetrecommendsFSFSoverBDBforease

    ofmaintenanceandsupportability.

如果不能访问看下你的防火墙

   -Youcanaccesstheapplicationfromlocalhos

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > PPT模板 > 卡通动漫

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1