Collaborate forum
cancel
Showing results for 
Search instead for 
Did you mean: 

BIMcloud basic backup scripts in Catalina or Big Sur

Erik Wallen
Newcomer
Hi.

I can't get the scheduled backup scripts according to http://download.graphisoft.com/ftp/techsupport/downloads/BIMcloud/IH/Backup_Guides/BIMcloud_Basic_22... to work in Mac OS Catalina or Big Sur. Has worked fine in previous version of Mac OS. Anyone know why it no longer works?

Thanks in advance.
Erik
8 REPLIES 8

SeRohde
Enthusiast
Hello Erik,

could you look up your BIMcloud basic Build Version?

PDF Page 5 "Run the backup with scripts"
Are the paths settings in the .sh file correctly setup? [line 4-11]

PDF Page 6-7 "Schedule Mac Backup Scripts to Run Unattended"
Are the plist files setup correctly? (trigger, ownership etc)

Maybe this applys too:
https://helpcenter.graphisoft.com/knowledgebase/118793/
Admin of BIM [Cloud] [SaaS] [Server] | AC 19-25 [Win&Mac Clients] | VM's

Erik Wallen
Newcomer
Hello

- The BIMcloud version is 25.0.184.1902
- The paths is correct. When I run the script from terminal everything works fine.
- The plist-file file is setup correctly (according to the PDF) but I guess somthing is wrong whit the permissions when it runs scheduled)
- Everyting is setup liked the knowledbase-link you sent.

I have tried to give the script full disk access but it doesn't help.
Any other suggestions?

Thanks!

SeRohde
Enthusiast
Erik,

I was checking the Link you provided and noticed something:
Within the PDF are Links with scripts which refer to themselves as v22.

So I went to: https://helpcenter.graphisoft.com/knowledgebase/52663/ and clicked on BIMcloud Basic Backup Guide from version 2020.2
http://dl.graphisoft.com/ftp/techsupport/documentation/BIMcloud_Backup_Guide/BIMcloud%20Basic%20Back...

These seem to be more "up-to-date" and the scripts refer to themselves as v24

v24MacServerAndManagerBkUp:
http://dl.graphisoft.com/ftp/techsupport/documentation/BIMcloud_Backup_Guide/v24MacServerAndManagerB...

MacScheduleBackupScriptsWithPlistFiles
http://dl.graphisoft.com/ftp/techsupport/documentation/BIMcloud_Backup_Guide/MacScheduleBackupScript...

I have not found the time yet to compare the v22 scripts with the v24 scripts but I would give them a try. Maybe they are still not the right ones - In this case someone who owns a Mac might help. I don't have one here.

Cheers,
S.
Admin of BIM [Cloud] [SaaS] [Server] | AC 19-25 [Win&Mac Clients] | VM's

Erik Wallen
Newcomer
Hello

I have used the script for 24 (shared wrong link).
The scripts work perfectly when I run it from the terminal, so there is nothing wrong with the script itself. It is the scheduling and the permissions when the script runs automatically that should be problem.

SeRohde
Enthusiast
Erik wrote:
- The plist-file file is setup correctly (according to the PDF) but I guess somthing is wrong whit the permissions when it runs scheduled)

Outline of scheduling a script to run on macOS:
1.Createa plistfile that configures the time and environment in which the backup script will run.
2.Give correct ownership for the plist file
3.Locatethat plist file appropriately on the computer.
4.Start/Stop the daemon (background process) that runs the script on its schedule.

So lets focus on the plist-file. Lets say the Daily Script (com.example.BkUpDaily_v24.plist)

(1) Check Path and Filename. Check in the xml Code <key>Label</key> and <key>ProgramArguments</key>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>Label</key>
  <string>com.example.BkUpDaily</string> <!-- OR com.example.BkUpDaily_v24 -->

  <key>ProgramArguments</key>
  <array>
	<string>/BSBkupScripts/backupscript.sh</string> <!-- Path? v24MacServerAndManagerBkUp.sh -->
  </array>
.
.
.
(2) ownership is? =root?
PDF says: sudo chown root:wheel “/Path/To/The/example.plist”
sudo chown root:wheel "/Path/To/The/com.example.BkUpDaily_v24.plist"
(3)
~/Library/LaunchAgents for testing
/Library/LaunchDaemons for production

(4) load/run/unload the script deamon
sudo launchctl load /Library/LaunchDaemons/Example.plist
launchctl load ~/Library/LaunchAgents/Example.plist

sudo launchctl unload /Library/LaunchDaemons/Example.plist
launchctl unload ~/Library/LaunchAgents/Example.plist
Admin of BIM [Cloud] [SaaS] [Server] | AC 19-25 [Win&Mac Clients] | VM's

Erik Wallen
Newcomer
I have checked and double checked all the .sh and .plist file and everything is fine.
I have also done everthing mentioned above and it doesn't help.
As I have mentioned before I think there is somthing wrong whit permissions.
Has anyone got the schedule to work at Catalina or Big Sur?

Ole Saalmann
Participant
Erik wrote:
As I have mentioned before I think there is somthing wrong whit permissions.
Has anyone got the schedule to work at Catalina or Big Sur?
Hi Erik,
I just got it to work. Here is how I did it, maybe that helps you:

- I use Lingon.app (https://www.peterborgapps.com/lingon/) for scheduling on macOS. That way I don't have to edit .plist files my self

- in the FAQs for Lingon on the above website, there is a section "Why doesn’t my job run properly in 10.15 Catalina and later?"

- I used the "Build as App” tip mentioned there. In Lingon, use Command-K to open "v24MacServerAndManagerBkUp.sh", then klick "Build an app" button. Save somewhere

- Afterwards, head to System Settings / Security / Privacy and give "Full Disc Access" to the new app.

That seems to have done the trick. Requires Lingon.app, though.

I believe the problem is, that a .sh script called from the .plist cannot get the required permissions.

Hope that helps.
ARCHICAD since 4.55 | iMac 27" 5K 4,2 GHz i7 32GB | macOS current | AC 21 5021

SeRohde
Enthusiast
Good to hear. Thank you for providing your solution.
Admin of BIM [Cloud] [SaaS] [Server] | AC 19-25 [Win&Mac Clients] | VM's

Still looking?

Browse more topics

Back to forum

See latest solutions

Accepted solutions

Start a new discussion!