我在 ServiceDefinition 文件中使用以下 WorkerRole 元素创建了一个工作角色。我已将整个 C:\Program Files (x86)\MySQL\MySQL Server 5.5 文件夹复制到工作角色文件夹下的一个文件夹中,当我运行 cspack 和 csrun 时,它的名称是 mysql 它启动模拟器但它启动和停止角色,它有时不起作用,但它说 odbs@localhost 拒绝访问。感谢您的帮助
<WorkerRole enableNativeCodeExecution="true" name="MyPhpProj_MyWorkerRole" vmsize="Small">
<LocalStorage name="E2EStorage" cleanOnRoleRecycle="false" />
<Endpoints>
<InternalEndpoint name="PeerEndpointIn" protocol="tcp" />
<InternalEndpoint name="MasterElectionService" protocol="tcp" />
<InternalEndpoint name="MySQL" protocol="tcp" />
<InternalEndpoint name="InstanceManagerEndpontIn" protocol="tcp" />
</Endpoints>
<Runtime executionContext="limited">
<EntryPoint>
<ProgramEntryPoint commandLine="./mysql/bin/mysql.exe" setReadyOnProcessStart="true" />
</EntryPoint>
</Runtime>
<Imports/>
<LocalResources>
<LocalStorage cleanOnRoleRecycle="false" name="MySQL" sizeInMB="260"/>
<LocalStorage cleanOnRoleRecycle="false" name="MySQLDatastore" sizeInMB="20"/>
</LocalResources>
<ConfigurationSettings>
<Setting name="InitFile"/>
<Setting name="LogLevel"/>
<Setting name="ScheduledTransferPeriodInSeconds"/>
<Setting name="WindowsAzureStorageConnectionString"/>
</ConfigurationSettings>
</WorkerRole>