Subscribe

Specify specific interface for snapmirror replication

Hi there,

I was wondering how I go about specifying what interface snapmirror has to use?

The replication link (1Gb dedicated) should go over interface destination_filer-rep and source_filer-rep

The hostname is in the destination_filer and source_filer format

On my source I specify in /etc/snapmirror.allow:

destination_filer-rep

On my destination I specify in /etc/snapmirror.allow:

source_filer-rep

On my destination under snapmirror.conf I have

source_filer-rep:vol1 destination_filer-rep:vol1 ,restart=always 15 * * 1,2,3,4,5

When I do an initialize with snapmirror initialize -S source_filer-rep:vol1 destination_filer-rep:vol1 I get an error

saying

Illegal destination filer specification: destination_filer-rep.
Destination filer, if specified, must match the local host: destination_filer

I can get snapmirror to go over the hostname interfaces but obviously we want to make use of dedicated link.
We don't have a need for multipath at this stage

Re: Specify specific interface for snapmirror replication

Hello again!

You need to set up a named path in /etc/snapmirror.conf and then use that named path as the source.  The man page for snapmirror.conf (find it in section 5.  FilerView has a nice way to view man pages) explains this pretty well.  You can set up a 'multi' type even if you have 1 IP pair.

Feel free to post follow-ups here.  I'll be glad to help.

Re: Specify specific interface for snapmirror replication

Hi Adam,

Not sure if I am looking at the right section but I think this is relevant

       The  following  snapmirror.conf  entry indi-
       cates that filer myfiler1's volume home_mir-
       ror   will   mirror   volume  home  via  the
       myfiler0-gig interface.   (The  myfiler0-gig
       interface  is  whatever  IP address myfiler1
       can resolve that name to.  In this case,  it
       might  be  a  gigabit ethernet link on filer
       myfiler0.)  The mirror is  updated  at  9:30
       a.m.,  1:30  p.m.,  and  7:30  p.m.,  Monday
       through Friday.  The asterisk means that the
       data replication schedule is not affected by
       the day of month; it is the same as entering
       numbers  1  through  31 (comma-separated) in
       that space.  The dash in the arguments field
       indicates  that  both  the  kbs  and restart
       arguments are set to default.

       myfiler0-gig:home myfiler1:home_mirror - 30 9,13,19 * 1,2,3,4,5

I tried this but I get the following errors:

On destination: SnapMirror: destination transfer from source-rep:vol1 to sm_vol1 : could not read from socket.
Transfer aborted: could not read from socket.

I noticed that the destination filer does not appear in error, just its volume

On source:  snapmirror.src.sockErr:error]: Cannot accept SnapMirror destination requests: Access denied for SnapMirror/SnapVault destination.

Excuse my ignorance but how would I use filerview to view manpages? I could not see so used CLI

Cheers

Re: Specify specific interface for snapmirror replication

Here are some relevant sections:

The other type of line allowed in this file is a connec_tion definition line. These lines define an alternate name for the source filer that can be used as the source host in the relationship lines. They are used to describe more specifically the parameters for the connection(s) to the source filer. SnapMirror supports the multi path specification for both asynchronous and synchronous mirrors.

Each connection definition is a single line giving a name to one or two pairs of IP addresses along with a mode of operation for the connection. The lines are specified in the following format:

name = mode( source_ip_addr1 , dest_ip_addr1 ) ( source_ip_addr2 , dest_ip_addr2 )

name This is the name of the connection you would like to define. This name is to be used as the source filer in relationship definitions.

mode The mode is optional and specifies the mode in which two IP address pairs will be used. Two modes are allowed multiplexing and failover mode and are specified by using the multi and failover keywords. If not specified, multiplexing mode is used.

The multiplexing mode causes snapmirror to use both paths at the same time. If one should fail, it will switch to use the remaining path only and use both again should the failing path be repaired.

Failover mode causes snapmirror to use the first path as the desired path and only use the second path should problems arise with the first path.

So you can create a multi type connection:

mypath = multi(src,dest)

mypath:<srdvol> dest:<dest_vol> ...... < insert schedule here.

Right after you login, you'll see a list of links. The first enters FilerView, but down below should be a link for man pages.  That's a pretty good man page viewer in my opinion.  It's probably what I use FilerView for the most.

Re: Specify specific interface for snapmirror replication

Hi Adam,

Still no luck.

My snapmirror.conf looks like this

mypath = multi(source-rep,destination-rep)

mypath:vol1 destination:vol1 ,restart=always 15 * * 1,2,3,4,5

I still get the same errors.

I can ping all the interfaces involved from both filers. However, they are returned with their interface name.
Could my order in the hosts file have anything to do with problems?


10.92.96.12          source-e2d source-rep


192.168.1.32        source-vif1_ag-200 source

Cheers

Re: Specify specific interface for snapmirror replication

Order of the host file shouldn't matter.  This is looking more like a snapmirror access issue on the source.  You may want to open a case to get someone to work on it directly with you, but it's looking like either the service is not turned on, or more likely the access is not set up correctly.

Re: Specify specific interface for snapmirror replication

If the destination is not instantiating the snapmirror from the right interface you can try to add a route on the destination to the source filer by pointing to the gateway of the interface you want it to go out of.  Also check the option snapmirror.access.  In order to use snapmirror.allow you have to set it to legacy.

Re: Specify specific interface for snapmirror replication

Hi guys,

One of my filer's did not have legacy so that could explain it. I will need to test it again.

I did try it with two different filer's and that seemed to work over the dedicated link. A few more questions though

In my snapmirror.conf I have

mypath = multi(source-rep,dest-rep)

mypath:vol1 dest:sm_vol1 ,restart=always 15 * * 1,2,3,4,5

Earlier on I ran a manual update

snapmirror update -S mypath:vol1 dest:sm_vol1

I get the message it cannot connect to the source. When I replace mypath with source-rep it works.

Is that the behaviour you would expect?

The schedule does not seem to work anymore either after I changed to the replication link.

Is this because I specified source when I originally initialized it?

When I looked at the lag time it was nearly two hours.

It is my understandig lag is the time passed since last execution?

Here is some output of my log.

dst Tue Mar 23 14:31:42 NZD source:vol dest:sm_vol1 Request (Initialize)
dst Tue Mar 23 14:31:46 NZD source:vol dest:sm_vol1 Start
dst Tue Mar 23 15:44:44 NZD source:vol dest:sm_vol1 End (216835208 KB)
dst Wed Mar 24 10:15:00 NZD source:vol dest:sm_vol1 Request (Scheduled)
dst Wed Mar 24 10:15:02 NZD source:vol dest:sm_vol1 Start
dst Wed Mar 24 10:15:31 NZD source:vol dest:sm_vol1 End (715040 KB)
dst Wed Mar 24 11:15:00 NZD source:vol dest:sm_vol1 Request (Scheduled)
dst Wed Mar 24 11:15:05 NZD source:vol dest:sm_vol1 Start
dst Wed Mar 24 11:15:32 NZD source:vol dest:sm_vol1 End (733704 KB)
sys Wed Mar 24 12:04:11 NZD SnapMirror_off (registry)
sys Thu Mar 25 09:50:29 NZD SnapMirror_on (registry)
dst Thu Mar 25 10:02:46 NZD mypath:vol dest:sm_vol1 Request (Update)
dst Thu Mar 25 10:02:46 NZD mypath:vol dest:sm_vol1 Abort (cannot connect to source filer)
dst Thu Mar 25 10:05:32 NZD mypath:vol dest:sm_vol1 Request (Update)
dst Thu Mar 25 10:05:32 NZD mypath:vol dest:sm_vol1 Abort (cannot connect to source filer)
dst Thu Mar 25 10:21:17 NZD mypath:vol dest:sm_vol1 Request (Update)
dst Thu Mar 25 10:21:17 NZD mypath:vol dest:sm_vol1 Abort (cannot connect to source filer)
dst Thu Mar 25 10:23:54 NZD source-rep:vol dest:sm_vol1 Request (Update)
dst Thu Mar 25 10:23:56 NZD source-rep:vol dest:sm_vol1 Start
dst Thu Mar 25 10:35:40 NZD source-rep:vol dest:sm_vol1 End (6309552 KB)
dst Thu Mar 25 12:17:53 NZD mypath:vol dest:sm_vol1 Request (Update)
dst Thu Mar 25 12:17:53 NZD mypath:vol dest:sm_vol1(cannot connect to source filer)
dst Thu Mar 25 12:18:56 NZD source-rep:vol dest:sm_vol1 Request (Update)
dst Thu Mar 25 12:18:59 NZD source-rep:vol dest:sm_vol1 Start
dst Thu Mar 25 12:20:42 NZD source-rep:vol dest:sm_vol1End (1105456 KB)
d

Re: Specify specific interface for snapmirror replication

Yeah, here's the trick on that.  The command line doesn't accept the named connections.  However, since you have a snapmirror entry already in snapmirror.conf, just drop the -S flag and only specify the destination volume and it should read the file and do the right thing.

So it would look more like this:

snapmirror update sm_vol1

Hope this helps.

Re: Specify specific interface for snapmirror replication

Thanks Adam,

I get this when specifying snapmirror update sm_vol1


Source not set on command line or in /etc/snapmirror.conf file.


dest> rdfile /etc/snapmirror.conf
mypath = multi(source-rep,dest-rep)
mypath:vol1 dest-rep:sm_vol1 ,restart=always 15 * * 1,2,3,4,5