Showing posts with label backup. Show all posts
Showing posts with label backup. Show all posts

Sunday, 26 November 2023

How To Backup Windows Server 2016

 How To Backup Windows Server 2016


Here we’ll show you how to install the Windows Server Backup feature in Windows Server 2016 with PowerShell and then configure basic server backups.

We’ll also take a quick look at how the backup files are stored and see if they are at all encrypted or not.

In order to perform simple backup and restores out of the box, Windows Server 2016 provides the Windows Server Backup feature. While this does work it is fairly basic and lacks many useful features, if you have many critical servers to backup I highly recommend that you look at something else such as Microsoft’s Data Protection Manager (DPM) or a third party backup solution from some other vendor.

An example of this is that when you backup over the network to an external share with Windows Server Backup you can only store one restore point at a time, any further backups will overwrite existing ones which isn’t very useful if you actually need some sort of retention. The backups are also managed on a per server basis which makes them difficult to maintain and manage.

Install Windows Server Backup Feature

Before we can actually configure the backups, we must first install the Windows Server Backup feature. This can be done through the graphical user interface, however it’s just faster to simply use PowerShell.

First we’ll use the Get-WindowsFeature cmdlet to search for available features that contain the string ‘*Backup*’ in the Name field.

PS C:\> Get-WindowsFeature -Name *Backup*

 


As we can see Windows-Server-Backup is available for install but not currently installed.

Next we use the Install-WindowsFeature cmdlet to install the Windows-Server-Backup feature, as shown below.

PS C:\> Install-WindowsFeature -Name Windows-Server-Backup

 


Once complete we should see that the installation has completed successfully, no reboot is required for this feature, we can begin using it straight away.

Configure Backups

Now that we have installed the Windows Server Backup feature, we can begin to configure our server backups. To begin we’re going to open the Windows Server Backup console from the Tools menu in Server Manager as shown below.

 


From the wbadmin window that opens up, select “Local Backup” from the menu on the left. We will see that there is a warning noting that no backup has been configured for this computer, which is currently expected. We can either configure a backup schedule which will perform the backup as we define, or we can perform a once off backup. Here we’ll setup a backup schedule, by clicking “Backup Schedule” on the right.

 


This will open up a Getting Started window advising that we can use this wizard to configure a regular backup schedule for the full server, system state, selected files, folders or entire volumes – click Next to proceed.

 


On the next Select Backup Configuration window we can select if we want to perform a full server backup which is the recommended and default action, or we can optionally select custom to pick specific volumes or files that we want to backup rather than the full server. In this example we will be configuring a full server backup, however you can change this to suit your requirements.

 


The next window allows us to specify the time the backup should run. We can set the backup to run once daily at a specified time, or we can optionally have it run multiple times per day by selecting the more than once a day option and adding the times the backup should run to the right side.

 


Next we will be asked to specify the destination of our backup data. The recommended option is to store the data on a separate disk that is attached to the server, however we can also change this to backup to another volume, or a network share. In this example I’ll be using a network share as I have one available, however note that there is a limitation of this, we will only be able to store one backup point at a time as new backups will overwrite the existing one. This limitation does not exist when you backup to another disk or volume.

We will now specify the network location, here I pick a file share that is available on the local network and click Next to continue. If you selected a disk or volume destination rather than network, you would instead be asked to pick that disk or volume here.

 


Finally we are presented with a confirmation screen which will summarize our options, click the Finish button to complete the process and accept this, or otherwise go back and make any changes as needed. The summary notes that as we are performing a full backup, we will be able to perform bare metal recovery of the entire system which is fairly powerful.

 







That’s it, the backup should automatically start at the time specified. We can manually initiate it by going back to the Windows Server Backup window and selecting “Backup Once”. From here we are given the option to create a once off backup based off of our scheduled backup, so all of the same settings will be used but we will be running the backup now rather than at the scheduled time.

Are Windows Server Backups Encrypted?

This is a common question that I’ve seen asked a few times, so I thought I’d take the opportunity to answer it here. No, by default backups in Windows Server 2016 (and previous versions for that matter) are not encrypted. We can confirm this by simply browsing to the location that we have specified to backup the data to and look through it. Primarily a .vhdx file is created for the C:\ drive of the server, which we can easily mount through disk manager, assign a drive letter to and then browse through the files and folders.

To encrypt the backup files we could setup Bitlocker on the disks where the backups are being stored, however note that this only protects the data at rest. If the data can be accessed while the drive is available for the backup to work, it could also be read by any potential attacker during this time.

Summary

We have shown you how to install the Windows Server Backup feature in Windows Server 2016 using PowerShell, and then configure a basic backup schedule to a network share.

We also then confirmed that the backup files are not encrypted, so additional steps should be taken to protect them.


Wednesday, 6 May 2020

2679373 - SWPM SYB: unable to set up backup server

Symptom

Error reported by SAP Installer is similar to the following:
Assertion failed: Unable to set up backup server. Refer to trace file sapinst_dev.log for further information.

Other Terms

ASE, backup server

Reason and Prerequisites

You are trying to install an SAP System based on ASE release 16.0 SP03 PL04 on the AIX platform. The host is configured to use virtual host names.
The SAP installer presents the message "Unable to set up backup server" and the installer's trace file sapinst_dev.log includes entries like:

Building Backup Server '<SID>_BS':
Writing entry into directory services...
Directory services entry complete.
Writing RUN_<SID>_BS file...
RUN_POP_BS file complete.
Starting server...
Unable to boot server '<SID>_BS'.  
Task failed
Server '<SID>_BS' was not created.

The corresponding backup server log file /sybase/<SID>/ASE-16_0/install/<SID>_BS.log includes traces like:

Started listener at tcp <IP ADDRESS 1> 4902
Backup Server: 2.24.2.1: The host '<IP ADDRESS 2>' is not authorized to connect to this Backup Server.
Backup Server: 5.40.2.1: Login host authentication has failed.

The root cause of the issue is that backup server does not recognize that IP ADDRESS 1 and IP ADDRESS 2 are the same host and requires a "remote host configuration". Further information about the topic can be found in the ASE documentation in the chapter "Remote Dump Host Control".

Solution

Create text file /sybase/<SID>/hosts.allow with the IP addresses from the backup server log with the following line:

<IP ADDRESS 1> <IP ADDRESS 2>

Set the file ownership to syb<sid>:sapsys with permission 640.
Terminate the running backup server with the OS command 'kill'.
Press the 'retry' button in the SAP installer dialog screen.

Saturday, 7 March 2020

Backup of file system using scripts and moving the backup file to remote server.

 #!/bin/bash
# This script is used to take backup of mount point /var and /etc

tar -cvzf /tmp/backup.tar.gz /var /tmp
find /tmp/backup.tar.gz -mtime +1 -type f -print &> /dev/null
If [ $? -eq 0 ]
        then
        echo backup completed successfully
        echo
 echo moving backup file to backup  server...
   echo .
   echo ..
   echo ...
scp /tmp/backup.tar.gz  root@192.168.1.1 x:/backup/
else
echo backup failed
echo
echo troubleshoot the script
fi

:wq!

Sunday, 8 December 2019

How to start sybase database and Backup server


  1. login with root or user with sudo -i authorization.
  2. su - syb<sid>

the screen looks like below:

hostname> su - syb<sid>
syb<sid>@hostname: 

     3. cd /sybase/sybase_ase/install/RUN_<SID>                        
             startserver -f  RUN_<SID>
Note: the above command is for starting the data server.which enable to start sybase Database.

    4.cd /sybase/sybase_ase_/install/RUN_<SID>_BS
             startserver -f  RUN_<SID>_BS
Note: the above command is for starting the Backup server.which needs while taking backup of server.


  • by performing step 3 and 4, makes the sybase database turn on:
can ensure through the command: ps -ef | grep -i syb<sid>

  1. dataserver
  2. backupserver.
  3. jsagent(job schedule agent).
on linux, a running sybase ASE should have at least the following process.


Thursday, 28 November 2019

Backup



Default location of HANA DB backup.


Thursday, 15 August 2019

cp - to copy the file in linux, to take backup of file in linux

$ cp <file_name>  <file_name.bkp>

ex:
$ cp  Naveen  Naveen_bkp

to copy the file in linux or to take the backup of existing file in linux


Monday, 31 December 2018

HANA DB backup using HANA studio

what is contained in the backup file?

The data backup includes not only data, but also data structure that are required for restore of DB.



why to take backup on regular basis?

To save data during disk failures



Pre-requsites:

DB user with roles: Backup Admin
                                Backup Operator
                                Catalog read
Note: same roles are enough for performing the recovery of HDB also.

SQL query for check the backup size:

select sum (allocated_page_size) from M_converter_Stastistics
select volume id, sum (allocated_page_size) from M_Converter_Stasticstics) group by volume id,

based on the out put of the above query --> make space arrangements.

Process:

Method1
  • Open HANA studio.
  • select the correct system for backup amomgs all systems.
  • Right click
  • choose backup
  • choose type as full / differential /incremental 
  • specify the location and prefix for the backup file.
  • conform 

Method 2

  • Open HANA studio.
  • login to system
  • open hdbsql
  • execute the query:

BACKU DATA USING FILE ('/usr/sap/<SID>/HDBXX/backup/data')