权限不允许服务与安装的虚拟文件夹/驱动器进行交互 [英] Permission is not letting Service interact with mounted virtual folder / drive

查看:74
本文介绍了权限不允许服务与安装的虚拟文件夹/驱动器进行交互的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在将文件夹安装到这样的虚拟磁盘上(在Windows XP上):

I'm mounting a folder to a virtual disk like this (I'm on Windows XP):

subst z: c:\virtual_disk

这对于一件事情来说完全可以,我正在运行一个Service(使用C ++/CreateService(...)创建),它可以将文件写入c:\ virtual_disk,但不能写入z:\

This works perfectly okay for one thing, I have a Service (created with C++ / CreateService(...) ) running and it can write files to c:\virtual_disk but not to z:\

我正在使用经典的fopen,fwrite等.

I'm using classic fopen, fwrite etc.

我认为我已经将问题缩小为某种许可问题,不过我不确定. 该服务在"localSystem"帐户上运行,该文件夹由我使用管理员帐户挂载.

I have, I think, narrowed down the problem to some sort of permission problem, I'm not sure though. The service runs on the "localSystem" account and the folder is mounted by me using an administrator account.

任何帮助表示赞赏!

推荐答案

映射是针对每个用户的.如果您使用自己的帐户映射了Z,则它不会捕获本地系统帐户.您可以使用自己的帐户运行该服务,也可以让它进行自己的映射.

Mapping is per user. If you mapped Z using your own account, it won't catch for the local system account. You can either run the service under your own account, or have it do its own mapping.

这篇关于权限不允许服务与安装的虚拟文件夹/驱动器进行交互的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆