Sys.Webforms.PageRequestManagerServerErrorException服务器错误503(Sys.Webforms.PageRequestManagerServerErrorException server error 503)

我正在引用此链接,因为我必须将文件从一个服务器写入另一个服务器我正在尝试在Windows服务器上创建自定义域帐户。

我在链接中完成了所有操作但是当我浏览网站时出现以下错误:

我正在考虑以下错误链接 。

但是还没有成功

当我为应用程序池授权我的网络服务时出现此错误

Access to the path '\\servername\c$\fromvini\abc.text is denied.'

I'm Referring to this link as I have to write file from one server to another I'm trying to create a custom domain account on Windows server.

I have done all as told in the link however when I browse the site I get the following error:

I was refferring the following link for the error.

However no success yet

I get this error when I authorise my network service for the application pool

Access to the path '\\servername\c$\fromvini\abc.text is denied.'

最满意答案

为了能够在远程计算机上读取文件,您有两种方法。

第一种方式 - 两台计算机都拥有相同的帐户。

两台计算机必须具有相同的用户名和密码 在运行该站点的IIS服务器上,您将该帐户设置为运行该站点的池,不要将此帐户设置为服务帐户,但您需要更正设置站点目录才能运行。 在远程服务器上,您可以通过此帐户查看共享连接,还可以更改目录和文件的凭据以获得该帐户的权限。

第二种方式 - 使用与池不同的登录名打开文件

该网站是在游戏池使用的情况下运行的,也许是服务帐户,我们不在乎。 在第二台服务器上设置您将在第一台服务器上使用的用户名/密码。 您打开文件的共享,并更改该帐户的文件权限。 您使用Impersonate在其他用户下运行文件访问。

例如:

using ( new Impersonator( "myUsername", "myDomainname", "myPassword" ) ) { //... read the file }

和一个完整的例子: http : //forums.asp.net/t/1840443.aspx/1?How+to+copy+file+from+network+share+in+VB

To been able to read the file on the remote computer you have two ways.

First way - both computers have the same account.

Both computers must have the same user name / and password On the IIS server that runs the site, you place that account to run the pool of that site, do not make this account as service account, but you need to correct setup the site directory to be able to run. On the remote server you let and the share connection to be able to seen by this account, but also you change the credential of the directory and the files to have permission for that account.

Second way - open the file with different login than the pool

The site is run under what ever pool use, maybe service account, we do not care. Setup on the second server the user name / password that you going to use on the first one. You open the share of the files, and change the file permissions for that acount. You use the Impersonate to run under the other user the File access.

for example:

using ( new Impersonator( "myUsername", "myDomainname", "myPassword" ) ) { //... read the file }

and one full example: http://forums.asp.net/t/1840443.aspx/1?How+to+copy+file+from+network+share+in+VB

Sys.Webforms.PageRequestManagerServerErrorException服务器错误503(Sys.Webforms.PageRequestManagerServerErrorException server error 503)

我正在引用此链接,因为我必须将文件从一个服务器写入另一个服务器我正在尝试在Windows服务器上创建自定义域帐户。

我在链接中完成了所有操作但是当我浏览网站时出现以下错误:

我正在考虑以下错误链接 。

但是还没有成功

当我为应用程序池授权我的网络服务时出现此错误

Access to the path '\\servername\c$\fromvini\abc.text is denied.'

I'm Referring to this link as I have to write file from one server to another I'm trying to create a custom domain account on Windows server.

I have done all as told in the link however when I browse the site I get the following error:

I was refferring the following link for the error.

However no success yet

I get this error when I authorise my network service for the application pool

Access to the path '\\servername\c$\fromvini\abc.text is denied.'

最满意答案

为了能够在远程计算机上读取文件,您有两种方法。

第一种方式 - 两台计算机都拥有相同的帐户。

两台计算机必须具有相同的用户名和密码 在运行该站点的IIS服务器上,您将该帐户设置为运行该站点的池,不要将此帐户设置为服务帐户,但您需要更正设置站点目录才能运行。 在远程服务器上,您可以通过此帐户查看共享连接,还可以更改目录和文件的凭据以获得该帐户的权限。

第二种方式 - 使用与池不同的登录名打开文件

该网站是在游戏池使用的情况下运行的,也许是服务帐户,我们不在乎。 在第二台服务器上设置您将在第一台服务器上使用的用户名/密码。 您打开文件的共享,并更改该帐户的文件权限。 您使用Impersonate在其他用户下运行文件访问。

例如:

using ( new Impersonator( "myUsername", "myDomainname", "myPassword" ) ) { //... read the file }

和一个完整的例子: http : //forums.asp.net/t/1840443.aspx/1?How+to+copy+file+from+network+share+in+VB

To been able to read the file on the remote computer you have two ways.

First way - both computers have the same account.

Both computers must have the same user name / and password On the IIS server that runs the site, you place that account to run the pool of that site, do not make this account as service account, but you need to correct setup the site directory to be able to run. On the remote server you let and the share connection to be able to seen by this account, but also you change the credential of the directory and the files to have permission for that account.

Second way - open the file with different login than the pool

The site is run under what ever pool use, maybe service account, we do not care. Setup on the second server the user name / password that you going to use on the first one. You open the share of the files, and change the file permissions for that acount. You use the Impersonate to run under the other user the File access.

for example:

using ( new Impersonator( "myUsername", "myDomainname", "myPassword" ) ) { //... read the file }

and one full example: http://forums.asp.net/t/1840443.aspx/1?How+to+copy+file+from+network+share+in+VB