Issue Details (XML | Word | Printable)

Key: CORE-3995
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Alexander Peshkov
Reporter: Ivan Arabadzhiev
Votes: 3
Watchers: 5

If you were logged in you would be able to see more operations.
Firebird Core

Regression: Problem with GBAK -V and -Y parameter checking

Created: 25/Nov/12 09:12 AM   Updated: 30/Jun/14 06:38 PM
Component/s: GBAK
Affects Version/s: 2.5.2
Fix Version/s: 3.0 Alpha 1, 2.5.3

Environment: Linux x86_x64
Issue Links:

 Description  « Hide
Up to Fb 2.5.1 I had the following crontask running to backup without a temporary file

/opt/firebird/bin/gbak -IG -E -USER $USERNAME -PASSWORD $PASSWORD -V -Y $BACKUP_NAME.log -T -B /storage/fb_db/aton/aton.fdb stdout | /usr/bin/pbzip2 -3 -cp3z - > $BACKUP_NAME.fbk.bz2

I recently upgraded to 2.5.2, which complains about verbose output and stdout at the same time. The check makes sense but I have already redirected the log to another file. Is there anyway the next version will take that into account? I`d prefer to have it out there just in case and I don`t really need the temporary file.

 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
kdv added a comment - 26/Nov/12 09:12 AM
complains how? on what Linux?

btw, this is not support list, but I can't resist to comment your backup options:
-IG - never use it, unless you have broken DB, and gbak without that option can't backup DB. While you have -IG "by default", you can miss case when your database is broken, and then you may face problems at restore of this backup.
-E - I don't know why you do not want backup data to be compressed (by default)
-T - this option is by default, not needed to specify

and, if you don't want backup to do garbage collection, and run faster - specify -B -G.

If you want to discuss it, send a message to firebird-support list.

Ivan Arabadzhiev added a comment - 04/Dec/12 09:10 AM
LinuxFromScratch (in case it actually matters)

My complain is simple :

gbak:creating file stdout
gbak: ERROR:standard output is not supported when using split operation or in verbose mode
gbak:Exiting before completion due to errors

I believe it should not happen when I have already specified a -Y (and thus redirected the verbose output), unless there has been some major change in 2.5.2 which makes it a problem to execute such a backup. Am I missing something? Because I have restored 2.5.1/2.1.* backups made this way and they have never been corrupt.

As for used parameters :
-IG : agreed, I will remove (though I backup frequently and might want to have a broken backup instead of none)
-E : I`m guessing gbak does single-threaded compression (haven`t checked 2.5 behavior). On the other hand I usually have 1-2 cores to spare, which is why I use pbzip :)
-T : Once upon a time I read a "don`t rely on default behavior" intro to programing and it kind of stuck with me.

Laszlo Szakmari added a comment - 13/Feb/13 12:05 AM - edited
As mentioned in a "duplicate" issue:
 This problem exists on Win7, XP ... and probably on other OSs too.

I've just experienced it, as I've tried to move from 2.1.5 to 2.5.2 version. My program failed to make backups. And it's not good, if NOTHING happens in the command line window. This function worked perfectly in 2.1 version !!! see:

My customers are not programmers. If they see "something running" in a black window for 3 minutes, they wait patiently like a sheep, but if it's just empty and waiting > they try to force-close.

And still.. the big question is > WHY isn't this message just shown, and the verbosity rather just ignored AS long this error isn't fixed, it's still better, than missing a scheduled backup, just because someone upgraded a database on one of the 1000 machines !

I really had liked to change from 2.1, but I still have to stay by it. :(
PLEASE correct this error soon, and make it work, just like it worked on 2.1.x... Thank you !

Alexander Peshkov added a comment - 13/Feb/13 09:02 AM
Laszlo, did you pay attention that an assue is resolved? That means that you may use snapshot builds or wait for 2.5.3.

Laszlo Szakmari added a comment - 07/Mar/13 08:34 AM
Just tested 2.5.3 snapshot. Verbose still not working.

1. gbak -B -T -V ......................... is NOT ignored nor showing any verbose messages on screen but drops an error and backup is FAILED !!!
2. gbak -B -T -V -Y filename.txt ... works, NO output on screen
3. gbak -B -T -V -Y >CON .......... does not work either
 (but this solution is not the best one, because not backward compatible with 2.1 .. 2.0 ... previous versions)
4. piped restore works fine with -V ... showing progress on screen, just like 2.1 did.

IMHO this tracker should be re-opened, or a new one should be created pointing to this one.

Alexander Peshkov added a comment - 12/Mar/13 08:56 AM
Hi Laszlo
What do you want from this command line?
gbak -B -T -V -Y >CON
You provide switch -y, but no value for it, and get in 2.1 for example:
gbak: ERROR:redirect location for output is not specified
gbak:Exiting before completion due to errors
I.e. on my mind this is not a solution at all.

p.2 & p.4 are working, looks like only p.1 to be fixed.
May be I'm missing something?

Laszlo Szakmari added a comment - 12/Mar/13 10:38 AM - edited
As I've mentioned, "3." is nothing, just a workaround test. Tried to redirect messages from file to the consol. You can forget about it.

The important thing is:
1/a : make -V option work again (without -Y file redirection too)

 ... or at least temporary:

1/b: ignore it and let the backup run !


PS: personaly it would be enough for me, if verbose message would be only: a "percentage line" 0.001% ..0.002% ... updating every 500ms in the same line, if that's quicker to do. Whatever easier to you ! (IMHO restoring how it was at 2.1 would be best.)

Alexander Peshkov added a comment - 12/Mar/13 11:45 AM
Restored original behavior when gbak is used in 'stdout' mode as utility.

Laszlo Szakmari added a comment - 13/Mar/13 05:02 PM - edited
gbak version WI-V2.5.3.26628 Firebird 2.5
Works Perfect :)
 ... waiting for final release of 2.5.3.
THANKS. (just looking for how to donate ;)