Upgraded my WHMCS to the latest, so also updated to the latest WHMCS module.
However resource updates aren’t working, they fail with error:
“UsageUpdate Fault: (Code: 0, Message: GetPackageBandwidth Fault: (Code: 0, Message: SOAP Fault: (Code: 0, Message: System.Web.Services.Protocols.SoapException: Server was unable to read request. —> System.InvalidOperationException: There is an error in the XML document. —> System.FormatException: Input string was not in a correct format. at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) at System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReader1.Read131_GetPackageBandwidth() at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, String encodingStyle, XmlDeserializationEvents events) — End of inner exception stack trace — at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, String encodingStyle, XmlDeserializationEvents events) at System.Web.Services.Protocols.SoapServerProtocol.ReadParameters() — End of inner exception stack trace — at System.Web.Services.Protocols.SoapServerProtocol.ReadParameters() at System.Web.Services.Protocols.WebServiceHandler.CoreProcessRequest()), Service ID: 4)”
I don’t use the Bandwidth counter in SolidCP as it still isn’t working (the looping error with SmarterMail) – so I assume that’s why this is failing. How can I tell the module not to count bandwidth?
I had a think and now I’ve found the issue.
If a customer has two packages under their account in SolidCP, the WHMCS resource counter will fail.
This is due to the “getUserPackages” function returning a multiple array, which is then passed to getPackageBandwidthUsage that of course errors out as there is no $package[’PackageID’]
I think this situation is rare (my client has two packages, which I put under a single user account – but show up in WHMCS as seperate packages) – but I think there should be some kind of error handling there 🙂
can you specify the issue a bit more?
In WHMCS there is one customer with one hosting service, which is related to one SolidCP user with one hosting space, correct?
I assume, there is a second hosting space under the same user in SolidCP, isn’t it? Where it is coming from? Was it created manually, because as far as I know the WHMCS module can’t create a second hosting space for one user in SolidCP currently.
Yes that is correct – I had a user with 2 (user) accounts – so to make things easier for him, I merged them all into one, so it’s now One user account with Two hosting spaces under him.
This causes the WHMCS Resource Scheduled Task to fail.
Can you please help me out in this, port 9002 is working fine, but when adding in WHMCS and clicked on test connection its going into infinite loop, not knowing whats happening, but its not getting processed.
- Views961 times
- Answers4 answers