无法浏览某些 pdf 和文档
我有一个网站,它使用 Microsoft 索引服务来索引和查询包含 pdf、rtf、mht 和 doc 类型的各种文档的目录。 索引和查询工作良好(在大多数情况下); 但是,有些文件会加载,而另一些则不会。
这是一个使用 IIS 6 运行站点的 Windows Server 2003 机器。
索引目录是站点根目录的子目录(即 http://my.domain.com/files/)。
URL 中的文件路径准确; 但是,我只能访问每种文件类型的部分文件。 我无法访问的文件给出 404 文件未找到。 我可以通过 Windows 资源管理器打开所有文件;但是,尝试通过 http 浏览器打开它们却时好时坏。
有谁经历过这个问题并知道如何解决它? 有人知道为什么我可以访问某些文件但不能访问其他文件吗? 有没有人对尝试此操作有什么建议(即所有者是否重要或类似的事情?)?
编辑: 以下是错误文件的请求和响应标头:
GET /files/file1.pdf HTTP/1.1 接受:image/gif、image/jpeg、image/pjpeg、image/pjpeg、application/x-shockwave-flash、application/xaml+xml、application/vnd.ms-xpsdocument、application/x-ms-xbap、application/ x-ms-application、application/x-silverlight、application/vnd.ms-excel、application/vnd.ms-powerpoint、application/msword、/ 接受语言:en-us 用户代理:Mozilla/4.0(兼容;MSIE 8.0;Windows NT 5.1;Trident/4.0;.NET CLR 1.1.4322;.NET CLR 2.0.50727;.NET CLR 3.0.04506.30;.NET CLR 3.0.04506.590;. .NET CLR 3.0.04506.648;.NET CLR 3.5.21022;.NET CLR 3.0.4506.2152;.NET CLR 3.5.30729 接受编码:gzip、deflate 代理连接:保持活动状态 主机:my.domain.com
HTTP/1.1 404 未找到 内容长度:1635 内容类型:text/html 服务器:微软-IIS/6.0 X-Powered-By: ASP.NET 日期:2009 年 6 月 1 日星期一 15:38:54 GMT [排除典型的 404 页面标记]
这是好文件的请求/响应标头:
GET /files/file2.pdf HTTP/1.1 接受:image/gif、image/jpeg、image/pjpeg、image/pjpeg、application/x-shockwave-flash、application/xaml+xml、application/vnd.ms-xpsdocument、application/x-ms-xbap、application/ x-ms-application、application/x-silverlight、application/vnd.ms-excel、application/vnd.ms-powerpoint、application/msword、/ 接受语言:en-us 用户代理:Mozilla/4.0(兼容;MSIE 8.0;Windows NT 5.1;Trident/4.0;.NET CLR 1.1.4322;.NET CLR 2.0.50727;.NET CLR 3.0.04506.30;.NET CLR 3.0.04506.590;. NET CLR 3.0.04506.648;.NET CLR 3.5.21022;.NET CLR 3.0.4506.2152; 接受编码:gzip、deflate 代理连接:保持活动状态 主机:my.domain.com
HTTP/1.1 200 确定 内容长度:352464 内容类型:应用程序/pdf 最后修改时间:2009 年 1 月 13 日星期二 15:27:35 GMT 接受范围:字节 ETag:“74ccc5759375c91:2a47” 服务器:微软-IIS/6.0 X-Powered-By: ASP.NET 日期:2009 年 6 月 1 日星期一 15:50:33 GMT
I have a web site that uses Microsoft Indexing Service to index and query a directory that holds various documents of type pdf, rtf, mht, and doc. The indexing and querying works well (for the most part); however, some files will load while others will not.
This is a Windows Server 2003 box running the site using IIS 6.
The indexed directory is a sub directory off of the site's root directory (i.e. http://my.domain.com/files/).
The file paths are accurate in the URL; however, I can only access some of the files of each file type. The files that I cannot access give a 404 File Not Found. I am able to open all files via windows explorer;however, attempting to open them via a browser over http is hit and miss.
Has anyone experienced this issue and know how to resolve it? Anyone have any idea why I could access some files but not others? Does anyone have any recommendations on what to look into to try this (i.e. does owner matter or something like that?)?
EDIT:
Here is the Request and Response Headers for a bad file:
GET /files/file1.pdf HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/xaml+xml, application/vnd.ms-xpsdocument, application/x-ms-xbap, application/x-ms-application, application/x-silverlight, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, /
Accept-Language: en-us
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.590; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
Accept-Encoding: gzip, deflate
Proxy-Connection: Keep-Alive
Host: my.domain.com
HTTP/1.1 404 Not Found
Content-Length: 1635
Content-Type: text/html
Server: Microsoft-IIS/6.0
X-Powered-By: ASP.NET
Date: Mon, 01 Jun 2009 15:38:54 GMT
[typical 404 page markup excluded]
Here is the Request/Response headers for the good file:
GET /files/file2.pdf HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/xaml+xml, application/vnd.ms-xpsdocument, application/x-ms-xbap, application/x-ms-application, application/x-silverlight, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, /
Accept-Language: en-us
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.590; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
Accept-Encoding: gzip, deflate
Proxy-Connection: Keep-Alive
Host: my.domain.com
HTTP/1.1 200 OK
Content-Length: 352464
Content-Type: application/pdf
Last-Modified: Tue, 13 Jan 2009 15:27:35 GMT
Accept-Ranges: bytes
ETag: "74ccc5759375c91:2a47"
Server: Microsoft-IIS/6.0
X-Powered-By: ASP.NET
Date: Mon, 01 Jun 2009 15:50:33 GMT
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
要解决此问题,请安装 Internet Explorer 的最新累积安全更新。
有关 Internet Explorer 最新累积安全更新的更多技术信息,请访问下面的 Microsoft 网站
To resolve this problem, install the most current cumulative security update for Internet Explorer.
For more technical information about the most current cumulative security update for Internet Explorer, visit the following Microsoft Web site
我发现问题出在 IIS 的配置上。 负责遇到此问题的服务器的系统管理员创建了与正在索引的子目录同名的虚拟目录。 当 IIS 解析路径时,文档将从虚拟目录提供,而不是像应有的那样从子目录提供。
I have discovered the issue being at the configuration of IIS. The Sys admin in charge of the server that was experience this issue made Virtual Directory with the same name as the subdirectory that was being indexed. When IIS would resolve the path, the documents would be served up from the virtual directory instead of the sub directory like it should have been.