Sunday, March 25, 2012

can't shrink a log file

actually i have a db file size of 400MB and it's log file about 4.5GB, i read
all about backup log and shrink the file, and the problems is every virtual
log file has an status of active, some are really old ( 2002 ), how can i
turn off the virtual files and left only one active (the last)Do you have any uncommitted transactions? What does DBCC OPENTRAN output?
--
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Fidel Ramírez" <Fidel Ramrez@.discussions.microsoft.com> wrote in message
news:A2AE904A-CE8C-48F1-9852-23F0033C56AD@.microsoft.com...
> actually i have a db file size of 400MB and it's log file about 4.5GB, i
read
> all about backup log and shrink the file, and the problems is every
virtual
> log file has an status of active, some are really old ( 2002 ), how can i
> turn off the virtual files and left only one active (the last)|||this is the message result
Información de transacción para la base de datos 'SII'.
Información de transacción duplicada:
LSN distribuido más antiguo : (4796:432:1)
LSN no distribuido más antiguo : (4796:457:1)
Ejecución de DBCC completada. Si hay mensajes de error, consulte al
administrador del sistema.
transaction information for db SII (my db)
transaction information duplicated
LSN older distributed : (4796:432:1)
LSN older not distributed : (4796:457:1)
DBCC execution completed. If there are error messages, contact system
administrator.
¿What's next?
"Paul S Randal [MS]" wrote:
> Do you have any uncommitted transactions? What does DBCC OPENTRAN output?
> --
> Paul Randal
> Dev Lead, Microsoft SQL Server Storage Engine
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "Fidel Ramírez" <Fidel Ramrez@.discussions.microsoft.com> wrote in message
> news:A2AE904A-CE8C-48F1-9852-23F0033C56AD@.microsoft.com...
> > actually i have a db file size of 400MB and it's log file about 4.5GB, i
> read
> > all about backup log and shrink the file, and the problems is every
> virtual
> > log file has an status of active, some are really old ( 2002 ), how can i
> > turn off the virtual files and left only one active (the last)
>
>|||Looks like you're running SQL Server 7.0 - is that correct? If so, DBCC
OPENTRAN doesn't tell you the start time of the oldest transaction but I
suspect you've got an uncommitted transaction that's preventing the log from
being truncated. Your best bet is to contact PSS
(http://support.microsoft.com) for help and guidance.
Regards.
--
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Fidel Ramirez" <Fidel Ramirez@.discussions.microsoft.com> wrote in message
news:54DEF4D8-CA4B-497C-A998-FE7E0FB59346@.microsoft.com...
> this is the message result
> Información de transacción para la base de datos 'SII'.
> Información de transacción duplicada:
> LSN distribuido más antiguo : (4796:432:1)
> LSN no distribuido más antiguo : (4796:457:1)
> Ejecución de DBCC completada. Si hay mensajes de error, consulte al
> administrador del sistema.
>
> transaction information for db SII (my db)
> transaction information duplicated
> LSN older distributed : (4796:432:1)
> LSN older not distributed : (4796:457:1)
> DBCC execution completed. If there are error messages, contact system
> administrator.
> ¿What's next?
>
> "Paul S Randal [MS]" wrote:
> > Do you have any uncommitted transactions? What does DBCC OPENTRAN
output?
> >
> > --
> > Paul Randal
> > Dev Lead, Microsoft SQL Server Storage Engine
> >
> > This posting is provided "AS IS" with no warranties, and confers no
rights.
> >
> > "Fidel Ramírez" <Fidel Ramrez@.discussions.microsoft.com> wrote in
message
> > news:A2AE904A-CE8C-48F1-9852-23F0033C56AD@.microsoft.com...
> > > actually i have a db file size of 400MB and it's log file about 4.5GB,
i
> > read
> > > all about backup log and shrink the file, and the problems is every
> > virtual
> > > log file has an status of active, some are really old ( 2002 ), how
can i
> > > turn off the virtual files and left only one active (the last)
> >
> >
> >|||thnks a lot i'll do it
"Paul S Randal [MS]" wrote:
> Looks like you're running SQL Server 7.0 - is that correct? If so, DBCC
> OPENTRAN doesn't tell you the start time of the oldest transaction but I
> suspect you've got an uncommitted transaction that's preventing the log from
> being truncated. Your best bet is to contact PSS
> (http://support.microsoft.com) for help and guidance.
> Regards.
> --
> Paul Randal
> Dev Lead, Microsoft SQL Server Storage Engine
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "Fidel Ramirez" <Fidel Ramirez@.discussions.microsoft.com> wrote in message
> news:54DEF4D8-CA4B-497C-A998-FE7E0FB59346@.microsoft.com...
> > this is the message result
> >
> > Información de transacción para la base de datos 'SII'.
> >
> > Información de transacción duplicada:
> > LSN distribuido más antiguo : (4796:432:1)
> > LSN no distribuido más antiguo : (4796:457:1)
> > Ejecución de DBCC completada. Si hay mensajes de error, consulte al
> > administrador del sistema.
> >
> >
> > transaction information for db SII (my db)
> > transaction information duplicated
> > LSN older distributed : (4796:432:1)
> > LSN older not distributed : (4796:457:1)
> > DBCC execution completed. If there are error messages, contact system
> > administrator.
> >
> > ¿What's next?
> >
> >
> > "Paul S Randal [MS]" wrote:
> >
> > > Do you have any uncommitted transactions? What does DBCC OPENTRAN
> output?
> > >
> > > --
> > > Paul Randal
> > > Dev Lead, Microsoft SQL Server Storage Engine
> > >
> > > This posting is provided "AS IS" with no warranties, and confers no
> rights.
> > >
> > > "Fidel Ramírez" <Fidel Ramrez@.discussions.microsoft.com> wrote in
> message
> > > news:A2AE904A-CE8C-48F1-9852-23F0033C56AD@.microsoft.com...
> > > > actually i have a db file size of 400MB and it's log file about 4.5GB,
> i
> > > read
> > > > all about backup log and shrink the file, and the problems is every
> > > virtual
> > > > log file has an status of active, some are really old ( 2002 ), how
> can i
> > > > turn off the virtual files and left only one active (the last)
> > >
> > >
> > >
>
>

No comments:

Post a Comment