Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replication causing database not to detach

Status
Not open for further replies.

dhiner

Programmer
Jan 9, 2003
4
US
I have a MSSQL 7.0 database that had replication running on the database. I have since then stopped the replication process from running due to a high strain on our sql server. This database has about 30,000 transactions going on it every minute of the day and my log file has grown to an exuberant amount. What I would like to do is detach the database, back up the log file, and create a new log file while backing up the log file to a separate server due to limited available space on our production server.

My issue is that sense there is replication for this database but is not running, I am unable to detach the database. Would anybody be able to provide me with instructions on how to remove replication from a database so I can detach this sql database and reattach it with a smaller log file.


Thanks,
David Hiner
Lead Reporting Analyst
Database Administrator

 
In Enterprise Manager click Tools>Replication>Disable Publication and Distribution. That should completly remove replication.

Backing up the transaction log in the method you posted will do you no good. Once you reattach the database you won't be able to do anything with the existing log file.

In this case I would recommend simply truncating the log file, shrinking it, and then doing a full database backup.

You can do this all while the database is online, and without effecting your users. (Removeing the Replication will cause database blocking while it is running, so do this during off hours.)

Denny

--Anything is possible. All it takes is a little research. (Me)

[noevil]
(My very old site)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top