OK, so it looks like the data on the tape is still OK.

The Volume=0 in the error message is what Bacula found for the "file" position
on the tape after trying to move it to the end of data.  This might be a bug
in the OS driver or tape firmware.  Were there any syslog messages at that
time?

You could try running btape and issuing the commands

rewind
cap
eod
status

to see what it reports.  (I don't think this will write anything to the tape.)

Also, have you run the btape test command successfully with this configuration
recently?  (Beware that this will overwrite the tape.)

__Martin


>>>>> On Tue, 6 Feb 2018 09:43:40 +0100 (CET), krashoverride  said:
> 
> Hello Martin, 
> 
> Problem occured last night,
> 
> 05-Feb 21:01 JobId 96: Error: Bacula cannot write on tape Volume "ROMBQ006" 
> because:
> The number of files mismatch! Volume=0 Catalog=71
> 05-Feb 21:01 JobId 96: Marking Volume "ROMBQ006" in Error in Catalog.
> 
> Then I bls'ed the tape :
> 
> bls: butil.c:293-0 Using device: "/dev/nst0" for reading.
> 06-Feb 08:57 bls JobId 0: Ready to read from volume "ROMBQ006" on tape device 
> "Lecteur_LTO6" (/dev/nst0).
> 
> Volume Label:
> Id                : Bacula 1.0 immortal
> VerNo             : 11
> VolName           : ROMBQ006
> PrevVolName       :
> VolFile           : 0
> LabelType         : VOL_LABEL
> LabelSize         : 164
> PoolName          : QUOT
> MediaType         : LTO-6
> PoolType          : Backup
> HostName          : server
> Date label written: 29-Jan-2018 16:39
> 
> Then 6 "Begin Job" / "End Job" 
> 
> Then
> 
> 06-Feb 09:07 bls JobId 0: End of Volume at file 71 on device "Lecteur_LTO6" 
> (/dev/nst0), Volume "ROMBQ006"
> 06-Feb 09:07 bls JobId 0: End of all volumes.
> Bacula "End of Tape" label found.
> 
> Confirming the number of files in the catalog. 
> 
> 
> ----- Mail original -----
> De: krashoverr...@free.fr
> À: "Martin Simmons" <mar...@lispworks.com>
> Cc: bacula-users@lists.sourceforge.net
> Envoyé: Jeudi 1 Février 2018 09:56:19
> Objet: Re: [Bacula-users] Number of files mismatch!
> 
> Hello Martin,
> 
> Sure, next time the problem occurs. It has not since, lets say 1 week. Last 
> time i had it, I tried to only restart bacula-sd service, and restarted my 
> backup, that worked like a charm.
> 
> I'll let you know!
> 
> Thank you
> 
> -- Thib
> 
> ----- Mail original -----
> De: "Martin Simmons" <mar...@lispworks.com>
> À: krashoverr...@free.fr
> Cc: itli...@igtp.cat, bacula-users@lists.sourceforge.net
> Envoyé: Jeudi 25 Janvier 2018 17:13:35
> Objet: Re: [Bacula-users] Number of files mismatch!
> 
> Can you post the output of the 'bls -j /dev/nst0' shell command with one of
> these "empty" tapes in the drive?
> 
> __Martin
> 
> 
>>>>> On Wed, 24 Jan 2018 21:04:06 +0100 (CET), krashoverride  said:
> > 
> > Feedback again, umount / mount has no effect.
> > Tapes are seen as empty.
> > 
> >     Total Bytes Read=64,512 Blocks Read=1 Bytes/block=64,512
> >     Positioned at File=0 Block=0
> > 
> > I don't know where to dig, now.
> > 
> > ----- Mail original -----
> > De: krashoverr...@free.fr
> > À: "itlinux_igtp" <itli...@igtp.cat>
> > Cc: bacula-users@lists.sourceforge.net
> > Envoyé: Mardi 23 Janvier 2018 21:24:34
> > Objet: Re: [Bacula-users] Number of files mismatch!
> > 
> > Good evening Iñaki,
> > 
> > Quick feedback : new package of tapes came, error persists.
> > It "seems" if I umount / mount my tape, error is gone.
> > I've tested right now, after being mailed file mismatch :
> > 1. cancel job
> > 2. update volume status from error to append
> > 3. umount
> > 4. mount
> > 5. manually run the job that starts successfully.
> > 
> > I'm gonna wait for the backup catalog in 2 hours, to see if it starts 
> > successfully
> > 
> > ----- Mail original -----
> > De: "itlinux_igtp" <itli...@igtp.cat>
> > À: bacula-users@lists.sourceforge.net
> > Envoyé: Lundi 22 Janvier 2018 09:40:58
> > Objet: Re: [Bacula-users] Number of files mismatch!
> > 
> > You might have a bad batch. It happened to me a while ago, weird issues 
> > with backups until I swapped tapes from a different batch and everything 
> > worked. If the tapes you are using come from the same package/batch I 
> > wouldn't discard that option. If you can test the backup with a known 
> > good tape, that would help you troubleshoot this.
> > 
> > PS: For LTO tapes you should have Random Access = no
> > 
> > Regards,
> > Iñaki
> > On 01/22/2018 09:11 AM, krashoverr...@free.fr wrote:
> > > Good morning here!
> > >
> > > About this problem, i've set my Q003 tape on quarantine, because of this 
> > > "file mismatch" problem
> > > I've created a Q004 tape, that ran successfully this weekend, until the 
> > > catalog backup :
> > > The number of files mismatch! Volume=0 Catalog=2464
> > > Do I have to consider that I have bad luck with 2 "bad tapes" ? Do I have 
> > > to force something in SD conf ?
> > >
> > > (BTW, how "files" are working ? I backup 2.461 TB and I have 2.464 files, 
> > > 1 files per giga ?)
> > >
> > > Thank you!
> > >
> > > -- Thib
> > >
> > >
> > > ----- Mail original -----
> > > De: "Kern Sibbald" <k...@sibbald.com>
> > > À: krashoverr...@free.fr, bacula-users@lists.sourceforge.net
> > > Envoyé: Mercredi 17 Janvier 2018 09:44:35
> > > Objet: Re: [Bacula-users] Number of files mismatch!
> > >
> > > Your tape seems to be bad or overwritten.
> > >
> > > I suggest to try a bls on the tape and see if it really has any data on
> > > it.  The Bacula SD thinks the tape is empty.
> > >
> > >
> > > On 16.01.2018 08:22, krashoverr...@free.fr wrote:
> > >> Hi again,
> > >>
> > >> Quick feedback, yesterday while I was writing this mail, i started again 
> > >> my bscan + change volume status process, then started again my 
> > >> differential backup on the same Q003 tape. Backup is successful this 
> > >> morning.
> > >>
> > >> ----- Mail original -----
> > >> De: krashoverr...@free.fr
> > >> À: bacula-users@lists.sourceforge.net
> > >> Envoyé: Lundi 15 Janvier 2018 21:47:11
> > >> Objet: [Bacula-users] Number of files mismatch!
> > >>
> > >> Good evening here,
> > >>
> > >> I'm having an issue with the number of files that does not match between 
> > >> the tape and the DB
> > >> Number of files on the tape is zero, while the tape isn't empty.
> > >> I'm using bacula-dir / bacula-sd 7.4.4 on a virtualized debian 9 server 
> > >> (SQLite database)
> > >>
> > >> 15-Jan 21:00 xxx-dir JobId 54: Using Device "Lecteur_LTO6" to write.
> > >> 15-Jan 21:00 xxx-sd JobId 54: Volume "Q003" previously written, moving 
> > >> to end of data.
> > >> 15-Jan 21:01 xxx-sd JobId 54: Error: Bacula cannot write on tape Volume 
> > >> "Q003" because:
> > >> The number of files mismatch! Volume=0 Catalog=132
> > >> 15-Jan 21:01 xxx-sd JobId 54: Marking Volume "Q003" in Error in Catalog.
> > >>
> > >> I've had this error yesterday evening, that i thought i fixed with a 
> > >> bscan command, that listed me jobs / files on tape correctly
> > >> After this bscan, i've changed the status of the volume from Error to 
> > >> Append, and started a catalog backup job, that ran successfully on tape 
> > >> Q003. Then, this evening, error again.
> > >>
> > >> Knowing that I have for now a total of 5 tapes in my bacula, and i've 
> > >> had no problems for any other tape but Q003, do I have to consider that 
> > >> the tape is faulty ?
> > >>
> > >> Also, i've read topics about the two directives "BSF at EOM" and "TWO 
> > >> EOF" that seemed to fix this problem for other persons. What do you 
> > >> think?
> > >> --
> > >> Device {
> > >>     Name = Lecteur_LTO6
> > >>     Archive Device = /dev/nst0
> > >>     Media Type = LTO-6
> > >>     LabelMedia = no
> > >>     Random Access = yes
> > >>     AutomaticMount = yes;
> > >>     RemovableMedia = no
> > >>     AlwaysOpen = no
> > >> }
> > >>
> > >> Thank you,
> > >>
> > >> Thibault.
> > >>
> > >>
> > >> ------------------------------------------------------------------------------
> > >> Check out the vibrant tech community on one of the world's most
> > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >> _______________________________________________
> > >> Bacula-users mailing list
> > >> Bacula-users@lists.sourceforge.net
> > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> > >>
> > >> ------------------------------------------------------------------------------
> > >> Check out the vibrant tech community on one of the world's most
> > >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >> _______________________________________________
> > >> Bacula-users mailing list
> > >> Bacula-users@lists.sourceforge.net
> > >> https://lists.sourceforge.net/lists/listinfo/bacula-users
> > >
> > > ------------------------------------------------------------------------------
> > > Check out the vibrant tech community on one of the world's most
> > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > _______________________________________________
> > > Bacula-users mailing list
> > > Bacula-users@lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > 
> > 
> > -- 
> > 
> > Iñaki Martinez de Ilarduya Muñoz
> > Systems Administrator IGTP
> > e-mail: itli...@igtp.org
> > Tel (+34) 93 554-3079
> > Fax (+34) 93 465-1472
> > 
> > Germans Trias i Pujol Research Institute (IGTP)
> > Ctra de Can Ruti, Camí de les Escoles s/n
> > 08916 Badalona, Barcelona,
> > Spain
> > www.germanstrias.org
> > 
> > 
> > ------------------------------------------------------------------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > Bacula-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > 
> > ------------------------------------------------------------------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > Bacula-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > 
> > ------------------------------------------------------------------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > Bacula-users mailing list
> > Bacula-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
> > 
> 
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
> 

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to