Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @HeikoAnkenbrand 

That's a great idea and great implementation!

Keep up the good work 🙂

 

0 Kudos
Highlighted
Nickel

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Thanks for this Script.

With json and jq most often you don't need additional bash commands. So you can replace

mgmt_cli -r true show gateways-and-servers details-level full --format json | $CPDIR/jq/jq -r '.objects[] | select(.type | contains("Member","simple-gateway")) | ."ipv4-address",."name"  ' |xargs -n 2 | grep -v 0.0.0. > /tmp/ebackup_topo;

with

mgmt_cli -r true show gateways-and-servers details-level full --format json | $CPDIR/jq/jq -r '.objects[] | select(.type | contains("Member","simple-gateway")) | select(."ipv4-address" != "0.0.0.0") | ."ipv4-address"+" "+ ."name"' > /tmp/ebackup_topo;

 

Bye

Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution
Thank you for the excellent script!

I have a suggestion to add an option to change the API port.
For example on my SMS, there is also Endpoint MGMT and default API port is changed to 4434 .
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @Dilian_Chernev,

That was a good point from you. 👍

Now in v1.1 the option -port <sms port> add the management server port, if it's not running on port 443.

Regards
Heiko

 

View solution in original post

Tags (1)
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution
Working perfectly!
Is it possible to add file transfer to a SCP server also ?
0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

@Dilian_Chernev  @HeikoAnkenbrand 

It should be fairly straight forward to do, but I'll leave that to Heiko to incorporate.

When it comes to storing the passwords for the ftp/scp/sftp on a server for a cron job, I tend to stay away from that.

My solution is to use the cprid capabilities to copy the file to a second Mgmt (HA), log server, SmartEvent server, or worse case a gateway, so that it exists in more than one location.

Just my 2 cents.

Paul G.

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi@Dilian_Chernev @Paul_Gademsky,

Check Point upload support for the backup file via cprid_util is added.😀

So you can copy the backup with the option -cpupload directly to another Check Point gateway or SMS/MDS.

Regards
Heiko

Tags (1)
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Thank you for the excellent script!

I have a suggestion to add an option to send the files (export & Gaia-configuration)  to a external server/location, via FTP o CIFS.

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @Giorgio_Giustoz ,

Now v1.3 with FTP Upload,

ebackup -ftpserver 1.1.1.1 -ftpuser username -ftppw test123   -> Backup all GAIA configs + migrate export with upload to a ftp server.

Regards

Heiko

Tags (1)
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @HeikoAnkenbrand,

I have been following this article for the last few days. This is a really good idea that you've developed here. In my opinion the script should be published in a JHF or in the next R80 version.

We use it on several management servers of our customers and it's working great now.

PS: Curl download works fine now.

Many thanks
Armin

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Now v1.3 with the following options:

Syntax  Description
-s
The option -s  performs a cpstop and cpstart when the migrate export tool is executed.
-no_migrate  The option -no_migrate has the consequence that no migrate export is executed.
-port <sms port>
The option -port <sms port> add the management server port, if it's not running on port 443.
-ftpserver <ftp server ip>
-ftpuser <username>
-ftppw <password>
The ftp options allow to upload the tar file to a ftp server.
 
Highlighted
Nickel

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Thank you so much for an awesome tool - this has been a gap in my toolbox for so long.  The only issue I have picked up in testing is a spelling mistake in the output file, as per attachment.

Thanks again,
Ruan

Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @Ruan_Kotze,

THX, I changed that. Is now correct.

Regards
Heiko

Tags (1)
0 Kudos

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Nice xcript. Thanks

Is there also a backup option for SMB devices?

 

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

The 1.4 version I posted has been successfully run against 3 different 1200R appliances at this point. Let me know if you have a different experience.

Paul G.

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @Jan_Elbers 

The tool supports all SMB applications where no 0.0.0.X IP address is set in the topology.

Regards
Heiko

Tags (1)
0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @HeikoAnkenbrand 

Can I execute the script as cronjob?

 

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @Harry_Morgan,

If the ebackup tool should be executed automatically, only a cronjob has to be created.
I described it in the article.

Regards
Heiko

Tags (1)
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hello @HeikoAnkenbrand,

Is it possible to add a scp upload?

Thanks

Pablo

0 Kudos
Highlighted
Ivory

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution
ssh upload?
0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

coming soon

Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Now tested with R80.40.

0 Kudos
Highlighted
Iron

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Thank you for this script.
One question in case of an Endpoint MGMT: is there also a opportunity to use the function of a migrate export with the syntax "--include-uepm-msi-files"?

That would great

Best regards

Moritz

0 Kudos
Highlighted
Iron

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hello @HeikoAnkenbrand 
now I have a second question:
after adding a test cronjob with ebackup, the topic of the job notification mail includes the users password. Is it possible to hide it?

And Im not sure if it is a typo in the script, because also in the job notification mail, I got an error message:

rm: cannot remove '/tmp/ebachup_cpupload': No such file or directory TERM environment variable not set.

Does this error occur because of "ebachup_cpupload" instead of "ebackup_cpupload". I can find it multiple times in the script.

Best regards

Moritz

0 Kudos
Highlighted

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

Hi @HeikoAnkenbrand 

Much appreciated tool. Works like a  charm on a R80.40-SMS, R80.30/R77.30 gateways, and TE appliance environment.

Regards

Mutumak

 

0 Kudos
Highlighted
Iron

Re: Easy Backup Tool - (migrate export + all GAIA configs)

Jump to solution

👍🏻

0 Kudos