Top | Previous | Next |
Mapping a Network Drive |
Windows makes it possible to map drives on network servers to local drive letters so they can be accessed by users as if they were a local drive. The problem, however, is that Windows is not very consistent about how it handles such mapped drives when accessed from a Windows Service, such as the Ignition Gateway. When the service is started manually, the drives will be available, but when the system is rebooted, the service will no longer be able to access them. There may be users that wish to read or write data in Ignition using shared drives, and don't want to manually set up shared drives each time.
** NOTE: Must be using Ignition at least 7.5 and Java Service Wrapper 3.5.4 **
To make shared drives available to Ignition on startup, place the following lines in the ignition.conf file, which is located in the data folder of the main Ignition installation folder (usually C:\Program Files\Inductive Automation\Ignition\data for Windows users):
wrapper.share.1.location=\\fileserver\folder wrapper.share.1.target=Z: wrapper.share.1.type=DISK
Change the appropriate data for location and target to match the computer's actual setup. If your shared drives require authentication, add the following lines, filling in the appropriate data for user, domain, and password:
wrapper.ntservice.account=user wrapper.ntservice.password=password wrapper.share.1.account=domain\user wrapper.share.1.password=password
To turn on debugging to see what is causing network share connection issues, make sure to enable wrapper.debug = TRUE by removing the pound (#) sign in front of that line of code. The location of the log file is in the main Ignition installation folder as wrapper.log.
Other Notes:
wrapper.share.1.shutdown.unmap=TRUE
wrapper.share.1.startup.max_retries=2
wrapper.share.1.startup.retry_interval=10
wrapper.share.1.startup.failure=SHUTDOWN
Troubleshooting: Here a couple of the common problems that are encountered when mapping network shares:
Server not found
The debug output will show something like this if a drive can't be reached:
wrapper | Attempting to map the "\\fileserver\folder" share to "S:"... wrapper | Unable to map "S:". Attempt #1 (The network name cannot be found. (0x43)) wrapper | Attempting to map the "\\fileserver\folder" share to "S:"... wrapper | Unable to map "S:". Trying to continue. (The network name cannot be found. (0x43))
Incorrect Login Data
If the configured account or password are incorrect (or are missing) then the mapping will fail with a message like the following:
wrapper | Attempting to map the "\\myfileserver\commonshare" share to "S:"... wrapper | Unable to map "S:". Trying to continue. (Access is denied. (0x5)) |