Unable to run the a...
 
Notifications
Clear all

Unable to run the auto update tool for 1.3

7 Posts
2 Users
0 Reactions
1,710 Views
Posts: 16
Topic starter
(@spence89)
Active Member
Joined: 8 years ago

Hi guys,

I am unable to use the powershell script on my server to upgrade SCP to 1.3.

My server has all servers and portal installed on the same server and I unblocked the file as per usual. When I right click and run with powershell the window comes up, flashes some red text and then closes straight away without enough time to read the error message.

Any ideas on this one? I'd appreciate some help 🙂

Many Thanks,
Adam

6 Replies
Posts: 1995
Admin
(@m-tiggelaar)
Noble Member
Joined: 9 years ago

hello,

Can you right click on powershell and open as administrator?

you then go to the file location using: cd c:yourfilelocation

and then run the powershell script using ./yourpsscript.ps1

It should run without issues, if some red text does pop up you can atleast see what it says and report it back in the forum 🙂

Regards,

Marco

Reply
Posts: 16
Topic starter
(@spence89)
Active Member
Joined: 8 years ago

Hi Marco,

Thanks for getting back to me.

Turns out it was the execution policy (something you might want to include in the relevant documentation) although after allowing scripts to run it still error with the following:

Cannot process the "#requires" statement at line 51 be
rrect format.
The "#requires" statement must be in one of the follow
"#requires -shellid <shellID>"
"#requires -version <major.minor>"
"#requires -pssnapin <psSnapInName> [-version <major.
At line:1 char:27
+ ./SolidCP-Auto-Upgrade.ps1 <<<<
+ CategoryInfo : ObjectNotFound: (:String
eption
+ FullyQualifiedErrorId : CommandNotFoundException

Any ideas please? I am familiar with web.config files and such but not .net applications in a full on development.

Many thanks,
Adam

Reply
Posts: 16
Topic starter
(@spence89)
Active Member
Joined: 8 years ago

Right,

So I managed to get the tool to work by updating powershell to v3.

I am now getting the following error and now the script appears to have hung:

 

Starting the "SolidCP Enterprise Server" upgrade
Stopping the "SolidCP Enterprise Server" website
Restarting IIS on this server for a clean upgrade
Stopping the "SolidCP Enterprise Server" Scheduler service
Creating a backup of the "Enterprise Server" files
Creating a backup of the "Enterprise Server" Database
New-SMBShare : The term 'New-SMBShare' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At C:UsersAdministratorDownloadsSolidCP-Auto-Upgrade-ToolSolidCP-Auto-Upgrade.ps1:401 char:6
+ New-SMBShare -Name "SCPUpgrade$" -Path "$SCP_UpdateDirEnterprise Server - ...
+ ~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (New-SMBShare:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException

Backup-SqlDatabase : System.Data.SqlClient.SqlError: Cannot open backup device '\192.168.0.15SCPUpgrade$SolidCP -
2017-10-03 - (11.44 AM).bak'. Operating system error 67(failed to retrieve text for this error. Reason: 15100).
At C:UsersAdministratorDownloadsSolidCP-Auto-Upgrade-ToolSolidCP-Auto-Upgrade.ps1:407 char:7
+ Backup-SqlDatabase -ServerInstance "$SCP_Database_Servr" -Database "$SCP_D ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [Backup-SqlDatabase], SmoException
+ FullyQualifiedErrorId : ExecutionFailed,Microsoft.SqlServer.Management.PowerShell.BackupSqlDatabaseCommand

What should I do now?

Thanks,
Adam

Reply
Posts: 1995
Admin
(@m-tiggelaar)
Noble Member
Joined: 9 years ago

Manually backup the database in question.

then use the older script:  http://installer.solidcp.com/Files/stable/Tools/SolidCP-Auto-Upgrade-Tool-1.6.zip

This script will show the same error but continue after (it will only affect the database).

Reply
Page 1 / 2
Share: