cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
SirArion
Engaged Sweeper
Ran the setup for 4.0 on our premium Lansweeper server, the SQL database is hosted on another server.

Setup seems to have stalled at this point and I am unsure if I should kill this or just let it go?? Been running for 4hours against a db of 2.5gb.

"Setup is updating your database to the latest version"
Currently running sql code:
-- end check all constraints
-- PRINT 'Changing computername keyfield'
DECLARE @computername nvarchar(300)
DECLARE @TEL int
DECLARE @TEMPSQL nvarchar(4000)
SET @TEL = 1
Declare Allcomputers cursor for
select computername from tblcomputers

open Allcomputers
fetch next from Allcomputers into @computername
WHILE @@fetch_status = 0
BEGIN
SET @TEMPSQL = N'update tblcomputers set computername = ' + '''' + cast(@TEL as varchar) + '''' + ' where computername = ' + '''' + @computername + ''''
EXEC sp_executesql @TEMPSQL

SET @TEL = @TEL + 1
FETCH NEXT FROM Allcomputers INTO @computername
END

CLOSE Allcomputers
DEALLOCATE Allcomputers
51 REPLIES 51
wierzbowski
Engaged Sweeper
I've had a go at the upgrade once but got cold feet after a few hours when reading this thread and reverted to a snapshot of the server. We've got about 3000 machines visible in the console and the upgrade stalled at the point listed in this thread.

In order to speed up the update does anybody think its worth deleting all of the machines from the database through the Lansweeper Configuration console but leaving the custom reports and actions?

I figure that the machines can all be re-scanned once the upgrade has taken place, and it doesn't matter if that part takes a few days; Lansweeper does all the work for you. Its only the reports that we've added that we're keen to retain.

I'd welcome any expert opinion, either way.

Wierz
wierzbowski wrote:

In order to speed up the update does anybody think its worth deleting all of the machines from the database through the Lansweeper Configuration console but leaving the custom reports and actions?


This will make the upgrade lightning fast.
Note that deleting all computers might also take some time.
Set your recovery mode to "simple" before you start.
SirArion
Engaged Sweeper
As originally posted, my DB was 2.5gb and the install ran for approx 8 hours. It did complete without errors and everything seems to be working.
KHabershon
Engaged Sweeper II
Just do a select * from tblcomputers .... without quotes.

The "Computername" column name will have changed from an actual computer name to a numerical form.
KHabershon wrote:
Just do a select * from tblcomputers .... without quotes.

The "Computername" column name will have changed from an actual computer name to a numerical form.


Thanks, done 1558 / 6131 so far.
poweld1
Champion Sweeper
How can I tell how many records have been processed?
KHabershon
Engaged Sweeper II
Ok, need to come up with another solution. I understand why it's taking so long, yes, the tblComputers is in almost every single table as a FK. Lansweeper is changing the PK from the PC # to an automatically generated numerical form. For each record in the computer table it has to touch every single table out there and change it. In almost 21 hours now, out of a tblComptuers (8000+ rows) it has completed 158 rows. That leaves almost 7900+ to do. This upgrade, based on it's current pace, will take almost 2 months to complete.

This is not going to work. Any other ideas?



text
update tblcomputers set computername = '241' where computername = '(COMPUTERNAME)'
cpu_time
19366969
total_elapsed_time
78719694
Hemoco
Lansweeper Alumni
KHabershon wrote:
This is not going to work. Any other ideas?


I suggest:
Stopping the setup
restoring the original Database.
switch the database to "simple" mode.
Reorganize and shrink the database.
Manually run the upgrade scripts (see first post)
KHabershon
Engaged Sweeper II
Just an update. Started at 1pm yesterday, still stuck on same task as previously mentioned.
Hemoco
Lansweeper Alumni
Changing table tblcomputers only takes 6 seconds, the problem is all other related tables.

New to Lansweeper?

Try Lansweeper For Free

Experience Lansweeper with your own data.
Sign up now for a 14-day free trial.

Try Now