0%

Epi Info™ 服务器部署(三):部署流程与弃坑

注意:此这篇博文很干,基本上不会有什么图片形式的东西,而且这片博文是对本次部署失败之后的一个说明,我希望对大家有帮助。同时,郑重提醒,如果你对阅读说明文能够忍受,请继续阅读,因为一定有惊喜

服务器部署流程前置准备

在解决完Epi Info™ 服务器部署(二):搞腚server SQL中的数据库问题之后,windows server 的部署乏善可陈,但是为了快速部署,还是提供几点建议。

服务器部署的官方文档可以通过这个链接下载,但是,文中还是有错误的(文章有大大的draft水印Q-Q),而且耽误了我好久时间。

首先放上服务器上的错误…

此外,由于之前向CDC的help desk 提交过bug,多数内容我将直接使用之前提交的文档,也就是说,这里会出现很多英文内容,请做好心理准备。同时我会在后续附上与CDC help desk沟通的邮件内容。Here we go:).

Environment

Hardware

Web server(our VPS is hosted on Tencent™ Cloud service):

Windows edition Windows server 2012 R2 Datacenter (English Version)
system Processor Intel(R) Xeon(R) CPU E5-26x v4 2.39 GHz
Installed memory(RAM):2.00 GB
System type 64-bit Operating System, x64-based processor

Software

Web erver:

IIS 8.5,.NET 4.5 and ASP .NET MVC4 were installed in advance.

Database server

SQL srever 2012 express with Sqk Server Management Studio(SSMS) were used for creating database.

SMTP server: we use enterprise mailbox server, the smtp=smtp.exmail.qq.com port=465

Epi Info web security was installed in advance.

Application installation:

Database configuration

We created the database by using the .sql script in the Database floder in the deployment package downloaded from the official site, and we followed the deployment manual strictly to create the database.

All database configuration was passed without any error,the GUID of user was generated using https://www.guidgen.com/ and so as organization GUID(which was encrypted with Epi info web security).

We successfully checked the database from remote using sql server authorization with the username and password created by .sql script.We also check the UserID and organization ID in 05InsertUserOrganization.sql script and found no err.

Application and Services Configuration

  1. We create inetpub\wwwroot\EpiInfoCloudDataCapture folder and copy the contents of EICloudDataCapture\ApplicationAndServices(but not the folder itself) in to the inetpub\wwwroot\EpiInfoCloudDataCapture folder.

  2. An IIS application called EpiInfoCloudDataCapture was then created using Default AppPool and linked to the folder created in step 1.And we also enabled Anonymous authentication & Forms Authentication.

  3. The web.config was modified with xfce4-mousepad(A linux text document editor).

  4. We update the email notification section in the web.config file with the smpt server listed above ,and we changed the port to 465 as the sercive provider required, the email username and password was rechecked and could be used with mutt.

  5. We updated the Log Setting section in the web.config file, we LOGGING_SEND_EMAIL_NOTIFICATION value to true and the email address provided can be accessed.

  6. We leave Caching section as default.

  7. The SERVER_NAME/APPLICATION_NAME strings were found and replaced with our_domain/EpiInfoCloudDataCapture using the editor feature.

  8. We leave password policy section as default.

  9. We use the default security keys(in one our the installations, we updated it, which didn’t influence the result).

  10. Connection string was modified and encrypted with Epi Info Web Security. Since the database and the application were in the same machiane, we add no port number follow the Data Source Name. All high light values in the deployment manual was checked at least for three times,and we copy the string in the right way, removed the additional spaces caused by pdf copy. No single space was ommitted in “Data Source”, “Initial Catalog”, “Persist Security Info” and “User ID” as noted.
    Then we replaced string in the EWEEntities section in the double quotes.

  11. We update the “EWEADO” section in the same way with step 10.

  12. We change nothing else in the web.config file, and tested the endpoint service in the Epi Info™ 7 in both remote and VPS envrionment. The Windows Authentication value is No, and the Binding Protocol used is Basic.The endpoint address was checked at least for three times, http://our_domain/EpiInfoCloudDataCapture/EWEManagerService.svc

  13. After click the Ping Service button we recived notification window said “Error:Fault exception occurred”.

Error log

We check the log in the Epidata7\Epi Info 7\Logs folder, and the log file says:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
Fault Exception ouccured !/n Stack:
Server stack trace:
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Epi.EWEManagerService.IEWEManagerService.GetOrganization(OrganizationRequest pRequest)
at Epi.EWEManagerService.EWEManagerServiceClient.GetOrganization(OrganizationRequest pRequest)
at Epi.Windows.Dialogs.OptionsDialog.ValidateEWESittings()
at Epi.Windows.Dialogs.OptionsDialog.button1_Click(Object sender, EventArgs e)/n Inner:The creator of this fault did not specify a Reason.

CDC Epi Info help desk

提交问题及完整流程

通过CDC Epi Info的官方网站下端help desk进入help desk 社群并注册,同时在社区内进行问题提交。

虽然是社群,但可以发现大多数人也是划划水,基本上不会有人回答你的问题。

我的完整上传报告可以通过这个链接下载

邮件沟通

很可惜的是大多数的邮件已经被我手动删除掉了还好我手动又找回了

仅以下图纪念我和Raj小哥的无数次对话…

由于邮件的信息过多,我将以截图的形式展示,并且附属上eml文件。

第一次沟通

Raj 2 me

me 2 Raj

第二次沟通

Raj 2 me

me 2 Raj

第三次沟通

Raj 2 me

me 2 Raj

第四次沟通

Raj 2 me

me 2 raj

第五次沟通

Raj 2 me

me 2 Raj

第六次沟通

Raj 2 me

以上六次沟通的邮件eml导出文件…自己看了下截图…隐隐有种美感。

社区大佬的帮助

还有很多很多值得铭记的会议,感谢#linuxba的onlylove大佬。

感谢这么多天来的帮助。。。

讯息与忠告

根据我和Raj的邮件来看,CDC大概在2020年7月分发布下一个版本的Epi Info Cloud Data Capture,因为之前最新版本的Epi Info web servuy 很容易就安装了,所以对于下一个版本还是有信心的。

以下是严正的忠告:

一看服务器是Win server的产品应该警惕!

IIS不值得,apache和nginx不香么?

还是Centos 和 Fedora不香?

此外…如果看见有Docker的那肯定要它啊!

还有一点很重要的,用户人群多,社区活跃的工具才有发展前景。

欢迎关注我的其它发布渠道