function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Sandy GaliSandy Gali 

Issue using Dataloader CLI

Hi All, 
         I am getting the below error when I trying to use a
dataloader CLI. I have followed the Salesforce documentation and this blog
http://www.jitendrazaa.com/blog/salesforce/tutorial-of-command-line-dataloader-salesforce/

I am not able to figure out what the issue is  and any help would be greatly appreciated

CONFIG.properties
#Tue Oct 11 2016
sfdc.debugMessages=true

process.encryptionKeyFile=C:\Users\SF\Desktop\CLI\Key.txt
sfdc.debugMessagesFile =C:\Users\SF\Desktop\CLI\logfile.log
sfdc.endpoint=https://test.salesforce.com
sfdc.username=<myusername>
sfdc.password=<encrypted password>
sfdc.proxyUsername=
sfdc.proxyPassword=
sfdc.proxyHost=
sfdc.proxyPort=
sfdc.loadBatchSize=200
sfdc.timeoutSecs=600

process-conf.xml

<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
<beans>
<bean id="Account"
    class="com.salesforce.dataloader.process.ProcessRunner"
    singleton="false">
        <description>Export Account Data</description>
        <property name="name" value="Account"/>
        <property name="configOverrideMap">
        <map>
            <entry key="sfdc.enableLastRunOutput" value="false"/>
            <entry key="sfdc.debugMessagesFile" value="C:\Users\SF\Desktop\CLI\sfdcSoapTrace.log"/>
            <entry key="sfdc.endpoint" value="https://test.salesforce.com"/>
            <entry key="sfdc.username" value="<username>"/>
            <entry key="sfdc.password" value="<encrypted password>"/>
            <entry key="sfdc.entity" value="Account"/>
            <entry key="process.operation" value="extract"/>
            <entry key="sfdc.extractionRequestSize" value="500"/>
            <entry key="sfdc.extractionSOQL" value="SELECT Id FROM Account"/>
            <entry key="dataAccess.name" value="C:\Users\SF\Desktop\CLI\AccountExport.csv"/>
            <entry key="dataAccess.type" value="csvWrite"/>
            <entry key="dataAccess.writeUTF8" value="true" />
        </map>
        </property>
    </bean>
</beans>


ERROR

2016-10-11 17:00:35,599 INFO  [main] controller.Controller initLog (Controller.j
ava:389) - Using built-in logging configuration, no log-conf.xml in C:\Program F
iles (x86)\salesforce.com\Data Loader\bin\log-conf.xml
2016-10-11 17:00:35,603 INFO  [main] controller.Controller initLog (Controller.j
ava:391) - The log has been initialized
2016-10-11 17:00:35,606 INFO  [main] process.ProcessConfig getBeanFactory (Proce
ssConfig.java:104) - Loading process configuration from config file: C:\Users\sg
387088\Desktop\CLI\process-conf.xml
2016-10-11 17:00:35,656 INFO  [main] support.AbstractApplicationContext prepareR
efresh (AbstractApplicationContext.java:495) - Refreshing org.springframework.co
ntext.support.FileSystemXmlApplicationContext@cd5f8b: startup date [Tue Oct 11 1
7:00:35 EST 2016]; root of context hierarchy
2016-10-11 17:00:35,683 INFO  [main] xml.XmlBeanDefinitionReader loadBeanDefinit
ions (XmlBeanDefinitionReader.java:315) - Loading XML bean definitions from file
 [C:\Users\SF\Desktop\CLI\process-conf.xml]
2016-10-11 17:00:35,711 INFO  [main] support.DefaultListableBeanFactory preInsta
ntiateSingletons (DefaultListableBeanFactory.java:557) - Pre-instantiating singl
etons in org.springframework.beans.factory.support.DefaultListableBeanFactory@15
3c375: defining beans [Account]; root of factory hierarchy
2016-10-11 17:00:35,740 INFO  [Account] controller.Controller initConfig (Contro
ller.java:327) - config dir created at C:\Users\SF\Desktop\CLI
2016-10-11 17:00:35,744 ERROR [Account] config.Config initEncryption (Config.jav
a:732) - Error initializing encryption for key file C:UsersSFDesktopCLIKey
.txt: Cannot Access Key File: C:UsersSFDesktopCLIKey.txt
2016-10-11 17:00:35,745 FATAL [Account] process.ProcessRunner topLevelError (Pro
cessRunner.java:238) - Unable to run process Account
java.lang.RuntimeException: com.salesforce.dataloader.exception.ControllerInitia
lizationException: Error loading config file: C:\Users\SF\Desktop\CLI\conf
ig.properties.  Please make sure that it exists and is readable
        at com.salesforce.dataloader.process.ProcessRunner.run(ProcessRunner.jav
a:112)
        at com.salesforce.dataloader.process.ProcessRunner.run(ProcessRunner.jav
a:100)
        at com.salesforce.dataloader.process.ProcessRunner.main(ProcessRunner.ja
va:253)
Caused by: com.salesforce.dataloader.exception.ControllerInitializationException
: Error loading config file: C:\Users\SF\Desktop\CLI\config.properties.  P
lease make sure that it exists and is readable
        at com.salesforce.dataloader.controller.Controller.initConfig(Controller
.java:360)
        at com.salesforce.dataloader.controller.Controller.<init>(Controller.jav
a:110)
        at com.salesforce.dataloader.controller.Controller.getInstance(Controlle
r.java:212)
        at com.salesforce.dataloader.process.ProcessRunner.run(ProcessRunner.jav
a:110)
        ... 2 more
Caused by: com.salesforce.dataloader.exception.ConfigInitializationException: Er
ror initializing encryption for key file C:UsersSFDesktopCLIKey.txt: Canno
t Access Key File: C:UsersSFDesktopCLIKey.txt
        at com.salesforce.dataloader.config.Config.initEncryption(Config.java:73
3)
        at com.salesforce.dataloader.config.Config.postLoad(Config.java:647)
        at com.salesforce.dataloader.config.Config.load(Config.java:630)
        at com.salesforce.dataloader.config.Config.load(Config.java:606)
        at com.salesforce.dataloader.controller.Controller.initConfig(Controller
.java:354)
        ... 5 more
karthikeyan perumalkarthikeyan perumal
Hello, 

Remove this line from your CONFIG.properties

process.encryptionKeyFile=C:\Users\SF\Desktop\CLI\Key.txt

Try to run it once again 

Hoep this will help you, 

Thanks
karthik

 
Sandy GaliSandy Gali
I did this too, but that did not help, any other ideas ?