June 27, 2005 at 3:41 am
I think that this line has been forgotten:
dbcc traceon (1807)
it should be added at the top.
It enables SQL Server to backup to a network disk.
So my script looks like this:
dbcc traceon (1807)
exec xp_cmdshell 'net use g: \\aserver\adisk myPassword /user:avalidNetworkLogin '
backup database pubs
to disk = 'g:\test.bak'
with stats=1
exec xp_cmdshell 'net use g: /d'
dbcc traceoff (1807)
HIH
Henrik Staun Poulsen
June 27, 2005 at 4:38 am
Osama,
Try this
dbcc traceon(1807)
go
BACKUP DATABASE [northwind]
TO DISK = N'\\192.168.4.23\c:\bk_db_pro\northwind.bkp'
with format
GO
Rgds
Binu john
June 27, 2005 at 5:15 am
sorry guys but it return the same error
June 27, 2005 at 6:04 am
dont need C: and bk_db_pro should be shared
dbcc traceon(1807)
go
BACKUP DATABASE [northwind]
TO DISK = N'\\192.168.4.23\bk_db_pro\northwind'
with format
GO
June 27, 2005 at 6:08 am
do you change the account of localsystem on the server?
You must change to a account that have the administrator power on the two computer... You must shutdown the sqlagent services and change for this account and start it again
and probaly you'll not get this borring error of deny access...
God bless you
June 27, 2005 at 6:17 am
oooooh finaly it's work
thanks Rookie it's true we don't need c:
also:
it only work when i write the name of the PC not the IP address (i don't know why but may be because we r in domain and we use DHCP , may be i don't know)
really thanks to all of u guys
June 27, 2005 at 6:20 am
Guys it work with out any permissions or dbcc traceon(1807) ..... it simply work with "SA" user .
don't ask me why all that happened but when i remove "c:" and change the IP address with computer name it work
June 27, 2005 at 10:28 am
Aslo make sure that you use a valid share name: '\\1.2.3.4\c:\xxxxxxxx' is not going to work, because the ':' is invalid.
If you mean the drive root, then you might connect to the 'c$' share.
hth
jg
Viewing 8 posts - 16 through 22 (of 22 total)
You must be logged in to reply to this topic. Login to reply