automatic upgrade_export

automatic upgrade_export

Secure Home | Search | About
 Networking Firewalls    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content add this group's latest topics to your Google content
Subject Author Date
automatic upgrade_export Pussala 04-30-2008
Posted by on April 30, 2008, 8:06 am
If you were  Registered and logged in, you could reply and use other advanced thread options
I want automatic upgrade_export.


[Expert@MNGFW01]# crontab -e:

50 12 * * * cd /opt/CPsuite-R62/fw1/bin/upgrade_tools
51 12 * * * echo | ./upgrade_export appoggio
25 13 * * * oggi=`date`
26 13 * * * mv appoggio.tgz.tar $oggi
27 13 * * * scp $oggi root@172.28.121.16:/data/backup_2008

[Expert@MNGFW01]# less /var/log/cron

Apr 30 12:50:00 MNGFW01 CROND[22798]: (root) CMD (cd /opt/CPsuite-R62/
fw1/bin/upgrade_tools)
Apr 30 12:51:00 MNGFW01 CROND[22806]: (root) CMD (echo | ./
upgrade_export appoggio)
Apr 30 12:52:24 MNGFW01 crontab[22820]: (root) LIST (root)
Apr 30 12:53:19 MNGFW01 crontab[22821]: (root) LIST (root)
Apr 30 12:54:14 MNGFW01 crontab[22827]: (root) BEGIN EDIT (root)
Apr 30 12:54:26 MNGFW01 crontab[22827]: (root) END EDIT (root)
Apr 30 13:25:00 MNGFW01 CROND[22966]: (root) CMD (oggi=`date`)
Apr 30 13:25:54 MNGFW01 crontab[22972]: (root) LIST (root)
Apr 30 13:26:00 MNGFW01 CROND[22974]: (root) CMD (mv appoggio.tgz.tar
$oggi)
Apr 30 13:27:00 MNGFW01 CROND[22980]: (root) CMD (scp $oggi
root@172.28.121.16:/data/backup_2008 )
Apr 30 13:28:30 MNGFW01 crontab[22988]: (root) LIST (root)
Apr 30 13:29:30 MNGFW01 crontab[22997]: (root) BEGIN EDIT (root)
Apr 30 13:30:05 MNGFW01 crontab[22997]: (root) END EDIT (root)

If I run commands without crontab all ok!
With crontab run upgrade_export but does not create anything!

What happens?
Where is the error?

Posted by Moe Trin on April 30, 2008, 3:58 pm
If you were  Registered and logged in, you could reply and use other advanced thread options
On Wed, 30 Apr 2008, in the Usenet newsgroup comp.security.firewalls, in article
Pussala@gmail.com wrote:

NOTE: Posting from groups.google.com (or some web-forums) dramatically
reduces the chance of your post being seen. Find a real news server.

>I want automatic upgrade_export.

And what does this have to do with firewalls?

>[Expert@MNGFW01]# crontab -e:
>
>50 12 * * * cd /opt/CPsuite-R62/fw1/bin/upgrade_tools
>51 12 * * * echo | ./upgrade_export appoggio
>25 13 * * * oggi=`date`
>26 13 * * * mv appoggio.tgz.tar $oggi
>27 13 * * * scp $oggi root@172.28.121.16:/data/backup_2008

1. uname -a
2. which cron
3. man cron
4. man crontab

Then add the following lines to this crontab:

52 12 * * * * set > /tmp/cron.environment.12.52
26 13 * * * * set > /tmp/cron.environment.13.26

and finally, run the command 'set > /tmp/my.environment

and then compare those three files in /tmp. You'll find that the
environment is quite different, and commands that you run in a cron
child process have no effect on _other_ child processes that may be
spawned by the parent. As you've decided to do this in cron, create
a single job that runs at a chosen time, such as

55 12 * * * run.this.silly.script

where 'run.this.silly.script' contains the actual commands

#!/bin/sh
cd /opt/CPsuite-R62/fw1/bin/upgrade_tools
echo | ./upgrade_export appoggio
oggi=`date`
mv appoggio.tgz.tar $oggi
scp $oggi root@172.28.121.16:/data/backup_2008

Incidentally, that is a rather interesting extension for a file 'tgz.tar'

For further help, try an appropriate UNIX newsgroup, or comp.unix.shell.
Do try to find a real news server first, as many people filter posts
from groups.google.com.

Old guy

Posted by on May 1, 2008, 12:37 pm
If you were  Registered and logged in, you could reply and use other advanced thread options
On Apr 30, 2:58=A0pm, ibupro...@painkiller.example.tld (Moe Trin) wrote:
> On Wed, 30 Apr 2008, in the Usenet newsgroup comp.security.firewalls, in a=
rticle
>
> Puss...@gmail.com wrote:
>
> NOTE: Posting from groups.google.com (or some web-forums) dramatically
> reduces the chance of your post being seen. =A0Find a real news server.
>
> >I want automatic upgrade_export.
>
> And what does this have to do with firewalls?

Because he is discussing an issue with Checkpoint upgrade_export
maybe.
I see he did go to www.cpug.org and asked the same question and got an
answer.


Posted by Moe Trin on May 2, 2008, 4:07 pm
If you were  Registered and logged in, you could reply and use other advanced thread options
On Thu, 1 May 2008, in the Usenet newsgroup comp.security.firewalls, in article
rick@bcm.tmc.edu wrote:

NOTE: Posting from groups.google.com (or some web-forums) dramatically
reduces the chance of your post being seen. Find a real news server.

>ibupro...@painkiller.example.tld (Moe Trin) wrote:

>> Puss...@gmail.com wrote:

>>> I want automatic upgrade_export.
>>
>> And what does this have to do with firewalls?
>
>Because he is discussing an issue with Checkpoint upgrade_export
>maybe.

Barking at the wrong tree - his problem is a fundamental mis-understanding
of the UNIX 'cron' daemon, and has nothing to do with any firewall. His
post in this group continued:

If I run commands without crontab all ok!
With crontab run upgrade_export but does not create anything!

So there is nothing wrong with the commands (what ever they may be), but
they fail to run in his rather bizarre interpretation of what the manual
page says for 'crontab'. That's also why (after answering his question)
I suggested he look at an appropriate UNIX newsgroup, or comp.unix.shell.

>I see he did go to www.cpug.org and asked the same question and got an
>answer.

He posted from googlegroups, and (like many) I filter those posts off
in a number of the other newsgroups I try to scan daily, but I also
see that he posted to (at least) 'comp.os.linux.misc' and got an answer
similar to the one I provided - run all of the commands out of a single
script, rather than running five independent (and unrelated) commands
out of root's crontab.

Old guy

Posted by on May 5, 2008, 9:05 am
If you were  Registered and logged in, you could reply and use other advanced thread options
On 2 Mag, 22:07, ibupro...@painkiller.example.tld (Moe Trin) wrote:
> On Thu, 1 May 2008, in the Usenet newsgroup comp.security.firewalls, in article
>
> r...@bcm.tmc.edu wrote:
>
> NOTE: Posting from groups.google.com (or some web-forums) dramatically
> reduces the chance of your post being seen. Find a real news server.
>
> >ibupro...@painkiller.example.tld (Moe Trin) wrote:
> >> Puss...@gmail.com wrote:
> >>> I want automatic upgrade_export.
>
> >> And what does this have to do with firewalls?
>
> >Because he is discussing an issue with Checkpoint upgrade_export
> >maybe.
>
> Barking at the wrong tree - his problem is a fundamental mis-understanding
> of the UNIX 'cron' daemon, and has nothing to do with any firewall. His
> post in this group continued:
>
> If I run commands without crontab all ok!
> With crontab run upgrade_export but does not create anything!
>
> So there is nothing wrong with the commands (what ever they may be), but
> they fail to run in his rather bizarre interpretation of what the manual
> page says for 'crontab'. That's also why (after answering his question)
> I suggested he look at an appropriate UNIX newsgroup, or comp.unix.shell.
>
> >I see he did go towww.cpug.organd asked the same question and got an
> >answer.
>
> He posted from googlegroups, and (like many) I filter those posts off
> in a number of the other newsgroups I try to scan daily, but I also
> see that he posted to (at least) 'comp.os.linux.misc' and got an answer
> similar to the one I provided - run all of the commands out of a single
> script, rather than running five independent (and unrelated) commands
> out of root's crontab.
>
> Old guy

I edit script for backup:

#!/bin/sh
. /etc/profile.d/CP.sh
cd /var/CPbackup/backups
echo | backup -d --file /var/CPbackup/backups/
scp fw_export pluto@172.29.198.23:/data/backup
exit 0

Can I exec the backup command without me being asked "Are you sure you
want to proceed?"
The command "echo |" not work !!!

Thanks

Similar ThreadsPosted
Re: Automatic fail-over with redundant firewalls August 17, 2006, 7:49 am
Newbie queries Norton Internet Security 2004 automatic connection August 1, 2004, 1:36 pm

The site map in XML format XML site map

Contact Us | Privacy Policy