Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Backups are not going where I think they're supposed to go and restarts are brain damaged

BricsCAD V19 on Ubuntu 18.04

Maybe I'm not understanding something correctly.

My drawing directory is /home/bill/BricsCAD
My backup directory is /home/bill/BricsCAD/Saved
I have SAVEFILEPATH = /home/bill/BricsCAD/Saved
I have SAVETIME = 3

I keep getting .bak files in my drawing directory instead of the backup directory. Why? I check SAVEFILEPATH to see if it's nulled out, but it's always as it should be. What is telling BricsCAD to save backups in my drawing directory ignoring my specific instructions via SAVEFILEPATH?

Also, when BricsCAD locks up and either I end it or it nukes itself, restarting BricsCAD acts like nothing just happened. That, in and of itself, is pretty rude.

If I select the drawing I was working on, it apparently knows there's a lock on that file and asks permission to unlock it and proceed. Fair enough, as far as that goes, but doesn't it also know there's a more recent backup and suggest hauling it up instead?

I'm ending up renaming the most recent .bak file to .dwg in the backup directory or the drawing directory depending on where I find it and opening it up to see if it's indeed better than the 'official' version in the drawing directory. I'm comparing the two versions to see which one I want, shutdown BricsCAD and then have to move files around via Linux to get an environment as a reasonable starting point to restart BricsCAD. That takes several minutes every time BricsCAD abends and that occurs often enough to warrant having a 3 minute backup interval.

How are others experiencing such issues?

Comments

  • For me that whole system is also overly complicated.

    Independent from backup activation,
    Brautocad throws BAK files beside each drawing file.
    I think there was a setting somewhere, to avoid creating BAK files.
    But I think that is not a good idea and less save ?
    AFAIK there is some strange back and forth voodoo when you save
    changes of a drawing file. (in case something goes wrong with writing)

    I also activated Backups, to a custom Path, and most times there are
    some files in there. AFAIK there is just again some voodoo with saving
    time interval - in case you do not work.
    (Makes sense to not keep 5 Backups of the same file state in that case)
    I think that is the reason when work with a new file, had a coffee brake,
    and after crashing wonder why there is no Backup file in your path.
    Normally I find some files in there.

    After a crash and loss of work I also don't know how to deal with it.
    Backup Files in Bricscad unfortunately have no time stamp in name
    to sort them by name. For me it means the need to order them in Finder
    to find the newest.
    I think in Backup Folder there are 2 versions of each backup, with
    different file endings (?) so I don't know to use which.

    Generally I have to find and check File and all derivates in drawing
    and backup Folders for newest save dates.
    BAK, DWG + stuff in backup folder.
    I still don't know if I should just go for the newest thing and overwrite
    the file ending and just open in Bricscad, to finally save as overwrite my
    original drawing.

    Yes, when Bricscad crashes a file, the only hint is the left over DWL
    that asks for write or read only mode, the next time you open such a
    crashed file.

    Opposed to Vectorworks.
    Backups to desired location,
    by time interval or number of changes,
    Backups have time stamps in name.

    If something went wrong,
    I got to Finder and check my drawing file save time,
    versus my last backup (at the bottom by order by name) save date.
    Choose the newest of both to open,
    overwrite original drawing by save as.

  • edited September 3

    This is by design. BricsCAD uses the same method as AutoCAD traditionally used.

    By default a .bak file is created with each subsequent save to the first. This file is a copy of your drawing immediately prior to the latest save. You can control whether these are created by changing the value of ISAVEBAK in SETTINGS. To use a .bak file, simply rename the extension to .dwg.

    Autosave creates a copy of your drawing after a set interval. These files are given a .sv$ extension and are saved to fixed location. You can use SAVEFILEFOLDER to navigate to the set folder. You can configure the folder location using SAVEFILEPATH, and the interval using SAVETIME. A couple of important things to know about Autosave:
    1. It ONLY does an Automatic save if you haven't within the set interval. If you save regularly, then an Autosave file won't get created. i.e. Everytime you do a SAVE the autosave time is reset.
    2. Autosave is ONLY triggered when you run a command. E.g. you have SAVETIME = 15mins. You make some changes to your drawing, then get called away forgetting to SAVE. After an 1hr you return and continue working on your drawing. It is only now when you run a command that the Autosave fires i.e. it didn't do an autosave while you where gone after 15mins.

    Regards,
    Jason Bourhill
    BricsCAD V19 Ultimate
    Quickly create HELP links on your forum posts

    CAD Concepts

  • Jason: Thank you for the explanation.

    So, to reiterate, .bak files are NOT part of the autosave mechanism, but the .SV$ files are.

    A .bak file represents the previous generation of a manually saved drawing and is placed along side the drawing file in the same directory with the same base name but with a .bak extension as opposed to a .dwg extension.

    This does not explain the files I find with names such as BaseName_8605.bak

    When I execute SAVEFILEFOLDER as a command, I get no output. It appears as an option as I'm keying in the appropriate leading character sequence, so I was expecting to be able to see it's contents if nothing else. As a professional programmer, I don't see the wisdom in offering something that does nothing from the end users point of view.
    I tried echo $SAVEFILEFOLDER in the Linux environment to see if BricsCAD had created a global environment variable, but that also returned nothing. I assume that variable is available to Lisp and the developers interface generally for supported language environments.

    Within the Nautilus file browser, I double clicked a .SV$ file and BricsCAD started up but displayed nothing. I then duplicated the .SV$ file and renamed it to a .dwg extension, double clicked it, and that did bring up the drawing. Again, I question the wisdom of starting the app and then displaying nothing.

    I understand wanting to maintain compatibility with Acad, but leaving around loose ends that do nothing but allow the end user to stumble over them seems ill advised and asks the end user to coax a reasonable response by manual intervention.

  • edited September 3

    RoatanBill, you summarized Jason's explanation well. About savefilefolder (that is new to me, handy!), some variables concerning save: savename savefile savetime savefilepath. You probably want to use savefilepath instead of savefilefolder? Confusing indeed, you named it right in the first post.

    Can't remember double clicking .sv$ files in AutoCAD returned a drawing, .sv$ as a last resort safety construction (move *.sv$ to *.dwg after a crash).

  • edited September 3

    (move *.sv$ to *.dwg after a crash)

    Does this mean I should place a copy of the SV$ into my
    drawing folder beside my drawing file after a crash,
    and when I File/Drawing Utilities/Recover it will recover
    my latest unsaved changes - when in the Backup File ?

    (If so, why doesn't Bricscad itself searches the Backup Path
    newer files states ?)

  • edited September 3

    Again, BricsCAD was designed to handle things the way AutoCAD does. This allows prior AutoCAD users to know what sort of behavior to expect from BricsCAD.

    The smarter programs become, the more important it is to know what they are thinking. And it takes years to really know a program in all its details. So, changing how BricsCAD behaves from how AutoCAD does it, would create uncertainty.

    However, it is also good for BricsCAD to introduce some new functionality... as long as it does not change any behaviors that were expected in AutoCAD. So, it may be viable to add the ability check all the SV$ files, to see if any seem to be newer than what you are opening now. That would slow the opening process though.

    -Joe

  • Michael, I like Joe's idea.

    For retrieving sv$ files, you may like this one...

    What it does:
    * Browse for a sv$ file
    * Move it to dwgname-fancypart.dwg
    * Open it
    * Then it is up to you to save it somewhere

    Code:

    ; A browser to recover autosave files, (c) NedCAD 2019 Wiebe van der Worp
    
    (defun c:autosave-browser ( / ran-t ran-3 sv-file sv-base sv-dir sv-ext dwg-file)
        (setq
            ran-t (itoa (getvar "millisecs"))
            ran-3 (substr ran-t (- (strlen ran-t) 3) 3)
        )
        (if (= (setq sv-path (getvar "savefilepath")) nil)
            (setq sv-path (getenv "tmp"))
        )
        (setq
            sv-file (getfiled "Select an automatic saved (sv$) drawing: " sv-path "sv$" 8)
            sv-base (vl-filename-base sv-file)
            sv-dir (vl-filename-directory sv-file)
            sv-ext (vl-filename-extension sv-file)
            dwg-file (strcat sv-dir "\\" sv-base "-" ran-3 ".dwg")
        )
        (if (vl-file-copy sv-file dwg-file)
            (progn
                (princ (strcat "\nFile " sv-base sv-ext " is copied to " dwg-file ". "))
                (vla-activate (vla-open (vla-get-documents (vlax-get-acad-object)) dwg-file))
                (princ "\nYou may want to save this file first. ")
            )
            (princ (strcat "\nAn error occured while copying file " sv-base sv-ext " to " dwg-file". "))
        )
        (princ)
    )
    
  • Thanks Wiebe,
    that looks handy.

    Just that I understand.
    If I crash a file where I realize that I forgot to save.
    I just have to search for a SV$ with a newer date and just open that
    after renaming its ending - to get most of my work back ?

    If I have a file constantly crashing,
    I can try any newest dated SV$ or DWG version, open it by Recover
    to try to repair it ?

    So there is no deeper fancy AI logic behind in Brautocad to recreate
    as much data as possible from the Software ?
    (Maybe I thought too complex so far, like a needed combination of
    DWG + SV$ history to make files recover)

    Well, my politest 3D Software welcomes me when reopening after
    a crash with a shy :
    Sorry, it looks that last time Modo crashed or quit unexpectedly.
    Would you like to open all recent files and try to recover your data - YES/NO

  • Wiebe: I've written software in 22 computer languages but I can't identify what you provided. Not only that, I have no idea where to put it to get it to run or how to call it up. I'm just too BricsCAD ignorant at this point.

    I'm not ready to delve into the BricsCAD API yet. I'm still trying to use the commands available and can spend the better part of an afternoon drawing a few interconnected solids that are supposed to represent the next steel project I'm contemplating welding up.

    I wish I were savvy enough to accept your gift. Maybe in a few months?

  • @Michael Mayer: It is as easy as you described. And I think we all agree that automatic recovery would be a valuable addition. That, combined with the observation that there is a highly motivated team of developers in Ghent and other places in the world... I would suggest you do a service request.

    @ RoatanBill:

    If you want to use files that BricsCAD can find, such as this Lisp file, you have to put locations in the search path, see settings > program options > files > support file search path, add directories to your needs.

    If you want to use the code, simply put it in a text file like load_me.lsp, AND somewhere in that search path.

    Now you can do two things:

    1: Enter on the command line, parentheses included: (load "load_me"). You have a new command: autosave-browser, just start typing the command.

    2: For automatic loading in every document, issue ._appload, button new, browse, check autoload.

    The world is full of pearls like these, just waiting to be loaded ;-)

  • Just to add to Wiebe's last post, you can also drag and drop LISP files onto your drawing window to load them. BTW this works with other file types too and if you right mouse drag and drop you will be presented with additional options on how to work with the file.

    Regards,
    Jason Bourhill
    BricsCAD V19 Ultimate
    Quickly create HELP links on your forum posts

    CAD Concepts

  • @Jason Bourhill , thanks for your valuable screening and addition.

  • You all might want to also look into the Autosave feature. This (at least in my v14) is not on by default. You can set the autosave interval.

    And I also have these files that are known for crashing quite regularly. It seems to be specific to those files. There are a few techniques to try to clear the problem out, but that is no guarantee any of them will work. So, for those files, the AutoSAVE is important. Also, incremental backups are important.

    -Joe

  • edited September 4

    @Wiebe van der Worp said:
    @Jason Bourhill , thanks for your valuable screening and addition.

    Thanks ALL for your input.
    I think I have quite an overview now.

  • @haileykhysen said:
    can spend the better part of an afternoon drawing a few interconnected solids that are supposed to represent the next steel project I'm contemplating welding up.

    I would start another thread elsewhere, if you want to pursue it further than what I am posting now. But, if you've already been through the tutorials, it sounds like you may benefit from a tutor to help you on your specific work flow. Hopefully, someone who you can call, and do some screen sharing. He may also advise you on your overall approach, which can take a lot of time to figure out how best to approach your own needs.

    -Joe

  • Joe, I think @haileykhysen is a spambot, carefully picking words from this thread, combining it into something sounding reasonable. Impressive! Hope I am not wrong :-)

  • edited November 8

    @Jason Bourhill said:
    This is by design. BricsCAD uses the same method as AutoCAD traditionally used.

    By default a .bak file is created with each subsequent save to the first. This file is a copy of your drawing immediately prior to the latest save. You can control whether these are created by changing the value of ISAVEBAK in SETTINGS. To use a .bak file, simply rename the extension to .dwg.

    Autosave creates a copy of your drawing after a set interval. These files are given a .sv$ extension and are saved to fixed location. You can use SAVEFILEFOLDER to navigate to the set folder. You can configure the folder location using SAVEFILEPATH, and the interval using SAVETIME. A couple of important things to know about Autosave:
    1. It ONLY does an Automatic save if you haven't within the set interval. If you save regularly, then an Autosave file won't get created. i.e. Everytime you do a SAVE the autosave time is reset.
    2. Autosave is ONLY triggered when you run a command. E.g. you have SAVETIME = 15mins. You make some changes to your drawing, then get called away forgetting to SAVE. After an 1hr you return and continue working on your drawing. It is only now when you run a command that the Autosave fires i.e. it didn't do an autosave while you where gone after 15mins. shareit vidmate

    Regards,
    Jason Bourhill
    BricsCAD V19 Ultimate
    Quickly create HELP links on your forum posts

    CAD Concepts

    thanks for sharing this kind information, this is really informative and helpful for me

    Regards.:)

Sign In or Register to comment.
Origami
Origami is the Japanese word for paper folding. ORI means to fold and KAMI means paper and involves the creation of paper forms usually entirely by folding.

Powered by VanillaForums, Designed by Steam