Opened 15 years ago

Closed 15 years ago

#304 closed defect (fixed)

-n options unable to discover NFS mount by hostname instead of IP

Reported by: clotho Owned by: Bruno Cornec
Priority: normal Milestone: 2.2.9
Component: mondo Version: 2.2.7
Severity: normal Keywords:
Cc:

Description

I have a machine with hostname "node01" and IP "192.168.1.1"

The command "mondoarchive -On 192.168.1.1:/mnt/nfs" fails with error "NFS share is not mounted. Please mount it." while "mondoarchive -On node01:/mnt/nfs" successes.

From source code, I find that at line 646 of mondo-cli.c http://www.mondorescue.org/cgi-bin/trac.cgi/browser/branches/stable/mondo/src/mondoarchive/mondo-cli.c?rev=910

At the fail case, the code grep "192.168.1.1:/mnt/nfs .*" from output of mount. However, As I mount the export by hostname, the output of mount is

node01:/mnt/nfs on /mnt/nfs type nfs (rw,addr=192.168.1.1)

Therefore the grep fails.

Change History (3)

comment:1 by Bruno Cornec, 15 years ago

Milestone: 2.2.82.2.9
Status: newassigned

comment:2 by clotho, 15 years ago

Moreover, if there is a '/' at end of the export, mondorescue also fails to detect it. For example,

node01:/mnt/nfs/ on /mnt/nfs type nfs (rw,addr=192.168.1.1) 192.168.1.1:/mnt/nfs/ on /mnt/nfs type nfs (rw,addr=192.168.1.1)

comment:3 by Bruno Cornec, 15 years ago

Resolution: fixed
Status: assignedclosed

Should be fixed (at least partly) with rev [2223], even if in your case it would mount the NFS dir twice then probably.

Note: See TracTickets for help on using tickets.