Save & Restore from command line

All those commands that we don't really use very often, but that we should ! Documented or not, they worth it !
Turlupin
Member
Posts: 101
Joined: 05 Jun 2007 07:59
Location: Paris / France

Save & Restore from command line

Post by Turlupin »

Hello everybody !

By default, the system backup only the mao data files, and the chorus data files.

The following commands will help you if you want to save or restore database, voice guide, accounting ... from the command line or automatically :


Save operations :

You can use root user to launch the command because under mtcl user, the swinst account password will be asked.

Code: Select all

 [root@xa000000 root]# /DHS3bin/soft_install/bin/bck -save param
Where param is :
  • - mao :save of the Mao
  • - mao-acc :save of the Mao, Voice guides, Accounting
  • - acc :save of the Accounting data
  • - acd :save of the ACD data (statistics) and configuration files
  • - vg :save of the Voice Guides
  • - mao-dat :save of the Mao data files (this is the save operations scheduled by default by the system
  • - obstraf :save of the Traffic observation files
  • - cho-dat :save of the Linux specific data
  • - noe :save of the 8&9 series customized files
You will find the files generated by the backup process in the directory : /usr4/BACKUP/IMMED/

You can schedule the save operation using crontab, for exmple :

Under root

Code: Select all

[root@xa000000 root]# crontab -e
Add the line (using vi command) : 0 4 * * * /DHS3bin/soft_install/bin/bck -save acd>/dev/null 2>&1

This will perform a save operations of all the acd files under /usr4/BACKUP/IMMED/ every day at 4 am.


Restore operations :

Place your backup file in the directory /usr4/BACKUP/IMMED/ directory and then launch the command :

Code: Select all

[root@xa000000 root]# /DHS3bin/soft_install/bin/bck -restore [b]param[/b]
You can use root user to launch the command be cause under mtcl user, the swinst account password will be asked.


Where param is :
  • - mao :restore Mao files
  • - mao-acc :restore the Mao, Voice guides, Accounting
  • - acc : restore the Accounting data
  • - acd :restore the ACD data (statistics) and configuration files
  • - vg :restore the Voice Guides
  • - mao-dat :restore the Mao data files (this is the save operations scheduled by default by the system
  • - obstraf :restore the Traffic observation files
  • - cho-dat :restore the Linux specific data
  • - noe :restore the 8&9 series customized files
Enjoy !
cavagnaro

Re: Save & Restore from command line

Post by cavagnaro »

Nice post Turlupin :) Thanks a lot for this cool info :D
torrentula

Re: Save & Restore from command line

Post by torrentula »

Thanks for the info....

What about 46X5? Are there no parameters for voicemail?
Turlupin
Member
Posts: 101
Joined: 05 Jun 2007 07:59
Location: Paris / France

Re: Save & Restore from command line

Post by Turlupin »

Yes, there is parameters for the 4635 et the 4645 backup.But in swinst you need to provide an argument (the voicemail hostname for the 4635) to launch the backup, and i'm still looking searching to transmit this agument on the command line.

The parameter for the 4635 is 4635j
The parameters for the 4645 are eva (for the configuration of the voicemail) and eva-msg (for the configuration and the messages)

Code: Select all

root@xa000000 root]# /DHS3bin/soft_install/bin/bck -save 4635j
root@xa000000 root]# /DHS3bin/soft_install/bin/bck -save eva
root@xa000000 root]# /DHS3bin/soft_install/bin/bck -save eva-msg
I can run my test only for the 4635 because whe don't have 4645 on the network, if somebody can try the command, it could be nice.
wizzy

Re: Save & Restore from command line

Post by wizzy »

Very nice and useful :D

Tested and working 100%

Nice job !!
torrentula

Re: Save & Restore from command line

Post by torrentula »

That's awesome, you da man Turlupin!!!!
mysticalself_DUP

Re: Save & Restore from command line

Post by mysticalself_DUP »

Hi ,
Where will the 46x5 backup be stored in?I mean which folder and how to restore it?
Turlupin
Member
Posts: 101
Joined: 05 Jun 2007 07:59
Location: Paris / France

Re: Save & Restore from command line

Post by Turlupin »

You will find the voicemail backup files in /usr4/BACKUP/IMMED

The command for the restoration will be :

Code: Select all

root@xa000000 root]# /DHS3bin/soft_install/bin/bck -restore eva/eva-msg/4635j (depends eon the file you want to restore)

But as i said in an earlier post, i still searching the differents parameters used on the command line for the backup/restore operations of the voicemail.
Sorry for my english .... :)
torrentula

Re: Save & Restore from command line

Post by torrentula »

It would be nice if it created folders for each day like the system automatic backup. But this is better than nothing.
Turlupin
Member
Posts: 101
Joined: 05 Jun 2007 07:59
Location: Paris / France

Re: Save & Restore from command line

Post by Turlupin »

If you want to store the bakcup file in a specific directory, you can execute a script with cron, which will first create a directory like /usr4/BACKUP/IMMED/01-03-2008, then launch the backup command and finaly move the backup file in this directory.
Sorry for my english .... :)
Post Reply

Return to “Usefull commands”