InstallingDSpaceonFreeBSD1Beforewestart2Requiredsofware3Configurationrollercoaster3.
1Configuresystem3.
2ConfigurePostgreSQL3.
3ConfigureJAVA3.
4ConfigureTomcat3.
5ConfigureApache4InstallDspace5Handle6Cleanupanddaemonsstartup7Finalnotes1BeforewestartTomcatrunsas"www"bydefaultandifoundabiteasiertorundspaceunder"www"usertoo.
IfYoudecidedtocreate"dspace"userthenpayattentiontofilesystempermissions.
Using"www"maynotbegoodideawhenserverisaccessiblebyanyotheruser(s)thansystemadministrator(s).
IfYouliketorundspaceonport80/443,you'llneedApachewebserver.
Tomcatitselfusesonportssomewhere8000.
.
.
9000.
Sincedspacedoesnotcomefromports,there'snoexactorgoodplaceforit.
Thinksomethingout.
Solarisoftenuses"/opt"or"/export".
Youmaycreatethosemountpoints.
Ithougtthat"/data"isfinetoputmostofdspacerelatedstuffthere.
Youcancreatemountpoint"/dspace"butidon'tthinkit'sagoodideatoputdspacesoftwaredirectlytomointpoint.
I'sbettertohavedspaceinsomekindsub-directory(eg/mntpnt/dspace).
Alsoavoidconstructionlike/dspace/dspace,whichisjustconfusing.
Idecidedtocreatesliceslikethat:tcsh#df-h-tufsFilesystemSizeUsedAvailCapacityMountedon/dev/da0s1a1.
9G489M1.
3G27%//dev/da0s1d496M84K456M0%/tmp/dev/da0s1e1.
4G826M537M61%/usr/local/dev/da0s1f1.
9G160M1.
6G9%/vartcsh#df-h-tzfsFilesystemSizeUsedAvailCapacityMountedondata63G2.
1G60G3%/data/usr/srcand/usr/portsaremountedfromNFSserverifneeded.
IfYouneedthosetoo,thenchangeparitionsizesaccordinglyandmaybeuseseparatemountpointfor"/usr"insteadof"/usr/local".
"/data"isseconddisk.
However-layoutaboveshouldgivepicturehowmuchrequiredsoftwareusesdiskspace.
NB!
Beextremelycarefulifusingcopy-paste!
Alsonotethatwikipagemayeatsomespecificchars.
2RequiredsofwareInstalltheminthatorder.
Youcanfindthemfrom/usr/ports.
lang/perl5.
14lang/python27www/apache22databases/postgresql91-server[databases/postgresql91-contrib>/etc/fstabtcsh#zpoolcreatedata/dev/da1Sinceweuse"www"usertorundspace,weneedtoprovideworkingshellandhomeforit.
Butlet'salsotightenaccess.
tcsh#grepAllowGroups/etc/ssh/sshd_configAllowGroupswheeltcsh#mkdir/var/log/apache2tcsh#chownwww/var/log/apache2tcsh#mkdir-p/data/home/wwwtcsh#pwusermodwww-d/data/home/wwwtcsh#echo"exit">/data/home/www/.
logintcsh#chsh-s/bin/shwwwSeveralscriptsfromdspaceareusing"/bin/bash".
Tomakethemhappy:tcsh#ln-s/usr/local/bin/bash/bin/bash3.
2ConfigurePostgreSQLtcsh#echo'postgresql_enable="YES"'>>/etc/rc.
conftcsh#echo'postgresql_data="/data/pgsql"'>>/etc/rc.
conftcsh#mkdir/data/pgsqltcsh#chown-Rpgsql:pgsql/data/pgsql/tcsh#/usr/local/etc/rc.
d/postgresqlinitdbBydefaultPostgreSQLuses"local0",butifYouareusingpffirewallloggingalso,thenchangeto"local3"forexampletoavoidmessinguplogs.
tcsh#egrep"listen|syslog_facility"/data/pgsql/postgresql.
conflisten_addresses='localhost'syslog_facility='LOCAL3'tcsh#egrep-v"#|"^$/data/pgsql/pg_hba.
conflocalallpgsqltrusthostdspacedbdspace127.
0.
0.
1/32md5Startdatabaseengineandcreatedatabaseuser"dspace":tcsh#/usr/local/etc/rc.
d/postgresqlstarttcsh#createuser-Upgsql-S-d-R-Pdspace#-S=--no-superuser#-d=userwillbeallowedtocreatedatabases#-R=--no-createrole#-Pcreateuserwillissueapromptforthepasswordortcsh#createuser-Upgsql-PdspaceEnterpasswordfornewrole:s0mepwEnteritagain:s0mepwShallthenewrolebeasuperuser(y/n)nShallthenewrolebeallowedtocreatedatabases(y/n)yShallthenewrolebeallowedtocreatemorenewroles(y/n)nCreatedatabasecalled"dspacedb":tcsh#createdb-Upgsql-Odspace-EUNICODEdspacedb3.
3ConfigureJAVAtcsh#echo"JAVA_HOME=/usr/local/openjdk6/">>/usr/local/etc/javavm_opts.
confFollowingaffectsonlycommandsfromshell.
IftheydifferMakesurethatbothparameters(-Xmxand-Xms)dohavesamevalueandatleast512m!
and/orarelessthan512,thenYoumayencounterproblemslateronifusing"antupdate"(ifupgradingdspace).
tcsh#echo'JAVA_OPTS="-Xmx512m-Xms512m"'>>/usr/local/etc/javavm_opts.
conf3.
4ConfigureTomcatOpenfilewithYourfavoritevi.
Locaterelevantlinesandupdatetobe:/usr/local/apache-tomcat-7.
0/conf/server.
xmlNB!
PayattentiontoUTF!
Onceagainifoundmorereasonablenottocopy(orsymlink)webappstotomcatappBasedirassuggestsdspaceofficialdocumentation.
Insteadi'mchangintomcatappBasetopointtodspacewebapps.
Alsoputtomcatlogswithotherwww/apachelogs.
Originallinesarecommentedoutandmylinesmarkedbold.
-->Finallyconfigureworker:tcsh#grep-v"#"/usr/local/etc/apache22/workers.
propertiesworker.
list=localhost-workerworker.
localhost-worker.
port=8009worker.
localhost-worker.
host=localhostworker.
localhost-worker.
type=ajp13worker.
localhost-worker.
lbfactor=13.
5ConfigureApacheSomelinesareomittedfromoutput.
Alsoconfigure"apache22/extra/httpd-mpm.
conf"and"httpd-default.
conf"tosuitYou.
Alsodon'tforgetapachecertificates.
tcsh#egrep-v"#|"^$/usr/local/etc/apache22/httpd.
conf/*/LoadModulerewrite_modulelibexec/apache22/mod_rewrite.
soLoadModulejk_modulelibexec/apache22/mod_jk.
so/*/ErrorLog"/var/log/apache2/httpd-error.
log"/*/CustomLog"|/usr/local/sbin/rotatelogs-l/var/log/apache2/httpd-access_%Y-%m-%d.
log86400"combined/*/Includeetc/apache22/extra/httpd-mpm.
confIncludeetc/apache22/extra/httpd-default.
confIncludeetc/apache22/extra/httpd-ssl.
conf/*/Includeetc/apache22/Includes/*.
confNameVirtualHost*:80#relativepathto/usr/localJkWorkersFileetc/apache22/workers.
propertiesJkShmFile/var/run/jk-runtime-statusJkLogLevelerrorJkLogFile/var/log/apache2/mod_jk.
logServerNamedspace.
example.
comDocumentRoot/usr/local/www/apache22/dataJkMount/xmluilocalhost-workerJkMount/xmlui/*localhost-workerJkMount/solrlocalhost-workerJkMount/solr/*localhost-workerJkMount/oailocalhost-workerJkMount/oai/*localhost-workerRewriteEngineOnRewriteRule^/$/xmlui/[PT]RewriteRule^/$/solr/[PT]RewriteRule^/$/oai/[PT]RewriteCondhttp://%{HTTP_HOST}%{REQUEST_URI}(.
*)-login(.
*)[OR]RewriteCondhttp://%{HTTP_HOST}%{REQUEST_URI}(.
*)/register(.
*)[OR]RewriteCondhttp://%{HTTP_HOST}%{REQUEST_URI}(.
*)/forgot(.
*)RewriteRule(.
*)https://%{HTTP_HOST}%{REQUEST_URI}#CustomLog"|/usr/local/sbin/rotatelogs-l/var/log/apache2/dspace.
example.
com-access-%Y-%m-%d.
log86400"combinedErrorLog/var/log/apache2/dspace.
example.
com-error.
logtcsh#egrep-v"#|"^$/usr/local/etc/apache22/extra/httpd-ssl.
confListen443/*/ServerNamedspace.
example.
com:443ServerAdminhostmaster@example.
comDocumentRoot"/usr/local/www/apache22/data"JkMount/xmluilocalhost-workerJkMount/xmlui/*localhost-workerJkMount/solrlocalhost-workerJkMount/solr/*localhost-workerJkMount/oailocalhost-workerJkMount/oai/*localhost-workerRewriteEngineOnRewriteRule^/$/xmlui/[PT]RewriteRule^/$/solr/[PT]RewriteRule^/$/oai/[PT]ErrorLog"|/usr/local/sbin/rotatelogs/var/log/apache2/https-error-%Y-%m-%d.
log5M"TransferLog"|/usr/local/sbin/rotatelogs/var/log/apache2/https-access-%Y-%m-%d.
log86400"/*/SSLCertificateFile"/usr/local/etc/apache22/certs/dspace.
example.
com.
crt"SSLCertificateKeyFile"/usr/local/etc/apache22/certs/dspace.
example.
com.
key"SSLCertificateChainFile"/usr/local/etc/apache22/certs/dspace-bundle.
example.
com.
crt"/*/SSLOptions+StdEnvVars+ExportCertData4InstallDspacetcsh#mkdir/data/dspacetcsh#cd/data*http://sourceforge.
net/projects/dspace/files/DSpace%20Stable/1.
8.
1/dspace-1.
8.
1-src-release.
tar.
gztcsh#fetch-odspace-1.
8.
1-src-release.
tar.
gz/download\*(http://sourceforge.
net/projects/dspace/files/DSpace%20Stable/1.
8.
1/dspace-1.
8.
1-src-release.
tar.
gz/download*)tcsh#tarxzfdspace-1.
8.
1-src-release.
tar.
gztcsh#cd/data/dspace-1.
8.
1-src-release/dspace/config/ConfigurewhateverauthenticationYouneed.
InfollowingexampledspaceisconfiguredtouseLDAP.
tcsh#egrep-v"#|"^$modules/authentication.
cfgplugin.
sequence.
org.
dspace.
authenticate.
AuthenticationMethod=org.
dspace.
authenticate.
LDAPHierarchicalAuthenticationOpen/data/dspace-1.
8.
1-src-release/dspace/config/andmakeYourchanges:dspace.
cfgdspace.
dir=/data/dspacedspace.
hostname=dspace.
example.
comdspace.
baseUrl=http://dspace.
example.
comdspace.
url=${dspace.
baseUrl}/xmluidspace.
name=DspaceatExample.
Comdb.
name=postgresdb.
url=jdbc:postgresql://localhost:5432/dspacedbdb.
driver=org.
postgresql.
Driverdb.
username=dspacedb.
password=s0mepwdb.
maxconnections=30db.
maxwait=5000db.
maxidle=-1db.
statementpool=truemail.
server=smtp.
example.
commail.
server.
port=25mail.
from.
address=dspace-noreply@example.
comfeedback.
recipient=dspace-help@example.
commail.
admin=dspace-help@example.
comalert.
recipient=postmaster@example.
comregistration.
notify=dspace-help@example.
commail.
charset=UTF-8mail.
allowed.
referrers=localhost,dspace.
example.
commail.
server.
disabled=falsedefault.
language=en_USassetstore.
dir=${dspace.
dir}/assetstorelog.
init.
config=${dspace.
dir}/config/log4j.
propertieslog.
dir=/var/log/apache2/search.
dir=${dspace.
dir}/search/*/handle.
canonical.
prefix=http://hdl.
handle.
net/handle.
prefix=12345handle.
dir=${dspace.
dir}/handle-server/*/upload.
max=536870912default.
locale=enxmlui.
supported.
locales=enxmlui.
force.
ssl=truexmlui.
user.
registration=falseConfigureLDAPmodule.
Asi'mwritingitsnotpossibletoconfiguremultipleldapserversinordertoachievefailover(eg.
ldap://ldapserver1ldapserver2/blahblah).
tcsh#egrep-v"#|"^$modules/authentication-ldap.
cfgenable=trueautoregister=trueprovider_url=ldaps://myldap.
example.
com/id_field=uidobject_context=ou=people,dc=example,dc=comsearch_context=ou=people,dc=example,dc=comemail_field=mailsurname_field=sngivenname_field=givenNamephone_field=telephoneNumbersearch_scope=2search.
user=cn=ldap-bind,cn=Users,dc=example,dc=comsearch.
password=s0mepw2netid_email_domain=@example.
comAsYoucansee,i'musingLDAPS.
We'llbebacktoitlateron.
Followingcommandfetchessoftwarefrominternetinordertobuilddspace.
Thissoftwillbeplacedunder$HOME/.
m2/directory.
Inmycase/root/.
m2/.
IfYouwantto,Youcanbuilddspaceas"www"user.
I'mdoingitasroot.
tcsh#/data/dspace-1.
8.
1-src-releasetcsh#mvnpackagetcsh#cd/data/dspace-1.
8.
1-src-release/dspace/target/dspace-1.
8.
1-build/tcsh#antfresh_installAslookingfrommynotestherewasanissuewithcreatingPostgreSQLdatabase(PL/pgSQLrelated).
Seemsthatfollowinghelpedout.
However-ican'tverifyorconfirmitatthemoment.
tcsh#dropdb-Upgsqldspacedbtcsh#createdb-Upgsql-Odspace-EUNICODEdspacedbtcsh#psql-hlocalhost-Udspace-f/data/dspace-1.
8.
1-src-release/dspace/etc/postgres/database_schema.
sqldspacedbAndfinallysetproperpermissons:tcsh#chown-Rwww:www/data/dspaceJustincaseverify/data/dspace/config/log4j.
propertiesdoesn'tbugYou.
Removeunneeded"/"Theremaybe3erraticlineslikethisone:/var/log/apache2//cocoon.
logAlsoverifythatandarecorrect.
/data/dspace/config/modules/authentication.
cfgauthentication-ldap.
cfgSinceiliketokeepalldspacerelatedthingsinoneplaceandihaveprettysmall/usr/local:tcsh#mkdir-p/data/dspace/tc-webinf/work/upload-dirtcsh#mkdir-p/data/dspace/tc-webinf/work/cache-dirtcsh#chown-Rwww:www/data/dspace/tc-webinftcsh#grepdspace/data/dspace/webapps/xmlui/WEB-INF/cocoon/properties/core.
propertiesorg.
apache.
cocoon.
uploads.
directory=/data/dspace/tc-webinf/work/upload-dirorg.
apache.
cocoon.
cache.
directory=/data/dspace/tc-webinf/work/cache-dirorg.
apache.
cocoon.
work.
directory=/data/dspace/tc-webinf/work/Don'tforgetthisoneifYouupgradedYourdspace-cocoonmayfill/usr/local.
Ifneeded,configureOAIalso::/data/dspace/config/oaicat.
properties/*/Crosswalks.
mods=org.
dspace.
app.
oai.
PluginCrosswalkCrosswalks.
mets=org.
dspace.
app.
oai.
PluginCrosswalkCrosswalks.
qdc=org.
dspace.
app.
oai.
PluginCrosswalkSetupcrontabs.
PATHisrequired.
dspace~#crontab-l-uwww#dspacewwwcrontabPATH=/data/dspace/bin:/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin#Sendoutsubscriptione-mailsat01:00everyday01***/data/dspace/bin/dspacesub-daily#Runthemediafilterat02:00everyday02***/data/dspace/bin/dspacefilter-media>/dev/null2>&1#Runthechecksumcheckerat03:0003***/data/dspace/bin/dspacechecker-lp>/dev/null2>&1#Mailtheresultstothesysadminat04:0004***/data/dspace/bin/dspacechecker-emailer-c>/dev/null2>&1#Runstatanalysis01***/data/dspace/bin/dspacestat-general01***/data/dspace/bin/dspacestat-monthly02***/data/dspace/bin/dspacestat-report-general02***/data/dspace/bin/dspacestat-report-monthlyNowinstallcertificatesrequiredtouseLDAPS.
MakesurethatYouhaveJAVA_HOMEset:tcsh#setJAVA_HOME=/usr/local/openjdk6tcsh#echo$JAVA_HOME/usr/local/openjdk6tcsh#keytool-import-file/tmp/myldap-clients.
example.
com.
crt-aliasmyldap.
example.
com-keystore$JAVA_HOME/jre/lib/security/cacertsEnterkeystorepassword:'changeit'>/var/log/apache2/catalina-`date+%Y-%m-%d`.
log2>&1"tomcat7_catalina_tmpdir="/tmp"handle_server_enable="YES"postgresql_enable="YES"postgresql_data="/data/pgsql"tcsh#sync;sync;reboot7FinalnotesIfYoushouldlateronupgrade"openjdk",thenYouneedtoimportLDAPcertificateagain-you'llloseit!
IfYoushouldupgrademod_jkport,thendontforgettouncomment"#LoadModulejk_module.
.
.
.
"line!
Afterdspaceupgradedontforgetcocoon:/data/dspace/webapps/xmlui/WEB-INF/cocoon/properties/core.
propertiesImplementbackupsandmonitoring!
Implementfirewall.
Ifusingpf:WEB_PORTS="{80,443}"HANDLE_PORTS="{2641,8000}"#wwwpassinlogquickon$EXT_IFprototcpfromanytoport$WEB_PORTS#dspacehandleservicepassinlogquickon$EXT_IFprototcpfromanytoport$HANDLE_PORTSMaybeYouneedSSHtoo,butingeneralkeepblocking.
Pleasereadcarefully.
dspacedocumentation
很久没有分享PhotonVPS的消息,最近看到商家VPS主机套餐有一些更新所以分享下。这是一家成立于2008年的国外VPS服务商,Psychz机房旗下的站点,主要提供VPS和独立服务器等,数据中心包括美国洛杉矶、达拉斯、芝加哥、阿什本等。目前,商家针对Cloud VPS提供8折优惠码,优惠后最低2G内存套餐每月4美元起。下面列出几款主机配置信息。CPU:1core内存:2GB硬盘:30GB NVm...
wordpress简洁英文主题,wordpress简洁通用大气的网站风格设计 + 更适于欧美国外用户操作体验,完善的外贸企业建站功能模块 + 更好的移动设备特色模块支持,更高效实用的后台自定义设置 + 标准高效的代码程序功能结构,更利于Goolge等国际搜索引擎的SEO搜索优化和站点收录排名。点击进入:wordpress简洁通用型高级外贸主题主题价格:¥3980 特 惠 价:¥1280安装环境:运...
已经有一段时间没有分享阿里云服务商的促销活动,主要原因在于他们以前的促销都仅限新用户,而且我们大部分人都已经有过账户基本上促销活动和我们无缘。即便老用户可选新产品购买,也是比较配置较高的,所以就懒得分享。这不看到有阿里云金秋活动,有不错的促销活动可以允许产品新购。即便我们是老用户,但是比如你没有购买过他们轻量服务器,也是可以享受优惠活动的。这次轻量服务器在金秋活动中力度折扣比较大,2G5M配置年付...
rewritecond为你推荐
域名查询我的电脑域名怎么查域名价格域名费用大概是多少?域名注册查询如何查域名有没有被注册国内ip代理全国各省代理IP域名备案买域名要备案吗免费网站空间那里有免费网站空间国内最好的虚拟主机国内虚拟主机哪家的好?韩国虚拟主机韩国虚拟主机好还是香港的好韩国虚拟主机香港和韩国的虚拟主机哪个比较好?虚拟主机控制面板虚拟主机控制面板是什么?
shopex虚拟主机 美国和欧洲vps 域名解析服务器 贝锐花生壳域名 草根过期域名 香港加速器 外贸主机 回程路由 bgp双线 cdn加速原理 免费phpmysql空间 gtt 搜索引擎提交入口 台湾谷歌 支付宝扫码领红包 华为云服务登录 cloudlink 阿里云官方网站 数据库空间 免费个人主页 更多