I hope that I need last help 🙂 I managed to create invoice and activate it. For first time there was no error only “success”. I looked into SolidCP Panel and there was no new account :/ So I did invoice again and there it comes.. error.
Full error: CreateAccount Fault: (Code: -2, Message: Fault: An unknown error occured (Code: -2). Please reference SolidCP BusinessErrorCodes for further information, Service ID: 2)
I went to git with hope to find whats error code -2, unfortunately I didn’t find in source code what’s error -2. Could you please help me to find out what’s the problem?
[whmcsVersion] => 6.3.0-release.1
[accountid] => 2
[serviceid] => 2
[userid] => 1
[domain] => example.com
[username] => testc
[password] => 3Lbe9zY5g0
[packageid] => 1
[pid] => 1
[serverid] => 1
[status] => Pending
[type] => hostingaccount
[producttype] => hostingaccount
[moduletype] => SolidCP
[configoption1] => Package1
[configoption4] => 8
[configoption5] => 1
[configoption6] => on
[configoption7] => http://127.0.0.1:9001
[configoption15] => on
[customfields] => Array
[configoptions] => Array
[clientsdetails] => Array
[userid] => 1
[id] => 1
[uuid] => 6d22c183-45a5-4537-97d2-e0c941bbdfbc
[firstname] => FirstName
[lastname] => LastName
[fullname] => FirstName LastName
[email] => test@test .com
[address1] => Addr1
[city] => City1
[fullstate] => CZ
[state] => CZ
[postcode] => 12345
[countrycode] => CZ
[country] => CZ
[phonenumber] => 123456789
[password] => $2y$10$pQiRQoBlyhbbFQWgQNhnrOsp9sXvNA1B.2Js6tfTqXVU3VJ74xarS
[statecode] => CZ
[countryname] => Czech Republic
[phonecc] => 420
[phonenumberformatted] => +420.123456789
[billingcid] => 0
[currency] => 2
[securityqid] => 0
[groupid] => 0
[status] => Inactive
[credit] => 0.00
[allowSingleSignOn] => 1
[lastlogin] => Date: 17/10/2016 23:03<br>IP Address: xxx.xxx.xxx.xxx<br>Host:
[server] => 1
[serverip] => 127.0.0.1
[serverhostname] => 127.0.0.1
[serverusername] => whmcs
[serverpassword] => p@ssw0rd
[serverhttpprefix] => http
[serverport] => 9002
[action] => create
Thanks for help
I found where problem was and now its working.
In solidCP I have reseller account “whmcs_module” which had active plan, from that plan I created new hosting spaces, hosting space I used in WHMCS was 8 but I was using spaceID for active plan which had “whmcs_module” account and not the one with hosting space 8.
So main problem: spaceID
Suggestions to improve error debugging:
- If createAccount throws -2 from DB it should say “wrong spaceID” or something like that on: https://git.key4ce.com/SolidCP/v1.0/blob/1.1.x/SolidCP/Sources/SolidCP.EnterpriseServer.Code/Wizards/UserCreationWizard.cs#L134
- If mail server is not configured or not installed on machine it should say something like that on instead of error -19xx on https://git.key4ce.com/SolidCP/v1.0/blob/1.1.x/SolidCP/Sources/SolidCP.EnterpriseServer.Code/Wizards/UserCreationWizard.cs#L343
Okay, so it fails there, I added values to comment, probably some value should not be null.
ObjectQualifier + “AddUser”, prmUserId,
new SqlParameter(“@ActorId “, actorId), // 2
new SqlParameter(“@OwnerID “, ownerId), // 1
new SqlParameter(“@RoleID “, roleId), // 2
new SqlParameter(“@StatusId “, statusId), // 1
new SqlParameter(“@SubscriberNumber “, subscriberNumber), // null
new SqlParameter(“@LoginStatusId “, loginStatusId), // 0
new SqlParameter(“@IsDemo “, isDemo), // false
new SqlParameter(“@IsPeer “, isPeer), // false
new SqlParameter(“@Comments “, comments), // null
new SqlParameter(“@username “, username), // example
new SqlParameter(“@password “, password), // wdJ7UG4m1hrkK4vsMPq2DxweLJnn2eQPYXI6lmwg3TM=
new SqlParameter(“@firstName “, firstName), // FirstName
new SqlParameter(“@lastName “, lastName), // null
new SqlParameter(“@email “, email), // example@example .com
new SqlParameter(“@secondaryEmail “, secondaryEmail), // “”
new SqlParameter(“@address “, address), // null
new SqlParameter(“@city “, city), // null
new SqlParameter(“@country “, country), // null
new SqlParameter(“@state “, state), // null
new SqlParameter(“@zip “, zip), // null
new SqlParameter(“@primaryPhone “, primaryPhone), // null
new SqlParameter(“@secondaryPhone “, secondaryPhone), // null
new SqlParameter(“@fax “, fax), // null
new SqlParameter(“@instantMessenger “, instantMessenger), // null
new SqlParameter(“@htmlMail “, htmlMail), // true
new SqlParameter(“@CompanyName “, companyName), // null
new SqlParameter(“@EcommerceEnabled “, ecommerceEnabled)); // false
EDIT: looking to DB.. why is fax not allowed to be null? :O
EDIT 2: FINALLY FOUND why -2!
In DB StoredProcedures -> AddUser
Normally you can remote debug it using the remote debugging tool. You will need to change the path for things like Enterprise server to the path in the source (C:\git\v1.0\SolidCP\Sources\SolidCP.EnterpriseServer)
Are you still getting the same error?
Okay one last thing to debug. Where is located optimize code in yours build.xml or something. If I turn off “optimize code” in .sln it still build optimized and disallow me to debug correctly :/
Also I figured out why error unknown. That’s thanks to this: https://git.key4ce.com/SolidCP/v1.0/blob/1.1.x/SolidCP/Sources/SolidCP.EnterpriseServer.Code/Wizards/UserCreationWizard.cs#L134
Which UserController returns on add -2 there: https://git.key4ce.com/SolidCP/v1.0/blob/1.1.x/SolidCP/Sources/SolidCP.EnterpriseServer.Code/Users/UserController.cs#L427
Which DataProvider reteurns there -2:
So misterious error comes from MS SQL 😀
You should use one of yours error codes there.
Wow, finally get debugging working, but still cant see vars values :/
BUT! I finally got ERROR name!
So WHMCS says now: “CreateAccount Fault: (Code: 0, Message: ChangeUserStatus Fault: (Code: 0, Message: SOAP Fault: (Code: 0, Message: Error Fetching http headers), Service ID: 2)”
I missed somehow something, so those are steps to get it working, if someone still reading and having problem.
- Stop Panel, Server, Enterprise server
- C:/SolidCP change dir letters from Panel to Panel_bck, Server to Server_bck etc.
- Copy from source code SolidCP/Deploy/Release/Install mentioned folders
- Copy from _bck folders web.config
- Start Panel, Server, Enterprise server
- Should work attach debug with loaded symbols 🙂
In this stage I don’t see variables value, even Watch can’t see :/
EDIT: to see variables I need “Use managed compability mode” which disallow remote debug, so crazy 🙁 Any idea how to get things working? I dont want to install Visual studio on server..
Alright, I installed fresh Virtual Machine with Win 10
VS 2015 Community with SQL libraries
Win SDK for .NET 3.5
Win SDK for .NET 4
Win 8 SDK for .NET 4
Wix toolset 3.10
It appears now wix is correctly installed but there is something hardcoded or what.. look on following image
So third reinstall ended here:
Did you have linking problem sometimes? I couldn’t find whats Light.exe dependencies.. file exists.
Can you check if V:mastertoolsWIXcandle.exe is present?
It appears to be saying that wont load but if it is present i would try reinstall wix.
Adding wix to the path shouldn’t be required.
Some progress! I don’t know why but I had to reinstall SDKs. Currently I have some trouble with Wix toolset, I installled them 2 days ago, today I added path to environment C:/Program Files (x86)/Wix 10.3/Bin
I can’t resolve this compile problem.
Any idea how to get working Wix?
- Views18021 times
- Answers23 answers