Thursday, 10 November 2011

CIFS Share Migration - Old filer to new filer Migration

Qtree SnapMirror (QSM)

  1. Logical replication
  2. Independent of the type of volume
  3. Source volume and qtree are online/writable
  4. Destination volume is online/writable

Requirements and Limitations for QSM

  1. Supports Async mode only
  2. Destination volume must have 5% extra space
  3. Destination qtree cannot be /etc name
  4. Cannot be initialized using a tape device
  5. Does not support cascading of mirrors
  6. Deep directory structure and large number of small files may impact performance

Migration task :

  1. Here iam going  to copy one cifs shares from source filer to destination filler 
  2. after migration user want to access his shares from destination filer
  3. so we need to do some changes on source and destination
  4. In destination side we need to configure cifs setup and others stuff

Other information:
share name : yogesh
username : yogesh

source> wrfile -a \etc\hosts 192.168.1.3 destination
source> ping 192.168.1.3
source> ping destination 

source> license add ******* => license no
source> options snapmirror.enable on
source> options snapmirror.access host=destination 
source> wrfile -a snapmirror.allow
192.168.1.3 # destination filer ip
destination # secondary filer name
Press CTRL-C to save and exit from the file

source> cifs shares
Name Mount Point Description ---- ----------- ----------- ETC$ /etc Remote Administration BUILTIN\Administrators / Full Control HOME /vol/vol0/home Default Share everyone / Full Control C$ / Remote Administration BUILTIN\Administrators / Full Control qtree /vol/vol1/qtree everyone / Full Control

Switch to Destination Filer for Pre-Check

1. check the filler panic error


# Commands

> check_netapp.pl Hardware -H <hostname|IP> -u  -o <temp|cool|power|nvram|disk>
> disk show -v

2. check rlm/sp is working properly
3. check all the disks are added properly


destination> aggr create aggr1 20
destination> aggr status
destination>  vol create vol1 aggr1 1g
destination> vol status
destination> wrfile -a \etc\hosts 192.168.1.2 source
destination> ping 192.168.1.2
destination>  ping source 
destination> cifs shares -add vol_qtree /vol/vol1/
destination> cifs shares # to check shares
destination > license add ******* => license no
destination> options snapmirror.enable on
destination> options snapmirror.access host=source
destination> wrfile -a snapmirror.allow
192.168.1.2 # source filer ip
source # source filer name
Press CTRL-C to exit and save the file

source> cifs shares
Name Mount Point Description ---- ----------- ----------- ETC$ /etc Remote Administration BUILTIN\Administrators / Full Control HOME /vol/vol0/home Default Share everyone / Full Control C$ / Remote Administration BUILTIN\Administrators / Full Control
vol1 /vol/vol1 everyone / Full Control


dst> vol restrict vol1 # please restrict qtree container volume.

CIFS Setup: we can setup cifs while ontap installation or after installation.

Blue color are some input for cifs setup.

This is after installation


destination > cifs setup This process will enable CIFS access to the filer from a Windows(R) system. Use "?" for help at any prompt and Ctrl-C to exit without committing changes. Your filer does not have WINS configured and is visible only to clients on the same subnet. Do you want to make the system visible via WINS? [n]:


A filer can be configured for multiprotocol access, or as an NTFS-only filer. Since multiple protocols are currently licensed on this filer, we recommend that you configure this filer as a multiprotocol filer (1) Multiprotocol filer (2) NTFS-only filer Selection (1-2)? [1]: 1
IFS requires local /etc/passwd and /etc/group files and default files will be created. The default passwd file contains entries for 'root', 'pcuser', and 'nobody'. Enter the password for the root user []:****** Retype the password:*******
The default name for this CIFS server is 'NETAPP'. Would you like to change this name? [n]:
ata ONTAP CIFS services support four styles of user authentication. Choose the one from the list below that best suits your situation. (1) Active Directory domain authentication (Active Directory domains only) (2) Windows NT 4 domain authentication (Windows NT or Active Directory domains) (3) Windows Workgroup authentication using the filer's local user accounts (4) /etc/passwd and/or NIS/LDAP authentication Selection (1-4)? [1]:1
In order to operate correctly within an Active Directory-based Windows domain, CIFS must use the DNS resolver service. That service is currently not configured on the filer. You must either configure DNS resolver services or choose a different authentication style. Do you want to configure the filer's DNS resolver service? [y]: What is the filer's DNS domain name? []: netapp.com # windows domain name What are the IPv4/IPv6 address(es) of your authoritative DNS name server(s)? : 192.168.1.4  # windows ip address Would you like to specify additional DNS name servers? [n]:n What is the name of the Active Directory domain? [netapp.com]:y
In Active Directory-based domains, it is essential that the filer's time match the domain's internal time so that the Kerberos-based authentication system works correctly. If the time difference between the filer and the domain controllers is more than 5 minutes, authentication will fail. Time services are currently not configured on this filer. Would you like to configure time services? [y]:n
In order to create an Active Directory machine account for the filer, you must supply the name and password of a Windows account with sufficient privileges to add computers to the netapp.COM domain. Enter the name of the Windows user [Administrator@netapp.COM]:administrator Password for administrator: CIFS - Logged in as administrator@netapp.COM. The user that you specified has permission to create the filer's machine account in several (2) containers. Please choose where you would like this account to be created. (1) CN=computers (2) OU=Domain Controllers (3) None of the above Selection (1-3)? [1]:1
IFS - Starting SMB protocol... Sun May 19 19:01:25 GMT [netapp:passwd.changed:info]: passwd for user 'root' changed. It is highly recommended that you create the local administrator account (NETAPP\administrator) for this filer. This account allows access to CIFS from Windows when domain controllers are not accessible. Do you want to create the NETAPP\administrator account? [y]:y Enter the new password for NETAPP\administrator: ******
Retype the password: ******
"NETAPP\administrator"
Welcome to the netapp.COM (CORP) Active Directory(R) domain. 

CIFS local server is running.
********************************************************I************

destination > ping windows_ip
destination> snapmirror initialize -S source:/vol/vol1/qtree destination:/vol/vol1/qtree
destination >
destination > snapmirror status -l vol1 
Snapmirror is on. 
Source: source:vol1 Destination: destination:vol1 
Status: Transferring 
Progress: 24 KB 
Compression Ratio: 4.5 : 1 
State: - Lag: - Mirror 
Timestamp: - Base Snapshot: - 
Current Transfer Type: Initialize 
Current Transfer Error: - 
Contents: - 
Last Transfer Type: Initialize
Last Transfer Size: 132 MB
Last Transfer Duration: 00:00:32 
Last Transfer From: source:vol1

destination > snapmirror update destination:/vol/vol1/qtree

destination >
destination > snapmirror status
Snapmirror is on.
Source                                        Destination                         State                    Lag             Status
source:/vol/vol1/qtree        destination:/vol/vol1/qtree       Snapmirrored           00:02:33           Idle

Note: Now both src and dst filer should have same size and files.

destination > snapmirror quiesce /vol/vol1/qtree        #its file-level so we should quiesce before break
destination > snapmirror break /vol/vol1/qtree           # check now dst volume should be read-write
destination > snapmirror migrate source:/vol/vol1/qtree destination:/vol/vol1/qtree





Note : As of now we copied the data from source filer to destination filer.
Now we need to load the qtree path in /etc/cifs_homedir_cfg.


destination > wrfile -a /etc/cifs_homedir.cfg /vol/vol1/qtree
destination > cifs homedir load -f
destination > cifs homedir showuser yogesh


Note : delete the old share and recreate the new cifs share for destination qtree.

source > cifs shares -delete qtree                                        # delete the old qtree share

destination> cifs shares -add qtree /vol/vol1/qtree              # create new share in new filer

*********************************************************************************

Then go windows user profile properties and change old filer name to new filer name or if you using
DFS software please update for the same






Please write your valuable comments, about my blogspot.






Snapmirror Secondary or Destination configuration of VSM & QSM

Snapmirror Secondary or Destination configuration of VSM  (Volume snapmirror)

primary controller name : src
Secondary controller name : dst

primary controller IP : 192.168.1.2
Secondary controller IP : 192.168.1.3

primary &Secondary  aggregate name: aggr1
primary &Secondary Vol name:vol1

Dst volume size should be same or grater than  the Source  volume

sec>  aggr create aggr1 20
sec>  aggr status
sec>  vol create vol1 aggr1 1g
sec>  vol status

sec>  wrfile -a \etc\hosts 192.168.1.2 src
sec>  ping 192.168.1.2
sec>  ping src

sec>  cifs shares -add vol_share2 /vol/vol1
sec>  cifs shares
sec>  vol restrict vol1
sec>  license add (snapmirror license no)
sec>  license
sec>  snapmirror initialize -S src:vol dst:vol1
sec>  snapmirror status


Switch to windows

Go to Run-> \\dst\vol_share2      # open this path

Now data started copying.




Note :

1. Before Migrate command please check both src and dst datas are in same size and check the total no of file manually.
2. snanpmirror Migrate :  command will release the relationship between src and dst and it will delete the base snapshot from on both side.


Last command:


sec>  snapmirror update  src:vol1 dst:vol1
sec>  snapmirror migrate  src:vol1 dst:vol1






Snapmirror Secondary configuration of QSM (Qtree snap mirror)

sec>  aggr create aggr1 20
sec>  aggr status
sec>  vol create vol1 aggr1 1g
sec>  vol status

sec>  wrfile -a \etc\hosts 192.168.1.2 src
sec>  ping 192.168.1.2
sec>  ping src

sec>  qtree create /vol/vol/qtree
sec>  cifs shares -add qtree_dst /vol/vol1/qtree
sec>  cifs shares
sec>  vol restrict vol1
sec>  license add (snapmirror license no)
sec>  license
sec>  snapmirror initialize -S src:\vol\vol1\qtree dst:\vol\vol1\qtree
sec>  snapmirror status

Switch to windows


Go to Run-> \\dst\vol_share2      # open this path

Now data started copying.

Note :
1. Before migrate command please check the both src and dst datas are in same size and check the total no of file manually.
2. snanpmirror migrate :   command will release the relationship between src and dst and it will delete the base snapshot from on both side.


Last command:


sec>  snapmirror update  src:\vol\vol1\qtree dst:\vol\vol1\qtree
sec> snapmirror migrate  src:\vol\vol1\qtree dst:\vol\vol1\qtree




                                                                                  Snapmirror Sync, Async, Semi-sync configuration

Increasing volume size for snapmirrored volume in destination filer

Steps to increase size for snapmirroed volume on the destination filer
Primary filer name : PRI
Primary Volume name : vol1
Destination filer name : DST
Destination volume name : vol1



Step 1 —  Break the snapmirror to make the DST volume read/writeable

DST> snapmirror break vol1

Step 2 — We need to change the volume option “vol1″ volume fs_size_fixed to off, if its ON we can’t increase volume size directly.

DST> vol options vol1 fs_size_fixed off

Step 3 — Next increase the size of the destination volume

DST> vol size vol1 +1g

Step 4 — Change the fs_size_fixed on before we resume the mirror

DST> options vol1 fs_size_fixed on

Step 5 —  Resync the destination side, to get latest updates from primary volume.

DST> snapmirror resync -S PRI:vol1

Snapmirror source or primary configuration of VSM & QSM

Snapmirror primary or source configuration  for VSM (Volume snapmirror)

primary controller name : src
Secondary controller name : dst

primary controller IP : 192.168.1.2
Secondary controller IP : 192.168.1.3

primary &Secondary  aggregate name: aggr1
primary &Secondary Vol name: vol1



src> aggr create aggr1 20
src> aggr status
src> vol create vol1 aggr1 1g
src> vol status
src> wrfile -a \etc\hosts 192.168.1.3 dst
src> ping 192.168.1.3
src>ping dst
src> license add (license no)
src> license  # to check license
src> options snapmirror.enable on
src> options snapmirror.access host=dst
src> wrfile snapmirror.allow
192.168.1.3 # secondary filer ip
dst    # secondary filer name

Press CTRL-C to exit and save the file


src> cifs shares -add vol_share1 /vol/vol1
src> cifs shares # to check shares




Host (Windows )

windows Start --> Run--> \\src\vol_share1              # Open this path

copy and paste some files  for to view the data replication from Primary to Secondary Replication

--------------*END*------------------




Snapmirror primary configuration  for QSM (Qtree snap mirror)

Storage

src> aggr create aggr1 20
src> aggr status
src> vol create vol1 aggr1 1g
src> vol status
src>wrfile -a \etc\hosts 192.168.1.3 dst
src> ping 192.168.1.3
src> ping dst
src> qtree create /vol/vol1/qtree
src> qtree  # to check qtree
src> cifs shares -add vol_qtree /vol/vol1/qtree
src> cifs shares # to check shares
src> license add (license no)
src> license  # to check license
src> options snapmirror.enable on
src>options snapmirror.access host=dst
src> wrfile snapmirror.allow
192.168.1.3 # secondary filer ip
dst    # secondary filer name
Press CTRL-C to exit and save the file

Host (Windows )

Go to Run-> \\src\vol_qtree  # open this path
copy and paste some files  for to view the data replication from Primary to Secondary Replication

--------------*END*------------------


Snapmirror schedule configuration

Three Type of  Snapmirror Configuration 

 
  • Snapmirroe initialize should run in destination filer only.
  • After initialize the snapmirror , destination filer will move all the data from primary filler to secondary.
  • Now create a new file in /etc/snapmirror.conf for scheduling sync (or) Async (or) semi-sync
  • Because once we excute the initialize and update command in destination side, it will touch the snapmirror.conf in etc path for any snapmirror sechedule.
sync mode

 Its is licensed product
 The source system acknowledges a client write operation only after both the source and destination systems have completed the write operation. The sync option provides a recovery point objective of 0 seconds


sec> license add <snapmirror_sync>
sec> wrfile -a /etc/snapmirror.conf src:vol1   dst:vol1  - sync

Note:
if u created that snapmirror.conf initialize no need to do snapmirror update
if snapmirror initialized just run snapmirror update

sec> snapmirror update -S src:vol1 dsr:vol1   # to enable the /etc/snapmirror.conf file

#  syncs will happen every minute

sec>  snapmirror update  # to enable the /etc/snapmirror.conf file

Async mode

async is not license product.
async will transfer as per schedule..

sec> wrfile -a /etc/snapmirror.conf src:vol1   dst:vol1 - 0 23 * *

Note:
if u created that snapmirror.conf initialize no need to do snapmirror update
if snapmirror initialized just run snapmirror update
 
sec>   snapmirror update -S src:vol1 dst:vol1    # to enable the /etc/snapmirror.conf file

#  syncs will happen at every 11:00 pm

Semi sync mode
 Its is licensed product.
The source system acknowledges the client write operation immediately after the source receives the data. The destination system is synchronized with the source at intervals of approximately 10 seconds. The semi-sync option provides a recovery point objective of about 10 seconds. This means that if the source becomes unavailable, you might lose up to 10 seconds worth of data changes. The semi-sync mode provides a performance advantage over the sync mode.
license name snapmirror_sync
 

sec> license add <snapmirror_sync>
sec> wrfile -a /etc/snapmirror.conf src:vol1   dst:vol1  - semi-sync
 
Note:
if u created that snapmirror.conf initialize no need to do snapmirror update
if snapmirror initialized just run snapmirror update


sec> snapmirror update -S src:vol1   dst:vol1     # to enable the /etc/snapmirror.conf file

data transfer will happen after 10sec after scheduling

 
 
 
 
Please write your valuable comments, about my blogspot.

SnapMirror

Snapmirror:

  1. Snapmirror is a license product in Netapp.
  2. SnapMirror is for Disaster recovery and its Loss of region.
  3. – Disaster Recovery
    – Data migration
    – Data replication
    – Remote access and load sharing
  4. Using snapmirror data transfer one filer to another filer or in same filer.
  5. Snapmirror will work at Volume and Qtree level.
  6. Snapmirrror needs a source and destination filer.
  7. Snapmirror is used primarily for data redundancy
  8. Real time replication of data
  9. Maximum distance of up to 35km
  10. Fibre Channel or DWDM protocol
In snapmirror 3 mode of data replication

Sync                = data transfer continually  
Async              = data transfer in scheduled timing
Semi-sync       =  like Async

Requirements and Limitations for VSM

  1. Destination’s Data ONTAP® version must be equal to or more recent than the source
  2. Like-to-like transfers only: flex-to-flex
  3. Destination volume capacity should be equal or greater than source
  4. Quota cannot be enabled on destination volume
  5. TCP port range 10565–10569 must be open

Qtree SnapMirror (QSM)

  1. Logical replication
  2. Independent of the type of volume
  3. Source volume and qtree are online/writable
  4. Destination volume is online/writable
  5. Destination qtree is read-only

Requirements and Limitations for QSM

  1. Supports Async mode only
  2. Destination volume must have 5% extra space
  3. Destination qtree cannot be /etc name
  4. Cannot be initialized using a tape device
  5. Does not support cascading of mirrors
  6. Deep directory structure and large number of small files may impact performance

Snapmirror primary configuration of VSM & QSM

Snapmirror Secondary configuration of VSM & QSM


Wednesday, 9 November 2011

Snapshot

Snapshot  

  • Snapshot technology enables you to create point-in-time copies of file systems.
  • You can use Snapshot technology while applications are running and to create Snapshot copies in less than a second.
  • Storing a Snapshot copy on a NetApp system has no performance impact while creating and deleting Snapshot copies.
  • Make up to 255 Snapshot copies per volume.
  • When we create a weekly, nightly, or hourly snapshot, the lowest value is newly created snapshot and highest value is older snapshot.

Snapshot space consumption


  • Snapshot will not take space while creating new snapshot until the file deleted. 
  • We have 3 files in the volume and each file having 10mb of size. At this time when we creating new snap1 and the snapshot size is little 4kb Size only. Because the snapshot pointing only the inodes, after you delete one file in the volume now the snap1 size should be the deleted file size. 


Snapshot Technologies

SnapDrive
SnapManager
SnapRestore
SnapMirror
SnapVault
FlexClone 
 

Commands related to Netapp Snapshot Management

All of the snap commands take the options -A and -V. to specify –A for Aggregate and –V for Volume

Volume creation commands 


To view snapshot of volume

bang> snap list vol1
Volume vol1
working...
%/used %/total date name
---------- ---------- ------------ --------
37% (37%) 0% ( 0%) Dec 02 16:00 hourly.0
51% (33%) 0% ( 0%) Dec 02 12:00 hourly.1
62% (36%) 0% ( 0%) Dec 02 08:00 hourly.2
63% (15%) 0% ( 0%) Dec 02 00:01 nightly.0
70% (46%) 0% ( 0%) Dec 01 20:00 hourly.3
74% (46%) 0% ( 0%) Dec 01 16:00 hourly.4
78% (56%) 0% ( 0%) Dec 01 00:01 nightly.1

To take snapshots manually

Snapshot Rename


Snapshot delete


Snapshot Disable

Command : 

vol options vol_name nosnap on

                (or) 

snap sched vol_name 000

the both command will not take snapshot for that specific volume.

Snapshot scheduling


  1. Retain up to 255 Snapshot copies per volume for any schedule.
  2. Scheduling for automatic snapshot to keep 2 weekly, 2 daily, 4 hourly(take at 2,6,10,12) online.


Snapshot Space Reservation

I. Default snapshot space reserve is 20% of the volume size
II. Changing the snapshot reserve to 5% of the volume size


Now the snapshot avail space changed 40mb to 10mb


Snap restore


  • Snap restore is license product in Netapp.
  • Restore the volume (or) file state as it is when snapshot is taken.
  • Recover entire volumes or individual files in seconds.


File restore using snapshot

I. We can restore the specific file or Lun in the volume


 Snap autodelete

  • Snap autodelete is used to automatically delete the old snapshots in the flexible volume. 
  • When the volume is nearly full, the old Snapshot copies will delete automatically. 
  • Snap autodelete future works together with try_first controls.
Syntax:

Bang1> snap autodelete vol_name on | off 

Bang1> vol options vol-name try_first [volume_grow|snap_delete]

To enable snap autodelete

Bang1> snap autodelete vol1 on

Bang1> vol options vol1 try_first "snap_delete"

Snap delta 


It estimate rate of change of data between two different snapshots copies in the volume

Syntax: 

Snap delta from hourly.0 to hourly.1 

Bang1>  snap delta vol_name hourly.0 hourly.1 

Snap delta from nightly.0 to hourly.1

Bang1>  snap delta vol_name nightly.0 hourly.1

Disable Snapshot folder to client


We can disable the snapshot folder to client access using snap vol options

Bang1> options cifs.show_snapshot off | on









Please write your valuable comments, about my blogspot.